On Mon, Jan 8, 2018 at 1:32 PM, Thomas Munro <thomas.mu...@enterprisedb.com> wrote: > Also pgarch.c, syncrep.c, walsender.c and walreceiver.c use > PostmasterIsAlive() every time through their loops[1] generating extra > syscalls, one instance of which has caused complaints before[1] on a > system where the syscall was expensive (arguably because that kernel > needs some work but still, it's an example of the thing you asked > about). > > [1] > https://www.postgresql.org/message-id/flat/20160915135755.GC19008%40genua.de
Or we could replace calls to PostmasterIsAlive() by checks on WL_POSTMASTER_DEATH? At least for the WAL sender portion it looks doable. -- Michael