Debian Codegraph @

gcc/testsuite/gcc.c-torture/execute/931102-2.c

raw
1 /* { dg-additional-options "-std=gnu89" } */
2
3 typedef union
4 {
5 long align;
6 struct
7 {
8 short h, l;
9 } b;
10 } T;
11
12 f (x)
13 int x;
14 {
15 int num = 0;
16 T reg;
17
18 reg.b.l = x;
19 while ((reg.b.l & 1) == 0)
20 {
21 num++;
22 reg.b.l >>= 1;
23 }
24 return num;
25 }
26
27 main ()
28 {
29 if (f (2) != 1)
30 abort ();
31 exit (0);
32 }
33