Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit421d7d8

Browse files
committed
Remove no-longer-needed ExecCountSlots infrastructure.
1 parentf92e8a4 commit421d7d8

File tree

56 files changed

+56
-477
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+56
-477
lines changed

‎src/backend/executor/execProcnode.c

Lines changed: 1 addition & 118 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,12 @@
1212
*
1313
*
1414
* IDENTIFICATION
15-
* $PostgreSQL: pgsql/src/backend/executor/execProcnode.c,v 1.65 2009/01/01 17:23:41 momjian Exp $
15+
* $PostgreSQL: pgsql/src/backend/executor/execProcnode.c,v 1.66 2009/09/27 21:10:53 tgl Exp $
1616
*
1717
*-------------------------------------------------------------------------
1818
*/
1919
/*
2020
* INTERFACE ROUTINES
21-
*ExecCountSlotsNode -count tuple slots needed by plan tree
2221
*ExecInitNode-initialize a plan node and its subplans
2322
*ExecProcNode-get a tuple by executing the plan node
2423
*ExecEndNode-shut down a plan node and its subplans
@@ -519,122 +518,6 @@ MultiExecProcNode(PlanState *node)
519518
}
520519

521520

522-
/*
523-
* ExecCountSlotsNode - count up the number of tuple table slots needed
524-
*
525-
* Note that this scans a Plan tree, not a PlanState tree, because we
526-
* haven't built the PlanState tree yet ...
527-
*/
528-
int
529-
ExecCountSlotsNode(Plan*node)
530-
{
531-
if (node==NULL)
532-
return0;
533-
534-
switch (nodeTag(node))
535-
{
536-
/*
537-
* control nodes
538-
*/
539-
caseT_Result:
540-
returnExecCountSlotsResult((Result*)node);
541-
542-
caseT_Append:
543-
returnExecCountSlotsAppend((Append*)node);
544-
545-
caseT_RecursiveUnion:
546-
returnExecCountSlotsRecursiveUnion((RecursiveUnion*)node);
547-
548-
caseT_BitmapAnd:
549-
returnExecCountSlotsBitmapAnd((BitmapAnd*)node);
550-
551-
caseT_BitmapOr:
552-
returnExecCountSlotsBitmapOr((BitmapOr*)node);
553-
554-
/*
555-
* scan nodes
556-
*/
557-
caseT_SeqScan:
558-
returnExecCountSlotsSeqScan((SeqScan*)node);
559-
560-
caseT_IndexScan:
561-
returnExecCountSlotsIndexScan((IndexScan*)node);
562-
563-
caseT_BitmapIndexScan:
564-
returnExecCountSlotsBitmapIndexScan((BitmapIndexScan*)node);
565-
566-
caseT_BitmapHeapScan:
567-
returnExecCountSlotsBitmapHeapScan((BitmapHeapScan*)node);
568-
569-
caseT_TidScan:
570-
returnExecCountSlotsTidScan((TidScan*)node);
571-
572-
caseT_SubqueryScan:
573-
returnExecCountSlotsSubqueryScan((SubqueryScan*)node);
574-
575-
caseT_FunctionScan:
576-
returnExecCountSlotsFunctionScan((FunctionScan*)node);
577-
578-
caseT_ValuesScan:
579-
returnExecCountSlotsValuesScan((ValuesScan*)node);
580-
581-
caseT_CteScan:
582-
returnExecCountSlotsCteScan((CteScan*)node);
583-
584-
caseT_WorkTableScan:
585-
returnExecCountSlotsWorkTableScan((WorkTableScan*)node);
586-
587-
/*
588-
* join nodes
589-
*/
590-
caseT_NestLoop:
591-
returnExecCountSlotsNestLoop((NestLoop*)node);
592-
593-
caseT_MergeJoin:
594-
returnExecCountSlotsMergeJoin((MergeJoin*)node);
595-
596-
caseT_HashJoin:
597-
returnExecCountSlotsHashJoin((HashJoin*)node);
598-
599-
/*
600-
* materialization nodes
601-
*/
602-
caseT_Material:
603-
returnExecCountSlotsMaterial((Material*)node);
604-
605-
caseT_Sort:
606-
returnExecCountSlotsSort((Sort*)node);
607-
608-
caseT_Group:
609-
returnExecCountSlotsGroup((Group*)node);
610-
611-
caseT_Agg:
612-
returnExecCountSlotsAgg((Agg*)node);
613-
614-
caseT_WindowAgg:
615-
returnExecCountSlotsWindowAgg((WindowAgg*)node);
616-
break;
617-
618-
caseT_Unique:
619-
returnExecCountSlotsUnique((Unique*)node);
620-
621-
caseT_Hash:
622-
returnExecCountSlotsHash((Hash*)node);
623-
624-
caseT_SetOp:
625-
returnExecCountSlotsSetOp((SetOp*)node);
626-
627-
caseT_Limit:
628-
returnExecCountSlotsLimit((Limit*)node);
629-
630-
default:
631-
elog(ERROR,"unrecognized node type: %d", (int)nodeTag(node));
632-
break;
633-
}
634-
635-
return0;
636-
}
637-
638521
/* ----------------------------------------------------------------
639522
*ExecEndNode
640523
*

‎src/backend/executor/nodeAgg.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
* Portions Copyright (c) 1994, Regents of the University of California
6464
*
6565
* IDENTIFICATION
66-
* $PostgreSQL: pgsql/src/backend/executor/nodeAgg.c,v 1.168 2009/07/23 20:45:27 tgl Exp $
66+
* $PostgreSQL: pgsql/src/backend/executor/nodeAgg.c,v 1.169 2009/09/27 21:10:53 tgl Exp $
6767
*
6868
*-------------------------------------------------------------------------
6969
*/
@@ -1239,8 +1239,6 @@ ExecInitAgg(Agg *node, EState *estate, int eflags)
12391239
ALLOCSET_DEFAULT_INITSIZE,
12401240
ALLOCSET_DEFAULT_MAXSIZE);
12411241

1242-
#defineAGG_NSLOTS 3
1243-
12441242
/*
12451243
* tuple table initialization
12461244
*/
@@ -1604,14 +1602,6 @@ GetAggInitVal(Datum textInitVal, Oid transtype)
16041602
returninitVal;
16051603
}
16061604

1607-
int
1608-
ExecCountSlotsAgg(Agg*node)
1609-
{
1610-
returnExecCountSlotsNode(outerPlan(node))+
1611-
ExecCountSlotsNode(innerPlan(node))+
1612-
AGG_NSLOTS;
1613-
}
1614-
16151605
void
16161606
ExecEndAgg(AggState*node)
16171607
{

‎src/backend/executor/nodeAppend.c

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/executor/nodeAppend.c,v 1.74 2009/01/01 17:23:41 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/executor/nodeAppend.c,v 1.75 2009/09/27 21:10:53 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -192,8 +192,6 @@ ExecInitAppend(Append *node, EState *estate, int eflags)
192192
* ExecQual or ExecProject.
193193
*/
194194

195-
#defineAPPEND_NSLOTS 1
196-
197195
/*
198196
* append nodes still have Result slots, which hold pointers to tuples, so
199197
* we have to initialize them.
@@ -233,17 +231,6 @@ ExecInitAppend(Append *node, EState *estate, int eflags)
233231
returnappendstate;
234232
}
235233

236-
int
237-
ExecCountSlotsAppend(Append*node)
238-
{
239-
ListCell*plan;
240-
intnSlots=0;
241-
242-
foreach(plan,node->appendplans)
243-
nSlots+=ExecCountSlotsNode((Plan*)lfirst(plan));
244-
returnnSlots+APPEND_NSLOTS;
245-
}
246-
247234
/* ----------------------------------------------------------------
248235
* ExecAppend
249236
*

‎src/backend/executor/nodeBitmapAnd.c

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapAnd.c,v 1.11 2009/01/01 17:23:41 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapAnd.c,v 1.12 2009/09/27 21:10:53 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -74,8 +74,6 @@ ExecInitBitmapAnd(BitmapAnd *node, EState *estate, int eflags)
7474
* ExecQual or ExecProject. They don't need any tuple slots either.
7575
*/
7676

77-
#defineBITMAPAND_NSLOTS 0
78-
7977
/*
8078
* call ExecInitNode on each of the plans to be executed and save the
8179
* results into the array "bitmapplanstates".
@@ -91,17 +89,6 @@ ExecInitBitmapAnd(BitmapAnd *node, EState *estate, int eflags)
9189
returnbitmapandstate;
9290
}
9391

94-
int
95-
ExecCountSlotsBitmapAnd(BitmapAnd*node)
96-
{
97-
ListCell*plan;
98-
intnSlots=0;
99-
100-
foreach(plan,node->bitmapplans)
101-
nSlots+=ExecCountSlotsNode((Plan*)lfirst(plan));
102-
returnnSlots+BITMAPAND_NSLOTS;
103-
}
104-
10592
/* ----------------------------------------------------------------
10693
* MultiExecBitmapAnd
10794
* ----------------------------------------------------------------

‎src/backend/executor/nodeBitmapHeapscan.c

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
*
2222
*
2323
* IDENTIFICATION
24-
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapHeapscan.c,v 1.35 2009/06/11 14:48:57 momjian Exp $
24+
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapHeapscan.c,v 1.36 2009/09/27 21:10:53 tgl Exp $
2525
*
2626
*-------------------------------------------------------------------------
2727
*/
@@ -597,8 +597,6 @@ ExecInitBitmapHeapScan(BitmapHeapScan *node, EState *estate, int eflags)
597597
ExecInitExpr((Expr*)node->bitmapqualorig,
598598
(PlanState*)scanstate);
599599

600-
#defineBITMAPHEAPSCAN_NSLOTS 2
601-
602600
/*
603601
* tuple table initialization
604602
*/
@@ -646,10 +644,3 @@ ExecInitBitmapHeapScan(BitmapHeapScan *node, EState *estate, int eflags)
646644
*/
647645
returnscanstate;
648646
}
649-
650-
int
651-
ExecCountSlotsBitmapHeapScan(BitmapHeapScan*node)
652-
{
653-
returnExecCountSlotsNode(outerPlan((Plan*)node))+
654-
ExecCountSlotsNode(innerPlan((Plan*)node))+BITMAPHEAPSCAN_NSLOTS;
655-
}

‎src/backend/executor/nodeBitmapIndexscan.c

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapIndexscan.c,v 1.31 2009/07/18 19:15:41 tgl Exp $
11+
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapIndexscan.c,v 1.32 2009/09/27 21:10:53 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -235,8 +235,6 @@ ExecInitBitmapIndexScan(BitmapIndexScan *node, EState *estate, int eflags)
235235
* sub-parts corresponding to runtime keys (see below).
236236
*/
237237

238-
#defineBITMAPINDEXSCAN_NSLOTS 0
239-
240238
/*
241239
* We do not open or lock the base relation here. We assume that an
242240
* ancestor BitmapHeapScan node is holding AccessShareLock (or better) on
@@ -318,10 +316,3 @@ ExecInitBitmapIndexScan(BitmapIndexScan *node, EState *estate, int eflags)
318316
*/
319317
returnindexstate;
320318
}
321-
322-
int
323-
ExecCountSlotsBitmapIndexScan(BitmapIndexScan*node)
324-
{
325-
returnExecCountSlotsNode(outerPlan((Plan*)node))+
326-
ExecCountSlotsNode(innerPlan((Plan*)node))+BITMAPINDEXSCAN_NSLOTS;
327-
}

‎src/backend/executor/nodeBitmapOr.c

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapOr.c,v 1.10 2009/01/01 17:23:41 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/executor/nodeBitmapOr.c,v 1.11 2009/09/27 21:10:53 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -75,8 +75,6 @@ ExecInitBitmapOr(BitmapOr *node, EState *estate, int eflags)
7575
* ExecQual or ExecProject. They don't need any tuple slots either.
7676
*/
7777

78-
#defineBITMAPOR_NSLOTS 0
79-
8078
/*
8179
* call ExecInitNode on each of the plans to be executed and save the
8280
* results into the array "bitmapplanstates".
@@ -92,17 +90,6 @@ ExecInitBitmapOr(BitmapOr *node, EState *estate, int eflags)
9290
returnbitmaporstate;
9391
}
9492

95-
int
96-
ExecCountSlotsBitmapOr(BitmapOr*node)
97-
{
98-
ListCell*plan;
99-
intnSlots=0;
100-
101-
foreach(plan,node->bitmapplans)
102-
nSlots+=ExecCountSlotsNode((Plan*)lfirst(plan));
103-
returnnSlots+BITMAPOR_NSLOTS;
104-
}
105-
10693
/* ----------------------------------------------------------------
10794
* MultiExecBitmapOr
10895
* ----------------------------------------------------------------

‎src/backend/executor/nodeCtescan.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/executor/nodeCtescan.c,v 1.5 2009/06/11 14:48:57 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/executor/nodeCtescan.c,v 1.6 2009/09/27 21:10:53 tgl Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -237,8 +237,6 @@ ExecInitCteScan(CteScan *node, EState *estate, int eflags)
237237
ExecInitExpr((Expr*)node->scan.plan.qual,
238238
(PlanState*)scanstate);
239239

240-
#defineCTESCAN_NSLOTS 2
241-
242240
/*
243241
* tuple table initialization
244242
*/
@@ -263,14 +261,6 @@ ExecInitCteScan(CteScan *node, EState *estate, int eflags)
263261
returnscanstate;
264262
}
265263

266-
int
267-
ExecCountSlotsCteScan(CteScan*node)
268-
{
269-
returnExecCountSlotsNode(outerPlan(node))+
270-
ExecCountSlotsNode(innerPlan(node))+
271-
CTESCAN_NSLOTS;
272-
}
273-
274264
/* ----------------------------------------------------------------
275265
*ExecEndCteScan
276266
*

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp