39 #define PGPROC_MAX_CACHED_SUBXIDS 64
57 #define PROC_IS_AUTOVACUUM 0x01
58 #define PROC_IN_VACUUM 0x02
59 #define PROC_IN_SAFE_IC 0x04
63 #define PROC_VACUUM_FOR_WRAPAROUND 0x08
64 #define PROC_IN_LOGICAL_DECODING 0x10
66 #define PROC_AFFECTS_ALL_HORIZONS 0x20
71 #define PROC_VACUUM_STATE_MASK \
72 (PROC_IN_VACUUM | PROC_IN_SAFE_IC | PROC_VACUUM_FOR_WRAPAROUND)
78 #define PROC_XMIN_FLAGS (PROC_IN_VACUUM | PROC_IN_SAFE_IC)
86 #define FP_LOCK_SLOTS_PER_BACKEND 16
120 #define DELAY_CHKPT_START (1<<0)
121 #define DELAY_CHKPT_COMPLETE (1<<1)
325 #define ProcNumberForTempRelations() \
326 (ParallelLeaderProcNumber == INVALID_PROC_NUMBER ? MyProcNumber : ParallelLeaderProcNumber)
433 #define GetPGProcByNumber(n) (&ProcGlobal->allProcs[(n)])
434 #define GetNumberFromPGProc(proc) ((proc) - &ProcGlobal->allProcs[0])
445 #define NUM_AUXILIARY_PROCS 6
uint32 LocalTransactionId
#define NUM_LOCK_PARTITIONS
void ProcSendSignal(ProcNumber procNumber)
PGDLLIMPORT int IdleInTransactionSessionTimeout
Size ProcGlobalShmemSize(void)
void ProcWakeup(PGPROC *proc, ProcWaitStatus waitStatus)
bool IsWaitingForLock(void)
PGDLLIMPORT int IdleSessionTimeout
bool HaveNFreeProcs(int n, int *nfree)
void InitAuxiliaryProcess(void)
PGDLLIMPORT PROC_HDR * ProcGlobal
#define FP_LOCK_SLOTS_PER_BACKEND
ProcWaitStatus ProcSleep(LOCALLOCK *locallock, LockMethod lockMethodTable, bool dontWait)
int GetStartupBufferPinWaitBufId(void)
PGDLLIMPORT PGPROC * MyProc
void ProcLockWakeup(LockMethod lockMethodTable, LOCK *lock)
#define PGPROC_MAX_CACHED_SUBXIDS
int ProcGlobalSemas(void)
void ProcReleaseLocks(bool isCommit)
void LockErrorCleanup(void)
bool BecomeLockGroupMember(PGPROC *leader, int pid)
PGDLLIMPORT int StatementTimeout
void BecomeLockGroupLeader(void)
PGDLLIMPORT int DeadlockTimeout
PGPROC * AuxiliaryPidGetProc(int pid)
PGDLLIMPORT int LockTimeout
void CheckDeadLockAlert(void)
void InitProcessPhase2(void)
void InitProcGlobal(void)
PGDLLIMPORT bool log_lock_waits
PGDLLIMPORT ProcNumber ParallelLeaderProcNumber
@ PROC_WAIT_STATUS_WAITING
PGDLLIMPORT PGPROC * PreparedXactProcs
PGDLLIMPORT int TransactionTimeout
struct XidCacheStatus XidCacheStatus
void SetStartupBufferPinWaitBufId(int bufid)
void ProcWaitForSignal(uint32 wait_event_info)
PGDLLIMPORT ProcNumber MyProcNumber
NON_EXEC_STATIC PGPROC * AuxiliaryProcs
NON_EXEC_STATIC slock_t * ProcStructLock
Oid fpRelId[FP_LOCK_SLOTS_PER_BACKEND]
bool procArrayGroupMember
XLogRecPtr clogGroupMemberLsn
pg_atomic_uint32 procArrayGroupNext
dlist_head lockGroupMembers
dlist_head * procgloballist
bool recoveryConflictPending
TransactionId clogGroupMemberXid
int64 clogGroupMemberPage
pg_atomic_uint64 waitStart
pg_atomic_uint32 clogGroupNext
XidStatus clogGroupMemberXidStatus
XidCacheStatus subxidStatus
LocalTransactionId fpLocalTransactionId
TransactionId procArrayGroupMemberXid
dlist_head myProcLocks[NUM_LOCK_PARTITIONS]
ProcWaitStatus waitStatus
XidCacheStatus * subxidStates
dlist_head autovacFreeProcs
int startupBufferPinWaitBufId
pg_atomic_uint32 clogGroupFirst
Latch * checkpointerLatch
dlist_head walsenderFreeProcs
dlist_head bgworkerFreeProcs
pg_atomic_uint32 procArrayGroupFirst
TransactionId xids[PGPROC_MAX_CACHED_SUBXIDS]