Re: Page replacement algorithm in buffer cache

Поиск
Список
Период
Сортировка
От Ants Aasma
Тема Re: Page replacement algorithm in buffer cache
Дата
Msg-id CA+CSw_vSJ49cHKKBhCFpd39h6Eud2LF6PKkME-=kUd7E2MzQRg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Page replacement algorithm in buffer cache  (Atri Sharma <atri.jiit@gmail.com>)
Список pgsql-hackers
On Sat, Mar 23, 2013 at 6:29 AM, Atri Sharma <atri.jiit@gmail.com> wrote:
> One way to distribute memory contention in case of spinlocks could be
> to utilize the fundamentals of NUMA architecture. Specifically, we can
> let the contending backends spin on local flags instead on the buffer
> header flags directly. As access to local cache lines is much cheaper
> and faster than memory locations which are far away in NUMA, we could
> potentially reduce the memory overhead for a specific line and reduce
> the overall overheads as well.

This is not even something for NUMA architectures (which is by now all
multiprocessor machines), even multicore machines have overheads for
bouncing cache lines. The locks don't even have to be local, it's good
enough to just have better probability of each backend contending
hitting a different lock, if we take care of not having the locks
share cache lines. IMO that's the whole point of striping locks, the
critical section is usually cheaper than the cost of getting the cache
line in an exclusive state.

Regards,
Ants Aasma
--
Cybertec Schönig & Schönig GmbH
Gröhrmühlgasse 26
A-2700 Wiener Neustadt
Web: http://www.postgresql-support.de



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

Предыдущее
От: Adriano Lange
Дата:
Сообщение: Re: SDP query optimizer
Следующее
От: Ants Aasma
Дата:
Сообщение: Re: Page replacement algorithm in buffer cache