Re: Using WaitEventSet in the postmaster
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Thomas Munro <thomas.munro@gmail.com>
Cc: Andres Freund <andres@anarazel.de>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2023-01-12T06:27:16Z
Lists: pgsql-hackers
Thomas Munro <thomas.munro@gmail.com> writes: > Pushed, after a few very minor adjustments, mostly comments. Thanks > for the reviews and pointers. I think there are quite a lot of > refactoring and refinement opportunities unlocked by this change (I > have some draft proposals already), but for now I'll keep an eye on > the build farm. skink seems to have found a problem: ==2011873== VALGRINDERROR-BEGIN ==2011873== Syscall param epoll_wait(events) points to unaddressable byte(s) ==2011873== at 0x4D8DC73: epoll_wait (epoll_wait.c:30) ==2011873== by 0x55CA49: WaitEventSetWaitBlock (latch.c:1527) ==2011873== by 0x55D591: WaitEventSetWait (latch.c:1473) ==2011873== by 0x4F2B28: ServerLoop (postmaster.c:1729) ==2011873== by 0x4F3E85: PostmasterMain (postmaster.c:1452) ==2011873== by 0x42643C: main (main.c:200) ==2011873== Address 0x7b1e620 is 1,360 bytes inside a recently re-allocated block of size 8,192 alloc'd ==2011873== at 0x48407B4: malloc (vg_replace_malloc.c:381) ==2011873== by 0x6D9D30: AllocSetContextCreateInternal (aset.c:446) ==2011873== by 0x4F2D9B: PostmasterMain (postmaster.c:614) ==2011873== by 0x42643C: main (main.c:200) ==2011873== ==2011873== VALGRINDERROR-END regards, tom lane
Commits
-
Remove unneeded volatile qualifiers from postmaster.c.
- 8d2c1913ed3d 16.0 landed
-
Fix WaitEventSetWait() buffer overrun.
- f1821b58fc8d 16.0 landed
- 8a98523a542f 15.2 landed
- 547e60b8317e 14.7 landed
- c159b0383fa6 13.10 landed
- bf388ab82850 12.14 landed
- 1b40710a8c89 11.19 landed
-
Refactor DetermineSleepTime() to use milliseconds.
- 5a26c7b310b6 16.0 landed
-
Use WaitEventSet API for postmaster's event loop.
- 7389aad63666 16.0 landed
-
Allow parent's WaitEventSets to be freed after fork().
- b5d0f8ec01c0 16.0 landed
-
Don't leak a signalfd when using latches in the postmaster.
- 1f0019de2fe3 16.0 landed
-
Add WL_SOCKET_ACCEPT event to WaitEventSet API.
- 30829e52ff1a 16.0 landed
-
From: Phil Thompson <phil@river-bank.demon.co.uk>
- d5bbe2aca55b 7.1.1 cited