OSDN Git Service

Repair old performance bug in tuplesort.c/logtape.c. In the case where
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 7 Mar 2006 19:06:50 +0000 (19:06 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 7 Mar 2006 19:06:50 +0000 (19:06 +0000)
commit8db05ba411ecd3ce2cb0cb7c78fec87658e1a4ab
tree7e0fd7aaff03dcd83ef3e4ac0232ae57c268f628
parente6107da53c93dc188e257d72c3412510d2584093
Repair old performance bug in tuplesort.c/logtape.c.  In the case where
we are doing the final merge pass on-the-fly, and not writing the data
back onto a 'tape', the number of free blocks in the tape set will become
large, leading to a lot of time wasted in ltsReleaseBlock().  There is
really no need to track the free blocks anymore in this state, so add a
simple shutoff switch.  Per report from Stefan Kaltenbrunner.
src/backend/utils/sort/logtape.c
src/backend/utils/sort/tuplesort.c
src/include/utils/logtape.h