Re: Parallel Bitmap Heap Scan reports per-worker stats in EXPLAIN ANALYZE
Heikki Linnakangas <hlinnaka@iki.fi>
From: Heikki Linnakangas <hlinnaka@iki.fi>
To: Melanie Plageman <melanieplageman@gmail.com>
Cc: Tomas Vondra <tomas.vondra@enterprisedb.com>,
Dilip Kumar <dilipbalaut@gmail.com>, David Geier <geidav.pg@gmail.com>,
PostgreSQL Developers <pgsql-hackers@lists.postgresql.org>
Date: 2024-03-14T20:59:50Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Show Parallel Bitmap Heap Scan worker stats in EXPLAIN ANALYZE
- 5a1e6df3b84c 18.0 landed
-
Widen lossy and exact page counters for Bitmap Heap Scan
- 7340d9362a79 18.0 landed
-
Remove redundant snapshot copying from parallel leader to workers
- 84c18acaf690 17.0 cited
On 14/03/2024 22:00, Melanie Plageman wrote:
> On Thu, Mar 14, 2024 at 05:30:30PM +0200, Heikki Linnakangas wrote:
>> typedef struct SharedBitmapHeapInstrumentation
>> {
>> int num_workers;
>> BitmapHeapScanInstrumentation sinstrument[FLEXIBLE_ARRAY_MEMBER];
>> } SharedBitmapHeapInstrumentation;
>>
>> typedef struct BitmapHeapScanState
>> {
>> ScanState ss; /* its first field is NodeTag */
>> ...
>> SharedBitmapHeapInstrumentation sinstrument;
>> } BitmapHeapScanState;
>>
>> that compiles, at least with my compiler, but I find it weird to have a
>> variable-length inner struct embedded in an outer struct like that.
>
> In the attached patch, BitmapHeapScanState->sinstrument is a pointer,
> though. Or are you proposing the above as an alternative that you
> decided not to go with?
Right, the above is what I contemplated at first but decided it was a
bad idea.
--
Heikki Linnakangas
Neon (https://neon.tech)