diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2004-10-16 18:57:26 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2004-10-16 18:57:26 +0000 |
| commit | fdd13f156814f81732c188788ab1b7b14c59f4da (patch) | |
| tree | 2ca797d2b320de27c01ec61f5480558a05c27f4d /src/include/storage/bufmgr.h | |
| parent | 1c2de4774620469375e6393fbdbcdaffb0c2d0b5 (diff) | |
Give the ResourceOwner mechanism full responsibility for releasing buffer
pins at end of transaction, and reduce AtEOXact_Buffers to an Assert
cross-check that this was done correctly. When not USE_ASSERT_CHECKING,
AtEOXact_Buffers is a complete no-op. This gets rid of an O(NBuffers)
bottleneck during transaction commit/abort, which recent testing has shown
becomes significant above a few tens of thousands of shared buffers.
Diffstat (limited to 'src/include/storage/bufmgr.h')
| -rw-r--r-- | src/include/storage/bufmgr.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/include/storage/bufmgr.h b/src/include/storage/bufmgr.h index 04bc09e22c6..5064a1857f6 100644 --- a/src/include/storage/bufmgr.h +++ b/src/include/storage/bufmgr.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2004, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/storage/bufmgr.h,v 1.87 2004/10/15 22:40:25 tgl Exp $ + * $PostgreSQL: pgsql/src/include/storage/bufmgr.h,v 1.88 2004/10/16 18:57:26 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -122,6 +122,8 @@ extern void InitBufferPoolAccess(void); extern char *ShowBufferUsage(void); extern void ResetBufferUsage(void); extern void AtEOXact_Buffers(bool isCommit); +extern void AtProcExit_Buffers(void); +extern void PrintBufferLeakWarning(Buffer buffer); extern void FlushBufferPool(void); extern BlockNumber BufferGetBlockNumber(Buffer buffer); extern BlockNumber RelationGetNumberOfBlocks(Relation relation); |
