postgresql/src/include
Andres Freund 59f71a0d0b Add a default local latch for use in signal handlers.
To do so, move InitializeLatchSupport() into the new common process
initialization functions, and add a new global variable MyLatch.

MyLatch is usable as soon InitPostmasterChild() has been called
(i.e. very early during startup). Initially it points to a process
local latch that exists in all processes. InitProcess/InitAuxiliaryProcess
then replaces that local latch with PGPROC->procLatch. During shutdown
the reverse happens.

This is primarily advantageous for two reasons: For one it simplifies
dealing with the shared process latch, especially in signal handlers,
because instead of having to check for MyProc, MyLatch can be used
unconditionally. For another, a later patch that makes FEs/BE
communication use latches, now can rely on the existence of a latch,
even before having gone through InitProcess.

Discussion: 20140927191243.GD5423@alap3.anarazel.de
2015-01-14 18:45:22 +01:00
..
access Update copyright for 2015 2015-01-06 11:43:47 -05:00
bootstrap Update copyright for 2015 2015-01-06 11:43:47 -05:00
catalog Update copyright for 2015 2015-01-06 11:43:47 -05:00
commands Update copyright for 2015 2015-01-06 11:43:47 -05:00
common Update copyright for 2015 2015-01-06 11:43:47 -05:00
datatype Update copyright for 2015 2015-01-06 11:43:47 -05:00
executor Update copyright for 2015 2015-01-06 11:43:47 -05:00
foreign Update copyright for 2015 2015-01-06 11:43:47 -05:00
lib Update copyright for 2015 2015-01-06 11:43:47 -05:00
libpq Update copyright for 2015 2015-01-06 11:43:47 -05:00
mb Update copyright for 2015 2015-01-06 11:43:47 -05:00
nodes Update copyright for 2015 2015-01-06 11:43:47 -05:00
optimizer Update copyright for 2015 2015-01-06 11:43:47 -05:00
parser Update copyright for 2015 2015-01-06 11:43:47 -05:00
port Fix typos in comment. 2015-01-13 10:32:38 +02:00
portability Update copyright for 2015 2015-01-06 11:43:47 -05:00
postmaster Update copyright for 2015 2015-01-06 11:43:47 -05:00
regex Update copyright for 2015 2015-01-06 11:43:47 -05:00
replication Update copyright for 2015 2015-01-06 11:43:47 -05:00
rewrite Update copyright for 2015 2015-01-06 11:43:47 -05:00
snowball Update copyright for 2015 2015-01-06 11:43:47 -05:00
storage Add a default local latch for use in signal handlers. 2015-01-14 18:45:22 +01:00
tcop Update copyright for 2015 2015-01-06 11:43:47 -05:00
tsearch Update copyright for 2015 2015-01-06 11:43:47 -05:00
utils Update copyright for 2015 2015-01-06 11:43:47 -05:00
.gitignore Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00
c.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
fmgr.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
funcapi.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
getaddrinfo.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
getopt_long.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
Makefile Install all headers for the new atomics API. 2014-10-02 16:52:21 +02:00
miscadmin.h Add a default local latch for use in signal handlers. 2015-01-14 18:45:22 +01:00
pg_config_ext.h.in Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00
pg_config_ext.h.win32 Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00
pg_config_manual.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
pg_config.h.in Remove configure test for nonstandard variants of getpwuid_r(). 2015-01-11 12:52:37 -05:00
pg_config.h.win32 Remove configure test for nonstandard variants of getpwuid_r(). 2015-01-11 12:52:37 -05:00
pg_getopt.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
pg_trace.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
pgstat.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
pgtar.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
pgtime.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
port.h Fix libpq's behavior when /etc/passwd isn't readable. 2015-01-11 12:35:44 -05:00
postgres_ext.h pgindent run for 9.4 2014-05-06 12:12:18 -04:00
postgres_fe.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
postgres.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
rusagestub.h Update copyright for 2015 2015-01-06 11:43:47 -05:00
windowapi.h Update copyright for 2015 2015-01-06 11:43:47 -05:00