| From: | Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com> |
|---|---|
| To: | Sami Imseih <samimseih(dot)pg(at)gmail(dot)com> |
| Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Report buffer access strategies in EXPLAIN |
| Date: | 2026-11-03 10:15:48 |
| Message-ID: | aum0VLX7xOoE5GOq@bdtpg |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hi,
On Mon, Nov 02, 2026 at 06:11:29AM -0600, Sami Imseih wrote:
> > For this first version, I’d prefer the patch series to focus on getting strategy
> > reporting right while keeping the additional instrumentation relatively light.
>
> Yes, that's the correct approach.
>
> > So I’d prefer to consider that as a follow up. Does that make sense?
>
> Yes, I am ok with this.
>
Thanks for confirming!
PFA v3 with the changes discussed up-thread. In addition, I adjusted SP-GiST to
record the strategy only when it is about to walk the index. I also clarified
that table scan strategies are reported only when provided by the table AM and
added comments to the new TAP tests.
To sum up, we have this 8 patch series:
0001 updates the buffer README to describe the current bulk-read ring sizing and
bulk-write users.
0002 documents the available buffer access strategy types.
0003 clarifies that strategy rings reference shared buffers in the pg_stat_io
documentation.
The above could be pushed independently of the followings.
0004 extracts the lookup of leader and per-worker table scan instrumentation.
0005 adds optional buffer access strategy instrumentation for table scans and
preserves every strategy observed across rescans.
0006 adds per-worker table scan instrumentation for sample and TID scans.
0007 reports the strategies used by table scans with EXPLAIN (ANALYZE, BUFFERS),
including parallel workers.
0008 reports the strategies used by index, index-only, and bitmap index scans.
Regards,
--
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com
| Attachment | Content-Type | Size |
|---|---|---|
| v3-0001-Update-buffer-strategy-descriptions-in-the-buffer.patch | text/x-diff | 4.9 KB |
| v3-0002-Describe-buffer-access-strategy-types-in-the-glos.patch | text/x-diff | 7.6 KB |
| v3-0003-Clarify-buffer-access-strategies-in-pg_stat_io-do.patch | text/x-diff | 4.5 KB |
| v3-0004-Refactor-table-scan-instrumentation-lookup.patch | text/x-diff | 5.9 KB |
| v3-0005-Add-buffer-access-strategies-to-table-scan-instru.patch | text/x-diff | 15.5 KB |
| v3-0006-Add-table-scan-instrumentation-for-sample-and-TID.patch | text/x-diff | 20.5 KB |
| v3-0007-Report-buffer-access-strategies-for-table-scans-i.patch | text/x-diff | 31.0 KB |
| v3-0008-Report-buffer-access-strategies-for-index-scans-i.patch | text/x-diff | 24.7 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Aleksander Alekseev | 2026-11-03 10:19:09 | Re: [PATCH] dynahash.c refactoring |
| Previous Message | Peter Eisentraut | 2026-11-03 10:11:21 | Re: ICU fixed digit reordering bug |