3 /* This problem occurs if a function is inlined. When its local
4 variables get allocated space on the caller's (the function to
5 which it is inlined) stack frame, they don't get 16-byte alignment
6 even if they need it. Here's an example with a union (that's the
7 first case I uncovered, but it's probably a general occurrence on
11 /* adjust N = size of buffer to try to get bad alignment for inlined union */
13 #define DO_INLINE __attribute__ ((always_inline))
14 #define DONT_INLINE __attribute__ ((noinline))
16 static DO_INLINE
int inline_me(vector
signed short data
)
18 union {vector
signed short v
; signed short s
[8];} u
;
23 static DONT_INLINE
int foo(vector
signed short data
)
31 buffer
[i
] = buffer
[i
-1] + c
*i
;
38 check(foo((vector
signed short)
39 ((vector
unsigned char){1,2,3,4,5,6,7,8,
40 9,10,11,12,13,14,15,16})) == 0x2b4e0,