summaryrefslogtreecommitdiff
path: root/src/backend/executor/spi.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2011-08-20 14:51:02 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2011-08-20 14:51:32 -0400
commit706493a1f7cbd9c7d3a792fd5066b55c145b9b01 (patch)
treeb008d8e26dc55ec2fc607c4592a25fd1243996bd /src/backend/executor/spi.c
parentd4c24254fab0b9908211f990c4239664f3ed5630 (diff)
Fix performance problem when building a lossy tidbitmap.
As pointed out by Sergey Koposov, repeated invocations of tbm_lossify can make building a large tidbitmap into an O(N^2) operation. To fix, make sure we remove more than the minimum amount of information per call, and add a fallback path to behave sanely if we're unable to fit the bitmap within the requested amount of memory. This has been wrong since the tidbitmap code was written, so back-patch to all supported branches.
Diffstat (limited to 'src/backend/executor/spi.c')
0 files changed, 0 insertions, 0 deletions