*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/heap/heapam.c,v 1.149 2002/09/26 22:46:29 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/heap/heapam.c,v 1.150 2003/02/13 05:35:07 momjian Exp $
*
*
* INTERFACE ROUTINES
int linesleft;
ItemPointer tid;
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_heapgettup);
- IncrHeapAccessStat(global_heapgettup);
-
tid = (tuple->t_data == NULL) ? (ItemPointer) NULL : &(tuple->t_self);
/*
Assert(lockmode >= NoLock && lockmode < MAX_LOCKMODES);
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_open);
- IncrHeapAccessStat(global_open);
-
/* The relcache does all the real work... */
r = RelationIdGetRelation(relationId);
Assert(lockmode >= NoLock && lockmode < MAX_LOCKMODES);
/*
- * increment access statistics
- */
- IncrHeapAccessStat(local_openr);
- IncrHeapAccessStat(global_openr);
-
- /*
* We assume we should not need to worry about the rel's OID changing,
* hence no need for AcceptInvalidationMessages here.
*/
{
Assert(lockmode >= NoLock && lockmode < MAX_LOCKMODES);
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_close);
- IncrHeapAccessStat(global_close);
-
if (lockmode != NoLock)
UnlockRelation(relation, lockmode);
HeapScanDesc scan;
/*
- * increment access statistics
- */
- IncrHeapAccessStat(local_beginscan);
- IncrHeapAccessStat(global_beginscan);
-
- /*
* sanity checks
*/
if (!RelationIsValid(relation))
ScanKey key)
{
/*
- * increment access statistics
- */
- IncrHeapAccessStat(local_rescan);
- IncrHeapAccessStat(global_rescan);
-
- /*
* unpin scan buffers
*/
if (BufferIsValid(scan->rs_cbuf))
void
heap_endscan(HeapScanDesc scan)
{
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_endscan);
- IncrHeapAccessStat(global_endscan);
-
/* Note: no locking manipulations needed */
/*
HeapTuple
heap_getnext(HeapScanDesc scan, ScanDirection direction)
{
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_getnext);
- IncrHeapAccessStat(global_getnext);
-
/* Note: no locking manipulations needed */
/*
bool valid;
/*
- * increment access statistics
- */
- IncrHeapAccessStat(local_fetch);
- IncrHeapAccessStat(global_fetch);
-
- /*
* get the buffer from the relation descriptor. Note that this does a
* buffer pin.
*/
{
Buffer buffer;
- /* increment access statistics */
- IncrHeapAccessStat(local_insert);
- IncrHeapAccessStat(global_insert);
-
if (relation->rd_rel->relhasoids)
{
#ifdef NOT_USED
Buffer buffer;
int result;
- /* increment access statistics */
- IncrHeapAccessStat(local_delete);
- IncrHeapAccessStat(global_delete);
-
Assert(ItemPointerIsValid(tid));
buffer = ReadBuffer(relation, ItemPointerGetBlockNumber(tid));
pagefree;
int result;
- /* increment access statistics */
- IncrHeapAccessStat(local_replace);
- IncrHeapAccessStat(global_replace);
-
Assert(ItemPointerIsValid(otid));
buffer = ReadBuffer(relation, ItemPointerGetBlockNumber(otid));
PageHeader dp;
int result;
- /* increment access statistics */
- IncrHeapAccessStat(local_mark4update);
- IncrHeapAccessStat(global_mark4update);
-
*buffer = ReadBuffer(relation, ItemPointerGetBlockNumber(tid));
if (!BufferIsValid(*buffer))
void
heap_markpos(HeapScanDesc scan)
{
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_markpos);
- IncrHeapAccessStat(global_markpos);
-
/* Note: no locking manipulations needed */
if (scan->rs_ctup.t_data != NULL)
void
heap_restrpos(HeapScanDesc scan)
{
- /*
- * increment access statistics
- */
- IncrHeapAccessStat(local_restrpos);
- IncrHeapAccessStat(global_restrpos);
-
/* XXX no amrestrpos checking that ammarkpos called */
/* Note: no locking manipulations needed */