1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-02 09:02:37 +03:00

Phase 3 of read-only-plans project: ExecInitExpr now builds expression

execution state trees, and ExecEvalExpr takes an expression state tree
not an expression plan tree.  The plan tree is now read-only as far as
the executor is concerned.  Next step is to begin actually exploiting
this property.
This commit is contained in:
Tom Lane
2002-12-13 19:46:01 +00:00
parent 77b7a740f9
commit 3a4f7dde16
49 changed files with 993 additions and 815 deletions

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/executor/nodeTidscan.c,v 1.28 2002/12/05 15:50:34 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/executor/nodeTidscan.c,v 1.29 2002/12/13 19:45:56 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -380,10 +380,10 @@ ExecInitTidScan(TidScan *node, EState *estate)
* initialize child expressions
*/
tidstate->ss.ps.targetlist = (List *)
ExecInitExpr((Node *) node->scan.plan.targetlist,
ExecInitExpr((Expr *) node->scan.plan.targetlist,
(PlanState *) tidstate);
tidstate->ss.ps.qual = (List *)
ExecInitExpr((Node *) node->scan.plan.qual,
ExecInitExpr((Expr *) node->scan.plan.qual,
(PlanState *) tidstate);
#define TIDSCAN_NSLOTS 2
@ -404,7 +404,10 @@ ExecInitTidScan(TidScan *node, EState *estate)
* get the tid node information
*/
tidList = (ItemPointerData *) palloc(length(node->tideval) * sizeof(ItemPointerData));
numTids = TidListCreate(node->tideval,
tidstate->tss_tideval = (List *)
ExecInitExpr((Expr *) node->tideval,
(PlanState *) tidstate);
numTids = TidListCreate(tidstate->tss_tideval,
tidstate->ss.ps.ps_ExprContext,
tidList);
tidPtr = -1;