Re: BUG #14932: SELECT DISTINCT val FROM table gets stuck in an infinite loop
Andres Freund <andres@anarazel.de>
From: Andres Freund <andres@anarazel.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Tomas Vondra <tomas.vondra@2ndquadrant.com>, "Todd A. Cook" <tcook@blackducksoftware.com>, pgsql-bugs@postgresql.org
Date: 2018-01-26T23:47:41Z
Lists: pgsql-bugs
On 2018-01-26 18:22:26 -0500, Tom Lane wrote: > In any case, we still need a fix for the behavior that the hash table size > is blown out by lots of collisions, because that can happen no matter what > the hash function is. Andres seems to have dropped the ball on doing > something about that. Didn't have spare brain cycles :(, and the next backbranch release wasn't yet close reducing immediate urgency a bit. As written nearby I think we should make execGrouping.c users of hashtables use a more random IV, and apply something similar to the growth limit patch from Tomas. Greetings, Andres Freund
Commits
-
Improve bit perturbation in TupleHashTableHash.
- d18d4bca81f8 10.2 landed
- c068f87723ca 11.0 landed
-
Prevent growth of simplehash tables when they're "too empty".
- d1aac2998789 10.2 landed
- ab9f2c429d8f 11.0 landed
-
Add stack-overflow guards in set-operation planning.
- 1b2a3860d3ea 10.2 cited