Hi hackers, While working on [1], I noticed a discrepancy between lwlock.c and wait_event_names.txt for 2 wait events.
Indeed, the wait event names are MultixactOffsetSLRU and MultixactMemberSLRU in the C file but MultiXactOffsetSLRU and MultiXactMemberSLRU in the text file. That breaks joins between pg_stat_activity and pg_wait_events on the wait event name. PFA a patch to fix those (I'm not able to find other discrepancy with the "automated" work I'm doing in [1], so I'm confident there is no others). Oversight in commit 53c2a97a9266. [1]: https://www.postgresql.org/message-id/aHZiHZ8sSQdHpyM6%40bdt-Laptop-13th-Gen-Intel-Core Regards, -- Bertrand Drouvot PostgreSQL Contributors Team RDS Open Source Databases Amazon Web Services: https://aws.amazon.com
>From ceef3dea35a28546bd4b6e4b5a78878640815c77 Mon Sep 17 00:00:00 2001 From: Bertrand Drouvot <bertranddrouvot...@gmail.com> Date: Wed, 16 Jul 2025 08:51:34 +0000 Subject: [PATCH v1] Fix lwlock.c and wait_event_names.txt discrepancy The wait event names are MultixactOffsetSLRU and MultixactMemberSLRU in the C file but MultiXactOffsetSLRU and MultiXactMemberSLRU in the text file. That breaks joins between pg_stat_activity and pg_wait_events on the wait event name. Fix to ensure both matches. Oversight in commit 53c2a97a9266. --- src/backend/storage/lmgr/lwlock.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/storage/lmgr/lwlock.c b/src/backend/storage/lmgr/lwlock.c index 46f44bc4511..2d43bf2cc13 100644 --- a/src/backend/storage/lmgr/lwlock.c +++ b/src/backend/storage/lmgr/lwlock.c @@ -170,8 +170,8 @@ static const char *const BuiltinTrancheNames[] = { [LWTRANCHE_DSM_REGISTRY_DSA] = "DSMRegistryDSA", [LWTRANCHE_DSM_REGISTRY_HASH] = "DSMRegistryHash", [LWTRANCHE_COMMITTS_SLRU] = "CommitTsSLRU", - [LWTRANCHE_MULTIXACTOFFSET_SLRU] = "MultixactOffsetSLRU", - [LWTRANCHE_MULTIXACTMEMBER_SLRU] = "MultixactMemberSLRU", + [LWTRANCHE_MULTIXACTOFFSET_SLRU] = "MultiXactOffsetSLRU", + [LWTRANCHE_MULTIXACTMEMBER_SLRU] = "MultiXactMemberSLRU", [LWTRANCHE_NOTIFY_SLRU] = "NotifySLRU", [LWTRANCHE_SERIAL_SLRU] = "SerialSLRU", [LWTRANCHE_SUBTRANS_SLRU] = "SubtransSLRU", -- 2.34.1