PR ipa/61602
[official-gcc.git] / gcc / testsuite / gcc.dg / torture / stackalign / struct-1.c
blobd0420ae23ce89833470169ec409d1f9234cb1a6e
1 /* { dg-do run } */
2 /* { dg-skip-if "Stack alignment is too small" { hppa*-*-hpux* } "*" "" } */
3 /* { dg-skip-if "Stack alignment causes use of alloca" { nvptx-*-* } "*" "" } */
5 #include "check.h"
7 #ifndef ALIGNMENT
8 #define ALIGNMENT 64
9 #endif
11 typedef int aligned __attribute__((aligned(ALIGNMENT)));
13 void
14 foo (void)
16 struct i
18 aligned i;
19 } i;
21 if (check_int (&i.i, __alignof__(i.i)) != i.i)
22 abort ();
25 int
26 main()
28 foo ();
29 return 0;