summaryrefslogtreecommitdiff
path: root/src/include/executor
diff options
context:
space:
mode:
authorRobert Haas <rhaas@postgresql.org>2015-11-11 08:57:52 -0500
committerRobert Haas <rhaas@postgresql.org>2015-11-11 08:57:52 -0500
commitf0661c4e8c44c0ec7acd4ea7c82e85b265447398 (patch)
tree0a31416ab40a9be4ab0f43c6ddd73221eed9dec6 /src/include/executor
parentf764ecd81b2a8a1e9000d43a73ca5eec8e8008bc (diff)
Make sequential scans parallel-aware.
In addition, this path fills in a number of missing bits and pieces in the parallel infrastructure. Paths and plans now have a parallel_aware flag indicating whether whatever parallel-aware logic they have should be engaged. It is believed that we will need this flag for a number of path/plan types, not just sequential scans, which is why the flag is generic rather than part of the SeqScan structures specifically. Also, execParallel.c now gives parallel nodes a chance to initialize their PlanState nodes from the DSM during parallel worker startup. Amit Kapila, with a fair amount of adjustment by me. Review of previous patch versions by Haribabu Kommi and others.
Diffstat (limited to 'src/include/executor')
-rw-r--r--src/include/executor/nodeSeqscan.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/include/executor/nodeSeqscan.h b/src/include/executor/nodeSeqscan.h
index 39d12a62fcd..f8f9299b652 100644
--- a/src/include/executor/nodeSeqscan.h
+++ b/src/include/executor/nodeSeqscan.h
@@ -14,6 +14,7 @@
#ifndef NODESEQSCAN_H
#define NODESEQSCAN_H
+#include "access/parallel.h"
#include "nodes/execnodes.h"
extern SeqScanState *ExecInitSeqScan(SeqScan *node, EState *estate, int eflags);
@@ -21,4 +22,9 @@ extern TupleTableSlot *ExecSeqScan(SeqScanState *node);
extern void ExecEndSeqScan(SeqScanState *node);
extern void ExecReScanSeqScan(SeqScanState *node);
+/* parallel scan support */
+extern void ExecSeqScanEstimate(SeqScanState *node, ParallelContext *pcxt);
+extern void ExecSeqScanInitializeDSM(SeqScanState *node, ParallelContext *pcxt);
+extern void ExecSeqScanInitializeWorker(SeqScanState *node, shm_toc *toc);
+
#endif /* NODESEQSCAN_H */