|
PostgreSQL Source Code git master
|


Go to the source code of this file.
Data Structures | |
| struct | SERIALIZABLEXACT |
| struct | PredXactListData |
| struct | RWConflictData |
| struct | RWConflictPoolHeaderData |
| struct | SERIALIZABLEXIDTAG |
| struct | SERIALIZABLEXID |
| struct | PREDICATELOCKTARGETTAG |
| struct | PREDICATELOCKTARGET |
| struct | PREDICATELOCKTAG |
| struct | PREDICATELOCK |
| struct | LOCALPREDICATELOCK |
| struct | PredicateLockData |
| struct | TwoPhasePredicateXactRecord |
| struct | TwoPhasePredicateLockRecord |
| struct | TwoPhasePredicateRecord |
Enumerations | |
| enum | PredicateLockTargetType { PREDLOCKTAG_RELATION , PREDLOCKTAG_PAGE , PREDLOCKTAG_TUPLE } |
| enum | TwoPhasePredicateRecordType { TWOPHASEPREDICATERECORD_XACT , TWOPHASEPREDICATERECORD_LOCK } |
Functions | |
| PredicateLockData * | GetPredicateLockStatusData (void) |
| int | GetSafeSnapshotBlockingPids (int blocked_pid, int *output, int output_size) |
| #define FirstNormalSerCommitSeqNo ((SerCommitSeqNo) 2) |
Definition at line 40 of file predicate_internals.h.
| #define GET_PREDICATELOCKTARGETTAG_DB | ( | locktag | ) | ((Oid) (locktag).locktag_field1) |
Definition at line 406 of file predicate_internals.h.
| #define GET_PREDICATELOCKTARGETTAG_OFFSET | ( | locktag | ) | ((OffsetNumber) (locktag).locktag_field4) |
Definition at line 412 of file predicate_internals.h.
| #define GET_PREDICATELOCKTARGETTAG_PAGE | ( | locktag | ) | ((BlockNumber) (locktag).locktag_field3) |
Definition at line 410 of file predicate_internals.h.
| #define GET_PREDICATELOCKTARGETTAG_RELATION | ( | locktag | ) | ((Oid) (locktag).locktag_field2) |
Definition at line 408 of file predicate_internals.h.
| #define GET_PREDICATELOCKTARGETTAG_TYPE | ( | locktag | ) |
Definition at line 414 of file predicate_internals.h.
| #define InvalidSerCommitSeqNo ((SerCommitSeqNo) PG_UINT64_MAX) |
Definition at line 38 of file predicate_internals.h.
| #define InvalidSerializableXact ((SERIALIZABLEXACT *) NULL) |
Definition at line 467 of file predicate_internals.h.
| #define PredXactListDataSize ((Size)MAXALIGN(sizeof(PredXactListData))) |
Definition at line 179 of file predicate_internals.h.
| #define RecoverySerCommitSeqNo ((SerCommitSeqNo) 1) |
Definition at line 39 of file predicate_internals.h.
| #define RWConflictDataSize ((Size)MAXALIGN(sizeof(RWConflictData))) |
Definition at line 203 of file predicate_internals.h.
| #define RWConflictPoolHeaderDataSize ((Size)MAXALIGN(sizeof(RWConflictPoolHeaderData))) |
Definition at line 214 of file predicate_internals.h.
| #define SET_PREDICATELOCKTARGETTAG_PAGE | ( | locktag, | |
| dboid, | |||
| reloid, | |||
| blocknum | |||
| ) |
Definition at line 394 of file predicate_internals.h.
| #define SET_PREDICATELOCKTARGETTAG_RELATION | ( | locktag, | |
| dboid, | |||
| reloid | |||
| ) |
Definition at line 388 of file predicate_internals.h.
| #define SET_PREDICATELOCKTARGETTAG_TUPLE | ( | locktag, | |
| dboid, | |||
| reloid, | |||
| blocknum, | |||
| offnum | |||
| ) |
Definition at line 400 of file predicate_internals.h.
| #define SXACT_FLAG_COMMITTED 0x00000001 /* already committed */ |
Definition at line 121 of file predicate_internals.h.
| #define SXACT_FLAG_CONFLICT_OUT 0x00000010 |
Definition at line 130 of file predicate_internals.h.
| #define SXACT_FLAG_DEFERRABLE_WAITING 0x00000040 |
Definition at line 132 of file predicate_internals.h.
| #define SXACT_FLAG_DOOMED 0x00000008 /* will roll back */ |
Definition at line 124 of file predicate_internals.h.
| #define SXACT_FLAG_PARTIALLY_RELEASED 0x00000800 |
Definition at line 142 of file predicate_internals.h.
| #define SXACT_FLAG_PREPARED 0x00000002 /* about to commit */ |
Definition at line 122 of file predicate_internals.h.
| #define SXACT_FLAG_READ_ONLY 0x00000020 |
Definition at line 131 of file predicate_internals.h.
| #define SXACT_FLAG_RO_SAFE 0x00000080 |
Definition at line 133 of file predicate_internals.h.
| #define SXACT_FLAG_RO_UNSAFE 0x00000100 |
Definition at line 134 of file predicate_internals.h.
| #define SXACT_FLAG_ROLLED_BACK 0x00000004 /* already rolled back */ |
Definition at line 123 of file predicate_internals.h.
| #define SXACT_FLAG_SUMMARY_CONFLICT_IN 0x00000200 |
Definition at line 135 of file predicate_internals.h.
| #define SXACT_FLAG_SUMMARY_CONFLICT_OUT 0x00000400 |
Definition at line 136 of file predicate_internals.h.
| typedef struct LOCALPREDICATELOCK LOCALPREDICATELOCK |
| typedef struct PREDICATELOCK PREDICATELOCK |
| typedef struct PredicateLockData PredicateLockData |
| typedef struct PREDICATELOCKTAG PREDICATELOCKTAG |
| typedef struct PREDICATELOCKTARGET PREDICATELOCKTARGET |
| typedef struct PREDICATELOCKTARGETTAG PREDICATELOCKTARGETTAG |
| typedef enum PredicateLockTargetType PredicateLockTargetType |
| typedef struct PredXactListData* PredXactList |
Definition at line 177 of file predicate_internals.h.
| typedef struct PredXactListData PredXactListData |
| typedef struct RWConflictData* RWConflict |
Definition at line 201 of file predicate_internals.h.
| typedef struct RWConflictData RWConflictData |
| typedef struct RWConflictPoolHeaderData* RWConflictPoolHeader |
Definition at line 212 of file predicate_internals.h.
| typedef struct RWConflictPoolHeaderData RWConflictPoolHeaderData |
| typedef uint64 SerCommitSeqNo |
Definition at line 24 of file predicate_internals.h.
| typedef struct SERIALIZABLEXACT SERIALIZABLEXACT |
| typedef struct SERIALIZABLEXID SERIALIZABLEXID |
| typedef struct SERIALIZABLEXIDTAG SERIALIZABLEXIDTAG |
| typedef struct TwoPhasePredicateLockRecord TwoPhasePredicateLockRecord |
| typedef struct TwoPhasePredicateRecord TwoPhasePredicateRecord |
| typedef enum TwoPhasePredicateRecordType TwoPhasePredicateRecordType |
| typedef struct TwoPhasePredicateXactRecord TwoPhasePredicateXactRecord |
| Enumerator | |
|---|---|
| PREDLOCKTAG_RELATION | |
| PREDLOCKTAG_PAGE | |
| PREDLOCKTAG_TUPLE | |
Definition at line 361 of file predicate_internals.h.
| Enumerator | |
|---|---|
| TWOPHASEPREDICATERECORD_XACT | |
| TWOPHASEPREDICATERECORD_LOCK | |
Definition at line 424 of file predicate_internals.h.
| PredicateLockData * GetPredicateLockStatusData | ( | void | ) |
Definition at line 1445 of file predicate.c.
References Assert(), data, hash_get_num_entries(), hash_seq_init(), hash_seq_search(), i, LW_SHARED, LWLockAcquire(), LWLockRelease(), PREDICATELOCKTAG::myTarget, PREDICATELOCKTAG::myXact, NUM_PREDICATELOCK_PARTITIONS, palloc(), PredicateLockHash, PredicateLockHashPartitionLockByIndex, PREDICATELOCKTARGET::tag, and PREDICATELOCK::tag.
Referenced by pg_lock_status().
| int GetSafeSnapshotBlockingPids | ( | int | blocked_pid, |
| int * | output, | ||
| int | output_size | ||
| ) |
Definition at line 1628 of file predicate.c.
References PredXactListData::activeList, dlist_iter::cur, dlist_container, dlist_foreach, LW_SHARED, LWLockAcquire(), LWLockRelease(), output, SERIALIZABLEXACT::pid, SERIALIZABLEXACT::possibleUnsafeConflicts, PredXact, SxactIsDeferrableWaiting, and RWConflictData::sxactOut.
Referenced by pg_isolation_test_session_is_blocked(), and pg_safe_snapshot_blocking_pids().