[llvm-bugs] [Bug 47463] New: [Windows][AArch64] setjmp/longjmp crashes with /guard:cf
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Sep 8 09:20:58 PDT 2020
https://bugs.llvm.org/show_bug.cgi?id=47463
Bug ID: 47463
Summary: [Windows][AArch64] setjmp/longjmp crashes with
/guard:cf
Product: lld
Version: unspecified
Hardware: PC
OS: Windows NT
Status: NEW
Severity: enhancement
Priority: P
Component: COFF
Assignee: unassignedbugs at nondot.org
Reporter: Richard.Townsend at arm.com
CC: llvm-bugs at lists.llvm.org
Created attachment 23936
--> https://bugs.llvm.org/attachment.cgi?id=23936&action=edit
Example program
When compiling the attached sample program (sample.c) in the following way from
an ARM64 cross-tools terminal:
clang-cl -o test-clang.obj -c sample.c /guard:cf --target=aarch64-windows /Z7
lld-link test-clang.obj /guard:cf -debug /out:test-clang-lld.exe
link test-clang.obj /guard:cf /out:test-clang-link.exe
The resulting binary (test-clang-lld.exe) terminates with a control flow guard
exception like the following:
EXCEPTION_RECORD: (.exr -1)
ExceptionAddress: 00007fff7a8337c8 (ntdll!RtlFailFast2)
ExceptionCode: c0000409 (Security check failure or stack buffer overrun)
ExceptionFlags: 00000001
NumberParameters: 1
Parameter[0]: 0000000000000026
Subcode: 0x26 FAST_FAIL_INVALID_LONGJUMP_TARGET
When linked with the Microsoft linker, everything works as expected.
Possible follow on to https://bugs.llvm.org/show_bug.cgi?id=40057
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200908/2c6d49f3/attachment-0001.html>
More information about the llvm-bugs
mailing list