https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112510
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org --- Comment #16 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Can't reproduce, neither with GCC 12 nor current trunk. In the ASAN_OPTIONS=detect_stack_use_after_return=1 case, the stack frames are allocated by __asan_stack_malloc_4, but that seems to return enough aligned frames for me (eventhough the routine doesn't have an argument to request a particular alignment). Even tried struct __attribute__((aligned (64))) S { char buf[64]; }; __attribute__((noinline, noclone, noipa)) void bar (struct S *p, char *a) { if ((__UINTPTR_TYPE__)p % 64) __builtin_abort (); } __attribute__((noinline, noclone, noipa)) void foo (void) { struct S s; char a; bar (&s, &a); } int main () { for (int i = 0; i < 32; ++i) foo (); } and the frames were sufficiently aligned in all 32 cases.