aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-cfg.cc
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2023-05-03 13:29:22 +0200
committerRichard Biener <rguenther@suse.de>2023-05-04 09:42:43 +0200
commitfe8ac82fc05b0ba60f50f94f702da9e154731aeb (patch)
treeb590ee23415519fc0face344446400bfd6ed9d31 /gcc/tree-cfg.cc
parent3a715d3e136fc4dfdc42cb6a3ee1a7df3e2a171a (diff)
downloadgcc-fe8ac82fc05b0ba60f50f94f702da9e154731aeb.zip
gcc-fe8ac82fc05b0ba60f50f94f702da9e154731aeb.tar.gz
gcc-fe8ac82fc05b0ba60f50f94f702da9e154731aeb.tar.bz2
Rename last_stmt to last_nondebug_stmt
The following renames last_stmt to last_nondebug_stmt which is what it really does. * tree-cfg.h (last_stmt): Rename to ... (last_nondebug_stmt): ... this. * tree-cfg.cc (last_stmt): Rename to ... (last_nondebug_stmt): ... this. (assign_discriminators): Adjust. (group_case_labels_stmt): Likewise. (gimple_can_duplicate_bb_p): Likewise. (execute_fixup_cfg): Likewise. * auto-profile.cc (afdo_propagate_circuit): Likewise. * gimple-range.cc (gimple_ranger::range_on_exit): Likewise. * omp-expand.cc (workshare_safe_to_combine_p): Likewise. (determine_parallel_type): Likewise. (adjust_context_and_scope): Likewise. (expand_task_call): Likewise. (remove_exit_barrier): Likewise. (expand_omp_taskreg): Likewise. (expand_omp_for_init_counts): Likewise. (expand_omp_for_init_vars): Likewise. (expand_omp_for_static_chunk): Likewise. (expand_omp_simd): Likewise. (expand_oacc_for): Likewise. (expand_omp_for): Likewise. (expand_omp_sections): Likewise. (expand_omp_atomic_fetch_op): Likewise. (expand_omp_atomic_cas): Likewise. (expand_omp_atomic): Likewise. (expand_omp_target): Likewise. (expand_omp): Likewise. (omp_make_gimple_edges): Likewise. * trans-mem.cc (tm_region_init): Likewise. * tree-inline.cc (redirect_all_calls): Likewise. * tree-parloops.cc (gen_parallel_loop): Likewise. * tree-ssa-loop-ch.cc (do_while_loop_p): Likewise. * tree-ssa-loop-ivcanon.cc (canonicalize_loop_induction_variables): Likewise. * tree-ssa-loop-ivopts.cc (stmt_after_ip_normal_pos): Likewise. (may_eliminate_iv): Likewise. * tree-ssa-loop-manip.cc (standard_iv_increment_position): Likewise. * tree-ssa-loop-niter.cc (do_warn_aggressive_loop_optimizations): Likewise. (estimate_numbers_of_iterations): Likewise. * tree-ssa-loop-split.cc (compute_added_num_insns): Likewise. * tree-ssa-loop-unswitch.cc (get_predicates_for_bb): Likewise. (set_predicates_for_bb): Likewise. (init_loop_unswitch_info): Likewise. (hoist_guard): Likewise. * tree-ssa-phiopt.cc (match_simplify_replacement): Likewise. (minmax_replacement): Likewise. * tree-ssa-reassoc.cc (update_range_test): Likewise. (optimize_range_tests_to_bit_test): Likewise. (optimize_range_tests_var_bound): Likewise. (optimize_range_tests): Likewise. (no_side_effect_bb): Likewise. (suitable_cond_bb): Likewise. (maybe_optimize_range_tests): Likewise. (reassociate_bb): Likewise. * tree-vrp.cc (rvrp_folder::pre_fold_bb): Likewise.
Diffstat (limited to 'gcc/tree-cfg.cc')
-rw-r--r--gcc/tree-cfg.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/gcc/tree-cfg.cc b/gcc/tree-cfg.cc
index 4927fc0..21cf6fc 100644
--- a/gcc/tree-cfg.cc
+++ b/gcc/tree-cfg.cc
@@ -1236,7 +1236,7 @@ assign_discriminators (void)
curr_discr = next_discriminator_for_locus (curr_locus);
}
- gimple *last = last_stmt (bb);
+ gimple *last = last_nondebug_stmt (bb);
location_t locus = last ? gimple_location (last) : UNKNOWN_LOCATION;
if (locus == UNKNOWN_LOCATION)
continue;
@@ -1246,7 +1246,7 @@ assign_discriminators (void)
FOR_EACH_EDGE (e, ei, bb->succs)
{
gimple *first = first_non_label_stmt (e->dest);
- gimple *last = last_stmt (e->dest);
+ gimple *last = last_nondebug_stmt (e->dest);
gimple *stmt_on_same_line = NULL;
if (first && same_line_p (locus, &locus_e,
@@ -1860,7 +1860,7 @@ group_case_labels_stmt (gswitch *stmt)
-Wreturn-type can be diagnosed. We'll optimize it later
during switchconv pass or any other cfg cleanup. */
&& (gimple_in_ssa_p (cfun)
- || (LOCATION_LOCUS (gimple_location (last_stmt (base_bb)))
+ || (LOCATION_LOCUS (gimple_location (last_nondebug_stmt (base_bb)))
!= BUILTINS_LOCATION)))
{
edge base_edge = find_edge (gimple_bb (stmt), base_bb);
@@ -2941,7 +2941,7 @@ first_non_label_stmt (basic_block bb)
/* Return the last statement in basic block BB. */
gimple *
-last_stmt (basic_block bb)
+last_nondebug_stmt (basic_block bb)
{
gimple_stmt_iterator i = gsi_last_bb (bb);
gimple *stmt = NULL;
@@ -6409,7 +6409,7 @@ gimple_split_block_before_cond_jump (basic_block bb)
static bool
gimple_can_duplicate_bb_p (const_basic_block bb)
{
- gimple *last = last_stmt (CONST_CAST_BB (bb));
+ gimple *last = last_nondebug_stmt (CONST_CAST_BB (bb));
/* Do checks that can only fail for the last stmt, to minimize the work in the
stmt loop. */
@@ -9954,7 +9954,7 @@ execute_fixup_cfg (void)
when inlining a noreturn call that does in fact return. */
if (EDGE_COUNT (bb->succs) == 0)
{
- gimple *stmt = last_stmt (bb);
+ gimple *stmt = last_nondebug_stmt (bb);
if (!stmt
|| (!is_ctrl_stmt (stmt)
&& (!is_gimple_call (stmt)