pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix IndexOnlyScan counter for heap fetches in parallel mode
Date: Tue, 10 Apr 2018 18:57:26 +0000
Message-ID: <E1f5ySM-0005B0-Ue@gemulon.postgresql.org> (raw)

Fix IndexOnlyScan counter for heap fetches in parallel mode

The HeapFetches counter was using a simple value in IndexOnlyScanState,
which fails to propagate values from parallel workers; so the counts are
wrong when IndexOnlyScan runs in parallel.  Move it to Instrumentation,
like all the other counters.

While at it, change INSERT ON CONFLICT conflicting tuple counter to use
the new ntuples2 instead of nfiltered2, which is a blatant misuse.

Discussion: https://postgr.es/m/20180409215851.idwc75ct2bzi6tea@alvherre.pgsql

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/15a8f8caad14c1f85b23d97842d0c27b106cc10e

Modified Files
--------------
src/backend/commands/explain.c           | 10 +++-------
src/backend/executor/instrument.c        |  1 +
src/backend/executor/nodeIndexonlyscan.c |  3 +--
src/backend/executor/nodeModifyTable.c   |  4 ++--
src/include/executor/instrument.h        |  1 +
src/include/nodes/execnodes.h            |  7 +++++--
6 files changed, 13 insertions(+), 13 deletions(-)



Message-ID: <E1f5ySM-0005B0-Ue@gemulon.postgresql.org>
Permalink:  ../E1f5ySM-0005B0-Ue@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1f5ySM-0005B0-Ue@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: alvherre@alvh.no-ip.org
  Subject: Re: pgsql: Fix IndexOnlyScan counter for heap fetches in parallel mode
  In-Reply-To: <E1f5ySM-0005B0-Ue@gemulon.postgresql.org>
  References: <E1f5ySM-0005B0-Ue@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