agora inbox for pgsql-committers@postgresql.org  
help / color / mirror / Atom feed
From: David Rowley <drowley@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Remove unused field from PartitionDescData struct
Date: Tue, 04 Aug 2026 01:30:10 +0000
Message-ID: <E1wr3ys-000000005YY-17en@gemulon.postgresql.org> (raw)

Remove unused field from PartitionDescData struct

3592e0ff9 added caching logic to ExecFindPartition() to allow faster
partition lookups for LIST and RANGE partitions when we hit the same
partition multiple times in a row.  The last_found_part_index field was
added, but it was never used, so remove it.  Caching works by caching the
last matching index into the PartitionBoundInfo.datums, not by caching the
last found partition index.

Update comments to reflect this, and perform other general improvements to
the comments in this area.

Author: Aleksander Alekseev <aleksander@tigerdata.com>
Author: David Rowley <dgrowleyml@gmail.com>
Discussion: https://postgr.es/m/CAJ7c6TMRxO6vo1tNgLZs4nTNizpjCSWdUviB8Mf3nkYiNHNhzg@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/5ea1022e4a987b6cffe4ca6014fd1389b3311f88

Modified Files
--------------
src/backend/executor/execPartition.c | 67 +++++++++++++++++++-----------------
src/backend/partitioning/partdesc.c  |  1 -
src/include/partitioning/partdesc.h  |  8 +----
3 files changed, 36 insertions(+), 40 deletions(-)



Message-ID: <E1wr3ys-000000005YY-17en@gemulon.postgresql.org>
Permalink:  ../E1wr3ys-000000005YY-17en@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1wr3ys-000000005YY-17en@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 using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: drowley@postgresql.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Remove unused field from PartitionDescData struct
  In-Reply-To: <E1wr3ys-000000005YY-17en@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 agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox