pgsql: Show number of disabled nodes in EXPLAIN ANALYZE output.

From: Robert Haas <rhaas(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Show number of disabled nodes in EXPLAIN ANALYZE output.
Date: 2024-08-21 14:24:59
Message-ID: E1sgmGh-000mPc-1E@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Show number of disabled nodes in EXPLAIN ANALYZE output.

Now that disable_cost is not included in the cost estimate, there's
no visible sign in EXPLAIN output of which plan nodes are disabled.
Fix that by propagating the number of disabled nodes from Path to
Plan, and then showing it in the EXPLAIN output.

There is some question about whether this is a desirable change.
While I personally believe that it is, it seems best to make it a
separate commit, in case we decide to back out just this part, or
rework it.

Reviewed by Andres Freund, Heikki Linnakangas, and David Rowley.

Discussion: http://postgr.es/m/CA+TgmoZ_+MS+o6NeGK2xyBv-xM+w1AfFVuHE4f_aq6ekHv7YSQ@mail.gmail.com

Branch
------
master

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

Modified Files
--------------
src/backend/commands/explain.c | 4 ++++
src/backend/optimizer/plan/createplan.c | 8 ++++++--
src/include/nodes/plannodes.h | 1 +
src/test/regress/expected/aggregates.out | 21 ++++++++++++++++++---
src/test/regress/expected/btree_index.out | 4 +++-
src/test/regress/expected/collate.icu.utf8.out | 6 ++++--
src/test/regress/expected/incremental_sort.out | 5 ++++-
src/test/regress/expected/inherit.out | 4 +++-
src/test/regress/expected/join.out | 4 +++-
src/test/regress/expected/memoize.out | 8 ++++++--
src/test/regress/expected/select_parallel.out | 6 +++++-
src/test/regress/expected/union.out | 3 ++-
12 files changed, 59 insertions(+), 15 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2024-08-21 16:00:23 pgsql: Disallow creating binary-coercible casts involving range types.
Previous Message Robert Haas 2024-08-21 14:12:43 pgsql: Treat number of disabled nodes in a path as a separate cost metr