--- Comment #11 from chefmax at gcc dot ---
(In reply to Jakub Jelinek from comment #10)
> Unfortunately that doesn't work, because the second argument to
> __asan_allocas_unpoison is incorrect then.

Unfortunately we can't use new_sp as a second parameter for
__asan_allocas_unpoison, because e.g. for PowerPC it doesn't point to a new
(restored) dynamic stack area
That's why current implementation inserts __asan_allocas_unpoison after
__builtin_stack_restore and uses virtual_dynamic_stack_rtx as a second
We can probably use a 'new_sp + STACK_DYNAMIC_OFFSET' for a second argument for
__asan_allocas_unpoison inside expand_asan_emit_allocas_unpoison, but AFAIU
STACK_DYNAMIC_OFFSET becomes valid only in pass_instantiate_virtual_regs (so we
can't rely on it during pass_expand).

Reply via email to