[clang] Adding Loongarch64 to OpenBSD parts (PR #149737)

Brad Smith via cfe-commits cfe-commits at lists.llvm.org
Sun Jul 20 16:16:34 PDT 2025


================
@@ -29,6 +29,19 @@
 // CHECK-MIPS64-CPU: "-target-cpu" "mips3"
 // CHECK-MIPS64EL-CPU: "-target-cpu" "mips3"
 
+// Check that LoongArch passes the correct linker emulation.
+//
+// RUN: %clang --target=loongarch64-unknown-openbsd -### %s %s 2>&1 \
+// RUN:   | FileCheck --check-prefix=CHECK-LA64-LD %s
+// CHECK-LA64-LD: ld{{.*}}" {{.*}} "-m" "elf64loongarch"
+//
+// Check options passed to the linker on LoongArch
+//
+// RUN: %clang --target=loongarch64-unknown-openbsd -mno-relax -### %s %s 2>&1 \
+// RUN:   | FileCheck --check-prefix=CHECK-LA64-LD-OPTS %s
+// CHECK-LA64-LD-OPTS: ld{{.*}}" {{.*}} "-X" "--no-relax"
+//
+
----------------
brad0 wrote:

You can unify the --no-relax test with the RISC-V test further down and leave off the other part.

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


More information about the cfe-commits mailing list