Re: tweaking NTUP_PER_BUCKET

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Tomas Vondra <tv(at)fuzzy(dot)cz>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: tweaking NTUP_PER_BUCKET
Date: 2014-07-11 07:27:41
Message-ID: CA+U5nMLaNa2vWcUPeTjDKQxqLCmJTasdAtyW0mZFwybDq-GtCg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 9 July 2014 18:54, Tomas Vondra <tv(at)fuzzy(dot)cz> wrote:

> (1) size the buckets for NTUP_PER_BUCKET=1 (and use whatever number
> of batches this requires)

If we start off by assuming NTUP_PER_BUCKET = 1, how much memory does
it save to recalculate the hash bucket at 10 instead?
Resizing sounds like it will only be useful of we only just overflow our limit.

If we release next version with this as a hardcoded change, my
understanding is that memory usage for hash joins will leap upwards,
even if the run time of queries reduces. It sounds like we need some
kind of parameter to control this. "We made it faster" might not be
true if we run this on servers that are already experiencing high
memory pressure.

--
Simon Riggs http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Benedikt Grundmann 2014-07-11 08:10:06 Is there a way to temporarily disable a index
Previous Message Jeevan Chalke 2014-07-11 07:23:46 Re: add line number as prompt option to psql