mirror of
https://github.com/MariaDB/server.git
synced 2026-05-07 07:35:32 +02:00
MDEV-8139: Clean up the freeing of B-tree pages
btr_page_free(): Renamed from btr_page_free_low(). If scrubbing is enabled, zero out the page with proper redo logging. Only pass ahi=true to fseg_free_page() if the page is actually indexed. fil_space_t::modify_check(): Renamed from fsp_space_modify_check(). fsp_init_file_page(): Define inline.
This commit is contained in:
parent
e124ff17e0
commit
4b822111ef
7 changed files with 98 additions and 218 deletions
|
|
@ -688,6 +688,26 @@ fsp_descr_page(
|
|||
@param[in,out] block buffer pool block */
|
||||
void fsp_apply_init_file_page(buf_block_t* block);
|
||||
|
||||
/** Initialize a file page.
|
||||
@param[in] space tablespace
|
||||
@param[in,out] block file page
|
||||
@param[in,out] mtr mini-transaction */
|
||||
inline void fsp_init_file_page(
|
||||
#ifdef UNIV_DEBUG
|
||||
const fil_space_t* space,
|
||||
#endif
|
||||
buf_block_t* block, mtr_t* mtr)
|
||||
{
|
||||
ut_d(space->modify_check(*mtr));
|
||||
ut_ad(space->id == block->page.id.space());
|
||||
fsp_apply_init_file_page(block);
|
||||
mlog_write_initial_log_record(block->frame, MLOG_INIT_FILE_PAGE2, mtr);
|
||||
}
|
||||
|
||||
#ifndef UNIV_DEBUG
|
||||
# define fsp_init_file_page(space, block, mtr) fsp_init_file_page(block, mtr)
|
||||
#endif
|
||||
|
||||
#ifdef UNIV_BTR_PRINT
|
||||
/*******************************************************************//**
|
||||
Writes info of a segment. */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue