diff options
Diffstat (limited to 'src/include/executor')
-rw-r--r-- | src/include/executor/execParallel.h | 36 | ||||
-rw-r--r-- | src/include/executor/instrument.h | 5 |
2 files changed, 41 insertions, 0 deletions
diff --git a/src/include/executor/execParallel.h b/src/include/executor/execParallel.h new file mode 100644 index 00000000000..4fc797ad982 --- /dev/null +++ b/src/include/executor/execParallel.h @@ -0,0 +1,36 @@ +/*-------------------------------------------------------------------- + * execParallel.h + * POSTGRES parallel execution interface + * + * Portions Copyright (c) 1996-2015, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * IDENTIFICATION + * src/include/executor/execParallel.h + *-------------------------------------------------------------------- + */ + +#ifndef EXECPARALLEL_H +#define EXECPARALLEL_H + +#include "access/parallel.h" +#include "nodes/execnodes.h" +#include "nodes/parsenodes.h" +#include "nodes/plannodes.h" + +typedef struct SharedExecutorInstrumentation SharedExecutorInstrumentation; + +typedef struct ParallelExecutorInfo +{ + PlanState *planstate; + ParallelContext *pcxt; + BufferUsage *buffer_usage; + SharedExecutorInstrumentation *instrumentation; + shm_mq_handle **tqueue; +} ParallelExecutorInfo; + +extern ParallelExecutorInfo *ExecInitParallelPlan(PlanState *planstate, + EState *estate, int nworkers); +extern void ExecParallelFinish(ParallelExecutorInfo *pei); + +#endif /* EXECPARALLEL_H */ diff --git a/src/include/executor/instrument.h b/src/include/executor/instrument.h index c9a2129c7ae..f28e56ce48c 100644 --- a/src/include/executor/instrument.h +++ b/src/include/executor/instrument.h @@ -66,8 +66,13 @@ typedef struct Instrumentation extern PGDLLIMPORT BufferUsage pgBufferUsage; extern Instrumentation *InstrAlloc(int n, int instrument_options); +extern void InstrInit(Instrumentation *instr, int instrument_options); extern void InstrStartNode(Instrumentation *instr); extern void InstrStopNode(Instrumentation *instr, double nTuples); extern void InstrEndLoop(Instrumentation *instr); +extern void InstrAggNode(Instrumentation *dst, Instrumentation *add); +extern void InstrStartParallelQuery(void); +extern void InstrEndParallelQuery(BufferUsage *result); +extern void InstrAccumParallelQuery(BufferUsage *result); #endif /* INSTRUMENT_H */ |