Rearrange backend startup sequence so that ShmemIndexLock can become
Tom Lane <tgl@sss.pgh.pa.us>
Rearrange backend startup sequence so that ShmemIndexLock can become an LWLock instead of a spinlock. This hardly matters on Unix machines but should improve startup performance on Windows (or any port using EXEC_BACKEND). Per previous discussion.
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/bootstrap/bootstrap.c | modified | +18 −15 |
| src/backend/postmaster/autovacuum.c | modified | +14 −4 |
| src/backend/postmaster/pgarch.c | modified | +4 −4 |
| src/backend/postmaster/pgstat.c | modified | +32 −13 |
| src/backend/postmaster/postmaster.c | modified | +99 −46 |
| src/backend/postmaster/syslogger.c | modified | +4 −4 |
| src/backend/storage/ipc/ipci.c | modified | +8 −8 |
| src/backend/storage/ipc/shmem.c | modified | +67 −54 |
| src/backend/storage/lmgr/proc.c | modified | +128 −91 |
| src/backend/tcop/postgres.c | modified | +14 −2 |
| src/backend/utils/init/postinit.c | modified | +11 −8 |
| src/include/storage/lwlock.h | modified | +2 −1 |
| src/include/storage/pg_shmem.h | modified | +3 −2 |
| src/include/storage/proc.h | modified | +7 −5 |
| src/include/storage/shmem.h | modified | +3 −2 |