2016-11-21 Thomas Preud'homme <thomas.preudhomme@arm.com>
[official-gcc.git] / gcc / testsuite / gcc.target / arm / pr49641.c
blob7f9b3769c1a1b6c4299be5ba0a588de33547c48d
1 /* { dg-do compile } */
2 /* { dg-options "-mthumb -O2" } */
3 /* { dg-require-effective-target arm_thumb1_ok } */
4 /* { dg-final { scan-assembler-not "stmia\[\\t \]*r3!\[^\\n]*r3" } } */
5 typedef struct {
6 void *t1, *t2, *t3;
7 } z;
8 extern volatile int y;
9 static inline void foo(z *x) {
10 x->t1 = &x->t2;
11 x->t2 = ((void *)0);
12 x->t3 = &x->t1;
14 extern z v;
15 void bar (void) {
16 y = 0;
17 foo(&v);