3 /* { dg-options "-g" } */
5 struct A
{ int i
; int j
; };
6 struct B
{ int : 4; int i
: 12; int j
: 12; int : 4; };
8 __attribute__((noinline
)) void
11 asm volatile ("" : : "r" (x
) : "memory");
14 __attribute__((noinline
)) int
17 struct A a
= { 4, k
+ 6 };
18 asm ("" : "+r" (a
.i
));
20 bar (a
.i
); /* { dg-final { gdb-test 21 "a.i" "4" } } */
21 bar (a
.j
); /* { dg-final { gdb-test 21 "a.j" "14" } } */
25 __attribute__((noinline
)) int
28 int a
[2] = { 4, k
+ 6 };
29 asm ("" : "+r" (a
[0]));
31 bar (a
[0]); /* { dg-final { gdb-test 32 "a\[0\]" "4" } } */
32 bar (a
[1]); /* { dg-final { gdb-test 32 "a\[1\]" "14" } } */
36 __attribute__((noinline
)) int
39 struct B a
= { 4, k
+ 6 };
40 asm ("" : "+r" (a
.i
));
42 bar (a
.i
); /* { dg-final { gdb-test 43 "a.i" "4" } } */
43 bar (a
.j
); /* { dg-final { gdb-test 43 "a.j" "14" } } */
51 asm ("" : "=r" (k
) : "0" (7));