MCPcopy Create free account
hub / github.com/apache/cloudberry / MultiExecProcNode

Function MultiExecProcNode

src/backend/executor/execProcnode.c:717–776  ·  view source on GitHub ↗

---------------------------------------------------------------- * MultiExecProcNode * * Execute a node that doesn't return individual tuples * (it might return a hashtable, bitmap, etc). Caller should * check it got back the expected kind of Node. * * This has essentially the same responsibilities as ExecProcNode, * but it does not do InstrStartNode/InstrStopNode (mainly because * i

Source from the content-addressed store, hash-verified

715 * ----------------------------------------------------------------
716 */
717Node *
718MultiExecProcNode(PlanState *node)
719{
720 Node *result;
721
722 check_stack_depth();
723
724 CHECK_FOR_INTERRUPTS();
725
726 Assert(NULL != node->plan);
727
728 TRACE_POSTGRESQL_EXECPROCNODE_ENTER(GpIdentity.segindex, currentSliceId, nodeTag(node), node->plan->plan_node_id);
729
730 if (!node->fHadSentNodeStart)
731 {
732 /* GPDB hook for collecting query info */
733 if (query_info_collect_hook)
734 (*query_info_collect_hook)(METRICS_PLAN_NODE_EXECUTING, node);
735 node->fHadSentNodeStart = true;
736 }
737
738 if (node->chgParam != NULL) /* something changed */
739 ExecReScan(node); /* let ReScan handle this */
740
741 switch (nodeTag(node))
742 {
743 /*
744 * Only node types that actually support multiexec will be listed
745 */
746
747 case T_HashState:
748 result = MultiExecHash((HashState *) node);
749 break;
750
751 case T_BitmapIndexScanState:
752 result = MultiExecBitmapIndexScan((BitmapIndexScanState *) node);
753 break;
754
755 case T_DynamicBitmapIndexScanState:
756 result = MultiExecDynamicBitmapIndexScan((DynamicBitmapIndexScanState *) node);
757 break;
758
759 case T_BitmapAndState:
760 result = MultiExecBitmapAnd((BitmapAndState *) node);
761 break;
762
763 case T_BitmapOrState:
764 result = MultiExecBitmapOr((BitmapOrState *) node);
765 break;
766
767 default:
768 elog(ERROR, "unrecognized node type: %d", (int) nodeTag(node));
769 result = NULL;
770 break;
771 }
772
773 TRACE_POSTGRESQL_EXECPROCNODE_EXIT(GpIdentity.segindex, currentSliceId, nodeTag(node), node->plan->plan_node_id);
774

Callers 4

MultiExecBitmapOrFunction · 0.85
ExecHashJoinImplFunction · 0.85
BitmapHeapNextFunction · 0.85
MultiExecBitmapAndFunction · 0.85

Calls 7

check_stack_depthFunction · 0.85
ExecReScanFunction · 0.85
MultiExecHashFunction · 0.85
MultiExecBitmapIndexScanFunction · 0.85
MultiExecBitmapAndFunction · 0.85
MultiExecBitmapOrFunction · 0.85

Tested by

no test coverage detected