|
PostgreSQL Source Code git master
|
#include "nodes/pathnodes.h"

Go to the source code of this file.
Typedefs | |
| typedef void(* | join_path_setup_hook_type) (PlannerInfo *root, RelOptInfo *joinrel, RelOptInfo *outerrel, RelOptInfo *innerrel, JoinType jointype, JoinPathExtraData *extra) |
| typedef void(* | set_rel_pathlist_hook_type) (PlannerInfo *root, RelOptInfo *rel, Index rti, RangeTblEntry *rte) |
| typedef void(* | set_join_pathlist_hook_type) (PlannerInfo *root, RelOptInfo *joinrel, RelOptInfo *outerrel, RelOptInfo *innerrel, JoinType jointype, JoinPathExtraData *extra) |
| typedef RelOptInfo *(* | join_search_hook_type) (PlannerInfo *root, int levels_needed, List *initial_rels) |
| typedef bool(* | ec_matches_callback_type) (PlannerInfo *root, RelOptInfo *rel, EquivalenceClass *ec, EquivalenceMember *em, void *arg) |
Enumerations | |
| enum | PathKeysComparison { PATHKEYS_EQUAL , PATHKEYS_BETTER1 , PATHKEYS_BETTER2 , PATHKEYS_DIFFERENT } |
| typedef bool(* ec_matches_callback_type) (PlannerInfo *root, RelOptInfo *rel, EquivalenceClass *ec, EquivalenceMember *em, void *arg) |
| typedef void(* join_path_setup_hook_type) (PlannerInfo *root, RelOptInfo *joinrel, RelOptInfo *outerrel, RelOptInfo *innerrel, JoinType jointype, JoinPathExtraData *extra) |
| typedef RelOptInfo *(* join_search_hook_type) (PlannerInfo *root, int levels_needed, List *initial_rels) |
| typedef void(* set_join_pathlist_hook_type) (PlannerInfo *root, RelOptInfo *joinrel, RelOptInfo *outerrel, RelOptInfo *innerrel, JoinType jointype, JoinPathExtraData *extra) |
| typedef void(* set_rel_pathlist_hook_type) (PlannerInfo *root, RelOptInfo *rel, Index rti, RangeTblEntry *rte) |
| Enumerator | |
|---|---|
| PATHKEYS_EQUAL | |
| PATHKEYS_BETTER1 | |
| PATHKEYS_BETTER2 | |
| PATHKEYS_DIFFERENT | |
Definition at line 218 of file paths.h.
|
extern |
Definition at line 2940 of file equivclass.c.
References add_child_eq_member(), adjust_appendrel_attrs(), adjust_appendrel_attrs_multilevel(), Assert, bms_add_members(), bms_difference(), bms_membership(), BMS_MULTIPLE, bms_next_member(), bms_overlap(), fb(), foreach_node, get_eclass_indexes_for_relids(), i, IS_JOIN_REL, list_nth(), MemoryContextSwitchTo(), RELOPT_JOINREL, RELOPT_OTHER_JOINREL, and root.
Referenced by build_child_join_rel().
|
extern |
Definition at line 2832 of file equivclass.c.
References add_child_eq_member(), adjust_appendrel_attrs(), adjust_appendrel_attrs_multilevel(), Assert, bms_add_members(), bms_difference(), bms_is_empty, bms_is_subset(), bms_next_member(), fb(), foreach_node, i, IS_SIMPLE_REL, list_nth(), RELOPT_BASEREL, and root.
Referenced by set_append_rel_size().
|
extern |
Definition at line 800 of file joinrels.c.
References bms_add_member(), bms_add_members(), bms_copy(), bms_is_member(), bms_is_subset(), SpecialJoinInfo::commute_above_l, SpecialJoinInfo::commute_below_l, fb(), JOIN_LEFT, SpecialJoinInfo::jointype, lappend(), lfirst, SpecialJoinInfo::ojrelid, and root.
Referenced by generate_join_implied_equalities(), and make_join_rel().
|
extern |
Definition at line 1404 of file allpaths.c.
References accumulate_append_subpath(), add_partial_path(), add_path(), Assert, bms_equal(), compare_pathkeys(), RelOptInfo::consider_parallel, RelOptInfo::consider_startup, create_append_path(), enable_parallel_append, fb(), for_each_from, generate_orderedappend_paths(), get_cheapest_fractional_path(), get_cheapest_parallel_safe_total_inner(), get_cheapest_parameterized_child_path(), lappend(), lfirst, linitial, list_length(), list_make1, Max, max_parallel_workers_per_gather, Min, NIL, Path::parallel_workers, PATH_REQ_OUTER, Path::pathkeys, PATHKEYS_EQUAL, pg_leftmost_one_pos32(), root, and subpath().
Referenced by apply_scanjoin_target_to_paths(), create_partitionwise_grouping_paths(), generate_partitionwise_join_paths(), and set_append_rel_pathlist().
|
extern |
Definition at line 123 of file joinpath.c.
References bms_add_members(), bms_difference(), bms_is_subset(), bms_join(), bms_overlap(), compute_semi_anti_join_factors(), fb(), hash_inner_and_outer(), JoinPathExtraData::inner_unique, innerrel_is_unique(), JOIN_ANTI, JOIN_FULL, JOIN_INNER, join_path_setup_hook, JOIN_SEMI, JOIN_UNIQUE_INNER, JOIN_UNIQUE_OUTER, RelOptInfo::lateral_relids, lfirst, match_unsorted_outer(), JoinPathExtraData::mergeclause_list, SpecialJoinInfo::min_lefthand, NIL, JoinPathExtraData::param_source_rels, PGS_FOREIGNJOIN, PGS_HASHJOIN, RelOptInfo::pgs_mask, JoinPathExtraData::pgs_mask, PGS_MERGEJOIN_ANY, RelOptInfo::relids, RELOPT_OTHER_JOINREL, RelOptInfo::reloptkind, JoinPathExtraData::restrictlist, root, select_mergejoin_clauses(), JoinPathExtraData::semifactors, set_join_pathlist_hook, JoinPathExtraData::sjinfo, sort_inner_and_outer(), and RelOptInfo::top_parent_relids.
Referenced by populate_joinrel_with_paths().
|
extern |
Definition at line 3083 of file equivclass.c.
References add_child_eq_member(), bms_add_range(), elog, ERROR, exprType(), fb(), lfirst_node, linitial, list_head(), list_length(), lnext(), and root.
Referenced by build_setop_child_paths().
Definition at line 107 of file pathkeys.c.
References Assert, fb(), lappend(), lfirst_node, NIL, pathkey_is_redundant(), and source.
Referenced by adjust_group_pathkeys_for_groupagg(), and make_pathkeys_for_window().
|
extern |
Definition at line 1000 of file pathkeys.c.
References COMPARE_GT, elog, ERROR, exprCollation(), fb(), get_ordering_op_properties(), list_make1, make_pathkey_from_sortinfo(), NIL, and root.
Referenced by set_function_pathlist().
|
extern |
Definition at line 740 of file pathkeys.c.
References fb(), i, indexcol_is_bool_constant_for_query(), lappend(), lfirst, make_pathkey_from_sortinfo(), NIL, pathkey_is_redundant(), root, and ScanDirectionIsBackward.
Referenced by build_index_paths().
|
extern |
Definition at line 1295 of file pathkeys.c.
References Assert, fb(), JOIN_FULL, JOIN_RIGHT, JOIN_RIGHT_ANTI, JOIN_RIGHT_SEMI, NIL, root, and truncate_useless_pathkeys().
Referenced by consider_parallel_mergejoin(), consider_parallel_nestloop(), match_unsorted_outer(), and sort_inner_and_outer().
|
extern |
Definition at line 919 of file pathkeys.c.
References Assert, fb(), i, IS_SIMPLE_REL, lappend(), linitial, RelOptInfo::live_parts, make_pathkey_from_sortinfo(), NIL, partitions_are_ordered(), partkey_is_bool_constant_for_query(), pathkey_is_redundant(), RelOptInfo::relids, root, and ScanDirectionIsBackward.
Referenced by generate_orderedappend_paths().
Definition at line 545 of file equivclass.c.
References applyRelabelType(), COERCE_IMPLICIT_CAST, exprCollation(), exprType(), exprTypmod(), and fb().
Referenced by convert_subquery_pathkeys(), get_eclass_for_sort_expr(), and process_equivalence().
|
extern |
Definition at line 3941 of file indxpath.c.
References Assert, RelOptInfo::baserestrictinfo, bms_del_members(), bms_difference(), bms_is_empty, bms_is_member(), bms_union(), RestrictInfo::clause, contain_mutable_functions(), fb(), find_childrel_parents(), generate_join_implied_equalities(), get_plan_rowmark(), RelOptInfo::indexlist, IS_SIMPLE_REL, join_clause_is_movable_to(), RelOptInfo::joininfo, lappend(), lfirst, list_concat(), list_copy(), list_make1, NIL, RelOptInfo::nulling_relids, predicate_implied_by(), RelOptInfo::relid, RelOptInfo::relids, RELOPT_OTHER_MEMBER_REL, RelOptInfo::reloptkind, and root.
Referenced by set_plain_rel_size(), and set_tablesample_rel_size().
|
extern |
Definition at line 304 of file pathkeys.c.
References fb(), forboth, lfirst, PATHKEYS_BETTER1, PATHKEYS_BETTER2, PATHKEYS_DIFFERENT, and PATHKEYS_EQUAL.
Referenced by add_partial_path(), add_partial_path_precheck(), add_path(), add_path_precheck(), add_paths_to_append_rel(), adjust_group_pathkeys_for_groupagg(), get_useful_group_keys_orderings(), get_useful_pathkeys_for_distinct(), pathkeys_contained_in(), and set_cheapest().
|
extern |
Definition at line 4726 of file allpaths.c.
References fb(), Max, Min, min_parallel_index_scan_size, min_parallel_table_scan_size, RelOptInfo::rel_parallel_workers, RELOPT_BASEREL, and RelOptInfo::reloptkind.
Referenced by cost_index(), create_partial_bitmap_paths(), create_plain_partial_paths(), create_tidscan_paths(), and plan_create_index_workers().
|
extern |
Definition at line 1054 of file pathkeys.c.
References Assert, canonicalize_ec_expression(), elog, equal(), ERROR, fb(), find_var_for_subquery_tle(), get_eclass_for_sort_expr(), get_sortgroupref_tle(), i, j, lappend(), lfirst, linitial, list_length(), list_nth(), make_canonical_pathkey(), NIL, pathkey_is_redundant(), RelOptInfo::relids, and root.
Referenced by build_setop_child_paths(), set_cte_pathlist(), and set_subquery_pathlist().
|
extern |
Definition at line 240 of file indxpath.c.
References add_path(), Assert, RelOptInfo::baserestrictinfo, bms_is_subset(), choose_bitmap_and(), consider_index_join_clauses(), RelOptInfo::consider_parallel, create_bitmap_heap_path(), create_partial_bitmap_paths(), fb(), generate_bitmap_or_paths(), get_index_paths(), get_loop_count(), INDEX_MAX_KEYS, RelOptInfo::indexlist, lappend(), RelOptInfo::lateral_relids, lfirst, list_append_unique(), list_concat(), match_eclass_clauses_to_index(), match_join_clauses_to_index(), match_restriction_clauses_to_index(), MemSet, NIL, PATH_REQ_OUTER, RelOptInfo::relid, and root.
Referenced by set_plain_rel_pathlist().
|
extern |
Definition at line 4690 of file allpaths.c.
References add_partial_path(), compute_bitmap_pages(), compute_parallel_worker(), create_bitmap_heap_path(), fb(), RelOptInfo::lateral_relids, max_parallel_workers_per_gather, and root.
Referenced by create_index_paths().
|
extern |
Definition at line 497 of file tidpath.c.
References add_partial_path(), add_path(), RelOptInfo::baserestrictinfo, BuildParameterizedTidPaths(), compute_parallel_worker(), RelOptInfo::consider_parallel, create_tidrangescan_path(), create_tidscan_path(), ec_member_matches_ctid(), fb(), generate_implied_equalities_for_column(), RelOptInfo::has_eclass_joins, RelOptInfo::joininfo, RelOptInfo::lateral_referencers, RelOptInfo::lateral_relids, max_parallel_workers_per_gather, NIL, RelOptInfo::pages, RelOptInfo::pgs_mask, PGS_TIDSCAN, root, TidQualFromRestrictInfoList(), and TidRangeQualFromRestrictInfoList().
Referenced by set_plain_rel_pathlist().
|
extern |
Definition at line 3830 of file equivclass.c.
References EquivalenceClass::ec_derives_hash, EquivalenceClass::ec_derives_list, fb(), list_free(), and NIL.
Referenced by process_equivalence(), remove_rel_from_eclass(), and update_eclasses().
|
extern |
Definition at line 3174 of file equivclass.c.
References bms_next_member(), fb(), lfirst_node, list_head(), lnext(), and NIL.
Referenced by find_computable_ec_member(), find_ec_member_matching_expr(), find_em_for_rel(), generate_implied_equalities_for_column(), generate_join_implied_equalities_normal(), get_eclass_for_sort_expr(), and match_pathkeys_to_index().
|
extern |
Definition at line 3489 of file equivclass.c.
References Assert, bms_is_empty, bms_is_subset(), bms_overlap(), eclass(), fb(), IS_OTHER_REL, lfirst, list_length(), RelOptInfo::relids, and RelOptInfo::top_parent_relids.
Referenced by get_useful_ecs_for_relation(), and pathkeys_useful_for_merging().
|
extern |
Definition at line 2647 of file equivclass.c.
References Assert, EquivalenceClass::ec_has_volatile, EquivalenceClass::ec_members, EquivalenceClass::ec_opfamilies, equal(), fb(), lfirst, list_member_oid(), OidIsValid, and root.
Referenced by add_unique_group_var(), and have_partkey_equi_join().
|
extern |
Definition at line 991 of file equivclass.c.
References bms_is_subset(), eclass_member_iterator_next(), fb(), is_parallel_safe(), lfirst, list_free(), list_member(), pull_var_clause(), PVC_INCLUDE_AGGREGATES, PVC_INCLUDE_PLACEHOLDERS, PVC_INCLUDE_WINDOWFUNCS, root, and setup_eclass_member_iterator().
Referenced by prepare_sort_from_pathkeys(), and relation_can_be_sorted_early().
|
extern |
Definition at line 2803 of file equivclass.c.
References Assert, EquivalenceClass::ec_has_const, ec_search_derived_clause_for_ems(), fb(), and root.
Referenced by get_foreign_key_join_selectivity().
|
extern |
Definition at line 916 of file equivclass.c.
References bms_is_subset(), eclass_member_iterator_next(), equal(), fb(), IsA, and setup_eclass_member_iterator().
Referenced by make_unique_from_pathkeys(), prepare_sort_from_pathkeys(), and relation_can_be_sorted_early().
|
extern |
Definition at line 1544 of file pathkeys.c.
References fb(), i, j, lappend(), lfirst, list_concat(), NIL, root, and update_mergeclause_eclasses().
Referenced by generate_mergejoin_paths(), and sort_inner_and_outer().
|
extern |
Definition at line 1187 of file equivclass.c.
References Assert, bms_add_member(), bms_is_member(), bms_membership(), BMS_MULTIPLE, bms_next_member(), EquivalenceClass::ec_broken, EquivalenceClass::ec_has_const, EquivalenceClass::ec_members, EquivalenceClass::ec_merged, EquivalenceClass::ec_relids, RelOptInfo::eclass_indexes, fb(), generate_base_implied_equalities_broken(), generate_base_implied_equalities_const(), generate_base_implied_equalities_no_const(), RelOptInfo::has_eclass_joins, i, lfirst, list_length(), RELOPT_BASEREL, RelOptInfo::reloptkind, and root.
Referenced by query_planner().
|
extern |
Definition at line 3188 of file allpaths.c.
References add_path(), compute_gather_rows(), create_gather_merge_path(), create_gather_path(), fb(), lfirst, linitial, NIL, RelOptInfo::partial_pathlist, GatherMergePath::path, RelOptInfo::reltarget, root, and subpath().
Referenced by generate_useful_gather_paths().
|
extern |
Definition at line 3442 of file allpaths.c.
References add_partial_path(), add_path(), AGG_HASHED, RelOptInfo::agg_info, RelAggInfo::agg_input, AGG_SORTED, RelAggInfo::agg_useful, AGGSPLIT_INITIAL_SERIAL, RelAggInfo::apply_agg_at, Assert, bms_equal(), RelOptInfo::cheapest_total_path, RelOptInfo::consider_parallel, create_agg_path(), create_incremental_sort_path(), create_projection_path(), create_sort_path(), enable_incremental_sort, estimate_num_groups(), fb(), get_agg_clause_costs(), RelAggInfo::group_clauses, RelAggInfo::group_exprs, RelOptInfo::grouped_rel, grouping_is_hashable(), grouping_is_sortable(), IS_DUMMY_REL, IS_OTHER_REL, lfirst, linitial, make_pathkeys_for_sortclauses(), make_tlist_from_pathtarget(), mark_dummy_rel(), MemSet, NIL, RelOptInfo::partial_pathlist, pathkeys_count_contained_in(), RelOptInfo::pathlist, RelOptInfo::relids, root, Path::rows, and RelAggInfo::target.
Referenced by generate_partitionwise_join_paths(), merge_clump(), set_grouped_rel_pathlist(), and standard_join_search().
|
extern |
Definition at line 3238 of file equivclass.c.
References Assert, bms_equal(), bms_is_subset(), bms_next_member(), bms_overlap(), callback(), create_join_clause(), RelOptInfo::eclass_indexes, eclass_member_iterator_next(), fb(), find_childrel_parents(), i, IS_SIMPLE_REL, lappend(), lfirst, list_length(), list_nth(), NIL, OidIsValid, RelOptInfo::relids, RELOPT_OTHER_MEMBER_REL, RelOptInfo::reloptkind, root, select_equality_operator(), and setup_eclass_member_iterator().
Referenced by create_tidscan_paths(), match_eclass_clauses_to_index(), and postgresGetForeignPaths().
|
extern |
Definition at line 1549 of file equivclass.c.
References add_outer_joins_to_relids(), Assert, bms_is_empty, bms_next_member(), bms_overlap(), bms_union(), EquivalenceClass::ec_broken, EquivalenceClass::ec_has_const, EquivalenceClass::ec_members, EquivalenceClass::ec_relids, fb(), generate_join_implied_equalities_broken(), generate_join_implied_equalities_normal(), get_common_eclass_indexes(), get_eclass_indexes_for_relids(), i, IS_OTHER_REL, list_concat(), list_length(), list_nth(), NIL, SpecialJoinInfo::ojrelid, and root.
Referenced by build_joinrel_restrictlist(), check_index_predicates(), get_baserel_parampathinfo(), get_joinrel_parampathinfo(), reduce_unique_semijoins(), and remove_self_joins_one_group().
|
extern |
Definition at line 1649 of file equivclass.c.
References Assert, bms_is_empty, bms_overlap(), bms_union(), EquivalenceClass::ec_broken, EquivalenceClass::ec_has_const, EquivalenceClass::ec_members, EquivalenceClass::ec_relids, fb(), generate_join_implied_equalities_broken(), generate_join_implied_equalities_normal(), IS_OTHER_REL, lfirst, list_concat(), list_length(), NIL, and root.
Referenced by get_joinrel_parampathinfo().
|
extern |
Definition at line 4814 of file allpaths.c.
References add_paths_to_append_rel(), Assert, bms_equal(), check_stack_depth(), RelOptInfo::consider_partitionwise_join, fb(), generate_grouped_paths(), generate_partitionwise_join_paths(), RelOptInfo::grouped_rel, IS_DUMMY_REL, IS_GROUPED_REL, IS_JOIN_REL, IS_OTHER_REL, IS_PARTITIONED_REL, lappend(), list_free(), mark_dummy_rel(), NIL, RelOptInfo::nparts, pprint(), RelOptInfo::relids, root, set_cheapest(), and RelOptInfo::top_parent_relids.
Referenced by generate_partitionwise_join_paths(), merge_clump(), and standard_join_search().
|
extern |
Definition at line 3325 of file allpaths.c.
References add_path(), compute_gather_rows(), create_gather_merge_path(), create_incremental_sort_path(), create_sort_path(), enable_incremental_sort, fb(), generate_gather_paths(), get_useful_pathkeys_for_relation(), lfirst, linitial, NIL, RelOptInfo::partial_pathlist, GatherMergePath::path, pathkeys_count_contained_in(), RelOptInfo::reltarget, root, and subpath().
Referenced by apply_scanjoin_target_to_paths(), create_partial_distinct_paths(), create_partial_unique_paths(), gather_grouping_paths(), merge_clump(), set_rel_pathlist(), and standard_join_search().
|
extern |
Definition at line 666 of file pathkeys.c.
References bms_is_subset(), compare_fractional_path_costs(), fb(), lfirst, PATH_REQ_OUTER, Path::pathkeys, and pathkeys_contained_in().
Referenced by build_minmax_path(), and generate_orderedappend_paths().
Definition at line 699 of file pathkeys.c.
References bms_is_empty, fb(), lfirst, and PATH_REQ_OUTER.
Referenced by add_paths_to_append_rel(), hash_inner_and_outer(), match_unsorted_outer(), and sort_inner_and_outer().
|
extern |
Definition at line 620 of file pathkeys.c.
References bms_is_subset(), compare_path_costs(), fb(), lfirst, Path::parallel_safe, PATH_REQ_OUTER, Path::pathkeys, and pathkeys_contained_in().
Referenced by generate_mergejoin_paths(), generate_nonunion_paths(), generate_orderedappend_paths(), generate_union_paths(), and get_cheapest_parameterized_child_path().
|
extern |
Definition at line 736 of file equivclass.c.
References add_eq_member(), Assert, bms_add_member(), bms_equal(), bms_is_member(), bms_next_member(), canonicalize_ec_expression(), contain_agg_clause(), contain_volatile_functions(), contain_window_function(), copyObject, RelOptInfo::eclass_indexes, eclass_member_iterator_next(), elog, equal(), ERROR, expression_returns_set(), fb(), i, lappend(), lfirst, linitial_node, list_copy(), list_length(), makeNode, MemoryContextSwitchTo(), NIL, pull_varnos(), RELOPT_BASEREL, RelOptInfo::reloptkind, root, and setup_eclass_member_iterator().
Referenced by convert_subquery_pathkeys(), get_eclass_for_sortgroupclause(), initialize_mergeclause_eclasses(), and make_pathkey_from_sortinfo().
|
extern |
Definition at line 467 of file pathkeys.c.
References Assert, GroupByOrdering::clauses, compare_pathkeys(), enable_group_by_reordering, enable_incremental_sort, fb(), for_each_from, forboth, group_keys_reorder_by_pathkeys(), lappend(), lfirst_node, linitial_node, list_difference(), list_difference_ptr(), list_length(), makeNode, NIL, parse(), GroupByOrdering::pathkeys, Path::pathkeys, pathkeys_contained_in(), PATHKEYS_EQUAL, and root.
Referenced by add_paths_to_grouping_rel(), and create_partial_grouping_paths().
|
extern |
Definition at line 3445 of file equivclass.c.
References bms_is_subset(), bms_next_member(), EquivalenceClass::ec_members, EquivalenceClass::ec_relids, fb(), get_eclass_indexes_for_relids(), i, list_length(), list_nth(), and root.
Referenced by build_join_rel().
|
extern |
Definition at line 2291 of file pathkeys.c.
References RelOptInfo::has_eclass_joins, RelOptInfo::joininfo, NIL, and root.
Referenced by build_child_join_rel(), build_index_paths(), and set_append_rel_size().
|
extern |
Definition at line 1254 of file joinrels.c.
References bms_is_subset(), bms_overlap(), fb(), has_legal_joinclause(), JOIN_FULL, SpecialJoinInfo::jointype, lfirst, SpecialJoinInfo::min_lefthand, SpecialJoinInfo::min_righthand, and root.
Referenced by desirable_join(), join_search_one_level(), and make_rels_by_clause_joins().
|
extern |
Definition at line 3369 of file equivclass.c.
References Assert, bms_next_member(), bms_overlap(), EquivalenceClass::ec_members, EquivalenceClass::ec_relids, fb(), get_common_eclass_indexes(), i, list_length(), list_nth(), and root.
Referenced by have_relevant_joinclause().
|
extern |
Definition at line 4303 of file indxpath.c.
References fb(), IsBooleanOpfamily(), lfirst, match_boolean_index_clause(), and root.
Referenced by build_index_pathkeys().
|
extern |
Definition at line 664 of file joinrels.c.
References SpecialJoinInfo::commute_above_l, SpecialJoinInfo::commute_above_r, SpecialJoinInfo::commute_below_l, SpecialJoinInfo::commute_below_r, fb(), JOIN_INNER, SpecialJoinInfo::jointype, SpecialJoinInfo::lhs_strict, SpecialJoinInfo::min_lefthand, SpecialJoinInfo::min_righthand, NIL, SpecialJoinInfo::ojrelid, SpecialJoinInfo::semi_can_btree, SpecialJoinInfo::semi_can_hash, SpecialJoinInfo::semi_operators, SpecialJoinInfo::semi_rhs_exprs, SpecialJoinInfo::syn_lefthand, and SpecialJoinInfo::syn_righthand.
Referenced by approx_tuple_count(), build_child_join_sjinfo(), compute_semi_anti_join_factors(), consider_new_or_clause(), and make_join_rel().
|
extern |
Definition at line 1463 of file pathkeys.c.
References Assert, fb(), get_eclass_for_sort_expr(), get_leftop(), get_rightop(), NIL, op_input_types(), and root.
Referenced by distribute_qual_to_rels().
|
extern |
Definition at line 3549 of file equivclass.c.
Referenced by create_tidscan_plan().
|
extern |
Definition at line 3576 of file equivclass.c.
References fb(), and lfirst_node.
Referenced by create_indexscan_plan(), extract_nonindex_conditions(), and has_indexed_join_quals().
|
extern |
Definition at line 78 of file joinrels.c.
References Assert, bms_overlap(), elog, ERROR, fb(), for_each_from, foreach_current_index, has_join_restriction(), have_join_order_restriction(), have_relevant_joinclause(), lfirst, make_join_rel(), make_rels_by_clause_joins(), make_rels_by_clauseless_joins(), NIL, and root.
Referenced by standard_join_search().
|
extern |
Definition at line 56 of file pathkeys.c.
References eclass(), elog, ERROR, fb(), lappend(), lfirst, makeNode, MemoryContextSwitchTo(), and root.
Referenced by convert_subquery_pathkeys(), get_useful_pathkeys_for_relation(), make_inner_pathkeys_for_merge(), make_pathkey_from_sortinfo(), and select_outer_pathkeys_for_merge().
|
extern |
Definition at line 1858 of file pathkeys.c.
References elog, ERROR, fb(), lappend(), lfirst, list_head(), lnext(), make_canonical_pathkey(), NIL, pathkey_is_redundant(), root, and update_mergeclause_eclasses().
Referenced by generate_mergejoin_paths(), and sort_inner_and_outer().
|
extern |
Definition at line 699 of file joinrels.c.
References add_outer_joins_to_relids(), Assert, bms_free(), bms_overlap(), bms_union(), build_join_rel(), fb(), init_dummy_sjinfo(), is_dummy_rel(), join_is_legal(), make_grouped_join_rel(), NIL, populate_joinrel_with_paths(), and root.
Referenced by join_search_one_level(), make_rels_by_clause_joins(), make_rels_by_clauseless_joins(), and merge_clump().
|
extern |
Definition at line 177 of file allpaths.c.
References Assert, bms_equal(), fb(), IS_DUMMY_REL, IS_SIMPLE_REL, make_rel_from_joinlist(), RelOptInfo::relids, root, set_base_rel_consider_startup(), set_base_rel_pathlists(), set_base_rel_sizes(), and setup_simple_grouped_rels().
Referenced by query_planner().
|
extern |
Definition at line 1336 of file pathkeys.c.
References Assert, fb(), make_pathkeys_for_sortclauses_extended(), and root.
Referenced by adjust_group_pathkeys_for_groupagg(), create_unique_paths(), generate_grouped_paths(), generate_nonunion_paths(), generate_union_paths(), grouping_planner(), make_pathkeys_for_window(), minmax_qp_callback(), and standard_qp_callback().
|
extern |
Definition at line 1381 of file pathkeys.c.
References Assert, bms_make_singleton(), fb(), foreach_delete_current, get_sortgroupclause_expr(), lappend(), lfirst, make_pathkey_from_sortop(), NIL, OidIsValid, pathkey_is_redundant(), remove_nulling_relids(), and root.
Referenced by make_pathkeys_for_sortclauses(), make_pathkeys_for_window(), and standard_qp_callback().
|
extern |
Definition at line 1513 of file joinrels.c.
References add_path(), create_append_path(), fb(), GetMemoryChunkContext(), is_dummy_rel(), RelOptInfo::lateral_relids, MemoryContextSwitchTo(), NIL, RelOptInfo::partial_pathlist, RelOptInfo::pathlist, RelOptInfo::rows, and set_cheapest().
Referenced by build_setop_child_paths(), build_simple_rel(), generate_grouped_paths(), generate_nonunion_paths(), generate_partitionwise_join_paths(), generate_union_paths(), and populate_joinrel_with_paths().
|
extern |
Definition at line 2709 of file equivclass.c.
References arg, Assert, bms_intersect(), bms_next_member(), EquivalenceClass::ec_has_volatile, EquivalenceClass::ec_members, EquivalenceClass::ec_opfamilies, equal(), fb(), get_mergejoin_opfamilies(), i, IS_SIMPLE_REL, IsA, lfirst, list_nth(), NIL, root, Var::varattno, and Var::varno.
Referenced by match_foreign_keys_to_quals().
|
extern |
Definition at line 4354 of file indxpath.c.
References arg, elog, equal(), ERROR, fb(), i, IsA, lfirst, list_head(), lnext(), and strip_phvs_in_index_operand().
Referenced by ec_member_matches_indexcol(), expand_indexqual_rowcompare(), get_actual_variable_range(), group_similar_or_args(), match_boolean_index_clause(), match_clause_to_indexcol(), match_clause_to_ordering_op(), match_funcclause_to_indexcol(), match_opclause_to_indexcol(), match_orclause_to_indexcol(), match_rowcompare_to_indexcol(), match_saopclause_to_indexcol(), and relation_has_unique_index_for().
Definition at line 343 of file pathkeys.c.
References compare_pathkeys(), fb(), PATHKEYS_BETTER2, and PATHKEYS_EQUAL.
Referenced by add_paths_with_pathkeys_for_rel(), adjust_foreign_grouping_path_cost(), consider_groupingsets_paths(), create_gather_merge_path(), create_gather_merge_plan(), create_mergejoin_plan(), generate_mergejoin_paths(), generate_nonunion_paths(), generate_orderedappend_paths(), get_cheapest_fractional_path_for_pathkeys(), get_cheapest_path_for_pathkeys(), get_useful_group_keys_orderings(), GetExistingLocalJoinPath(), initial_cost_mergejoin(), try_mergejoin_path(), and try_partial_mergejoin_path().
Definition at line 558 of file pathkeys.c.
References fb(), forboth, lfirst, list_length(), and NIL.
Referenced by build_setop_child_paths(), cost_append(), count_common_leading_pathkeys_ordered(), create_append_plan(), create_final_unique_paths(), create_merge_append_path(), create_merge_append_plan(), create_one_window_path(), create_ordered_paths(), create_partial_unique_paths(), create_window_paths(), gather_grouping_paths(), generate_grouped_paths(), generate_useful_gather_paths(), GetExistingLocalJoinPath(), make_ordered_path(), try_mergejoin_path(), and try_partial_mergejoin_path().
|
extern |
Definition at line 179 of file equivclass.c.
References add_eq_member(), Assert, bms_join(), canonicalize_ec_expression(), ec_add_derived_clauses(), EquivalenceClass::ec_broken, EquivalenceClass::ec_childmembers, EquivalenceClass::ec_childmembers_size, ec_clear_derived_clauses(), EquivalenceClass::ec_collation, EquivalenceClass::ec_derives_hash, EquivalenceClass::ec_derives_list, EquivalenceClass::ec_has_const, EquivalenceClass::ec_has_volatile, EquivalenceClass::ec_max_security, EquivalenceClass::ec_members, EquivalenceClass::ec_merged, EquivalenceClass::ec_min_security, EquivalenceClass::ec_opfamilies, EquivalenceClass::ec_relids, EquivalenceClass::ec_sortref, EquivalenceClass::ec_sources, elog, equal(), ERROR, exprType(), fb(), foreach_current_index, func_strict(), get_leftop(), get_rightop(), IS_NOT_NULL, is_opclause(), lappend(), lfirst, list_concat(), list_delete_nth_cell(), list_make1, make_restrictinfo(), makeNode, Max, Min, NIL, op_input_types(), root, and set_opfuncid().
Referenced by distribute_qual_to_rels(), reconsider_full_join_clause(), and reconsider_outer_join_clause().
|
extern |
Definition at line 2573 of file equivclass.c.
References add_vars_to_attr_needed(), Assert, EquivalenceClass::ec_childmembers, EquivalenceClass::ec_has_const, EquivalenceClass::ec_members, EquivalenceClass::ec_relids, fb(), lfirst, list_free(), list_length(), pull_var_clause(), PVC_INCLUDE_PLACEHOLDERS, PVC_RECURSE_AGGREGATES, PVC_RECURSE_WINDOWFUNCS, and root.
Referenced by remove_leftjoinrel_from_query(), and remove_self_join_rel().
|
extern |
Definition at line 2134 of file equivclass.c.
References distribute_restrictinfo_to_rels(), fb(), foreach_delete_current, RestrictInfo::has_clone, RestrictInfo::incompatible_relids, RestrictInfo::is_clone, RestrictInfo::is_pushed_down, lfirst, make_restrictinfo(), makeBoolConst(), RestrictInfo::outer_relids, reconsider_full_join_clause(), reconsider_outer_join_clause(), RestrictInfo::required_relids, and root.
Referenced by query_planner().
|
extern |
Definition at line 1076 of file equivclass.c.
References EquivalenceClass::ec_has_volatile, expression_returns_set(), PathTarget::exprs, fb(), find_computable_ec_member(), find_ec_member_matching_expr(), is_parallel_safe(), lfirst, RelOptInfo::relids, RelOptInfo::reltarget, and root.
Referenced by get_useful_pathkeys_for_relation().
|
extern |
Definition at line 4145 of file indxpath.c.
References Assert, RelOptInfo::baserestrictinfo, bms_is_empty, bms_membership(), BMS_SINGLETON, RestrictInfo::clause, fb(), get_leftop(), get_rightop(), RelOptInfo::indexlist, lappend(), lfirst, list_member_oid(), match_index_to_operand(), MemoryContextSwitchTo(), NIL, and root.
Referenced by rel_is_distinct_for().
|
extern |
Definition at line 1659 of file pathkeys.c.
References Assert, bms_overlap(), COMPARE_LT, EquivalenceClass::ec_opfamilies, fb(), j, lappend(), lfirst, linitial_oid, list_copy(), list_copy_head(), list_length(), make_canonical_pathkey(), NIL, palloc(), pathkey_is_redundant(), pfree(), RelOptInfo::relids, root, and update_mergeclause_eclasses().
Referenced by sort_inner_and_outer().
|
extern |
Definition at line 3155 of file equivclass.c.
References EquivalenceClass::ec_childmembers, EquivalenceClass::ec_members, fb(), and list_head().
Referenced by find_computable_ec_member(), find_ec_member_matching_expr(), find_em_for_rel(), generate_implied_equalities_for_column(), generate_join_implied_equalities_normal(), get_eclass_for_sort_expr(), and match_pathkeys_to_index().
|
extern |
Definition at line 3885 of file allpaths.c.
References Assert, bms_equal(), elog, ERROR, fb(), generate_grouped_paths(), generate_partitionwise_join_paths(), generate_useful_gather_paths(), RelOptInfo::grouped_rel, IS_GROUPED_REL, join_search_one_level(), lfirst, linitial, list_length(), NIL, palloc0(), pprint(), RelOptInfo::relids, root, and set_cheapest().
Referenced by make_rel_from_joinlist().
Definition at line 4449 of file indxpath.c.
References contain_strippable_phv_walker(), fb(), and strip_phvs_in_index_operand_mutator().
Referenced by fix_indexqual_operand(), and match_index_to_operand().
|
extern |
Definition at line 1961 of file pathkeys.c.
References fb(), i, lappend(), lfirst, list_head(), lnext(), and NIL.
Referenced by generate_mergejoin_paths().
|
extern |
Definition at line 2200 of file pathkeys.c.
References count_common_leading_pathkeys_ordered(), count_common_leading_pathkeys_unordered(), fb(), list_copy_head(), list_length(), Max, pathkeys_useful_for_merging(), and root.
Referenced by build_index_paths(), and build_join_pathkeys().
|
extern |
Definition at line 1510 of file pathkeys.c.
References Assert, fb(), and NIL.
Referenced by find_mergeclauses_for_outer_pathkeys(), get_useful_ecs_for_relation(), make_inner_pathkeys_for_merge(), pathkeys_useful_for_merging(), select_mergejoin_clauses(), and select_outer_pathkeys_for_merge().
|
extern |
Definition at line 82 of file allpaths.c.
Referenced by setup_eager_aggregation().
|
extern |
Definition at line 81 of file allpaths.c.
Referenced by make_rel_from_joinlist().
|
extern |
Definition at line 32 of file pathkeys.c.
Referenced by get_useful_group_keys_orderings().
|
extern |
Definition at line 83 of file allpaths.c.
Referenced by make_rel_from_joinlist().
|
extern |
Definition at line 32 of file joinpath.c.
Referenced by add_paths_to_joinrel().
|
extern |
Definition at line 92 of file allpaths.c.
Referenced by make_rel_from_joinlist().
|
extern |
Definition at line 84 of file allpaths.c.
Referenced by create_rel_agg_info().
|
extern |
Definition at line 86 of file allpaths.c.
Referenced by compute_parallel_worker(), and parallel_vacuum_compute_workers().
|
extern |
Definition at line 85 of file allpaths.c.
Referenced by compute_parallel_worker().
|
extern |
Definition at line 31 of file joinpath.c.
Referenced by add_paths_to_joinrel().
|
extern |
Definition at line 89 of file allpaths.c.
Referenced by set_rel_pathlist().