|
PostgreSQL Source Code git master
|


Go to the source code of this file.
Data Structures | |
| struct | TidStoreIterResult |
Typedefs | |
| typedef struct TidStore | TidStore |
| typedef struct TidStoreIter | TidStoreIter |
| typedef struct TidStoreIterResult | TidStoreIterResult |
Functions | |
| TidStore * | TidStoreCreateLocal (size_t max_bytes, bool insert_only) |
| TidStore * | TidStoreCreateShared (size_t max_bytes, int tranche_id) |
| TidStore * | TidStoreAttach (dsa_handle area_handle, dsa_pointer handle) |
| void | TidStoreDetach (TidStore *ts) |
| void | TidStoreLockExclusive (TidStore *ts) |
| void | TidStoreLockShare (TidStore *ts) |
| void | TidStoreUnlock (TidStore *ts) |
| void | TidStoreDestroy (TidStore *ts) |
| void | TidStoreSetBlockOffsets (TidStore *ts, BlockNumber blkno, OffsetNumber *offsets, int num_offsets) |
| bool | TidStoreIsMember (TidStore *ts, const ItemPointerData *tid) |
| TidStoreIter * | TidStoreBeginIterate (TidStore *ts) |
| TidStoreIterResult * | TidStoreIterateNext (TidStoreIter *iter) |
| int | TidStoreGetBlockOffsets (TidStoreIterResult *result, OffsetNumber *offsets, int max_offsets) |
| void | TidStoreEndIterate (TidStoreIter *iter) |
| size_t | TidStoreMemoryUsage (TidStore *ts) |
| dsa_pointer | TidStoreGetHandle (TidStore *ts) |
| dsa_area * | TidStoreGetDSA (TidStore *ts) |
Definition at line 20 of file tidstore.h.
| typedef struct TidStoreIter TidStoreIter |
Definition at line 21 of file tidstore.h.
| typedef struct TidStoreIterResult TidStoreIterResult |
| TidStore * TidStoreAttach | ( | dsa_handle | area_handle, |
| dsa_pointer | handle | ||
| ) |
Definition at line 244 of file tidstore.c.
References TidStore::area, Assert(), dsa_attach(), DSA_HANDLE_INVALID, DsaPointerIsValid, palloc0(), TidStore::shared, and TidStore::tree.
Referenced by parallel_vacuum_main().
| TidStoreIter * TidStoreBeginIterate | ( | TidStore * | ts | ) |
Definition at line 471 of file tidstore.c.
References TidStore::local, TidStoreIter::local, palloc0(), TidStore::shared, TidStoreIter::shared, TidStoreIsShared, TidStore::tree, TidStoreIter::tree_iter, and TidStoreIter::ts.
Referenced by check_set_block_offsets(), and lazy_vacuum_heap_rel().
| TidStore * TidStoreCreateLocal | ( | size_t | max_bytes, |
| bool | insert_only | ||
| ) |
Definition at line 162 of file tidstore.c.
References ALLOCSET_DEFAULT_INITSIZE, ALLOCSET_DEFAULT_MAXSIZE, ALLOCSET_DEFAULT_MINSIZE, AllocSetContextCreate, BumpContextCreate(), CurrentMemoryContext, TidStore::local, palloc0(), TidStore::rt_context, and TidStore::tree.
Referenced by dead_items_alloc(), dead_items_reset(), and test_create().
| TidStore * TidStoreCreateShared | ( | size_t | max_bytes, |
| int | tranche_id | ||
| ) |
Definition at line 208 of file tidstore.c.
References TidStore::area, dsa_create_ext(), DSA_DEFAULT_INIT_SEGMENT_SIZE, DSA_MAX_SEGMENT_SIZE, DSA_MIN_SEGMENT_SIZE, palloc0(), TidStore::shared, and TidStore::tree.
Referenced by parallel_vacuum_init(), parallel_vacuum_reset_dead_items(), and test_create().
| void TidStoreDestroy | ( | TidStore * | ts | ) |
Definition at line 317 of file tidstore.c.
References TidStore::area, dsa_detach(), TidStore::local, MemoryContextDelete(), pfree(), TidStore::rt_context, TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by dead_items_reset(), parallel_vacuum_end(), parallel_vacuum_reset_dead_items(), and test_destroy().
| void TidStoreDetach | ( | TidStore * | ts | ) |
Definition at line 269 of file tidstore.c.
References TidStore::area, Assert(), dsa_detach(), pfree(), TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by parallel_vacuum_main().
| void TidStoreEndIterate | ( | TidStoreIter * | iter | ) |
Definition at line 518 of file tidstore.c.
References TidStoreIter::local, pfree(), TidStoreIter::shared, TidStoreIsShared, TidStoreIter::tree_iter, and TidStoreIter::ts.
Referenced by check_set_block_offsets(), and lazy_vacuum_heap_rel().
| int TidStoreGetBlockOffsets | ( | TidStoreIterResult * | result, |
| OffsetNumber * | offsets, | ||
| int | max_offsets | ||
| ) |
Definition at line 566 of file tidstore.c.
References BITS_PER_BITMAPWORD, BlocktableEntry::full_offsets, BlocktableEntry::header, i, TidStoreIterResult::internal_page, InvalidOffsetNumber, NUM_FULL_OFFSETS, BlocktableEntry::nwords, and BlocktableEntry::words.
Referenced by check_set_block_offsets(), and lazy_vacuum_heap_rel().
Definition at line 544 of file tidstore.c.
References TidStore::area, Assert(), and TidStoreIsShared.
Referenced by parallel_vacuum_init(), parallel_vacuum_reset_dead_items(), and test_create().
| dsa_pointer TidStoreGetHandle | ( | TidStore * | ts | ) |
Definition at line 552 of file tidstore.c.
References Assert(), TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by parallel_vacuum_init(), and parallel_vacuum_reset_dead_items().
| bool TidStoreIsMember | ( | TidStore * | ts, |
| const ItemPointerData * | tid | ||
| ) |
Definition at line 421 of file tidstore.c.
References BITNUM, BlocktableEntry::full_offsets, BlocktableEntry::header, i, ItemPointerGetBlockNumber(), ItemPointerGetOffsetNumber(), TidStore::local, NUM_FULL_OFFSETS, BlocktableEntry::nwords, TidStore::shared, TidStoreIsShared, TidStore::tree, WORDNUM, and BlocktableEntry::words.
Referenced by check_set_block_offsets(), and vac_tid_reaped().
| TidStoreIterResult * TidStoreIterateNext | ( | TidStoreIter * | iter | ) |
Definition at line 493 of file tidstore.c.
References TidStoreIterResult::blkno, TidStoreIterResult::internal_page, sort-test::key, TidStoreIter::local, TidStoreIter::output, TidStoreIter::shared, TidStoreIsShared, TidStoreIter::tree_iter, and TidStoreIter::ts.
Referenced by check_set_block_offsets(), and vacuum_reap_lp_read_stream_next().
| void TidStoreLockExclusive | ( | TidStore * | ts | ) |
Definition at line 287 of file tidstore.c.
References TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by do_set_block_offsets().
| void TidStoreLockShare | ( | TidStore * | ts | ) |
Definition at line 294 of file tidstore.c.
References TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by check_set_block_offsets().
| size_t TidStoreMemoryUsage | ( | TidStore * | ts | ) |
Definition at line 532 of file tidstore.c.
References TidStore::local, TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by dead_items_add(), lazy_scan_heap(), lazy_vacuum(), test_create(), and test_is_full().
| void TidStoreSetBlockOffsets | ( | TidStore * | ts, |
| BlockNumber | blkno, | ||
| OffsetNumber * | offsets, | ||
| int | num_offsets | ||
| ) |
Definition at line 345 of file tidstore.c.
References Assert(), BITNUM, BITS_PER_BITMAPWORD, data, elog, ERROR, BlocktableEntry::full_offsets, BlocktableEntry::header, i, idx(), InvalidOffsetNumber, TidStore::local, MAX_OFFSET_IN_BITMAP, MaxBlocktableEntrySize, NUM_FULL_OFFSETS, BlocktableEntry::nwords, TidStore::shared, TidStoreIsShared, TidStore::tree, word(), WORDNUM, BlocktableEntry::words, and WORDS_PER_PAGE.
Referenced by dead_items_add(), and do_set_block_offsets().
| void TidStoreUnlock | ( | TidStore * | ts | ) |
Definition at line 301 of file tidstore.c.
References TidStore::shared, TidStoreIsShared, and TidStore::tree.
Referenced by check_set_block_offsets(), and do_set_block_offsets().