postgresql/src/include/nodes
Andres Freund a7f107df2b Evaluate arguments of correlated SubPlans in the referencing ExprState
Until now we generated an ExprState for each parameter to a SubPlan and
evaluated them one-by-one ExecScanSubPlan. That's sub-optimal as creating lots
of small ExprStates
a) makes JIT compilation more expensive
b) wastes memory
c) is a bit slower to execute

This commit arranges to evaluate parameters to a SubPlan as part of the
ExprState referencing a SubPlan, using the new EEOP_PARAM_SET expression
step. We emit one EEOP_PARAM_SET for each argument to a subplan, just before
the EEOP_SUBPLAN step.

It likely is worth using EEOP_PARAM_SET in other places as well, e.g. for
SubPlan outputs, nestloop parameters and - more ambitiously - to get rid of
ExprContext->domainValue/caseValue/ecxt_agg*.  But that's for later.

Author: Andres Freund <andres@anarazel.de>
Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>
Reviewed-by: Alena Rybakina <lena.ribackina@yandex.ru>
Discussion: https://postgr.es/m/20230225214401.346ancgjqc3zmvek@awork3.anarazel.de
2024-07-31 19:54:46 -07:00
..
.gitignore Automatically generate node support functions 2022-07-09 08:53:59 +02:00
bitmapset.h Move some bitmap logic out of bitmapset.c 2024-03-06 14:30:16 +07:00
execnodes.h Evaluate arguments of correlated SubPlans in the referencing ExprState 2024-07-31 19:54:46 -07:00
extensible.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
lockoptions.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
makefuncs.h Add basic JSON_TABLE() functionality 2024-04-04 20:20:15 +09:00
memnodes.h Add path column to pg_backend_memory_contexts view 2024-07-25 15:03:28 +12:00
meson.build Update copyright for 2024 2024-01-03 20:49:05 -05:00
miscnodes.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
multibitmapset.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
nodeFuncs.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
nodes.h Support "Right Semi Join" plan shapes 2024-07-05 09:26:48 +09:00
params.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
parsenodes.h Fix another couple of outdated comments for MERGE RETURNING. 2024-06-04 09:29:42 +01:00
pathnodes.h Support "Right Semi Join" plan shapes 2024-07-05 09:26:48 +09:00
pg_list.h Add macros for looping through a List without a ListCell. 2024-01-04 16:09:34 -06:00
plannodes.h Fix a couple of outdated comments now that we have MERGE RETURNING 2024-05-23 15:24:54 +12:00
primnodes.h SQL/JSON: Always coerce JsonExpr result at runtime 2024-06-28 21:58:13 +09:00
print.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
queryjumble.h revert: Transform OR clauses to ANY expression 2024-04-10 02:28:09 +03:00
readfuncs.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
replnodes.h Allow setting failover property in the replication command. 2024-01-29 09:37:23 +05:30
subscripting.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
supportnodes.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
tidbitmap.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
value.h Update copyright for 2024 2024-01-03 20:49:05 -05:00