Re: A better way than tweaking NTUP_PER_BUCKET - Mailing list pgsql-hackers

From Stephen Frost
Subject Re: A better way than tweaking NTUP_PER_BUCKET
Date
Msg-id 20140125220221.GR31026@tamriel.snowman.net
Whole thread Raw
In response to Re: A better way than tweaking NTUP_PER_BUCKET  (Bruce Momjian <bruce@momjian.us>)
Responses Re: A better way than tweaking NTUP_PER_BUCKET  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
* Bruce Momjian (bruce@momjian.us) wrote:
> Uh, were are we on this?  Is it a TODO?

I've been strongly considering my previous patch which tweaked
NTUP_PER_BUCKET to '1' (instead of the default '10') when there's
sufficient work_mem for it.  There was recently another complaint on IRC
about our tendency to hash the larger partition rather than the smaller
one which I believe would be resolved by doing so.

The main thing holding me back has been concern that there may be cases
which perform worse with the change, either because hashing the larger
partition actually ended up being faster or due to the increase in
memory usage.

In the end, I believe we absolutely should do something about this.
Hashing a 64M-row table (requiring upwards of 8G) instead of hashing
a 2M-row table is really bad of us.

Thoughts?
Thanks,
    Stephen

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: A minor correction in comment in heaptuple.c
Next
From: Florian Pflug
Date:
Subject: Re: [PATCH] Negative Transition Aggregate Functions (WIP)