xids = palloc(sizeof(TransactionId) * (xlrec->xcnt + xlrec->subxcnt));
nxids = 0;
+ /*
+ * Nobody else is running yet, but take locks anyhow
+ */
+ LWLockAcquire(ProcArrayLock, LW_EXCLUSIVE);
+
ProcArrayDisplay(trace_recovery(DEBUG3));
/*
}
- /*
- * Nobody else is running yet, but take locks anyhow
- */
- LWLockAcquire(ProcArrayLock, LW_EXCLUSIVE);
-
if (TransactionIdPrecedes(ShmemVariableCache->latestCompletedXid,
xlrec->latestCompletedXid))
ShmemVariableCache->latestCompletedXid = xlrec->latestCompletedXid;
* Prune KnownAssignedXids up to, but *not* including xid. If xid is invalid
* then clear the whole table.
*
- * Must be called while not holding ProcArrayLock. Will grab lock if required.
+ * Must be called while holding ProcArrayLock in Exclusive mode.
*/
static void
KnownAssignedXidsRemoveMany(TransactionId xid)
/*
* Display KnownAssignedXids to provide debug trail
*
- * Must be called while holding ProcArrayLock in Exclusive mode
+ * Must be called while holding ProcArrayLock in Shared mode
*/
void
KnownAssignedXidsDisplay(int trace_level)