|
|
@ -306,25 +306,12 @@ public: |
|
|
|
/** @return true if we are inside the change buffer code */ |
|
|
|
bool is_inside_ibuf() const { return m_inside_ibuf; } |
|
|
|
|
|
|
|
/** Note that system tablespace page has been freed. */ |
|
|
|
void freed_system_tablespace_page() { m_freed_in_system_tablespace= true; } |
|
|
|
|
|
|
|
/** Note that pages has been trimed */ |
|
|
|
void set_trim_pages() { m_trim_pages= true; } |
|
|
|
|
|
|
|
/** @return true if pages has been trimed */ |
|
|
|
bool is_trim_pages() { return m_trim_pages; } |
|
|
|
|
|
|
|
/** @return whether a page_compressed table was modified */ |
|
|
|
bool is_page_compressed() const |
|
|
|
{ |
|
|
|
#if defined(HAVE_FALLOC_PUNCH_HOLE_AND_KEEP_SIZE) || defined(_WIN32) |
|
|
|
return m_user_space && m_user_space->is_compressed(); |
|
|
|
#else |
|
|
|
return false; |
|
|
|
#endif |
|
|
|
} |
|
|
|
|
|
|
|
/** Latch a buffer pool block. |
|
|
|
@param block block to be latched |
|
|
|
@param rw_latch RW_S_LATCH, RW_SX_LATCH, RW_X_LATCH, RW_NO_LATCH */ |
|
|
@ -377,12 +364,6 @@ public: |
|
|
|
|
|
|
|
/** @return the memo stack */ |
|
|
|
mtr_buf_t* get_memo() { return &m_memo; } |
|
|
|
|
|
|
|
/** @return true if system tablespace page has been freed */ |
|
|
|
bool is_freed_system_tablespace_page() |
|
|
|
{ |
|
|
|
return m_freed_in_system_tablespace; |
|
|
|
} |
|
|
|
#endif /* UNIV_DEBUG */ |
|
|
|
|
|
|
|
/** @return true if a record was added to the mini-transaction */ |
|
|
@ -588,12 +569,18 @@ public: |
|
|
|
const char *new_path= nullptr); |
|
|
|
|
|
|
|
/** Add freed page numbers to freed_pages */ |
|
|
|
void add_freed_offset(page_id_t id) |
|
|
|
void add_freed_offset(fil_space_t *space, uint32_t page) |
|
|
|
{ |
|
|
|
ut_ad(m_user_space == NULL || id.space() == m_user_space->id); |
|
|
|
ut_ad(is_named_space(space)); |
|
|
|
if (!m_freed_pages) |
|
|
|
{ |
|
|
|
m_freed_pages= new range_set(); |
|
|
|
m_freed_pages->add_value(id.page_no()); |
|
|
|
ut_ad(!m_freed_space); |
|
|
|
m_freed_space= space; |
|
|
|
} |
|
|
|
else |
|
|
|
ut_ad(m_freed_space == space); |
|
|
|
m_freed_pages->add_value(page); |
|
|
|
} |
|
|
|
|
|
|
|
/** Determine the added buffer fix count of a block. |
|
|
@ -671,9 +658,6 @@ private: |
|
|
|
to suppress some read-ahead operations, @see ibuf_inside() */ |
|
|
|
uint16_t m_inside_ibuf:1; |
|
|
|
|
|
|
|
/** whether the page has been freed in system tablespace */ |
|
|
|
uint16_t m_freed_in_system_tablespace:1; |
|
|
|
|
|
|
|
/** whether the pages has been trimmed */ |
|
|
|
uint16_t m_trim_pages:1; |
|
|
|
|
|
|
@ -695,6 +679,8 @@ private: |
|
|
|
/** LSN at commit time */ |
|
|
|
lsn_t m_commit_lsn; |
|
|
|
|
|
|
|
/** tablespace where pages have been freed */ |
|
|
|
fil_space_t *m_freed_space= nullptr; |
|
|
|
/** set of freed page ids */ |
|
|
|
range_set *m_freed_pages= nullptr; |
|
|
|
}; |
|
|
|