diff options
| author | Fujii Masao | 2020-04-03 18:13:17 +0000 |
|---|---|---|
| committer | Fujii Masao | 2020-04-03 18:13:17 +0000 |
| commit | ce77abe63cfc85fb0bc236deb2cc34ae35cb5324 (patch) | |
| tree | 375470c0688d84b9abe19bc78430dd47563f5cfc /src/test | |
| parent | e41955faf060f90918303ce0623df9d765144bf6 (diff) | |
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/[email protected]
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/regress/expected/explain.out | 55 |
1 files changed, 51 insertions, 4 deletions
diff --git a/src/test/regress/expected/explain.out b/src/test/regress/expected/explain.out index 3ec66ceda3c..96baba038c2 100644 --- a/src/test/regress/expected/explain.out +++ b/src/test/regress/expected/explain.out @@ -105,7 +105,19 @@ select explain_filter('explain (analyze, buffers, format json) select * from int "Temp Read Blocks": N, + "Temp Written Blocks": N + }, + - "Planning Time": N.N, + + "Planning": { + + "Planning Time": N.N, + + "Shared Hit Blocks": N, + + "Shared Read Blocks": N, + + "Shared Dirtied Blocks": N, + + "Shared Written Blocks": N, + + "Local Hit Blocks": N, + + "Local Read Blocks": N, + + "Local Dirtied Blocks": N, + + "Local Written Blocks": N, + + "Temp Read Blocks": N, + + "Temp Written Blocks": N + + }, + "Triggers": [ + ], + "Execution Time": N.N + @@ -142,7 +154,19 @@ select explain_filter('explain (analyze, buffers, format xml) select * from int8 <Temp-Read-Blocks>N</Temp-Read-Blocks> + <Temp-Written-Blocks>N</Temp-Written-Blocks> + </Plan> + - <Planning-Time>N.N</Planning-Time> + + <Planning> + + <Planning-Time>N.N</Planning-Time> + + <Shared-Hit-Blocks>N</Shared-Hit-Blocks> + + <Shared-Read-Blocks>N</Shared-Read-Blocks> + + <Shared-Dirtied-Blocks>N</Shared-Dirtied-Blocks>+ + <Shared-Written-Blocks>N</Shared-Written-Blocks>+ + <Local-Hit-Blocks>N</Local-Hit-Blocks> + + <Local-Read-Blocks>N</Local-Read-Blocks> + + <Local-Dirtied-Blocks>N</Local-Dirtied-Blocks> + + <Local-Written-Blocks>N</Local-Written-Blocks> + + <Temp-Read-Blocks>N</Temp-Read-Blocks> + + <Temp-Written-Blocks>N</Temp-Written-Blocks> + + </Planning> + <Triggers> + </Triggers> + <Execution-Time>N.N</Execution-Time> + @@ -176,7 +200,18 @@ select explain_filter('explain (analyze, buffers, format yaml) select * from int Local Written Blocks: N + Temp Read Blocks: N + Temp Written Blocks: N + - Planning Time: N.N + + Planning: + + Planning Time: N.N + + Shared Hit Blocks: N + + Shared Read Blocks: N + + Shared Dirtied Blocks: N + + Shared Written Blocks: N + + Local Hit Blocks: N + + Local Read Blocks: N + + Local Dirtied Blocks: N + + Local Written Blocks: N + + Temp Read Blocks: N + + Temp Written Blocks: N + Triggers: + Execution Time: N.N (1 row) @@ -366,9 +401,21 @@ select jsonb_pretty( "Shared Dirtied Blocks": 0, + "Shared Written Blocks": 0 + }, + + "Planning": { + + "Planning Time": 0.0, + + "Local Hit Blocks": 0, + + "Temp Read Blocks": 0, + + "Local Read Blocks": 0, + + "Shared Hit Blocks": 0, + + "Shared Read Blocks": 0, + + "Temp Written Blocks": 0, + + "Local Dirtied Blocks": 0, + + "Local Written Blocks": 0, + + "Shared Dirtied Blocks": 0, + + "Shared Written Blocks": 0 + + }, + "Triggers": [ + ], + - "Planning Time": 0.0, + "Execution Time": 0.0 + } + ] |
