Get rid of rd_nblocks field in relcache entries. Turns out this was
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 8 May 2004 19:09:25 +0000 (19:09 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 8 May 2004 19:09:25 +0000 (19:09 +0000)
commit4af3421161ce7847a019ec0799c898586574801f
tree3ec8744681ef2d3e03b4479a677151a15a68b3f1
parent1fe11fad543fcaaf9ae7826f1234530a9d59c1b0
Get rid of rd_nblocks field in relcache entries.  Turns out this was
costing us lots more to maintain than it was worth.  On shared tables
it was of exactly zero benefit because we couldn't trust it to be
up to date.  On temp tables it sometimes saved an lseek, but not often
enough to be worth getting excited about.  And the real problem was that
we forced an lseek on every relcache flush in order to update the field.
So all in all it seems best to lose the complexity.
14 files changed:
contrib/pgstattuple/pgstattuple.c
src/backend/access/heap/heapam.c
src/backend/access/nbtree/nbtree.c
src/backend/catalog/heap.c
src/backend/catalog/index.c
src/backend/commands/analyze.c
src/backend/commands/sequence.c
src/backend/commands/vacuum.c
src/backend/commands/vacuumlazy.c
src/backend/storage/buffer/bufmgr.c
src/backend/utils/cache/relcache.c
src/include/access/relscan.h
src/include/storage/bufmgr.h
src/include/utils/rel.h