pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Thomas Munro <tmunro@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Remove dependency on HeapTuple from predicate locking functions.
Date: Tue, 28 Jan 2020 00:46:51 +0000
Message-ID: <E1iwF1n-0000bS-3A@gemulon.postgresql.org> (raw)

Remove dependency on HeapTuple from predicate locking functions.

The following changes make the predicate locking functions more
generic and suitable for use by future access methods:

- PredicateLockTuple() is renamed to PredicateLockTID().  It takes
  ItemPointer and inserting transaction ID instead of HeapTuple.

- CheckForSerializableConflictIn() takes blocknum instead of buffer.

- CheckForSerializableConflictOut() no longer takes HeapTuple or buffer.

Author: Ashwin Agrawal
Reviewed-by: Andres Freund, Kuntal Ghosh, Thomas Munro
Discussion: https://postgr.es/m/CALfoeiv0k3hkEb3Oqk%3DziWqtyk2Jys1UOK5hwRBNeANT_yX%2Bng%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/6f38d4dac381b5b8bead302a0b4f81761042cd25

Modified Files
--------------
src/backend/access/gin/ginbtree.c        |   2 +-
src/backend/access/gin/ginfast.c         |   2 +-
src/backend/access/gin/gininsert.c       |   6 +-
src/backend/access/gist/gist.c           |   2 +-
src/backend/access/hash/hashinsert.c     |   2 +-
src/backend/access/heap/heapam.c         | 125 ++++++++++++++++++++++++----
src/backend/access/heap/heapam_handler.c |  11 +--
src/backend/access/index/indexam.c       |   4 +-
src/backend/access/nbtree/nbtinsert.c    |   4 +-
src/backend/storage/lmgr/predicate.c     | 137 ++++++++++---------------------
src/include/access/heapam.h              |   2 +
src/include/storage/predicate.h          |   9 +-
12 files changed, 176 insertions(+), 130 deletions(-)



view thread (6+ messages)  latest in thread

Message-ID: <E1iwF1n-0000bS-3A@gemulon.postgresql.org>
Permalink:  ../E1iwF1n-0000bS-3A@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1iwF1n-0000bS-3A@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tmunro@postgresql.org
  Subject: Re: pgsql: Remove dependency on HeapTuple from predicate locking functions.
  In-Reply-To: <E1iwF1n-0000bS-3A@gemulon.postgresql.org>
  References: <E1iwF1n-0000bS-3A@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox