Re: Some shared memory chunks are allocated even if related processes won't start

Поиск
Список
Период
Сортировка
От 'Alvaro Herrera'
Тема Re: Some shared memory chunks are allocated even if related processes won't start
Дата
Msg-id 202403041152.fl4psozsstnt@alvherre.pgsql
обсуждение исходный текст
Ответ на RE: Some shared memory chunks are allocated even if related processes won't start  ("Hayato Kuroda (Fujitsu)" <kuroda.hayato@fujitsu.com>)
Ответы RE: Some shared memory chunks are allocated even if related processes won't start  ("Hayato Kuroda (Fujitsu)" <kuroda.hayato@fujitsu.com>)
Список pgsql-hackers
On 2024-Mar-04, Hayato Kuroda (Fujitsu) wrote:

> However, the second idea is still valid, which allows the allocation
> of shared memory dynamically. This is a bit efficient for the system
> which tuples won't be frozen. Thought?

I think it would be worth allocating AutoVacuumShmem->av_workItems using
dynamic shmem allocation, particularly to prevent workitems from being
discarded just because the array is full¹; but other than that, the
struct is just 64 bytes long so I doubt it's useful to allocate it
dynamically.

¹ I mean, if the array is full, just allocate another array, point to it
from the original one, and keep going.

-- 
Álvaro Herrera         PostgreSQL Developer  —  https://www.EnterpriseDB.com/
"The problem with the facetime model is not just that it's demoralizing, but
that the people pretending to work interrupt the ones actually working."
                  -- Paul Graham, http://www.paulgraham.com/opensource.html



В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Andrey M. Borodin"
Дата:
Сообщение: Re: CF entries for 17 to be reviewed
Следующее
От: Mats Kindahl
Дата:
Сообщение: Hooking into ExplainOneQuery() complicated by missing standard_ExplainOneQuery