pgsql: Use key and partdesc from PartitionDispatch where possible.

From: Robert Haas <rhaas(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Use key and partdesc from PartitionDispatch where possible.
Date: 2018-07-27 13:44:51
Message-ID: E1fj335-0001Nb-1M@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Use key and partdesc from PartitionDispatch where possible.

Instead of repeatedly fishing the data out of the relcache entry,
let's use the version that we cached in the PartitionDispatch. We
could alternatively rip out the PartitionDispatch fields altogether,
but it doesn't make much sense to have them and not use them; before
this patch, partdesc was set but altogether unused. Amit Langote and
I both thought using them was a litle better than removing them, so
this patch takes that approach.

Discussion: http://postgr.es/m/CA+TgmobFnxcaW-Co-XO8=yhJ5pJXoNkCj6Z7jm9Mwj9FGv-D7w@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/3e32109049142d3b6adb3b45afd0bb0dea24c23a

Modified Files
--------------
src/backend/executor/execPartition.c | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Alvaro Herrera 2018-07-27 14:58:30 pgsql: Fix grammar in README.tuplock
Previous Message Amit Kapila 2018-07-27 05:44:11 pgsql: Fix the buffer release order for parallel index scans.