80 for (rti = 1; rti <
root->simple_rel_array_size; rti++)
133 if (rinfo->pseudoconstant)
174 foreach(lc, ((
BoolExpr *) or_rinfo->orclause)->args)
186 foreach(lc2, andargs)
202 subclauses =
lappend(subclauses, suborclause);
221 if (subclauses ==
NIL)
235 clauselist =
lappend(clauselist, subclause);
243 if (clauselist !=
NIL)
339 join_or_rinfo->norm_selec = orig_selec / or_selec;
341 if (join_or_rinfo->norm_selec > 1)
342 join_or_rinfo->norm_selec = 1;
bool bms_equal(const Bitmapset *a, const Bitmapset *b)
Bitmapset * bms_difference(const Bitmapset *a, const Bitmapset *b)
#define Assert(condition)
bool contain_volatile_functions(Node *clause)
Selectivity clause_selectivity(PlannerInfo *root, Node *clause, int varRelid, JoinType jointype, SpecialJoinInfo *sjinfo)
void init_dummy_sjinfo(SpecialJoinInfo *sjinfo, Relids left_relids, Relids right_relids)
List * lappend(List *list, void *datum)
List * list_concat(List *list1, const List *list2)
Expr * make_ands_explicit(List *andclauses)
Expr * make_orclause(List *orclauses)
static bool is_andclause(const void *clause)
static bool is_orclause(const void *clause)
#define castNode(_type_, nodeptr)
void extract_restriction_or_clauses(PlannerInfo *root)
static void consider_new_or_clause(PlannerInfo *root, RelOptInfo *rel, Expr *orclause, RestrictInfo *join_or_rinfo)
static Expr * extract_or_clause(RestrictInfo *or_rinfo, RelOptInfo *rel)
static bool is_safe_restriction_clause_for(RestrictInfo *rinfo, RelOptInfo *rel)
#define lfirst_node(type, lc)
bool restriction_is_or_clause(RestrictInfo *restrictinfo)
RestrictInfo * make_restrictinfo(PlannerInfo *root, Expr *clause, bool is_pushed_down, bool has_clone, bool is_clone, bool pseudoconstant, Index security_level, Relids required_relids, Relids incompatible_relids, Relids outer_relids)
bool join_clause_is_movable_to(RestrictInfo *rinfo, RelOptInfo *baserel)
Index baserestrict_min_security