[PATCH] D157547: Arm64EC entry/exit thunks, consolidated.
Billy Laws via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 14 07:56:34 PDT 2023
bylaws added inline comments.
================
Comment at: llvm/lib/Target/AArch64/AArch64MCInstLower.cpp:59
+
+ StringRef Name = Printer.getSymbol(GV)->getName();
+ // Don't mangle ARM64EC runtime functions.
----------------
bylaws wrote:
> This mangling logic is also necessary for dllimported functions, as is visible if you compile:
>
> __declspec(dllimport) long UnhandledExceptionFilter (void *ExceptionInfo);
>
> void test() {
> UnhandledExceptionFilter(0);
> }
>
> With cl.exe /c and run dumpbin, without this link.exe will fail
Looking into it further, it probably makes sense to drop MO_DLLIMPORT from the `hasDLLImportStorageClass` case in `AArch64Subtarget::classifyGlobalFunctionReference`, then emit the __imp symbol for that special case here
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D157547/new/
https://reviews.llvm.org/D157547
More information about the cfe-commits
mailing list