Re: Scaling shared buffer eviction

Поиск
Список
Период
Сортировка
От Ants Aasma
Тема Re: Scaling shared buffer eviction
Дата
Msg-id CA+CSw_spxTeW1tm6e8FuhH1phKsfjCcJJdBue8dOpUjtqNvKtw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Scaling shared buffer eviction  (Andres Freund <andres@2ndquadrant.com>)
Ответы Re: Scaling shared buffer eviction  (Andres Freund <andres@2ndquadrant.com>)
Список pgsql-hackers
On Fri, Sep 26, 2014 at 3:26 PM, Andres Freund <andres@2ndquadrant.com> wrote:
> Neither, really. The hash calculation is visible in the profile, but not
> that pronounced yet. The primary thing noticeable in profiles (besides
> cache efficiency) is the comparison of the full tag after locating a
> possible match in a bucket. 20 byte memcmp's aren't free.

I'm not arguing against a more efficient hash table, but one simple
win would be to have a buffer tag specific comparison function. I mean
something like the attached patch. This way we avoid the loop counter
overhead, can check the blocknum first and possibly have better branch
prediction.

Do you have a workload where I could test if this helps alleviate the
comparison overhead?

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 по дате отправления:

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Scaling shared buffer eviction
Следующее
От: Stephen Frost
Дата:
Сообщение: WITH CHECK and Column-Level Privileges