• Marko Mäkelä's avatar
    Bug #58549 Race condition in buf_LRU_drop_page_hash_for_tablespace() · 8da1dfa9
    Marko Mäkelä authored
    and compressed tables
    
    buf_LRU_drop_page_hash_for_tablespace(): after releasing and
    reacquiring the buffer pool mutex, do not dereference any block
    descriptor pointer that is not known to be a pointer to an
    uncompressed page frame (type buf_block_t; state ==
    BUF_BLOCK_FILE_PAGE). Also, defer the acquisition of the block_mutex
    until it is needed.
    
    buf_page_get_gen(): Add mode == BUF_GET_IF_IN_POOL_PEEK for
    buffer-fixing a block without making it young in the LRU list.
    
    buf_page_get_gen(), buf_page_init(), buf_LRU_block_remove_hashed_page():
    Set bpage->state = BUF_BLOCK_ZIP_FREE before buf_buddy_free(bpage),
    so that similar race conditions might be detected a little easier.
    
    btr_search_drop_page_hash_when_freed(): Use BUF_GET_IF_IN_POOL_PEEK
    when dropping the hash indexes.
    
    rb://528 approved by Jimmy Yang
    8da1dfa9
To find the state of this project's repository at the time of any of these versions, check out the tags.
ChangeLog 66.7 KB