From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Nathan Bossart <nathandbossart(at)gmail(dot)com> |
Cc: | Andres Freund <andres(at)anarazel(dot)de>, Álvaro Herrera <alvherre(at)kurilemu(dot)de>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, Salvatore Dipietro <dipietro(dot)salvatore(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org, Salvatore Dipietro <dipiets(at)amazon(dot)com>, blakgeof(at)amazon(dot)com |
Subject: | Re: Remove Instruction Synchronization Barrier in spin_delay() for ARM64 architecture |
Date: | 2025-08-17 06:19:03 |
Message-ID: | aKF0V-T8-XAxj47T@paquier.xyz |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Aug 15, 2025 at 03:54:29PM -0500, Nathan Bossart wrote:
> On Fri, Aug 15, 2025 at 03:25:20PM -0500, Nathan Bossart wrote:
>> On Fri, Aug 15, 2025 at 04:13:30PM -0400, Andres Freund wrote:
>>> IMO, the only way to actually make pg_stat_statements scale is to move to a
>>> model much more like our regular stats. I.e. accumulate counters in backend
>>> local memory and only occasionally update the shared stats.
>>
>> Agreed. I remember discussing something similar at pgconf.dev this year.
>
> BTW I'm planning to give this a try...
This means to use the pluggable pgstats API to achieve that. FWIW,
one difficulty I am foreseeing is how we want to cap and control the
number of PGSS entries that are saved in the pgstats hash table, based
on the current max PGSS can be set to. Just saying that we'll most
likely rely on a separate zone of shared memory to track this
information. Most of that should happen in the flush callback, based
on the current infra in place, I guess.
More stats are good to have, still capping them is key to keep the
backend under control, and it does not make sense to me to use a fixed
chunk of shared memory for this side (meaning a fixed-sized pgstats
kind for PGSS). Another benefit is to make the max reloadable.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2025-08-17 06:26:20 | Re: Dead code with short varlenas in toast_save_datum() |
Previous Message | Thomas Munro | 2025-08-17 04:57:29 | Re: [PATCH] Let's get rid of the freelist and the buffer_strategy_lock |