model-writtenrun 6238 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Yura Sokolov reported a customer's hash aggregation hanging while growing beyond 2^31 buckets and supplied a patch widening the growth arguments to uint64 and computing the bucket mask correctly at 2^32 buckets #1.
- David Rowley agreed with both fixes, treated the planner's distinct-count estimate as a separate issue, and explained that patching would wait until the imminent minor releases were out #2.
- Ranier Vilela spotted that the SH_GROW declaration still used uint32, and Yura incorporated that correction and updated its comment in the second patchset #3 #4.
- David committed the second patchset with only whitespace adjustment and backpatched through PostgreSQL 10 #4 37450f2ca9; his subsequent report described reproducing the hang on a 256GB machine, successfully aggregating 2^31 groups after patching, and lowering fill factors to verify the capacity error #5.
- After the commit, Andres Freund requested a practical large-table test using techniques such as MAP_NORESERVE and suggested an explicit all-bits-set mask; Yura offered to write a test with guidance and defended the unconditional size-minus-one expression #6 #7.
- Andres suggested a SQL-callable test function and explained his readability preference, while Ranier reported identical generated code and Yura corrected the demonstration link #8 #9 #10.
- The thread ended with the fix landed and backpatched, but no automated test or further mask revision submitted; Andres emphasized that readability, rather than instruction cost, motivated his suggestion #5 #11.