Re: Inefficiency in SLRU stats collection

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Inefficiency in SLRU stats collection
Дата
Msg-id 389.1589380963@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Inefficiency in SLRU stats collection  (Kyotaro Horiguchi <horikyota.ntt@gmail.com>)
Список pgsql-hackers
Kyotaro Horiguchi <horikyota.ntt@gmail.com> writes:
> AFAICS it is right and the change suggested looks reasonable to me.
> One arguable point might be whether it is right that SlruData holds
> pgstats internal index from the standpoint of modularity.  (It is one
> of the reasons I didn't propose a patch for that..)

Yeah, this is a fair point.  On the other hand, the existing code has
pgstat.c digging into the SLRU control structure, which is as bad or
worse a modularity violation.  Perhaps we could ditch that by having
slru.c obtain and store the integer index which it then passes to
the pgstat.c counter routines, rather than passing a SlruCtl pointer.

I'll have to look at whether 28cac71bd exposed a data structure that
was formerly private, but if it did I'd be VERY strongly inclined
to revert that.

            regards, tom lane



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

Предыдущее
От: Антон Пацев
Дата:
Сообщение: Ideas about moving live rows to the top of the table
Следующее
От: Fujii Masao
Дата:
Сообщение: Re: SLRU statistics