提交 cff8694d 编写于 作者: H Heikki Linnakangas

Clean up execnodes.h to match upstream more closely.

Mostly whitespace changes.
上级 f55436c2
......@@ -19,6 +19,7 @@
#include <sys/time.h>
#endif
#include "executor/tuptable.h"
#include "nodes/params.h"
#include "nodes/plannodes.h"
#include "nodes/relation.h"
......@@ -38,7 +39,6 @@ struct CdbExplain_ShowStatCtx; /* private, in "cdb/cdbexplain.c" */
struct ChunkTransportState; /* #include "cdb/cdbinterconnect.h" */
struct StringInfoData; /* #include "lib/stringinfo.h" */
struct Tuplestorestate; /* #include "utils/tuplestore.h" */
struct TupleTableSlot;
struct TupleTableData;
struct MemTupleBinding;
struct SnapshotData;
......@@ -146,9 +146,9 @@ typedef struct ExprContext
NodeTag type;
/* Tuples that Var nodes in expression may refer to */
struct TupleTableSlot *ecxt_scantuple;
struct TupleTableSlot *ecxt_innertuple;
struct TupleTableSlot *ecxt_outertuple;
TupleTableSlot *ecxt_scantuple;
TupleTableSlot *ecxt_innertuple;
TupleTableSlot *ecxt_outertuple;
/* Memory contexts for expression evaluation --- see notes above */
MemoryContext ecxt_per_query_memory;
......@@ -230,7 +230,7 @@ typedef struct ProjectionInfo
NodeTag type;
List *pi_targetlist;
ExprContext *pi_exprContext;
struct TupleTableSlot *pi_slot;
TupleTableSlot *pi_slot;
ExprDoneCond *pi_itemIsDone;
bool pi_isVarList;
int *pi_varSlotOffsets;
......@@ -269,7 +269,7 @@ typedef struct JunkFilter
List *jf_targetList;
TupleDesc jf_cleanTupType;
AttrNumber *jf_cleanMap;
struct TupleTableSlot *jf_resultSlot;
TupleTableSlot *jf_resultSlot;
} JunkFilter;
typedef void *RelationUpdateDesc;
......@@ -334,8 +334,8 @@ typedef struct ResultRelInfo
int ri_aosegno;
uint64 ri_aoprocessed; /* tuples added/deleted for AO */
struct AttrMap *ri_partInsertMap;
struct TupleTableSlot *ri_partSlot;
struct TupleTableSlot *ri_resultSlot;
TupleTableSlot *ri_partSlot;
TupleTableSlot *ri_resultSlot;
/* Parent relation in checkPartitionUpdate */
Relation ri_PartitionParent;
/* tupdesc_match for checkPartitionUpdate */
......@@ -518,7 +518,7 @@ typedef struct EState
/* AO fileseg info for target relation */
List *es_result_aosegnos;
struct TupleTableSlot *es_trig_tuple_slot; /* for trigger output tuples */
TupleTableSlot *es_trig_tuple_slot; /* for trigger output tuples */
/* Stuff used for SELECT INTO: */
Relation es_into_relation_descriptor;
......@@ -674,8 +674,8 @@ typedef struct TupleHashTableData
MemoryContext tablecxt; /* memory context containing table */
MemoryContext tempcxt; /* context for function evaluations */
Size entrysize; /* actual size to make each hash entry */
struct TupleTableSlot *tableslot; /* slot for referencing table entries */
struct TupleTableSlot *inputslot; /* current input tuple's slot */
TupleTableSlot *tableslot; /* slot for referencing table entries */
TupleTableSlot *inputslot; /* current input tuple's slot */
} TupleHashTableData;
typedef HASH_SEQ_STATUS TupleHashIterator;
......@@ -863,7 +863,7 @@ typedef struct FuncExprState
* The slot holds the row currently being returned.
*/
struct Tuplestorestate *funcResultStore;
struct TupleTableSlot *funcResultSlot;
TupleTableSlot *funcResultSlot;
/*
* In some cases we need to compute a tuple descriptor for the function's
......@@ -1271,8 +1271,8 @@ typedef struct PlanState
/*
* Other run-time state needed by most if not all node types.
*/
struct TupleTableSlot *ps_OuterTupleSlot; /* slot for current "outer" tuple */
struct TupleTableSlot *ps_ResultTupleSlot; /* slot for my result tuples */
TupleTableSlot *ps_OuterTupleSlot; /* slot for current "outer" tuple */
TupleTableSlot *ps_ResultTupleSlot; /* slot for my result tuples */
ExprContext *ps_ExprContext; /* node's expression-evaluation context */
ProjectionInfo *ps_ProjInfo; /* info for doing tuple projection */
......@@ -1365,9 +1365,10 @@ typedef struct ResultState
ExprState *resconstantqual;
bool inputFullyConsumed; /* are we done? */
bool rs_checkqual; /* do we need to check the qual? */
bool isSRF;/* state flag for processing set-valued
bool isSRF; /* state flag for processing set-valued
* functions in targetlist */
ExprDoneCond lastSRFCond; /* Applicable only if isSRF is true. Represents the last done flag */
ExprDoneCond lastSRFCond; /* Applicable only if isSRF is true.
* Represents the last done flag */
} ResultState;
/* ----------------
......@@ -1379,7 +1380,7 @@ typedef struct RepeatState
PlanState ps; /* its first field is NodeTag */
bool repeat_done; /* are we done? */
struct TupleTableSlot *slot; /* The current tuple */
TupleTableSlot *slot; /* The current tuple */
int repeat_count; /* The number of repeats for the current tuple */
ExprState *expr_state; /* The state to evaluate the expression */
} RepeatState;
......@@ -1508,7 +1509,7 @@ typedef struct ScanState
{
PlanState ps; /* its first field is NodeTag */
Relation ss_currentRelation;
struct TupleTableSlot *ss_ScanTupleSlot;
TupleTableSlot *ss_ScanTupleSlot;
int scan_state;
......@@ -1594,8 +1595,8 @@ typedef struct IndexScanState
struct IndexScanDescData *iss_ScanDesc;
/*
* tableOid is the oid of the partition or relation on which
* our current index relation is defined.
* tableOid is the oid of the partition or relation on which our current
* index relation is defined.
*/
Oid tableOid;
} IndexScanState;
......@@ -1657,7 +1658,7 @@ typedef struct BitmapIndexScanState
typedef struct BitmapHeapScanState
{
ScanState ss; /* its first field is NodeTag */
struct HeapScanDescData * ss_currentScanDesc;
struct HeapScanDescData *ss_currentScanDesc;
List *bitmapqualorig;
Node *tbm;
struct TBMIterateResult *tbmres;
......@@ -1996,13 +1997,12 @@ typedef struct NestLoopState
bool reset_inner; /*CDB-OLAP*/
bool require_inner_reset; /*CDB-OLAP*/
struct TupleTableSlot *nl_NullInnerTupleSlot;
TupleTableSlot *nl_NullInnerTupleSlot;
List *nl_InnerJoinKeys; /* list of ExprState nodes */
List *nl_OuterJoinKeys; /* list of ExprState nodes */
bool nl_innerSideScanned; /* set to true once we've scanned all inner tuples the first time */
bool nl_qualResultForNull; /* the value of the join condition when one of the sides contains a NULL */
} NestLoopState;
/* ----------------
......@@ -2037,11 +2037,11 @@ typedef struct MergeJoinState
bool mj_FillInner;
bool mj_MatchedOuter;
bool mj_MatchedInner;
struct TupleTableSlot *mj_OuterTupleSlot;
struct TupleTableSlot *mj_InnerTupleSlot;
struct TupleTableSlot *mj_MarkedTupleSlot;
struct TupleTableSlot *mj_NullOuterTupleSlot;
struct TupleTableSlot *mj_NullInnerTupleSlot;
TupleTableSlot *mj_OuterTupleSlot;
TupleTableSlot *mj_InnerTupleSlot;
TupleTableSlot *mj_MarkedTupleSlot;
TupleTableSlot *mj_NullOuterTupleSlot;
TupleTableSlot *mj_NullInnerTupleSlot;
ExprContext *mj_OuterEContext;
ExprContext *mj_InnerEContext;
bool prefetch_inner; /* MPP-3300 */
......@@ -2089,10 +2089,10 @@ typedef struct HashJoinState
List *hj_OuterHashKeys; /* list of ExprState nodes */
List *hj_InnerHashKeys; /* list of ExprState nodes */
List *hj_HashOperators; /* list of operator OIDs */
struct TupleTableSlot *hj_OuterTupleSlot;
struct TupleTableSlot *hj_HashTupleSlot;
struct TupleTableSlot *hj_NullInnerTupleSlot;
struct TupleTableSlot *hj_FirstOuterTupleSlot;
TupleTableSlot *hj_OuterTupleSlot;
TupleTableSlot *hj_HashTupleSlot;
TupleTableSlot *hj_NullInnerTupleSlot;
TupleTableSlot *hj_FirstOuterTupleSlot;
bool hj_NeedNewOuter;
bool hj_MatchedOuter;
bool hj_OuterNotEmpty;
......@@ -2241,7 +2241,7 @@ typedef struct AggState
struct MemTupleData *grp_firstTuple; /* copy of first tuple of current group */
/* these fields are used in AGG_HASHED mode: */
TupleHashTable hashtable; /* hash table with one entry per group */
struct TupleTableSlot *hashslot; /* slot for loading hash table */
TupleTableSlot *hashslot; /* slot for loading hash table */
List *hash_needed; /* list of columns needed in hash table */
TupleHashIterator hashiter; /* for iterating through hash table */
......@@ -2285,10 +2285,10 @@ typedef struct WindowState
PlanState ps; /* its first field is NodeTag */
List *wrxstates; /* all WindowRefExprState nodes in targetlist */
FmgrInfo *eqfunctions; /* equality fns for partition key */
struct TupleTableSlot *priorslot; /* place for prior tuple */
struct TupleTableSlot *curslot; /* current tuple */
struct TupleTableSlot *spare; /* current tuple */
struct TupleTableSlot *saveslot; /* convenient place holder */
TupleTableSlot *priorslot; /* place for prior tuple */
TupleTableSlot *curslot; /* current tuple */
TupleTableSlot *spare; /* current tuple */
TupleTableSlot *saveslot; /* convenient place holder */
/* meta data about the current slot */
bool cur_slot_is_new; /* is this a slot from a buffer or outer plan */
......@@ -2425,7 +2425,7 @@ typedef struct LimitState
bool noCount; /* if true, ignore count */
LimitStateCond lstate; /* state machine status, as above */
int64 position; /* 1-based index of last tuple returned */
struct TupleTableSlot *subSlot; /* tuple last obtained from subplan */
TupleTableSlot *subSlot; /* tuple last obtained from subplan */
} LimitState;
/*
......@@ -2443,7 +2443,7 @@ typedef struct DMLState
{
PlanState ps;
JunkFilter *junkfilter; /* filter that removes junk and dropped attributes */
struct TupleTableSlot *cleanedUpSlot; /* holds 'final' tuple which matches the target relation schema */
TupleTableSlot *cleanedUpSlot; /* holds 'final' tuple which matches the target relation schema */
} DMLState;
/*
......@@ -2457,9 +2457,10 @@ typedef struct DMLState
typedef struct SplitUpdateState
{
PlanState ps;
bool processInsert; /* flag that specifies the operator's next action. */
struct TupleTableSlot *insertTuple; /* tuple to Insert */
struct TupleTableSlot *deleteTuple; /* tuple to Delete */
bool processInsert; /* flag that specifies the operator's next
* action. */
TupleTableSlot *insertTuple; /* tuple to Insert */
TupleTableSlot *deleteTuple; /* tuple to Delete */
} SplitUpdateState;
/*
......@@ -2480,18 +2481,18 @@ typedef struct AssertOpState
typedef struct RowTriggerState
{
PlanState ps;
struct TupleTableSlot *newTuple; /* stores new values */
struct TupleTableSlot *oldTuple; /* stores old values */
struct TupleTableSlot *triggerTuple; /* stores returned values by the trigger */
TupleTableSlot *newTuple; /* stores new values */
TupleTableSlot *oldTuple; /* stores old values */
TupleTableSlot *triggerTuple; /* stores returned values by the
* trigger */
} RowTriggerState;
typedef enum MotionStateType
{
MOTIONSTATE_NONE, /* The motion state is not decided, or non active in a slice
* (neither send nor recv)
*/
MOTIONSTATE_NONE, /* The motion state is not decided, or non
* active in a slice (neither send nor recv) */
MOTIONSTATE_SEND, /* The motion is sender */
MOTIONSTATE_RECV, /* The motion is recver */
} MotionStateType;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册