Re: EXPLAIN: showing ReadStream / prefetch stats - Mailing list pgsql-hackers

From Tomas Vondra
Subject Re: EXPLAIN: showing ReadStream / prefetch stats
Date
Msg-id 7ef4455a-5325-4dd8-906d-7bb7f3e787d7@vondra.me
Whole thread Raw
In response to Re: EXPLAIN: showing ReadStream / prefetch stats  (Melanie Plageman <melanieplageman@gmail.com>)
Responses Re: EXPLAIN: showing ReadStream / prefetch stats
List pgsql-hackers
On 4/7/26 21:42, Melanie Plageman wrote:
> On Tue, Apr 7, 2026 at 1:34 PM Tomas Vondra <tomas@vondra.me> wrote:
>>
>> On 4/7/26 18:07, Melanie Plageman wrote:
>>
>>> I see I had bitmapheapscan use
>>>     if (!node->ss.ps.instrument || pcxt->nworkers == 0)
>>>         return;
>>>
>>> while seq scan uses
>>>     if (!estate->es_instrument || pcxt->nworkers == 0)
>>>         return;
>>>
>>> That does seem worth being consistent about. Though the estate one is
>>> probably better to use and changing bitmapheapscan in this commit
>>> might be noisy... I don't feel strongly either way.
>>
>> I'm not sure this is just a question of consistency, because BHS may
>> need the shared instrumentation even if (es_instrument = 0), no? While
>> the seqscan/tidrange scan only need it with EXPLAIN(IO).
>>
>> So I think the two nodes should check
>>
>>   ((estate->es_instrument & INSTRUMENT_IO) == 0)
> 
> Makes sense to me.
> 
> I skimmed v14 quite quickly and LGTM.
> 

Thanks. I've now pushed all parts of this patch series.


-- 
Tomas Vondra




pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: pg_plan_advice
Next
From: Andrew Dunstan
Date:
Subject: Re: Add errdetail() with PID and UID about source of termination signal