Re: wal stats questions

Поиск
Список
Период
Сортировка
От Kyotaro Horiguchi
Тема Re: wal stats questions
Дата
Msg-id 20210329.110900.1325449677023103678.horikyota.ntt@gmail.com
обсуждение исходный текст
Ответ на Re: wal stats questions  (Andres Freund <andres@anarazel.de>)
Ответы Re: wal stats questions  (Kyotaro Horiguchi <horikyota.ntt@gmail.com>)
Список pgsql-hackers
At Fri, 26 Mar 2021 10:07:45 -0700, Andres Freund <andres@anarazel.de> wrote in 
> Hi,
> 
> On 2021-03-25 16:37:10 +0900, Kyotaro Horiguchi wrote:
> > On the other hand, the counters are incremented in XLogInsertRecord()
> > and I think we don't want add instructions there.
> 
> I don't really buy this. Setting a boolean to true, in a cacheline
> you're already touching, isn't that much compared to all the other stuff
> in there. The branch to check if wal stats timing etc is enabled is much
> more expensive.  I think we should just set a boolean to true and leave
> it at that.

Hmm. Yes, I agree to you in that opinion.  I (remember I) was told not
to add even a cycle to the hot path as far as we can avoid when I
tried something like that.

So I'm happy to +1 for that if it is the consensus here, since it is
cleaner.

regards.

-- 
Kyotaro Horiguchi
NTT Open Source Software Center



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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: multi-install PostgresNode
Следующее
От: Kyotaro Horiguchi
Дата:
Сообщение: Re: wal stats questions