Re: dynamically allocating chunks from shared memory

Поиск
Список
Период
Сортировка
От Markus Wanner
Тема Re: dynamically allocating chunks from shared memory
Дата
Msg-id 4C604F3F.1060002@bluegap.ch
обсуждение исходный текст
Ответ на Re: dynamically allocating chunks from shared memory  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-hackers
On 08/09/2010 08:49 PM, Bruce Momjian wrote:
> Markus Wanner wrote:
>> That's what my patch allows you to do, yes. Currently you are bound to
>> pre-allocate shared memory at startup. Or how would you allocate small
>> chunks from shared memory at the moment?
>
> We don't --- we allocate it all at startup.

Exactly. And that's the difference to a thread-based approach. The 
downside of it is that you need to know in advance how much shared 
memory each of the subsystems is going to need. On the upside is the 
certainty, that you already have the memory allocated and cannot run out 
of it. You just have what you have.

(Note that you could do that as well with the thread-based approach, if 
you want. Most other programs I know don't choose that approach, though, 
but instead try to cope with OOM).

Regards

Markus


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

Предыдущее
От: Thom Brown
Дата:
Сообщение: Re: host name support in pg_hba.conf
Следующее
От: Robert Haas
Дата:
Сообщение: Re: dynamically allocating chunks from shared memory