74 for (blkno = 0; blkno < nblocks; blkno++)
91 stat->tuple_len += BLCKSZ - freespace;
92 stat->free_space += freespace;
161 stat->dead_tuple_count++;
164 elog(
ERROR,
"unexpected HeapTupleSatisfiesVacuum result");
193 stat->scanned_percent = 100.0 * scanned / nblocks;
194 stat->tuple_percent = 100.0 *
stat->tuple_len /
stat->table_len;
195 stat->dead_tuple_percent = 100.0 *
stat->dead_tuple_len /
stat->table_len;
196 stat->free_percent = 100.0 *
stat->free_space /
stat->table_len;
void ReleaseBuffer(Buffer buffer)
void UnlockReleaseBuffer(Buffer buffer)
void LockBuffer(Buffer buffer, int mode)
Buffer ReadBufferExtended(Relation reln, ForkNumber forkNum, BlockNumber blockNum, ReadBufferMode mode, BufferAccessStrategy strategy)
#define BUFFER_LOCK_SHARE
#define RelationGetNumberOfBlocks(reln)
static Page BufferGetPage(Buffer buffer)
static bool BufferIsValid(Buffer bufnum)
Size PageGetExactFreeSpace(Page page)
static bool PageIsEmpty(Page page)
static Item PageGetItem(Page page, ItemId itemId)
static ItemId PageGetItemId(Page page, OffsetNumber offsetNumber)
static bool PageIsNew(Page page)
static OffsetNumber PageGetMaxOffsetNumber(Page page)
#define Assert(condition)
BufferAccessStrategy GetAccessStrategy(BufferAccessStrategyType btype)
Size GetRecordedFreeSpace(Relation rel, BlockNumber heapBlk)
@ HEAPTUPLE_RECENTLY_DEAD
@ HEAPTUPLE_INSERT_IN_PROGRESS
@ HEAPTUPLE_DELETE_IN_PROGRESS
HTSV_Result HeapTupleSatisfiesVacuum(HeapTuple htup, TransactionId OldestXmin, Buffer buffer)
HeapTupleHeaderData * HeapTupleHeader
#define ItemIdGetLength(itemId)
#define ItemIdIsNormal(itemId)
#define ItemIdIsDead(itemId)
#define ItemIdIsUsed(itemId)
#define ItemIdIsRedirected(itemId)
static void ItemPointerSet(ItemPointerData *pointer, BlockNumber blockNumber, OffsetNumber offNum)
#define CHECK_FOR_INTERRUPTS()
#define OffsetNumberNext(offsetNumber)
#define FirstOffsetNumber
TransactionId GetOldestNonRemovableTransactionId(Relation rel)
#define RelationGetRelid(relation)
double vac_estimate_reltuples(Relation relation, BlockNumber total_pages, BlockNumber scanned_pages, double scanned_tuples)
#define VM_ALL_VISIBLE(r, b, v)