[clang] [llvm] [AArch64] Make apple-m4 armv8.7-a again (from armv9.2-a). (PR #106312)

Tomas Matheson via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 28 02:41:04 PDT 2024


================
@@ -895,7 +895,10 @@ def ProcessorFeatures {
                                      FeatureLSE, FeaturePAuth, FeatureFPAC,
                                      FeatureRAS, FeatureRCPC, FeatureRDM,
                                      FeatureBF16, FeatureDotProd, FeatureMatMulInt8, FeatureSSBS];
-  list<SubtargetFeature> AppleM4 = [HasV9_2aOps, FeatureSHA2, FeatureFPARMv8,
+  // Technically apple-m4 is ARMv9.2a, but a quirk of LLVM defines v9.0 as
+  // requiring SVE, which is optional according to the Arm ARM and not
+  // supported by the core. ARMv8.7a is the next closest choice.
----------------
tmatheson-arm wrote:

Please update the comment to explain the "quirk". I think what you mean is that clang will still add all of the architecture default features when you are selecting a particular CPU, even if the backend wouldn't add them.

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


More information about the cfe-commits mailing list