pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jeff Davis <jdavis@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Rework HashAgg GUCs.
Date: Thu, 11 Jun 2020 20:11:20 +0000
Message-ID: <E1jjTXk-0002Ea-QZ@gemulon.postgresql.org> (raw)

Rework HashAgg GUCs.

Eliminate enable_groupingsets_hash_disk, which was primarily useful
for testing grouping sets that use HashAgg and spill. Instead, hack
the table stats to convince the planner to choose hashed aggregation
for grouping sets that will spill to disk. Suggested by Melanie
Plageman.

Rename enable_hashagg_disk to hashagg_avoid_disk_plan, and invert the
meaning of on/off. The new name indicates more strongly that it only
affects the planner. Also, the word "avoid" is less definite, which
should avoid surprises when HashAgg still needs to use the
disk. Change suggested by Justin Pryzby, though I chose a different
GUC name.

Discussion: https://postgr.es/m/CAAKRu_aisiENMsPM2gC4oUY1hHG3yrCwY-fXUg22C6_MJUwQdA%40mail.gmail.com
Discussion: https://postgr.es/m/20200610021544.GA14879@telsasoft.com
Backpatch-through: 13

Branch
------
REL_13_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/13e0fa7ae50cd0e91158877dba37098492b234e8

Modified Files
--------------
doc/src/sgml/config.sgml                   | 31 +++---------
src/backend/optimizer/path/costsize.c      |  3 +-
src/backend/optimizer/plan/planner.c       | 20 ++++----
src/backend/utils/misc/guc.c               | 16 ++----
src/include/optimizer/cost.h               |  3 +-
src/test/regress/expected/aggregates.out   | 46 ++++++++---------
src/test/regress/expected/groupingsets.out | 80 ++++++++++++++----------------
src/test/regress/expected/sysviews.out     |  4 +-
src/test/regress/sql/aggregates.sql        | 36 +++++++-------
src/test/regress/sql/groupingsets.sql      | 38 +++++++-------
10 files changed, 119 insertions(+), 158 deletions(-)



view thread (4+ messages)  latest in thread

Message-ID: <E1jjTXk-0002Ea-QZ@gemulon.postgresql.org>
Permalink:  ../E1jjTXk-0002Ea-QZ@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1jjTXk-0002Ea-QZ@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: jdavis@postgresql.org
  Subject: Re: pgsql: Rework HashAgg GUCs.
  In-Reply-To: <E1jjTXk-0002Ea-QZ@gemulon.postgresql.org>
  References: <E1jjTXk-0002Ea-QZ@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox