pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: David Rowley <drowley@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix EXPLAIN ANALYZE for parallel HashAgg plans
Date: Fri, 19 Jun 2020 05:26:08 +0000
Message-ID: <E1jm9XU-00015I-Pl@gemulon.postgresql.org> (raw)

Fix EXPLAIN ANALYZE for parallel HashAgg plans

Since 1f39bce02, HashAgg nodes have had the ability to spill to disk when
memory consumption exceeds work_mem. That commit added new properties to
EXPLAIN ANALYZE to show the maximum memory usage and disk usage, however,
it didn't quite go as far as showing that information for parallel
workers.  Since workers may have experienced something very different from
the main process, we should show this information per worker, as is done
in Sort.

Reviewed-by: Justin Pryzby
Reviewed-by: Jeff Davis
Discussion: https://postgr.es/m/CAApHDvpEKbfZa18mM1TD7qV6PG+w97pwCWq5tVD0dX7e11gRJw@mail.gmail.com
Backpatch-through: 13, where the hashagg spilling code was added.

Branch
------
REL_13_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/bdee4af8e07648008fe522fc5a562db453be5ad7

Modified Files
--------------
src/backend/commands/explain.c      | 110 +++++++++++++++++++++++++++++++-----
src/backend/executor/execParallel.c |  19 ++++++-
src/backend/executor/nodeAgg.c      | 103 +++++++++++++++++++++++++++++++++
src/include/executor/nodeAgg.h      |   7 +++
src/include/nodes/execnodes.h       |  22 ++++++++
5 files changed, 244 insertions(+), 17 deletions(-)



view thread (2+ messages)

Message-ID: <E1jm9XU-00015I-Pl@gemulon.postgresql.org>
Permalink:  ../E1jm9XU-00015I-Pl@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1jm9XU-00015I-Pl@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: drowley@postgresql.org
  Subject: Re: pgsql: Fix EXPLAIN ANALYZE for parallel HashAgg plans
  In-Reply-To: <E1jm9XU-00015I-Pl@gemulon.postgresql.org>
  References: <E1jm9XU-00015I-Pl@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