Re: pgstat cleanup: use palloc and AllocateFile

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pgstat cleanup: use palloc and AllocateFile
Дата
Msg-id 21029.1098894047@sss.pgh.pa.us
обсуждение исходный текст
Ответ на pgstat cleanup: use palloc and AllocateFile  (Neil Conway <neilc@samurai.com>)
Ответы Re: pgstat cleanup: use palloc and AllocateFile  (Neil Conway <neilc@samurai.com>)
Список pgsql-patches
Neil Conway <neilc@samurai.com> writes:
> I changed more_tabstat_space() (which is invoked at various times
> indirectly throughout the backend) to allocate memory in its own private
> memory context, rather than use malloc() -- we can't just use
> CurrentMemoryContext because that may not be sufficiently long-lived.

I'd suggest just allocating the tabstat space in TopMemoryContext.  The
extra sub-context is useless overhead, since you don't actually use it
for management purposes.

            regards, tom lane

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

Предыдущее
От: Devrim GUNDUZ
Дата:
Сообщение: Updated Turkish translations
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: pg_ctl -D canonicalization