[clang] [Clang] [ARM] Ensure FPU Features are collected when using the Clang Assembler (PR #134366)

Martin Storsjö via cfe-commits cfe-commits at lists.llvm.org
Mon Apr 7 03:11:25 PDT 2025


================
@@ -0,0 +1,8 @@
+// Ensure that we can assemble NEON by just specifying an armv7
+// Apple or Windows target.
+
+// REQUIRES: arm-registered-target
+// RUN: %clang -c -target armv7-apple-darwin -o /dev/null %s
+// RUN: %clang -c -target armv7-windows -o /dev/null %s
----------------
mstorsjo wrote:

Ok, sure.

FWIW, the prime motivation behind all this, is to make sure that these testcases still compile successfully in this form, when downstream applies patches like https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/-/blob/19/debian/patches/clang-arm-default-vfp3-on-armv7a.patch?ref_type=heads.

Previously, testing that was a bit hard as we didn't pass the `-target-feature` flags when calling `-cc1as`, but as we do now, we can definitely test that (and the actual `RUN` when we try to assemble things, which isn't really kosher in `clang/test/Driver`, perhaps even could be skipped - although it's nice to have for extra test coverage).

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


More information about the cfe-commits mailing list