PostgreSQL Source Code
git master
|
#include "postgres.h"
#include <signal.h>
#include <unistd.h>
#include <sys/time.h>
#include "access/transam.h"
#include "access/twophase.h"
#include "access/xlogutils.h"
#include "miscadmin.h"
#include "pgstat.h"
#include "postmaster/autovacuum.h"
#include "replication/slot.h"
#include "replication/syncrep.h"
#include "replication/walsender.h"
#include "storage/condition_variable.h"
#include "storage/ipc.h"
#include "storage/lmgr.h"
#include "storage/pmsignal.h"
#include "storage/proc.h"
#include "storage/procarray.h"
#include "storage/procsignal.h"
#include "storage/spin.h"
#include "storage/standby.h"
#include "utils/timeout.h"
#include "utils/timestamp.h"
Go to the source code of this file.
Variables | |
int | DeadlockTimeout = 1000 |
int | StatementTimeout = 0 |
int | LockTimeout = 0 |
int | IdleInTransactionSessionTimeout = 0 |
int | IdleSessionTimeout = 0 |
bool | log_lock_waits = false |
PGPROC * | MyProc = NULL |
NON_EXEC_STATIC slock_t * | ProcStructLock = NULL |
PROC_HDR * | ProcGlobal = NULL |
NON_EXEC_STATIC PGPROC * | AuxiliaryProcs = NULL |
PGPROC * | PreparedXactProcs = NULL |
static LOCALLOCK * | lockAwaited = NULL |
static DeadLockState | deadlock_state = DS_NOT_YET_CHECKED |
static volatile sig_atomic_t | got_deadlock_timeout |
PGPROC* AuxiliaryPidGetProc | ( | int | pid | ) |
Definition at line 965 of file proc.c.
References AuxiliaryProcs, NUM_AUXILIARY_PROCS, and PGPROC::pid.
Referenced by pg_log_backend_memory_contexts(), and pg_stat_get_activity().
|
static |
Definition at line 921 of file proc.c.
References arg, Assert(), AuxiliaryProcs, ConditionVariableCancelSleep(), DatumGetInt32(), DisownLatch(), LWLockReleaseAll(), MyProc, NUM_AUXILIARY_PROCS, PG_USED_FOR_ASSERTS_ONLY, pgstat_reset_wait_event_storage(), PGPROC::pid, ProcGlobal, PGPROC::procLatch, ProcStructLock, SpinLockAcquire, SpinLockRelease, PROC_HDR::spins_per_delay, SwitchBackToLocalLatch(), and update_spins_per_delay().
Referenced by InitAuxiliaryProcess().
void BecomeLockGroupLeader | ( | void | ) |
Definition at line 1824 of file proc.c.
References Assert(), dlist_push_head(), PGPROC::lockGroupLeader, PGPROC::lockGroupLink, PGPROC::lockGroupMembers, LockHashPartitionLockByProc, LW_EXCLUSIVE, LWLockAcquire(), LWLockRelease(), and MyProc.
Referenced by LaunchParallelWorkers().
Definition at line 1854 of file proc.c.
References Assert(), dlist_push_tail(), PGPROC::lockGroupLeader, PGPROC::lockGroupLink, PGPROC::lockGroupMembers, LockHashPartitionLockByProc, LW_EXCLUSIVE, LWLockAcquire(), LWLockRelease(), MyProc, and PGPROC::pid.
Referenced by ParallelWorkerMain().
|
static |
Definition at line 1685 of file proc.c.
References Assert(), deadlock_state, DeadLockCheck(), DS_HARD_DEADLOCK, i, PGPROC::links, LockHashPartitionLockByIndex, LockTagHashCode(), LW_EXCLUSIVE, LWLockAcquire(), LWLockRelease(), MyProc, dlist_node::next, NUM_LOCK_PARTITIONS, dlist_node::prev, RemoveFromWaitQueue(), LOCK::tag, and PGPROC::waitLock.
Referenced by ProcSleep().
void CheckDeadLockAlert | ( | void | ) |
Definition at line 1771 of file proc.c.
References got_deadlock_timeout, MyLatch, and SetLatch().
Referenced by InitPostgres(), and ProcessRecoveryConflictInterrupt().
int GetStartupBufferPinWaitBufId | ( | void | ) |
Definition at line 639 of file proc.c.
References ProcGlobal, and PROC_HDR::startupBufferPinWaitBufId.
Referenced by HoldingBufferPinThatDelaysRecovery(), and ProcessRecoveryConflictInterrupt().
bool HaveNFreeProcs | ( | int | n, |
int * | nfree | ||
) |
Definition at line 655 of file proc.c.
References Assert(), dlist_foreach, PROC_HDR::freeProcs, ProcGlobal, ProcStructLock, SpinLockAcquire, and SpinLockRelease.
Referenced by InitPostgres().
void InitAuxiliaryProcess | ( | void | ) |
Definition at line 509 of file proc.c.
References Assert(), AuxiliaryProcKill(), AuxiliaryProcs, PGPROC::backendId, PGPROC::databaseId, PGPROC::delayChkptFlags, dlist_is_empty(), dlist_node_init(), elog(), ERROR, FATAL, PGPROC::fpLocalTransactionId, PGPROC::fpVXIDLock, i, Int32GetDatum(), InvalidBackendId, InvalidLocalTransactionId, InvalidOid, InvalidTransactionId, IsBackgroundWorker, PGPROC::isBackgroundWorker, PGPROC::links, PGPROC::lockGroupLeader, PGPROC::lockGroupMembers, LW_WS_NOT_WAITING, PGPROC::lwWaiting, PGPROC::lwWaitMode, PGPROC::lxid, MyProc, PGPROC::myProcLocks, MyProcPid, NUM_AUXILIARY_PROCS, NUM_LOCK_PARTITIONS, on_shmem_exit(), OwnLatch(), PANIC, pg_atomic_write_u64(), PGSemaphoreReset(), pgstat_set_wait_event_storage(), PGPROC::pid, PROC_WAIT_STATUS_OK, ProcGlobal, PGPROC::procLatch, ProcStructLock, PGPROC::roleId, PGPROC::sem, set_spins_per_delay(), SpinLockAcquire, SpinLockRelease, PROC_HDR::spins_per_delay, PGPROC::statusFlags, SwitchToSharedLatch(), PGPROC::tempNamespaceId, PGPROC::wait_event_info, PGPROC::waitLock, PGPROC::waitProcLock, PGPROC::waitStart, PGPROC::waitStatus, PGPROC::xid, and PGPROC::xmin.
Referenced by AuxiliaryProcessMain().
void InitProcess | ( | void | ) |
Definition at line 297 of file proc.c.
References am_walsender, Assert(), PROC_HDR::autovacFreeProcs, PGPROC::backendId, PROC_HDR::bgworkerFreeProcs, PGPROC::clogGroupMember, PGPROC::clogGroupMemberLsn, PGPROC::clogGroupMemberPage, PGPROC::clogGroupMemberXid, PGPROC::clogGroupMemberXidStatus, PGPROC::clogGroupNext, PGPROC::databaseId, PGPROC::delayChkptFlags, dlist_is_empty(), dlist_node_init(), dlist_pop_head_node(), elog(), ereport, errcode(), errmsg(), ERROR, FATAL, PGPROC::fpLocalTransactionId, PGPROC::fpVXIDLock, PROC_HDR::freeProcs, i, InitDeadLockChecking(), InitLWLockAccess(), INVALID_PGPROCNO, InvalidBackendId, InvalidLocalTransactionId, InvalidOid, InvalidTransactionId, InvalidXLogRecPtr, IsAnyAutoVacuumProcess, IsAutoVacuumLauncherProcess(), IsAutoVacuumWorkerProcess(), IsBackgroundWorker, PGPROC::isBackgroundWorker, IsUnderPostmaster, PGPROC::links, PGPROC::lockGroupLeader, PGPROC::lockGroupMembers, LW_WS_NOT_WAITING, PGPROC::lwWaiting, PGPROC::lwWaitMode, PGPROC::lxid, MarkPostmasterChildActive(), max_wal_senders, MyProc, PGPROC::myProcLocks, MyProcPid, NUM_LOCK_PARTITIONS, on_shmem_exit(), OwnLatch(), PANIC, pg_atomic_read_u32(), pg_atomic_write_u64(), PGSemaphoreReset(), pgstat_set_wait_event_storage(), PGPROC::pid, PROC_IS_AUTOVACUUM, PROC_WAIT_STATUS_OK, PGPROC::procArrayGroupMember, PGPROC::procArrayGroupMemberXid, PGPROC::procArrayGroupNext, ProcGlobal, PGPROC::procgloballist, ProcKill(), PGPROC::procLatch, ProcStructLock, PGPROC::recoveryConflictPending, PGPROC::roleId, PGPROC::sem, set_spins_per_delay(), SpinLockAcquire, SpinLockRelease, PROC_HDR::spins_per_delay, PGPROC::statusFlags, SwitchToSharedLatch(), SYNC_REP_NOT_WAITING, PGPROC::syncRepLinks, PGPROC::syncRepState, PGPROC::tempNamespaceId, TRANSACTION_STATUS_IN_PROGRESS, PGPROC::wait_event_info, PGPROC::waitLock, PGPROC::waitLSN, PGPROC::waitProcLock, PGPROC::waitStart, PGPROC::waitStatus, PROC_HDR::walsenderFreeProcs, PGPROC::xid, and PGPROC::xmin.
Referenced by AutoVacLauncherMain(), AutoVacWorkerMain(), BackendStartup(), BootstrapModeMain(), PostgresSingleUserMain(), and StartBackgroundWorker().
void InitProcessPhase2 | ( | void | ) |
Definition at line 474 of file proc.c.
References Assert(), MyProc, on_shmem_exit(), ProcArrayAdd(), and RemoveProcFromArray().
Referenced by InitPostgres().
void InitProcGlobal | ( | void | ) |
Definition at line 157 of file proc.c.
References PROC_HDR::allProcCount, PROC_HDR::allProcs, Assert(), PROC_HDR::autovacFreeProcs, autovacuum_max_workers, AuxiliaryProcs, PROC_HDR::bgworkerFreeProcs, PROC_HDR::checkpointerLatch, PROC_HDR::clogGroupFirst, PGPROC::clogGroupNext, DEFAULT_SPINS_PER_DELAY, dlist_init(), dlist_push_head(), PGPROC::fpInfoLock, PROC_HDR::freeProcs, i, InitSharedLatch(), INVALID_PGPROCNO, j, PGPROC::links, PGPROC::lockGroupMembers, LWLockInitialize(), LWTRANCHE_LOCK_FASTPATH, max_prepared_xacts, max_worker_processes, MaxBackends, MaxConnections, MemSet, PGPROC::myProcLocks, NUM_AUXILIARY_PROCS, NUM_LOCK_PARTITIONS, pg_atomic_init_u32(), pg_atomic_init_u64(), PGPROC::pgprocno, PGSemaphoreCreate(), PreparedXactProcs, PROC_HDR::procArrayGroupFirst, PGPROC::procArrayGroupNext, ProcGlobal, PGPROC::procgloballist, PGPROC::procLatch, ProcStructLock, PGPROC::sem, ShmemAlloc(), ShmemInitStruct(), SpinLockInit, PROC_HDR::spins_per_delay, PROC_HDR::startupBufferPinWaitBufId, PROC_HDR::statusFlags, PROC_HDR::subxidStates, PGPROC::waitStart, PROC_HDR::walsenderFreeProcs, PROC_HDR::walwriterLatch, and PROC_HDR::xids.
Referenced by CreateSharedMemoryAndSemaphores().
bool IsWaitingForLock | ( | void | ) |
Definition at line 681 of file proc.c.
References lockAwaited.
Referenced by ProcessRecoveryConflictInterrupt().
void LockErrorCleanup | ( | void | ) |
Definition at line 698 of file proc.c.
References AbortStrongLockAcquire(), DEADLOCK_TIMEOUT, disable_timeouts(), dlist_node_is_detached(), GrantAwaitedLock(), LOCALLOCK::hashcode, HOLD_INTERRUPTS, DisableTimeoutParams::id, DisableTimeoutParams::keep_indicator, PGPROC::links, LOCK_TIMEOUT, lockAwaited, LockHashPartitionLock, LW_EXCLUSIVE, LWLockAcquire(), LWLockRelease(), MyProc, PROC_WAIT_STATUS_OK, RemoveFromWaitQueue(), RESUME_INTERRUPTS, and PGPROC::waitStatus.
Referenced by AbortSubTransaction(), AbortTransaction(), ProcessInterrupts(), ProcessRecoveryConflictInterrupt(), and ProcReleaseLocks().
int ProcGlobalSemas | ( | void | ) |
Definition at line 122 of file proc.c.
References MaxBackends, and NUM_AUXILIARY_PROCS.
Referenced by CalculateShmemSize().
Size ProcGlobalShmemSize | ( | void | ) |
Definition at line 100 of file proc.c.
References add_size(), max_prepared_xacts, MaxBackends, mul_size(), NUM_AUXILIARY_PROCS, ProcGlobal, PROC_HDR::statusFlags, PROC_HDR::subxidStates, and PROC_HDR::xids.
Referenced by CalculateShmemSize().
|
static |
Definition at line 802 of file proc.c.
References Assert(), AutovacuumLauncherPid, ConditionVariableCancelSleep(), DisownLatch(), dlist_delete(), dlist_is_empty(), dlist_push_head(), dlist_push_tail(), i, IsAutoVacuumLauncherProcess(), IsUnderPostmaster, kill, PGPROC::links, PGPROC::lockGroupLeader, PGPROC::lockGroupLink, PGPROC::lockGroupMembers, LockHashPartitionLockByProc, LW_EXCLUSIVE, LWLockAcquire(), LWLockRelease(), LWLockReleaseAll(), MarkPostmasterChildInactive(), MyProc, PGPROC::myProcLocks, NUM_LOCK_PARTITIONS, pgstat_reset_wait_event_storage(), ProcGlobal, PGPROC::procgloballist, PGPROC::procLatch, ProcStructLock, SIGUSR2, SpinLockAcquire, SpinLockRelease, PROC_HDR::spins_per_delay, SwitchBackToLocalLatch(), SyncRepCleanupAtProcExit(), and update_spins_per_delay().
Referenced by InitProcess().
void ProcLockWakeup | ( | LockMethod | lockMethodTable, |
LOCK * | lock | ||
) |
Definition at line 1637 of file proc.c.
References LockMethodData::conflictTab, dlist_mutable_iter::cur, dclist_foreach_modify, dclist_is_empty(), dlist_container, GrantLock(), links, LOCKBIT_ON, LockCheckConflicts(), PROC_WAIT_STATUS_OK, ProcWakeup(), PGPROC::waitLockMode, PGPROC::waitProcLock, and LOCK::waitProcs.
Referenced by CleanUpLock(), and DeadLockCheck().
void ProcReleaseLocks | ( | bool | isCommit | ) |
Definition at line 774 of file proc.c.
References DEFAULT_LOCKMETHOD, LockErrorCleanup(), LockReleaseAll(), MyProc, and USER_LOCKMETHOD.
Referenced by ResourceOwnerReleaseInternal().
void ProcSendSignal | ( | int | pgprocno | ) |
Definition at line 1809 of file proc.c.
References PROC_HDR::allProcCount, PROC_HDR::allProcs, elog(), ERROR, ProcGlobal, PGPROC::procLatch, and SetLatch().
Referenced by ReleasePredicateLocks(), and UnpinBuffer().
ProcWaitStatus ProcSleep | ( | LOCALLOCK * | locallock, |
LockMethod | lockMethodTable | ||
) |
Definition at line 1004 of file proc.c.
References AccessExclusiveLock, appendStringInfo(), Assert(), buf, CHECK_FOR_INTERRUPTS, CheckDeadLock(), CheckRecoveryConflictDeadlock(), LockMethodData::conflictTab, dlist_iter::cur, StringInfoData::data, dclist_foreach, dclist_insert_before(), dclist_is_empty(), dclist_push_tail(), deadlock_state, DEADLOCK_TIMEOUT, DeadlockTimeout, DEBUG1, EnableTimeoutParams::delay_ms, DescribeLockTag(), disable_timeout(), disable_timeouts(), dlist_container, dlist_foreach, DS_BLOCKED_BY_AUTOVACUUM, DS_HARD_DEADLOCK, DS_NO_DEADLOCK, DS_NOT_YET_CHECKED, DS_SOFT_DEADLOCK, enable_timeout_after(), enable_timeouts(), ereport, errdetail_log(), errdetail_log_plural(), errmsg(), errmsg_internal(), get_timeout_start_time(), GetBlockingAutoVacuumPgproc(), GetCurrentTimestamp(), GetLockConflicts(), GetLockmodeName(), got_deadlock_timeout, GrantAwaitedLock(), GrantLock(), PROCLOCK::groupLeader, LOCALLOCK::hashcode, PGPROC::heldLocks, PROCLOCK::holdMask, EnableTimeoutParams::id, DisableTimeoutParams::id, InHotStandby, initStringInfo(), InRecovery, DisableTimeoutParams::keep_indicator, kill, PGPROC::links, links, LOCALLOCKTAG::lock, LOCALLOCK::lock, LOCK_TIMEOUT, lockAwaited, LOCKBIT_ON, LockCheckConflicts(), PGPROC::lockGroupLeader, LockHashPartitionLock, LOCKTAG::locktag_lockmethodid, LOCKTAG::locktag_type, LockTimeout, LOG, log_lock_waits, log_recovery_conflict_waits, LogRecoveryConflict(), LW_EXCLUSIVE, LW_SHARED, LWLockAcquire(), LWLockRelease(), message_level_is_interesting(), LOCALLOCKTAG::mode, MyLatch, MyProc, PROCLOCKTAG::myProc, MyProcPid, now(), pfree(), pg_atomic_write_u64(), PG_WAIT_LOCK, PGPROC::pgxactoff, PGPROC::pid, PROC_IS_AUTOVACUUM, PROC_VACUUM_FOR_WRAPAROUND, PROC_WAIT_STATUS_ERROR, PROC_WAIT_STATUS_OK, PROC_WAIT_STATUS_WAITING, ProcGlobal, LOCALLOCK::proclock, LOCK::procLocks, PROCSIG_RECOVERY_CONFLICT_LOCK, RecoveryInProgress(), RememberSimpleDeadLock(), RemoveFromWaitQueue(), ResetLatch(), ResolveRecoveryConflictWithLock(), PROC_HDR::statusFlags, LOCK::tag, PROCLOCK::tag, LOCALLOCK::tag, TimestampDifference(), TimestampDifferenceExceeds(), TMPARAM_AFTER, EnableTimeoutParams::type, WaitLatch(), PGPROC::waitLock, PGPROC::waitLockMode, LOCK::waitMask, PGPROC::waitProcLock, LOCK::waitProcs, PGPROC::waitStart, PGPROC::waitStatus, WARNING, WL_EXIT_ON_PM_DEATH, and WL_LATCH_SET.
Referenced by WaitOnLock().
void ProcWaitForSignal | ( | uint32 | wait_event_info | ) |
Definition at line 1797 of file proc.c.
References CHECK_FOR_INTERRUPTS, MyLatch, ResetLatch(), WaitLatch(), WL_EXIT_ON_PM_DEATH, and WL_LATCH_SET.
Referenced by GetSafeSnapshot(), LockBufferForCleanup(), ResolveRecoveryConflictWithBufferPin(), and ResolveRecoveryConflictWithLock().
void ProcWakeup | ( | PGPROC * | proc, |
ProcWaitStatus | waitStatus | ||
) |
Definition at line 1609 of file proc.c.
References Assert(), dclist_delete_from_thoroughly(), dlist_node_is_detached(), PGPROC::links, MyProc, pg_atomic_write_u64(), PROC_WAIT_STATUS_WAITING, PGPROC::procLatch, SetLatch(), PGPROC::waitLock, PGPROC::waitProcLock, LOCK::waitProcs, PGPROC::waitStart, and PGPROC::waitStatus.
Referenced by ProcLockWakeup().
|
static |
Definition at line 791 of file proc.c.
References Assert(), InvalidTransactionId, MyProc, and ProcArrayRemove().
Referenced by InitProcessPhase2().
void SetStartupBufferPinWaitBufId | ( | int | bufid | ) |
Definition at line 627 of file proc.c.
References ProcGlobal, and PROC_HDR::startupBufferPinWaitBufId.
Referenced by LockBufferForCleanup().
NON_EXEC_STATIC PGPROC* AuxiliaryProcs = NULL |
Definition at line 79 of file proc.c.
Referenced by AuxiliaryPidGetProc(), AuxiliaryProcKill(), InitAuxiliaryProcess(), and InitProcGlobal().
|
static |
Definition at line 85 of file proc.c.
Referenced by CheckDeadLock(), and ProcSleep().
int DeadlockTimeout = 1000 |
Definition at line 58 of file proc.c.
Referenced by LockBufferForCleanup(), ProcSleep(), ResolveRecoveryConflictWithBufferPin(), ResolveRecoveryConflictWithLock(), and ResolveRecoveryConflictWithVirtualXIDs().
|
static |
Definition at line 88 of file proc.c.
Referenced by CheckDeadLockAlert(), and ProcSleep().
int IdleInTransactionSessionTimeout = 0 |
Definition at line 61 of file proc.c.
Referenced by PostgresMain(), and ProcessInterrupts().
int IdleSessionTimeout = 0 |
Definition at line 62 of file proc.c.
Referenced by PostgresMain(), and ProcessInterrupts().
|
static |
Definition at line 83 of file proc.c.
Referenced by IsWaitingForLock(), LockErrorCleanup(), and ProcSleep().
int LockTimeout = 0 |
Definition at line 60 of file proc.c.
Referenced by ProcSleep().
Definition at line 63 of file proc.c.
Referenced by ProcSleep().
PGPROC* MyProc = NULL |
Definition at line 66 of file proc.c.
Referenced by _bt_parallel_build_main(), AbortTransaction(), AtEOSubXact_Namespace(), AtEOXact_Namespace(), AtEOXact_Snapshot(), attach_to_queues(), AutoVacWorkerMain(), AuxiliaryProcKill(), BackgroundWriterMain(), BaseInit(), BecomeLockGroupLeader(), BecomeLockGroupMember(), CheckDeadLock(), CheckpointerMain(), CommitTransaction(), ComputeXidHorizons(), ConditionVariableBroadcast(), ConditionVariableCancelSleep(), ConditionVariablePrepareToSleep(), ConditionVariableTimedSleep(), CountOtherDBBackends(), CreateReplicationSlot(), DefineIndex(), EndPrepare(), errdetail_abort(), exec_eval_simple_expr(), exec_simple_check_plan(), exec_stmt_call(), ExecParallelGetReceiver(), ExecParallelSetupTupleQueues(), ExportSnapshot(), FastPathGetRelationLockEntry(), FastPathGrantRelationLock(), FastPathUnGrantRelationLock(), FindLockCycleRecurseMember(), fmgr_sql(), get_cast_hashentry(), GetCurrentVirtualXIDs(), GetLockConflicts(), GetNewTransactionId(), GetSerializableTransactionSnapshotInt(), GetSnapshotData(), GetSnapshotDataReuse(), GetStableLatestTransactionId(), init_sql_fcache(), InitAuxiliaryProcess(), InitBufferPoolAccess(), InitializeParallelDSM(), InitializeSessionUserId(), InitPostgres(), InitProcess(), InitProcessPhase2(), InitTempTableNamespace(), InitWalSenderSlot(), lock_and_open_sequence(), LockAcquireExtended(), LockBufferForCleanup(), LockCheckConflicts(), LockErrorCleanup(), LockRelease(), LockReleaseAll(), log_status_format(), logicalrep_worker_attach(), LWLockAcquire(), LWLockAcquireOrWait(), LWLockAttemptLock(), LWLockDequeueSelf(), LWLockQueueSelf(), LWLockWaitForVar(), MarkAsPreparingGuts(), MarkBufferDirtyHint(), MinimumActiveBackends(), pa_setup_dsm(), parallel_vacuum_main(), ParallelApplyWorkerMain(), ParallelWorkerMain(), PgArchiverMain(), pgstat_report_activity(), PhysicalReplicationSlotNewXmin(), PostPrepare_Locks(), PrepareTransaction(), ProcArrayGroupClearXid(), ProcArrayInstallImportedXmin(), ProcArrayInstallRestoredXmin(), ProcessRecoveryConflictInterrupt(), ProcessStandbyHSFeedbackMessage(), ProcKill(), ProcReleaseLocks(), ProcSleep(), ProcWakeup(), RecordTransactionCommit(), RecordTransactionCommitPrepared(), ReinitializeParallelDSM(), RelationTruncate(), RemoveProcFromArray(), ReplicationSlotRelease(), ResolveRecoveryConflictWithLock(), set_indexsafe_procflags(), setup_dynamic_shared_memory(), SharedInvalBackendInit(), shm_mq_attach(), shm_mq_detach_internal(), shm_mq_receive(), shm_mq_sendv(), shm_mq_wait_for_attach(), SnapBuildInitialSnapshot(), SnapshotResetXmin(), StartTransaction(), StartupDecodingContext(), SwitchBackToLocalLatch(), SwitchToSharedLatch(), SyncRepCancelWait(), SyncRepCleanupAtProcExit(), SyncRepQueueInsert(), SyncRepWaitForLSN(), TerminateOtherDBBackends(), TransactionGroupUpdateXidStatus(), TransactionIdIsInProgress(), TransactionIdSetPageStatus(), TruncateMultiXact(), UnlockBuffers(), vacuum_rel(), VirtualXactLockTableCleanup(), VirtualXactLockTableInsert(), WaitXLogInsertionsToFinish(), WALInsertLockAcquire(), WalReceiverMain(), WalWriterMain(), write_csvlog(), write_jsonlog(), XidCacheRemoveRunningXids(), and XLogSaveBufferForHint().
PGPROC* PreparedXactProcs = NULL |
Definition at line 80 of file proc.c.
Referenced by InitProcGlobal(), and TwoPhaseShmemInit().
PROC_HDR* ProcGlobal = NULL |
Definition at line 78 of file proc.c.
Referenced by AuxiliaryProcKill(), BackendXidGetPid(), CheckpointerMain(), ComputeXidHorizons(), CountOtherDBBackends(), CreateSharedProcArray(), FastPathTransferRelationLocks(), FinishPreparedTransaction(), ForwardSyncRequest(), GetCurrentVirtualXIDs(), GetLockConflicts(), GetLockStatusData(), GetNewTransactionId(), GetOldestActiveTransactionId(), GetOldestSafeDecodingTransactionId(), GetRunningTransactionData(), GetSnapshotData(), GetStartupBufferPinWaitBufId(), GXactLoadSubxactData(), HaveNFreeProcs(), InitAuxiliaryProcess(), InitProcess(), InitProcGlobal(), LockGXact(), MarkAsPrepared(), MarkAsPreparingGuts(), pg_prepared_xact(), PgArchWakeup(), ProcArrayAdd(), ProcArrayClearTransaction(), ProcArrayEndTransaction(), ProcArrayEndTransactionInternal(), ProcArrayGroupClearXid(), ProcArrayInstallImportedXmin(), ProcArrayInstallRestoredXmin(), ProcArrayRemove(), ProcGlobalShmemSize(), ProcKill(), ProcSendSignal(), ProcSleep(), ReplicationSlotRelease(), set_indexsafe_procflags(), SetStartupBufferPinWaitBufId(), StartPrepare(), StartupDecodingContext(), StrategyGetBuffer(), TransactionGroupUpdateXidStatus(), TransactionIdIsActive(), TransactionIdIsInProgress(), TwoPhaseGetDummyProc(), TwoPhaseGetXidByVirtualXID(), vacuum_rel(), WalWriterMain(), XidCacheRemoveRunningXids(), and XLogSetAsyncXactLSN().
NON_EXEC_STATIC slock_t* ProcStructLock = NULL |
Definition at line 75 of file proc.c.
Referenced by AuxiliaryProcKill(), HaveNFreeProcs(), InitAuxiliaryProcess(), InitProcess(), InitProcGlobal(), and ProcKill().
int StatementTimeout = 0 |
Definition at line 59 of file proc.c.
Referenced by enable_statement_timeout().