Re: Incorrect CHUNKHDRSZ in nodeAgg.c - Mailing list pgsql-hackers

From John Naylor
Subject Re: Incorrect CHUNKHDRSZ in nodeAgg.c
Date
Msg-id CANWCAZa5HzVH0uJ4XSJFatAtaGK7iND7JoJE9Pyd6b9SM_9=vA@mail.gmail.com
Whole thread Raw
In response to Re: Incorrect CHUNKHDRSZ in nodeAgg.c  (David Rowley <dgrowleyml@gmail.com>)
Responses Re: Incorrect CHUNKHDRSZ in nodeAgg.c
List pgsql-hackers
On Thu, Jan 2, 2025 at 7:24 AM David Rowley <dgrowleyml@gmail.com> wrote:
>
> Bump wouldn't work due to the SH_FREE() in SH_GROW() when resizing the
> table. If sizeof(TupleHashEntryData) were a power-of-two, then there'd
> be no wastage as the hash table always has a power-of-two bucket count
> and two powers-of-two multiplied are always a power-of-two value.
> Unfortunately, TupleHashEntryData is 24 bytes and I don't see any easy
> way to shrink it to 16 bytes.

FYI, there is a proposal for that at
https://www.postgresql.org/message-id/817d244237878cebdff0bc363718feaf49a1ea7d.camel@j-davis.com

--
John Naylor
Amazon Web Services



pgsql-hackers by date:

Previous
From: Matthias van de Meent
Date:
Subject: Re: Revisiting {CREATE INDEX, REINDEX} CONCURRENTLY improvements
Next
From: wenhui qiu
Date:
Subject: Re: POC: track vacuum/analyze cumulative time per relation