From: Tom Lane <tgl@sss.pgh.pa.us>
To: Fujii Masao <masao.fujii@oss.nttdata.com>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Fujii Masao <fujii@postgresql.org>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Include information on buffer usage during planning phase, in EX
Date: Fri, 03 Apr 2020 10:55:27 -0400
Message-ID: <32174.1585925727@sss.pgh.pa.us> (raw)
In-Reply-To: <1c26658b-fb09-3c4c-2eff-a61e86ab5316@oss.nttdata.com>
References: <E1jKC4J-0007R3-Bo@gemulon.postgresql.org>
<20200403025751.GB1759@paquier.xyz>
<0fa34bc8-479e-61e8-94c0-9cdbc34ea0bb@oss.nttdata.com>
<23095.1585884653@sss.pgh.pa.us>
<4ecdae9c-fa0b-17b6-9166-0a45c396da22@oss.nttdata.com>
<20577.1585920933@sss.pgh.pa.us>
<1c26658b-fb09-3c4c-2eff-a61e86ab5316@oss.nttdata.com>
Fujii Masao <masao.fujii@oss.nttdata.com> writes:
> On 2020/04/03 22:35, Tom Lane wrote:
>> I think this is a bad idea. It's overcomplicated, and more to the
>> point: now that we've seen the problem we should realize that we're
>> eventually going to have failures for *any* Buffers line in text-mode
>> output. We're already filtering them so hard as to be nearly useless
>> (see a couple lines further down). I think we should just drop them
>> in text mode and be content with checking for them in non-text modes.
> Yeah, I'm fine with the idea. The regression test for EXPLAIN has
> the following four similar tests. The first one fails in regression test
> because of buffers output for the planning. Your idea seems to be
> equal to removal of this first test. Because there are already
> the same tests with other format. Is my understanding right?
Well, there are at least three ways you could interpret my suggestion:
* don't do the test with format = text at all
* do it, but remove the buffers option
* keep test the same, make explain_filter() drop Buffers lines
But I had the last one in mind. Even if we can't *see* the output,
there is some value in making the backend run through the code ---
it'd at least catch core-dumping bugs there.
> Or another idea is to specify "summary off" in the above first
> EXPLAIN command, to suppress the summary output including
> the buffers output for the planning. This seems simple and enough.
That's still assuming that only the summary Buffers line is problematic,
which I think is wrong. Keep in mind that the explain.sql test is
barely two months old; it has never seen the field, and there is no
good reason to trust that it's rock solid stable. Now that we've
seen this failure, I'm quite afraid that the existing test case
Seq Scan on int8_tbl i8 (cost=N.N..N.N rows=N width=N) (actual time=N.N..N.N rows=N loops=N)
Buffers: shared [read]
Planning Time: N.N ms
can be made to fall over, eg by running with high enough shared_buffers.
regards, tom lane
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: tgl@sss.pgh.pa.us, masao.fujii@oss.nttdata.com, michael@paquier.xyz, fujii@postgresql.org
Subject: Re: pgsql: Include information on buffer usage during planning phase, in EX
In-Reply-To: <32174.1585925727@sss.pgh.pa.us>
References: <E1jKC4J-0007R3-Bo@gemulon.postgresql.org> <20200403025751.GB1759@paquier.xyz> <0fa34bc8-479e-61e8-94c0-9cdbc34ea0bb@oss.nttdata.com> <23095.1585884653@sss.pgh.pa.us> <4ecdae9c-fa0b-17b6-9166-0a45c396da22@oss.nttdata.com> <20577.1585920933@sss.pgh.pa.us> <1c26658b-fb09-3c4c-2eff-a61e86ab5316@oss.nttdata.com> <32174.1585925727@sss.pgh.pa.us>
* 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