PR middle-end/77357 - strlen of constant strings not folded
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / ssa-ifcombine-8.c
blob5bddf68e2d10426d43daaaa82046547c6d982996
1 /* { dg-do compile } */
2 /* { dg-options "-O -fno-trapping-math -fdump-tree-ifcombine-details-blocks" } */
4 double test1 (double i, double j)
6 if (i >= j)
7 if (i <= j)
8 goto plif;
9 else
10 goto plouf;
11 else
12 goto plif;
14 plif:
15 return 0;
16 plouf:
17 return -1;
20 /* The above should be optimized to a i > j test by ifcombine.
21 The transformation would also be legal with -ftrapping-math.
22 Instead we get u<=, which is acceptable with -fno-trapping-math. */
24 /* { dg-final { scan-tree-dump " u<= " "ifcombine" } } */
25 /* { dg-final { scan-tree-dump-not "Invalid sum" "ifcombine" } } */