Fix warning with -Wsign-compare -Wsystem-headers
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / ssa-sink-8.c
blob48af4218fc074b802184ff85a45bc2ffcd191b4a
1 /* { dg-do compile } */
2 /* { dg-options "-O -fdump-tree-sink" } */
4 int foo(int *a, int r, short *b)
6 int ret = 0;
7 *a = 1;
8 switch (r)
10 case 3:
11 *a = 5;
12 break;
13 case 4:
14 case 5:
15 *a = 9;
16 ret = r + 25;
17 break;
18 default:
19 ret = r + 20;
21 *b = 9;
22 return ret;
25 /* *a = 1 should be sunk into the default case. */
27 /* { dg-final { scan-tree-dump-times "Sinking" 1 "sink" } } */