[llvm] [clang] [flang] [AArch64][Driver] Better handling of target feature dependencies (PR #78270)
Tomas Matheson via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 17 08:26:54 PST 2024
================
@@ -1,49 +1,51 @@
// RUN: %clang -target aarch64-linux-gnu -march=armv8-a+sme %s -### 2>&1 | FileCheck %s --check-prefix=SME-IMPLY
-// SME-IMPLY: "-target-feature" "+sme" "-target-feature" "+bf16"
+// SME-IMPLY: "-target-feature" "+bf16"{{.*}} "-target-feature" "+sme"
// RUN: %clang -target aarch64-linux-gnu -march=armv8-a+nosme %s -### 2>&1 | FileCheck %s --check-prefix=NOSME
-// NOSME: "-target-feature" "-sme"
+// NOSME-NOT: "-target-feature" "{{\+|-}}sme"
// RUN: %clang -target aarch64-linux-gnu -march=armv8-a+sme+nosme %s -### 2>&1 | FileCheck %s --check-prefix=SME-REVERT
// SME-REVERT-NOT: "-target-feature" "+sme"
-// SME-REVERT: "-target-feature" "+bf16" "-target-feature" "-sme" "-target-feature" "-sme-f64f64" "-target-feature" "-sme-i16i64"
+// SME-REVERT: "-target-feature" "+bf16"{{.*}} "-target-feature" "-sme"
----------------
tmatheson-arm wrote:
So here, `+sme+nosme` should no longer explicitly remove `sme-f64f64` etc, which are dependencies of `+sme`, instead they default to off and are not mentioned on the `-cc1` command line? In other words, there is no behaviour change here, iiuc.
Do we have any later checks that the features are reassembled correctly? Checks for preprocessor macros maybe.
https://github.com/llvm/llvm-project/pull/78270
More information about the cfe-commits
mailing list