Commit 91546e7d authored by marko's avatar marko

branches/zip: buf_LRU_free_block(): When freeing the uncompressed page

of a dirty block, relocate the control blocks on buf_pool->flush_list
instead of calling buf_flush_insert_into_flush_list().
parent b68c7012
...@@ -1008,7 +1008,28 @@ buf_LRU_free_block( ...@@ -1008,7 +1008,28 @@ buf_LRU_free_block(
if (b->state == BUF_BLOCK_ZIP_PAGE) { if (b->state == BUF_BLOCK_ZIP_PAGE) {
buf_LRU_insert_zip_clean(b); buf_LRU_insert_zip_clean(b);
} else { } else {
buf_flush_insert_into_flush_list(b); buf_page_t* prev;
ut_ad(b->in_flush_list);
ut_d(bpage->in_flush_list = FALSE);
prev = UT_LIST_GET_PREV(list, b);
UT_LIST_REMOVE(list,
buf_pool->flush_list,
b);
if (prev) {
ut_ad(prev->in_flush_list);
UT_LIST_INSERT_AFTER(
list,
buf_pool->flush_list,
prev, b);
} else {
UT_LIST_ADD_FIRST(
list,
buf_pool->flush_list,
b);
}
} }
mutex_enter(block_mutex); mutex_enter(block_mutex);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment