GCC Middle and Back End API Reference
|
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "backend.h"
#include "rtl.h"
#include "tree.h"
#include "gimple.h"
#include "tree-pass.h"
#include "ssa.h"
#include "gimple-pretty-print.h"
#include "fold-const.h"
#include "gimple-iterator.h"
#include "tree-cfg.h"
#include "tree-dfa.h"
#include "tree-cfgcleanup.h"
#include "alias.h"
#include "tree-ssa-loop.h"
#include "diagnostic.h"
#include "cfghooks.h"
#include "tree-into-ssa.h"
#include "cfganal.h"
#include "dbgcnt.h"
#include "target.h"
#include "alloc-pool.h"
#include "tree-switch-conversion.h"
#include "tree-ssa-reassoc.h"
#include "tree-ssa.h"
Data Structures | |
struct | condition_info |
struct | if_chain |
Functions | |
static int | range_cmp (const void *a, const void *b) |
static int | cluster_cmp (const void *a, const void *b) |
static void | dump_clusters (vec< cluster * > *clusters, const char *message) |
static tree | build_case_label (tree index_type, tree min, tree max, basic_block dest) |
static int | label_cmp (const void *a, const void *b) |
static void | convert_if_conditions_to_switch (if_chain *chain) |
static void | find_conditions (basic_block bb, hash_map< basic_block, condition_info * > *conditions_in_bbs) |
gimple_opt_pass * | make_pass_if_to_switch (gcc::context *ctxt) |
|
static |
Build case label with MIN and MAX values of a given basic block DEST.
References build_case_label(), fold_convert, gimple_block_label(), NULL_TREE, and TREE_TYPE.
Referenced by build_case_label(), convert_if_conditions_to_switch(), expand_late_variant_directive(), expand_omp_sections(), gimplify_switch_expr(), lower_eh_dispatch(), lower_try_finally_switch(), preprocess_case_label_vec_for_gimple(), simplify_gimple_switch_label_vec(), and sjlj_emit_dispatch_table().
|
static |
Compare clusters by minimum value.
References a, b, tree_switch_conversion::simple_cluster::get_high(), tree_switch_conversion::simple_cluster::get_low(), and tree_int_cst_compare().
Referenced by if_chain::is_beneficial().
|
static |
Convert a given if CHAIN into a switch GIMPLE statement.
References add_phi_arg(), build_case_label(), dbg_cnt(), delete_basic_block(), dump_file, find_edge(), gimple_build_switch(), gsi_for_stmt(), gsi_insert_before(), GSI_NEW_STMT, gsi_remove(), i, label_cmp(), chain::length, condition_info::m_bb, condition_info::m_cond, condition_info::m_false_edge, condition_info::m_false_edge_phi_mapping, condition_info::m_forwarder_bb, condition_info::m_ranges, condition_info::m_true_edge, condition_info::m_true_edge_phi_mapping, make_edge(), NULL, NULL_TREE, print_gimple_stmt(), remove_edge(), single_succ_edge(), split_edge(), TDF_SLIM, TREE_TYPE, and UNKNOWN_LOCATION.
Dump constructed CLUSTERS with prefix MESSAGE.
References dump_file, dump_flags, i, and TDF_DETAILS.
Referenced by if_chain::is_beneficial().
|
static |
Identify an index variable used in BB in a GIMPLE condition. Save information about the condition into CONDITIONS_IN_BBS.
References dyn_cast(), extract_true_false_edges_from_block(), gimple_assign_rhs1(), gimple_assign_rhs2(), gimple_assign_rhs_code(), gimple_cond_code(), gimple_cond_lhs(), gimple_cond_rhs(), gsi_end_p(), gsi_last_nondebug_bb(), gsi_stmt(), i, init_range_entry(), integer_zerop(), INTEGRAL_TYPE_P, condition_info::m_false_edge, condition_info::m_false_edge_phi_mapping, condition_info::m_ranges, condition_info::m_true_edge, condition_info::m_true_edge_phi_mapping, no_side_effect_bb(), NULL, NULL_TREE, hash_map< KeyId, Value, Traits >::put(), condition_info::record_phi_mapping(), SSA_NAME_DEF_STMT, TREE_CODE, TREE_TYPE, and TYPE_PRECISION.
|
static |
Compare two integer constants.
References a, b, CASE_LOW, and tree_int_cst_compare().
Referenced by convert_if_conditions_to_switch().
gimple_opt_pass * make_pass_if_to_switch | ( | gcc::context * | ctxt | ) |
|
static |
Compare two case ranges by minimum value.
References a, b, range_entry::low, and tree_int_cst_compare().
Referenced by if_chain::check_non_overlapping_cases().