Re: [RFC, POC] Don't require a NBuffer sized PrivateRefCount array of local buffer pins

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: [RFC, POC] Don't require a NBuffer sized PrivateRefCount array of local buffer pins
Дата
Msg-id 20140409143050.GK4161@awork2.anarazel.de
обсуждение исходный текст
Ответ на Re: [RFC, POC] Don't require a NBuffer sized PrivateRefCount array of local buffer pins  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 2014-04-09 10:26:25 -0400, Tom Lane wrote:
> Andres Freund <andres@2ndquadrant.com> writes:
> > It's not unreasonable to argue that we just shouldn't optimize for
> > several pins held by the same backend for the same and always touch the
> > global count.
> 
> NAK.

Note I didn't implement it because I wasn't too convinced either ;)

> That would be a killer because of increased contention for buffer
> headers.  The code is full of places where a buffer's PrivateRefCount
> jumps up and down a bit, for example when transferring a tuple into a
> TupleTableSlot.

On the other hand in those scenarios the backend is pretty likely to
already have the cacheline locally in exclusive mode...

Greetings,

Andres Freund

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



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [RFC, POC] Don't require a NBuffer sized PrivateRefCount array of local buffer pins
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: New option in pg_basebackup to exclude pg_log files during base backup