From: Richard Biener Date: Tue, 23 Oct 2018 11:37:52 +0000 (+0000) Subject: tree-vrp.c (add_assert_info): Guard dump_printf with dump_enabled_p. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=99c24b911b385a3dddfe8fe5730d2c659a92222a;p=gcc.git tree-vrp.c (add_assert_info): Guard dump_printf with dump_enabled_p. 2018-10-23 Richard Biener * tree-vrp.c (add_assert_info): Guard dump_printf with dump_enabled_p. * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::record_ranges_from_incoming_edge): Use value_range::ignore_equivs_equal_p. From-SVN: r265422 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 367e60f4c6b..f0820c086af 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2018-10-23 Richard Biener + + * tree-vrp.c (add_assert_info): Guard dump_printf with + dump_enabled_p. + * gimple-ssa-evrp-analyze.c + (evrp_range_analyzer::record_ranges_from_incoming_edge): + Use value_range::ignore_equivs_equal_p. + 2018-10-23 Richard Biener PR tree-optimization/87105 diff --git a/gcc/gimple-ssa-evrp-analyze.c b/gcc/gimple-ssa-evrp-analyze.c index b7b0fd8f17c..3e5287b1b0b 100644 --- a/gcc/gimple-ssa-evrp-analyze.c +++ b/gcc/gimple-ssa-evrp-analyze.c @@ -209,9 +209,7 @@ evrp_range_analyzer::record_ranges_from_incoming_edge (basic_block bb) value_range *old_vr = get_value_range (vrs[i].first); value_range tem (old_vr->kind (), old_vr->min (), old_vr->max ()); tem.intersect (vrs[i].second); - if (tem.kind () == old_vr->kind () - && tem.min () == old_vr->min () - && tem.max () == old_vr->max ()) + if (tem.ignore_equivs_equal_p (*old_vr)) continue; push_value_range (vrs[i].first, vrs[i].second); if (is_fallthru diff --git a/gcc/tree-vrp.c b/gcc/tree-vrp.c index e3a64fd7e9e..17b0b6c6037 100644 --- a/gcc/tree-vrp.c +++ b/gcc/tree-vrp.c @@ -2299,9 +2299,10 @@ add_assert_info (vec &asserts, info.val = val; info.expr = expr; asserts.safe_push (info); - dump_printf (MSG_NOTE | MSG_PRIORITY_INTERNALS, - "Adding assert for %T from %T %s %T\n", - name, expr, op_symbol_code (comp_code), val); + if (dump_enabled_p ()) + dump_printf (MSG_NOTE | MSG_PRIORITY_INTERNALS, + "Adding assert for %T from %T %s %T\n", + name, expr, op_symbol_code (comp_code), val); } /* If NAME doesn't have an ASSERT_EXPR registered for asserting