Re: [PATCH] PostgreSQL 9.4 mmap(2) performance regression on FreeBSD...

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: [PATCH] PostgreSQL 9.4 mmap(2) performance regression on FreeBSD...
Дата
Msg-id 20140812165949.GA26489@awork2.anarazel.de
обсуждение исходный текст
Ответ на [PATCH] PostgreSQL 9.4 mmap(2) performance regression on FreeBSD...  (Sean Chittenden <sean@chittenden.org>)
Ответы Re: [PATCH] PostgreSQL 9.4 mmap(2) performance regression on FreeBSD...  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
On 2014-08-12 09:42:30 -0700, Sean Chittenden wrote:
> One of the patches that I've been sitting on and am derelict in punting
> upstream is the attached mmap(2) flags patch for the BSDs. Is there any
> chance this can be squeezed in to the PostreSQL 9.4 release?
> 
> The patch is trivial in size and is used to add one flag to mmap(2) calls in
> dsm_impl.c.  Alan Cox (FreeBSD alc, not Linux) and I went back and forth
> regarding PostgreSQL's use of mmap(2) and determined that the following is
> correct and will prevent a likely performance regression in PostgreSQL 9.4.
> In PostgreSQL 9.3, all mmap(2) calls were called with the flags MAP_ANON |
> MAP_SHARED, whereas in PostgreSQL 9.4 this is not the case.

The performancewise important call to mmap will still use that set of
flags, no? That's the one backing shared_buffers.

The mmap backend for *dynamic* shared memory (aka dsm) is *NOT* supposed
to be used on common platforms. Both posix and sysv shared memory will
be used before falling back to the mmap() backend.

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



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

Предыдущее
От: Sean Chittenden
Дата:
Сообщение: [PATCH] PostgreSQL 9.4 mmap(2) performance regression on FreeBSD...
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [RFC] Should smgrtruncate() avoid sending sinval message for temp relations