On Thu, Mar 23, 2023 at 7:43 AM Thomas Munro <thomas.munro@gmail.com> wrote:
>
> Hi,
>
> Commit dee663f7 made WAIT_EVENT_SLRU_FLUSH_SYNC redundant, so here's a
> patch to remove it.
Yeah, commit [1] removed the last trace of it. I wonder if we can add
a WAIT_EVENT_SLRU_FLUSH_SYNC wait event in SlruSyncFileTag(), similar
to mdsyncfiletag. This way, we would have covered all sync_syncfiletag
fsyncs with wait events.
> In case it's useful again, here's how I noticed:
>
> for X in ` grep WAIT_EVENT_ src/include/utils/wait_event.h |
> sed '/^#/d;s/,//;s/ = .*//' `
> do
> if ! ( git grep $X |
> grep -v src/include/utils/wait_event.h |
> grep -v src/backend/utils/activity/wait_event.c |
> grep $X > /dev/null )
> then
> echo "$X is not used"
> fi
> done
Interesting. It might be an overkill to think of placing it as a
compile-time script to catch similar miss-outs in future.
[1]
commit dee663f7843902535a15ae366cede8b4089f1144
Author: Thomas Munro <tmunro@postgresql.org>
Date: Fri Sep 25 18:49:43 2020 +1200
Defer flushing of SLRU files.
--
Bharath Rupireddy
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com