Re: pg_shmem_allocations view

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: pg_shmem_allocations view
Дата
Msg-id CA+TgmoZQq4ppNC-oA4oiBq7zJ_m5ZyiF4rFY6XXQqrCjQaoJYQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: pg_shmem_allocations view  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: pg_shmem_allocations view
Re: pg_shmem_allocations view
Список pgsql-hackers
On Tue, May 6, 2014 at 2:34 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Andres Freund <andres@2ndquadrant.com> writes:
>> Attached are two patches:
>> a) Patch addin a 'name' parameter to dsm_create(). I think we should
>>    apply this to 9.4.
>> b) pg_dynamic_shmem_allocations and pg_static_shmem_allocations
>>    views. The previous version didn't include dsm support and didn't
>>    take the required lock.
>
>> I am not so sure whether b) should be applied together with a) in 9.4,
>> but I'd be happy enough to add docs if people agree with the naming.
>
> FWIW, I vote for fixing (a) now but holding (b) for 9.5.

I guess I'll vote for applying both.  I don't see a lot of risk, and I
think doing one with out the other is somewhat pointless.

Regarding patch 0002, I don't think we're using the term "static
shmem" anywhere else, so I vote for dropping the word static, so that
we have pg_get_shmem_allocations() and
pg_get_dynamic_shmem_allocations().  Also, I think using the
"allocated" column is pretty weird.  There are always exactly two
entries with allocated = false, one of which is for actual free memory
and the other of which is for memory that actually IS allocated but
without using ShmemIndex (maybe the latter was supposed to have
allocated = true but still key = null?).  I guess I'd vote for
ditching the allocated column completely and outputting the memory
allocated without ShmemIndex using some fixed tag (like "ShmemIndex"
or "Bootstrap" or "Overhead" or something).

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Wanted: jsonb on-disk representation documentation
Следующее
От: Kevin Grittner
Дата:
Сообщение: Re: [COMMITTERS] pgsql: pgindent run for 9.4