Re: EXPLAIN: showing ReadStream / prefetch stats

From: Melanie Plageman <melanieplageman(at)gmail(dot)com>
To: Tomas Vondra <tomas(at)vondra(dot)me>
Cc: Lukas Fittl <lukas(at)fittl(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: EXPLAIN: showing ReadStream / prefetch stats
Date: 2026-04-07 19:42:39
Message-ID: CAAKRu_ZKCGgm=hVmuSLdsQ4n8dGDdQX-A2MzLCUezj-O+xFRHw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Apr 7, 2026 at 1:34 PM Tomas Vondra <tomas(at)vondra(dot)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.

- Melanie

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Treat 2026-04-07 19:43:50 Re: Adding REPACK [concurrently]
Previous Message Matthias van de Meent 2026-04-07 19:38:37 Re: Better shared data structure management and resizable shared data structures