Re: [HACKERS] recent deadlock regression test failures - Mailing list pgsql-hackers

From Kevin Grittner
Subject Re: [HACKERS] recent deadlock regression test failures
Date
Msg-id CACjxUsOoFB+3K5UmiGEW3fhfaHJ9hb3YqWJ=+GWYGdLTReqMOA@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] recent deadlock regression test failures  (Thomas Munro <thomas.munro@enterprisedb.com>)
List pgsql-hackers
On Fri, Apr 7, 2017 at 9:24 PM, Thomas Munro
<thomas.munro@enterprisedb.com> wrote:

> 2.  Did I understand correctly that it is safe to scan the list of
> SERIALIZABLEXACTs and access the possibleUnsafeConflicts list while
> holding only SerializableXactHashLock,

Yes.

> and that 'inLink' is the correct link to be following?

If you're starting from the blocked (read-only) transaction (which
you are), inLink is the one to follow.

Note: It would be better form to use the SxactIsDeferrableWaiting()
macro than repeat the bit-testing code directly in your function.

--
Kevin Grittner



pgsql-hackers by date:

Previous
From: Kevin Grittner
Date:
Subject: Re: [HACKERS] [PATCH] Add GUCs for predicate lock promotion thresholds
Next
From: Masahiko Sawada
Date:
Subject: Re: [HACKERS] Remaining 2017-03 CF entries