Include information on buffer usage during planning phase, in EXPLAIN output, take...
authorFujii Masao <[email protected]>
Fri, 3 Apr 2020 18:13:17 +0000 (03:13 +0900)
committerFujii Masao <[email protected]>
Fri, 3 Apr 2020 18:13:17 +0000 (03:13 +0900)
commitce77abe63cfc85fb0bc236deb2cc34ae35cb5324
tree375470c0688d84b9abe19bc78430dd47563f5cfc
parente41955faf060f90918303ce0623df9d765144bf6
Include information on buffer usage during planning phase, in EXPLAIN output, take two.

When BUFFERS option is enabled, EXPLAIN command includes the information
on buffer usage during each plan node, in its output. In addition to that,
this commit makes EXPLAIN command include also the information on
buffer usage during planning phase, in its output. This feature makes it
easier to discern the cases where lots of buffer access happen during
planning.

This commit revives the original commit ed7a509571 that was reverted by
commit 19db23bcbd. The original commit had to be reverted because
it caused the regression test failure on the buildfarm members prion and
dory. But since commit c0885c4c30 got rid of the caues of the test failure,
the original commit can be safely introduced again.

Author: Julien Rouhaud, slightly revised by Fujii Masao
Reviewed-by: Justin Pryzby
Discussion: https://postgr.es/m/16109-26a1a88651e90608@postgresql.org
src/backend/commands/explain.c
src/backend/commands/prepare.c
src/include/commands/explain.h
src/test/regress/expected/explain.out