Fix warning with -Wsign-compare -Wsystem-headers
[official-gcc.git] / gcc / testsuite / gcc.target / arm / pr40835.c
blob76ad509ebd2a721ee86be65f78707b6cd4fd3dd2
1 /* { dg-options "-mthumb -Os" } */
2 /* { dg-require-effective-target arm_thumb1_ok } */
3 /* { dg-final { scan-assembler-not "cmp" } } */
5 int bar();
6 void goo(int, int);
8 void eq()
10 int v = bar();
11 if (v == 0)
12 return;
13 goo(1, v);
16 void ge()
18 int v = bar();
19 if (v >= 0)
20 return;
21 goo(1, v);
24 void gt()
26 int v = bar();
27 if (v > 0)
28 return;
29 goo(1, v);
32 void lt()
34 int v = bar();
35 if (v < 0)
36 return;
37 goo(1, v);
40 void le()
42 int v = bar();
43 if (v <= 0)
44 return;
45 goo(1, v);
48 unsigned int foo();
50 void leu()
52 unsigned int v = foo();
53 if (v <= 0)
54 return;
55 goo(1, v);