Make IndexScanInstrumentation a pointer in executor scan nodes.
Change the IndexScanInstrumentation fields in IndexScanState,
IndexOnlyScanState, and BitmapIndexScanState from inline structs to
pointers. This avoids additional space overhead whenever new fields are
added to IndexScanInstrumentation in the future, at least in the common
case where the instrumentation isn't used (i.e. when the executor node
isn't being run through an EXPLAIN ANALYZE).
Preparation for an upcoming patch series that will add index
prefetching. The new slot-based interface that will enable index
prefetching necessitates that we add at least one more field to
IndexScanInstrumentation (to count heap fetches during index-only
scans).
Author: Peter Geoghegan <pg@bowt.ie>
Reviewed-By: Andres Freund <andres@anarazel.de>
Discussion: https://postgr.es/m/CAH2-Wz=g=JTSyDB4UtB5su2ZcvsS7VbP+ZMvvaG6ABoCb+s8Lw@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/f026fbf059f2d9d7c8f1f52e9210018d38d795d8
Modified Files
--------------
src/backend/commands/explain.c | 6 +++---
src/backend/executor/nodeBitmapIndexscan.c | 8 ++++++--
src/backend/executor/nodeIndexonlyscan.c | 12 ++++++++----
src/backend/executor/nodeIndexscan.c | 14 +++++++++-----
src/include/nodes/execnodes.h | 6 +++---
5 files changed, 29 insertions(+), 17 deletions(-)