• Marko Mäkelä's avatar
    MDEV-10813: Update buf_page_t::buf_fix_count outside mutex · 2c8d9a4e
    Marko Mäkelä authored
    Since MySQL 5.6.16 (and MariaDB Server 10.0.11), changes of
    buf_page_t::buf_fix_count are atomic memory operations if
    PAGE_ATOMIC_REF_COUNT is defined. Since MySQL 5.7
    (and MariaDB Server 10.2.2), the field is always updated
    by atomic memory operations.
    
    In a few occurrences, updates of the counter were unnecessarily
    surrounded by an acquisition and release of the block mutex
    (buf_block_t::mutex or buf_pool_t::zip_mutex). Remove these
    unnecessary mutex operations.
    2c8d9a4e
btr0cur.cc 229 KB