At Mon, 11 Nov 2019 10:03:14 +0100, Antonin Houska <a...@cybertec.at> wrote in > Michael Paquier <mich...@paquier.xyz> wrote: > > Does something like the attached patch make sense? Reviews are > > welcome. > > This looks good to me.
I have a qustion. The current code assumes that !BM_DIRTY means that the function is dirtying the page. But if !BM_JUST_DIRTIED, the function actually is going to re-dirty the page even if BM_DIRTY. If this is correct, the trigger for stats update is not !BM_DIRTY but !BM_JUST_DIRTIED, or the fact that we passed the line of XLogSaveBufferForHint() could be the trigger, regardless whether the LSN is valid or not. regards. -- Kyotaro Horiguchi NTT Open Source Software Center