This patch extracts page buffer pooling and the simple

Bruce Momjian <bruce@momjian.us>

Commit: 0abe7431c6d7a022e7f24a4f145c702900f56174
Author: Bruce Momjian <bruce@momjian.us>
Date: 2003-06-11T22:37:46Z
Releases: 7.4.1
This patch extracts page buffer pooling and the simple
least-recently-used strategy from clog.c into slru.c.  It doesn't
change any visible behaviour and passes all regression tests plus a
TruncateCLOG test done manually.

Apart from refactoring I made a little change to SlruRecentlyUsed,
formerly ClogRecentlyUsed:  It now skips incrementing lru_counts, if
slotno is already the LRU slot, thus saving a few CPU cycles.  To make
this work, lru_counts are initialised to 1 in SimpleLruInit.

SimpleLru will be used by pg_subtrans (part of the nested transactions
project), so the main purpose of this patch is to avoid future code
duplication.

Manfred Koizar

Files