Re: Memory Usage and libpq

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Memory Usage and libpq
Дата
Msg-id 14006.1144181166@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Memory Usage and libpq  (Keary Suska <hierophant@pcisys.net>)
Список pgsql-interfaces
Keary Suska <hierophant@pcisys.net> writes:
> I am investigating a memory usage issue and I noticed something with libpq.
> It appears that libpq doesn't actually free memory allocated to store
> results, even after PQclear() is called. In a debug program I can inspect
> the buffer so I know it exists. I haven't verified whether the buffer is
> resized with subsequent calls, but when dealing with large result sets it
> creates a significant memory overhead.

This would depend entirely on how malloc/free are implemented on your
platform.  Some versions can release space back to the OS, some can't.
In some it depends on what else has been allocated.
        regards, tom lane


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

Предыдущее
От: Keary Suska
Дата:
Сообщение: Re: PQconnectdb et.all.
Следующее
От: "patrick keshishian"
Дата:
Сообщение: pgsql_perl5-1.9.0 / Pg - patch for PQescapeString