[lld] [LLD][COFF] Add support for MinGW auto-export on ARM64X (PR #125862)

Martin Storsjö via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 6 04:54:36 PST 2025


================
@@ -0,0 +1,93 @@
+// REQUIRES: aarch64
+
+// RUN: llvm-mc -filetype=obj -triple=aarch64-windows %s -o %t.arm64.obj
+// RUN: llvm-mc -filetype=obj -triple=arm64ec-windows %s -o %t.arm64ec.obj
+// RUN: llvm-mc -filetype=obj -triple=arm64ec-windows %S/Inputs/loadconfig-arm64ec.s -o %t-loadconfig-arm64ec.obj
+// RUN: llvm-mc -filetype=obj -triple=aarch64-windows %S/Inputs/loadconfig-arm64.s -o %t-loadconfig-arm64.obj
+
+// Check that all symbols are exported in both EC and native views.
+
+// RUN: lld-link -machine:arm64x -lldmingw -dll -noentry -out:%t.dll %t.arm64.obj %t.arm64ec.obj %t-loadconfig-arm64.obj %t-loadconfig-arm64ec.obj
+
+// RUN: llvm-readobj --coff-exports %t.dll | FileCheck --check-prefix=EXP %s
+// EXP:      Format: COFF-ARM64X
+// EXP-NEXT: Arch: aarch64
+// EXP-NEXT: AddressSize: 64bit
+// EXP-NEXT: Export {
+// EXP-NEXT:   Ordinal: 1
+// EXP-NEXT:   Name: _load_config_used
----------------
mstorsjo wrote:

Side note; I guess this is a symbol we could include in `excludeSymbols`, as it doesn't make sense to autoexport this one.

https://github.com/llvm/llvm-project/pull/125862


More information about the llvm-commits mailing list