aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeHashjoin.c
diff options
context:
space:
mode:
authorJeff Davis <jdavis@postgresql.org>2020-07-28 23:15:47 -0700
committerJeff Davis <jdavis@postgresql.org>2020-07-28 23:17:23 -0700
commit3a232a3183d517743acf232794fadc07f0944220 (patch)
treee32dee4bb9a66ca84771e12a4cc4e9883d6cf58e /src/backend/executor/nodeHashjoin.c
parentcdd7bd695bed552936e86b70ff1d234360bc5bea (diff)
downloadpostgresql-3a232a3183d517743acf232794fadc07f0944220.tar.gz
postgresql-3a232a3183d517743acf232794fadc07f0944220.zip
HashAgg: use better cardinality estimate for recursive spilling.
Use HyperLogLog to estimate the group cardinality in a spilled partition. This estimate is used to choose the number of partitions if we recurse. The previous behavior was to use the number of tuples in a spilled partition as the estimate for the number of groups, which lead to overpartitioning. That could cause the number of batches to be much higher than expected (with each batch being very small), which made it harder to interpret EXPLAIN ANALYZE results. Reviewed-by: Peter Geoghegan Discussion: https://postgr.es/m/a856635f9284bc36f7a77d02f47bbb6aaf7b59b3.camel@j-davis.com Backpatch-through: 13
Diffstat (limited to 'src/backend/executor/nodeHashjoin.c')
0 files changed, 0 insertions, 0 deletions