[llvm] [aarch64] Mix the frame pointer with the stack cookie when protecting the stack (PR #197346)
Pan Tao via llvm-commits
llvm-commits at lists.llvm.org
Fri May 22 00:55:09 PDT 2026
================
@@ -31,14 +31,18 @@ declare void @_Z7CapturePi(ptr)
; WINDOWS-AARCH64: adrp x8, __security_cookie
; WINDOWS-AARCH64: ldr x8, [x8, :lo12:__security_cookie]
+; WINDOWS-AARCH64: sub x8, sp, x8
; WINDOWS-AARCH64: str x8, [sp, #8]
; WINDOWS-AARCH64: bl _Z7CapturePi
-; WINDOWS-AARCH64: ldr x0, [sp, #8]
+; WINDOWS-AARCH64: ldr x9, [sp, #8]
+; WINDOWS-AARCH64: sub x8, sp, x8
----------------
PanTao2 wrote:
Thank you very much for your help. I reproduced the error triggering 0xc0000409 (STATUS_STACK_BUFFER_OVERRUN) on my arm64 Windows machine and fixed it. Could you please help deploy a new test for the new version '1b7040f3f4adc99fe43dfcfb129ecd1142f2Fe6b'? Thanks in advance.
https://github.com/llvm/llvm-project/pull/197346
More information about the llvm-commits
mailing list