From 7b5272524790b773908c67c271a92761930c80d9 Mon Sep 17 00:00:00 2001
From: Sergey Fedorov <barracuda@macos-powerpc.org>
Date: Sat, 22 Nov 2025 22:51:18 +0700
Subject: [PATCH 7/7] AArch64: drop unsupported features from specs

---
 llvm/include/llvm/Support/AArch64TargetParser.def |  6 +++---
 llvm/lib/Target/AArch64/AArch64.td                | 15 +--------------
 2 files changed, 4 insertions(+), 17 deletions(-)

diff --git llvm/include/llvm/Support/AArch64TargetParser.def llvm/include/llvm/Support/AArch64TargetParser.def
index b6d70e5a724..7ee4078c0e3 100644
--- llvm/include/llvm/Support/AArch64TargetParser.def
+++ llvm/include/llvm/Support/AArch64TargetParser.def
@@ -103,11 +103,11 @@ AARCH64_CPU_NAME("apple-a11", ARMV8_2A, FK_CRYPTO_NEON_FP_ARMV8, false,
 AARCH64_CPU_NAME("apple-a12", ARMV8_3A, FK_CRYPTO_NEON_FP_ARMV8, false,
                  (AArch64::AEK_FP16))
 AARCH64_CPU_NAME("apple-a13", ARMV8_4A, FK_CRYPTO_NEON_FP_ARMV8, false,
-                 (AArch64::AEK_FP16 | AArch64::AEK_FP16FML))
+                 (AArch64::AEK_FP16))
 AARCH64_CPU_NAME("apple-a14", ARMV8_5A, FK_CRYPTO_NEON_FP_ARMV8, false,
-                 (AArch64::AEK_FP16 | AArch64::AEK_FP16FML))
+                 (AArch64::AEK_FP16))
 AARCH64_CPU_NAME("apple-m1", ARMV8_5A, FK_CRYPTO_NEON_FP_ARMV8, false,
-                 (AArch64::AEK_FP16 | AArch64::AEK_FP16FML))
+                 (AArch64::AEK_FP16))
 AARCH64_CPU_NAME("apple-s4", ARMV8_3A, FK_CRYPTO_NEON_FP_ARMV8, false,
                  (AArch64::AEK_FP16))
 AARCH64_CPU_NAME("apple-s5", ARMV8_3A, FK_CRYPTO_NEON_FP_ARMV8, false,
diff --git llvm/lib/Target/AArch64/AArch64.td llvm/lib/Target/AArch64/AArch64.td
index 821baba7e8d..17c61422883 100644
--- llvm/lib/Target/AArch64/AArch64.td
+++ llvm/lib/Target/AArch64/AArch64.td
@@ -372,10 +372,7 @@ def ProcAppleA10 : SubtargetFeature<"apple-a10", "ARMProcFamily", "AppleA10",
                                     FeatureZCRegMove,
                                     FeatureZCZeroing,
                                     FeatureCRC,
-                                    FeatureRDM,
-                                    FeaturePAN,
-                                    FeatureLOR,
-                                    FeatureVH,
+                                    FeatureRDM
                                     ]>;
 
 def ProcAppleA11 : SubtargetFeature<"apple-a11", "ARMProcFamily", "AppleA11",
@@ -429,7 +426,6 @@ def ProcAppleA13 : SubtargetFeature<"apple-a13", "ARMProcFamily", "AppleA13",
                                      FeatureZCRegMove,
                                      FeatureZCZeroing,
                                      FeatureFullFP16,
-                                     FeatureFP16FML,
                                      FeatureSHA3,
                                      HasV8_4aOps
                                      ]>;
@@ -438,30 +434,21 @@ def ProcAppleA14 : SubtargetFeature<"apple-a14", "ARMProcFamily", "AppleA14",
                                      "Apple A14", [
                                      FeatureAggressiveFMA,
                                      FeatureAlternateSExtLoadCVTF32Pattern,
-                                     FeatureAltFPCmp,
                                      FeatureArithmeticBccFusion,
                                      FeatureArithmeticCbzFusion,
                                      FeatureCrypto,
                                      FeatureDisableLatencySchedHeuristic,
                                      FeatureFPARMv8,
-                                     FeatureFRInt3264,
                                      FeatureFuseAddress,
                                      FeatureFuseAES,
-                                     FeatureFuseArithmeticLogic,
                                      FeatureFuseCCSelect,
                                      FeatureFuseCryptoEOR,
                                      FeatureFuseLiterals,
                                      FeatureNEON,
                                      FeaturePerfMon,
-                                     FeatureSpecRestrict,
-                                     FeatureSSBS,
-                                     FeatureSB,
-                                     FeaturePredRes,
-                                     FeatureCacheDeepPersist,
                                      FeatureZCRegMove,
                                      FeatureZCZeroing,
                                      FeatureFullFP16,
-                                     FeatureFP16FML,
                                      FeatureSHA3,
                                      HasV8_4aOps
                                      ]>;
