summaryrefslogtreecommitdiff
path: root/src/third_party/wiredtiger/src/include/reconcile.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/third_party/wiredtiger/src/include/reconcile.h')
-rw-r--r--src/third_party/wiredtiger/src/include/reconcile.h89
1 files changed, 37 insertions, 52 deletions
diff --git a/src/third_party/wiredtiger/src/include/reconcile.h b/src/third_party/wiredtiger/src/include/reconcile.h
index 22f63ae4ff4..1c02f8353c6 100644
--- a/src/third_party/wiredtiger/src/include/reconcile.h
+++ b/src/third_party/wiredtiger/src/include/reconcile.h
@@ -33,12 +33,9 @@ struct __wt_reconcile {
/* Track the page's min/maximum transactions. */
uint64_t max_txn;
- wt_timestamp_t max_timestamp;
-
- /* Lookaside boundary tracking. */
- uint64_t unstable_txn;
- wt_timestamp_t unstable_durable_timestamp;
- wt_timestamp_t unstable_timestamp;
+ wt_timestamp_t max_ts;
+ wt_timestamp_t max_ondisk_ts;
+ wt_timestamp_t min_skipped_ts;
u_int updates_seen; /* Count of updates seen. */
u_int updates_unstable; /* Count of updates not visible_all. */
@@ -56,43 +53,36 @@ struct __wt_reconcile {
bool leave_dirty;
/*
- * Track if reconciliation has seen any overflow items. If a leaf page
- * with no overflow items is written, the parent page's address cell is
- * set to the leaf-no-overflow type. This means we can delete the leaf
- * page without reading it because we don't have to discard any overflow
+ * Track if reconciliation has seen any overflow items. If a leaf page with no overflow items is
+ * written, the parent page's address cell is set to the leaf-no-overflow type. This means we
+ * can delete the leaf page without reading it because we don't have to discard any overflow
* items it might reference.
*
- * The test test is per-page reconciliation, that is, once we see an
- * overflow item on the page, all subsequent leaf pages written for the
- * page will not be leaf-no-overflow type, regardless of whether or not
- * they contain overflow items. In other words, leaf-no-overflow is not
- * guaranteed to be set on every page that doesn't contain an overflow
- * item, only that if it is set, the page contains no overflow items.
- * XXX
- * This was originally done because raw compression couldn't do better,
- * now that raw compression has been removed, we should do better.
+ * The test test is per-page reconciliation, that is, once we see an overflow item on the page,
+ * all subsequent leaf pages written for the page will not be leaf-no-overflow type, regardless
+ * of whether or not they contain overflow items. In other words, leaf-no-overflow is not
+ * guaranteed to be set on every page that doesn't contain an overflow item, only that if it is
+ * set, the page contains no overflow items. XXX This was originally done because raw
+ * compression couldn't do better, now that raw compression has been removed, we should do
+ * better.
*/
bool ovfl_items;
/*
- * Track if reconciliation of a row-store leaf page has seen empty (zero
- * length) values. We don't write out anything for empty values, so if
- * there are empty values on a page, we have to make two passes over the
- * page when it's read to figure out how many keys it has, expensive in
- * the common case of no empty values and (entries / 2) keys. Likewise,
- * a page with only empty values is another common data set, and keys on
- * that page will be equal to the number of entries. In both cases, set
- * a flag in the page's on-disk header.
+ * Track if reconciliation of a row-store leaf page has seen empty (zero length) values. We
+ * don't write out anything for empty values, so if there are empty values on a page, we have to
+ * make two passes over the page when it's read to figure out how many keys it has, expensive in
+ * the common case of no empty values and (entries / 2) keys. Likewise, a page with only empty
+ * values is another common data set, and keys on that page will be equal to the number of
+ * entries. In both cases, set a flag in the page's on-disk header.
*
- * The test is per-page reconciliation as described above for the
- * overflow-item test.
+ * The test is per-page reconciliation as described above for the overflow-item test.
*/
bool all_empty_value, any_empty_value;
/*
- * Reconciliation gets tricky if we have to split a page, which happens
- * when the disk image we create exceeds the page type's maximum disk
- * image size.
+ * Reconciliation gets tricky if we have to split a page, which happens when the disk image we
+ * create exceeds the page type's maximum disk image size.
*
* First, the target size of the page we're building.
*/
@@ -106,31 +96,26 @@ struct __wt_reconcile {
uint32_t min_split_size; /* Minimum split page size */
/*
- * We maintain two split chunks in the memory during reconciliation to
- * be written out as pages. As we get to the end of the data, if the
- * last one turns out to be smaller than the minimum split size, we go
- * back into the penultimate chunk and split at this minimum split size
- * boundary. This moves some data from the penultimate chunk to the last
- * chunk, hence increasing the size of the last page written without
- * decreasing the penultimate page size beyond the minimum split size.
- * For this reason, we maintain an expected split percentage boundary
- * and a minimum split percentage boundary.
+ * We maintain two split chunks in the memory during reconciliation to be written out as pages.
+ * As we get to the end of the data, if the last one turns out to be smaller than the minimum
+ * split size, we go back into the penultimate chunk and split at this minimum split size
+ * boundary. This moves some data from the penultimate chunk to the last chunk, hence increasing
+ * the size of the last page written without decreasing the penultimate page size beyond the
+ * minimum split size. For this reason, we maintain an expected split percentage boundary and a
+ * minimum split percentage boundary.
*
- * Chunks are referenced by current and previous pointers. In case of a
- * split, previous references the first chunk and current switches to
- * the second chunk. If reconciliation generates more split chunks, the
- * the previous chunk is written to the disk and current and previous
- * swap.
+ * Chunks are referenced by current and previous pointers. In case of a split, previous
+ * references the first chunk and current switches to the second chunk. If reconciliation
+ * generates more split chunks, the previous chunk is written to the disk and current and
+ * previous swap.
*/
struct __wt_rec_chunk {
/*
- * The recno and entries fields are the starting record number
- * of the split chunk (for column-store splits), and the number
- * of entries in the split chunk.
+ * The recno and entries fields are the starting record number of the split chunk (for
+ * column-store splits), and the number of entries in the split chunk.
*
- * The key for a row-store page; no column-store key is needed
- * because the page's recno, stored in the recno field, is the
- * column-store key.
+ * The key for a row-store page; no column-store key is needed because the page's recno,
+ * stored in the recno field, is the column-store key.
*/
uint32_t entries;
uint64_t recno;