mirror of
https://github.com/postgres/postgres.git
synced 2025-11-21 00:42:43 +03:00
Split WaitEventSet functions to separate source file
latch.c now only contains the Latch related functions, which build on the WaitEventSet abstraction. Most of the platform-dependent stuff is now in waiteventset.c. Reviewed-by: Andres Freund <andres@anarazel.de> Discussion: https://www.postgresql.org/message-id/8a507fb6-df28-49d3-81a5-ede180d7f0fb@iki.fi
This commit is contained in:
@@ -42,7 +42,7 @@ pqinitmask(void)
|
||||
{
|
||||
sigemptyset(&UnBlockSig);
|
||||
|
||||
/* Note: InitializeLatchSupport() modifies UnBlockSig. */
|
||||
/* Note: InitializeWaitEventSupport() modifies UnBlockSig. */
|
||||
|
||||
/* First set all signals, then clear some. */
|
||||
sigfillset(&BlockSig);
|
||||
|
||||
@@ -548,7 +548,7 @@ PostmasterMain(int argc, char *argv[])
|
||||
pqsignal(SIGCHLD, handle_pm_child_exit_signal);
|
||||
|
||||
/* This may configure SIGURG, depending on platform. */
|
||||
InitializeLatchSupport();
|
||||
InitializeWaitEventSupport();
|
||||
InitProcessLocalLatch();
|
||||
|
||||
/*
|
||||
|
||||
@@ -25,6 +25,7 @@ OBJS = \
|
||||
signalfuncs.o \
|
||||
sinval.o \
|
||||
sinvaladt.o \
|
||||
standby.o
|
||||
standby.o \
|
||||
waiteventset.o
|
||||
|
||||
include $(top_srcdir)/src/backend/common.mk
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -18,5 +18,6 @@ backend_sources += files(
|
||||
'sinval.c',
|
||||
'sinvaladt.c',
|
||||
'standby.c',
|
||||
'waiteventset.c',
|
||||
|
||||
)
|
||||
|
||||
2036
src/backend/storage/ipc/waiteventset.c
Normal file
2036
src/backend/storage/ipc/waiteventset.c
Normal file
File diff suppressed because it is too large
Load Diff
@@ -127,7 +127,7 @@ InitPostmasterChild(void)
|
||||
#endif
|
||||
|
||||
/* Initialize process-local latch support */
|
||||
InitializeLatchSupport();
|
||||
InitializeWaitEventSupport();
|
||||
InitProcessLocalLatch();
|
||||
InitializeLatchWaitSet();
|
||||
|
||||
@@ -188,7 +188,7 @@ InitStandaloneProcess(const char *argv0)
|
||||
InitProcessGlobals();
|
||||
|
||||
/* Initialize process-local latch support */
|
||||
InitializeLatchSupport();
|
||||
InitializeWaitEventSupport();
|
||||
InitProcessLocalLatch();
|
||||
InitializeLatchWaitSet();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user