Fix warning with -Wsign-compare -Wsystem-headers
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / phi-opt-2.c
blobe0b261810382083253ca8b76156bf5847c518484
1 /* { dg-do compile } */
2 /* { dg-options "-O1 -fdump-tree-optimized" } */
3 /* { dg-additional-options "-mbranch-cost=1" { target branch_cost } } */
5 _Bool f1(_Bool a, _Bool b)
7 if (a)
9 if (b)
10 return 1;
11 else
12 return 0;
14 return 0;
18 /* There should be only one if, the outer one; the inner one
19 should have been changed to straight line code with the
20 value of b (except that we don't fold ! (b != 0) into b
21 which can be fixed in a different patch).
22 Test this only when known to be !LOGICAL_OP_NON_SHORT_CIRCUIT,
23 otherwise ifcombine may convert this into return a & b;. */
24 /* { dg-final { scan-tree-dump-times "if" 1 "optimized" { target { i?86-*-* x86_64-*-* mips*-*-* s390*-*-* avr*-*-* } } } } */