pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kevin Grittner <kgrittn@postgresql.org>
To: pgsql-committers@postgresql.org
Subject: pgsql: Revert no-op changes to BufferGetPage()
Date: Wed, 20 Apr 2016 13:41:46 +0000
Message-ID: <E1assO2-0003we-8k@gemulon.postgresql.org> (raw)
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

Revert no-op changes to BufferGetPage()

The reverted changes were intended to force a choice of whether any
newly-added BufferGetPage() calls needed to be accompanied by a
test of the snapshot age, to support the "snapshot too old"
feature.  Such an accompanying test is needed in about 7% of the
cases, where the page is being used as part of a scan rather than
positioning for other purposes (such as DML or vacuuming).  The
additional effort required for back-patching, and the doubt whether
the intended benefit would really be there, have indicated it is
best just to rely on developers to do the right thing based on
comments and existing usage, as we do with many other conventions.

This change should have little or no effect on generated executable
code.

Motivated by the back-patching pain of Tom Lane and Robert Haas

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/a343e223a5c33a7283a6d8b255c9dbc48dbc5061

Modified Files
--------------
contrib/bloom/blinsert.c                  |   3 +-
contrib/bloom/blscan.c                    |   4 +-
contrib/bloom/blutils.c                   |   8 +-
contrib/bloom/blvacuum.c                  |   2 +-
contrib/pageinspect/btreefuncs.c          |   8 +-
contrib/pageinspect/rawpage.c             |   4 +-
contrib/pg_visibility/pg_visibility.c     |   4 +-
contrib/pgstattuple/pgstatapprox.c        |   2 +-
contrib/pgstattuple/pgstatindex.c         |   6 +-
contrib/pgstattuple/pgstattuple.c         |  12 ++-
src/backend/access/brin/brin.c            |  15 ++--
src/backend/access/brin/brin_pageops.c    |  52 +++++-------
src/backend/access/brin/brin_revmap.c     |  19 +++--
src/backend/access/brin/brin_xlog.c       |  16 ++--
src/backend/access/gin/ginbtree.c         |  71 ++++++-----------
src/backend/access/gin/gindatapage.c      |  18 ++---
src/backend/access/gin/ginentrypage.c     |  18 ++---
src/backend/access/gin/ginfast.c          |  22 ++---
src/backend/access/gin/ginget.c           |  41 +++++-----
src/backend/access/gin/gininsert.c        |   6 +-
src/backend/access/gin/ginutil.c          |  12 ++-
src/backend/access/gin/ginvacuum.c        |  29 +++----
src/backend/access/gin/ginxlog.c          |  34 ++++----
src/backend/access/gist/gist.c            |  48 ++++-------
src/backend/access/gist/gistbuild.c       |  14 ++--
src/backend/access/gist/gistget.c         |   5 +-
src/backend/access/gist/gistutil.c        |   6 +-
src/backend/access/gist/gistvacuum.c      |   6 +-
src/backend/access/gist/gistxlog.c        |   8 +-
src/backend/access/hash/hash.c            |  18 ++---
src/backend/access/hash/hashinsert.c      |  11 ++-
src/backend/access/hash/hashovfl.c        |  30 ++++---
src/backend/access/hash/hashpage.c        |  21 +++--
src/backend/access/hash/hashsearch.c      |  18 ++---
src/backend/access/hash/hashutil.c        |   2 +-
src/backend/access/heap/heapam.c          | 128 +++++++++++++-----------------
src/backend/access/heap/hio.c             |  27 +++----
src/backend/access/heap/pruneheap.c       |  12 ++-
src/backend/access/heap/visibilitymap.c   |  21 ++---
src/backend/access/nbtree/nbtinsert.c     |  47 +++++------
src/backend/access/nbtree/nbtpage.c       |  78 +++++++++---------
src/backend/access/nbtree/nbtree.c        |   2 +-
src/backend/access/nbtree/nbtsearch.c     |  46 ++++++-----
src/backend/access/nbtree/nbtutils.c      |   4 +-
src/backend/access/nbtree/nbtxlog.c       |  37 ++++-----
src/backend/access/spgist/spgdoinsert.c   |  39 ++++-----
src/backend/access/spgist/spginsert.c     |  12 +--
src/backend/access/spgist/spgscan.c       |   3 +-
src/backend/access/spgist/spgutils.c      |  19 ++---
src/backend/access/spgist/spgvacuum.c     |  13 ++-
src/backend/access/spgist/spgxlog.c       |  50 ++++++------
src/backend/access/transam/generic_xlog.c |  16 ++--
src/backend/access/transam/xloginsert.c   |   8 +-
src/backend/access/transam/xlogutils.c    |   8 +-
src/backend/catalog/index.c               |   4 +-
src/backend/commands/analyze.c            |   2 +-
src/backend/commands/sequence.c           |  12 +--
src/backend/commands/trigger.c            |   2 +-
src/backend/commands/vacuumlazy.c         |  12 +--
src/backend/executor/nodeBitmapHeapscan.c |   4 +-
src/backend/executor/nodeSamplescan.c     |   4 +-
src/backend/storage/buffer/bufmgr.c       |  10 +--
src/backend/storage/freespace/freespace.c |  29 +++----
src/backend/storage/freespace/fsmpage.c   |   2 +-
src/include/storage/bufmgr.h              |  42 +++-------
65 files changed, 550 insertions(+), 736 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


Message-ID: <E1assO2-0003we-8k@gemulon.postgresql.org>
Permalink:  ../E1assO2-0003we-8k@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1assO2-0003we-8k@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: kgrittn@postgresql.org
  Subject: Re: pgsql: Revert no-op changes to BufferGetPage()
  In-Reply-To: <E1assO2-0003we-8k@gemulon.postgresql.org>
  References: <E1assO2-0003we-8k@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