]> granicus.if.org Git - postgresql/commit
Resurrect heap_deformtuple(), this time implemented as a singly nested
authorTom Lane <tgl@sss.pgh.pa.us>
Fri, 4 Jun 2004 20:35:21 +0000 (20:35 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Fri, 4 Jun 2004 20:35:21 +0000 (20:35 +0000)
commit8f2ea8b7b53a02078ba0393e6892ac5356a3631e
tree536f02e4a6eec0304d76688d65cffbcea9679c9b
parentaf44cac6ef46e225ae963c5e1f9e2e91a0112e04
Resurrect heap_deformtuple(), this time implemented as a singly nested
loop over the fields instead of a loop around heap_getattr.  This is
considerably faster (O(N) instead of O(N^2)) when there are nulls or
varlena fields, since those prevent use of attcacheoff.  Replace loops
over heap_getattr with heap_deformtuple in situations where all or most
of the fields have to be fetched, such as printtup and tuptoaster.
Profiling done more than a year ago shows that this should be a nice
win for situations involving many-column tables.
src/backend/access/common/heaptuple.c
src/backend/access/common/printtup.c
src/backend/access/heap/tuptoaster.c
src/backend/commands/tablecmds.c
src/backend/commands/typecmds.c
src/backend/executor/execJunk.c
src/backend/executor/spi.c
src/include/access/heapam.h