bar ();
}
-/* { dg-final { scan-tree-dump-not "== 5" "evrp" } } */
-/* { dg-final { scan-tree-dump-not "== 6" "evrp" } } */
+/* { dg-final { scan-tree-dump-times "Folding predicate minv_.* == 5 to 0" 1 "evrp" } } */
+/* { dg-final { scan-tree-dump-times "Folding predicate minv_.* == 6 to 0" 1 "evrp" } } */
+/* { dg-final { scan-tree-dump-times "Folding predicate maxv_.* == 5 to 0" 1 "evrp" } } */
+/* { dg-final { scan-tree-dump-times "Folding predicate maxv_.* == 6 to 0" 1 "evrp" } } */
if (TREE_CODE (gimple_cond_lhs (cond)) != SSA_NAME
&& TREE_CODE (gimple_cond_rhs (cond)) != SSA_NAME)
return false;
+ if (dump_file)
+ {
+ fprintf (dump_file, "Folding predicate ");
+ print_gimple_expr (dump_file, cond, 0);
+ fprintf (dump_file, " to ");
+ }
edge e0 = EDGE_SUCC (gimple_bb (cond), 0);
edge e1 = EDGE_SUCC (gimple_bb (cond), 1);
if (r.zero_p ())
{
- if (dump_file && (dump_flags & TDF_DETAILS))
- fprintf (dump_file, "\nPredicate evaluates to: 0\n");
+ if (dump_file)
+ fprintf (dump_file, "0\n");
gimple_cond_make_false (cond);
if (e0->flags & EDGE_TRUE_VALUE)
set_and_propagate_unexecutable (e0);
}
else
{
- if (dump_file && (dump_flags & TDF_DETAILS))
- fprintf (dump_file, "\nPredicate evaluates to: 1\n");
+ if (dump_file)
+ fprintf (dump_file, "1\n");
gimple_cond_make_true (cond);
if (e0->flags & EDGE_FALSE_VALUE)
set_and_propagate_unexecutable (e0);