Debian Codegraph @

gcc/testsuite/gcc.dg/field-merge-26.c

raw
1 /* { dg-do run } */
2 /* { dg-options "-O1 -fno-tree-ccp -fno-tree-copy-prop -fno-tree-forwprop -fno-tree-fre" } */
3
4 /* PR tree-optimization/118805 */
5
6 /* Test that ifcombine doesn't get confused by tests for the sign bit of
7 extended values that would normally be folded before. */
8
9 unsigned char a = 255;
10 int b;
11 int main() {
12 int c = 0;
13 if (c > a && a >= 255)
14 __builtin_abort ();
15 if (c <= a && a == 254)
16 __builtin_abort ();
17 if (a < c || a != 255)
18 __builtin_abort ();
19 return 0;
20 }