Skip to content

Commit 263965e

Browse files
tmatheson-armtru
authored andcommitted
[AArch64] Add a check for invalid default features (#104435)
This adds a check that all ExtensionWithMArch which are marked as implied features for an architecture are also present in the list of default features. It doesn't make sense to have something mandatory but not on by default. There were a number of existing cases that violated this rule, and some changes to which features are mandatory (indicated by the Implies field). This resulted in a bug where if a feature was marked as `Implies` but was not added to `DefaultExt`, then for `-march=base_arch+nofeat` the Driver would consider `feat` to have never been added and therefore would do nothing to disable it (no `-target-feature -feat` would be added, but the backend would enable the feature by default because of `Implies`). See clang/test/Driver/aarch64-negative-modifiers-for-default-features.c. Note that the processor definitions do not respect the architecture DefaultExts. These apply only when specifying `-march=<some architecture version>`. So when a feature is moved from `Implies` to `DefaultExts` on the Architecture definition, the feature needs to be added to all processor definitions (that are based on that architecture) in order to preserve the existing behaviour. I have checked the TRMs for many cases (see specific commit messages) but in other cases I have just kept the current behaviour and not tried to fix it.
1 parent bb46c72 commit 263965e

21 files changed

+154
-84
lines changed

clang/test/CodeGen/aarch64-targetattr.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -195,19 +195,19 @@ void minusarch() {}
195195
// CHECK: attributes #[[ATTR0]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+crc,+fp-armv8,+lse,+neon,+ras,+rdm,+v8.1a,+v8.2a,+v8a" }
196196
// CHECK: attributes #[[ATTR1]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+crc,+fp-armv8,+fullfp16,+lse,+neon,+ras,+rdm,+sve,+v8.1a,+v8.2a,+v8a" }
197197
// CHECK: attributes #[[ATTR2]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+crc,+fp-armv8,+fullfp16,+lse,+neon,+ras,+rdm,+sve,+sve2,+v8.1a,+v8.2a,+v8a" }
198-
// CHECK: attributes #[[ATTR3]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+bf16,+complxnum,+crc,+dotprod,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+ras,+rcpc,+rdm,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8.6a,+v8a" }
199-
// CHECK: attributes #[[ATTR4]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="cortex-a710" "target-features"="+bf16,+complxnum,+crc,+dotprod,+ete,+flagm,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+mte,+neon,+pauth,+perfmon,+ras,+rcpc,+rdm,+sb,+sve,+sve2,+sve2-bitperm,+trbe,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8a,+v9a" }
198+
// CHECK: attributes #[[ATTR3]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+bf16,+bti,+ccidx,+complxnum,+crc,+dit,+dotprod,+flagm,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+predres,+ras,+rcpc,+rdm,+sb,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8.6a,+v8a" }
199+
// CHECK: attributes #[[ATTR4]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="cortex-a710" "target-features"="+bf16,+bti,+ccidx,+complxnum,+crc,+dit,+dotprod,+ete,+flagm,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+mte,+neon,+pauth,+perfmon,+predres,+ras,+rcpc,+rdm,+sb,+ssbs,+sve,+sve2,+sve2-bitperm,+trbe,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8a,+v9a" }
200200
// CHECK: attributes #[[ATTR5]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "tune-cpu"="cortex-a710" }
201201
// CHECK: attributes #[[ATTR6]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="generic" "target-features"="+ete,+fp-armv8,+neon,+trbe,+v8a" }
202202
// CHECK: attributes #[[ATTR7]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "tune-cpu"="generic" }
203203
// CHECK: attributes #[[ATTR8]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-n1" "target-features"="+aes,+crc,+dotprod,+fp-armv8,+fullfp16,+lse,+neon,+perfmon,+ras,+rcpc,+rdm,+sha2,+spe,+ssbs,+v8.1a,+v8.2a,+v8a" "tune-cpu"="cortex-a710" }
204204
// CHECK: attributes #[[ATTR9]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+fp-armv8,+fullfp16,+sve" "tune-cpu"="cortex-a710" }
205-
// CHECK: attributes #[[ATTR10]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-v1" "target-features"="+aes,+bf16,+ccdp,+complxnum,+crc,+dotprod,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+rand,+ras,+rcpc,+rdm,+sha2,+sha3,+sm4,+spe,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8a" }
206-
// CHECK: attributes #[[ATTR11]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-v1" "target-features"="+aes,+bf16,+ccdp,+complxnum,+crc,+dotprod,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+rand,+ras,+rcpc,+rdm,+sha2,+sha3,+sm4,+spe,+ssbs,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8a,-sve" }
205+
// CHECK: attributes #[[ATTR10]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-v1" "target-features"="+aes,+bf16,+ccdp,+ccidx,+complxnum,+crc,+dit,+dotprod,+flagm,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+rand,+ras,+rcpc,+rdm,+sha2,+sha3,+sm4,+spe,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8a" }
206+
// CHECK: attributes #[[ATTR11]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-v1" "target-features"="+aes,+bf16,+ccdp,+ccidx,+complxnum,+crc,+dit,+dotprod,+flagm,+fp-armv8,+fp16fml,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+rand,+ras,+rcpc,+rdm,+sha2,+sha3,+sm4,+spe,+ssbs,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8a,-sve" }
207207
// CHECK: attributes #[[ATTR12]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+fp-armv8,+fullfp16,+sve" }
208208
// CHECK: attributes #[[ATTR13]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="+fp-armv8,+fullfp16" }
209-
// CHECK: attributes #[[ATTR14]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-n1" "target-features"="+aes,+bf16,+complxnum,+crc,+dotprod,+fp-armv8,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+ras,+rcpc,+rdm,+sha2,+spe,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8.6a,+v8a" "tune-cpu"="cortex-a710" }
210-
// CHECK: attributes #[[ATTR15]] = { noinline nounwind optnone "branch-target-enforcement" "guarded-control-stack" "no-trapping-math"="true" "sign-return-address"="non-leaf" "sign-return-address-key"="a_key" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-n1" "target-features"="+aes,+bf16,+complxnum,+crc,+dotprod,+fp-armv8,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+ras,+rcpc,+rdm,+sha2,+spe,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8.6a,+v8a" "tune-cpu"="cortex-a710" }
209+
// CHECK: attributes #[[ATTR14]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-n1" "target-features"="+aes,+bf16,+bti,+ccidx,+complxnum,+crc,+dit,+dotprod,+flagm,+fp-armv8,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+predres,+ras,+rcpc,+rdm,+sb,+sha2,+spe,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8.6a,+v8a" "tune-cpu"="cortex-a710" }
210+
// CHECK: attributes #[[ATTR15]] = { noinline nounwind optnone "branch-target-enforcement" "guarded-control-stack" "no-trapping-math"="true" "sign-return-address"="non-leaf" "sign-return-address-key"="a_key" "stack-protector-buffer-size"="8" "target-cpu"="neoverse-n1" "target-features"="+aes,+bf16,+bti,+ccidx,+complxnum,+crc,+dit,+dotprod,+flagm,+fp-armv8,+fullfp16,+i8mm,+jsconv,+lse,+neon,+pauth,+perfmon,+predres,+ras,+rcpc,+rdm,+sb,+sha2,+spe,+ssbs,+sve,+sve2,+v8.1a,+v8.2a,+v8.3a,+v8.4a,+v8.5a,+v8.6a,+v8a" "tune-cpu"="cortex-a710" }
211211
// CHECK: attributes #[[ATTR16]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" }
212212
// CHECK: attributes #[[ATTR17]] = { noinline nounwind optnone "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-features"="-v9.3a" }
213213
//.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
// Test that default features (e.g. flagm/sb/ssbs for 8.5) can be disabled via -march.
2+
3+
// RUN: %clang --target=aarch64 -march=armv8.5-a+noflagm+nosb+nossbs -c %s -### 2>&1 | FileCheck %s
4+
// CHECK: "-triple" "aarch64"
5+
// CHECK-SAME: "-target-feature" "+v8.5a"
6+
// CHECK-SAME: "-target-feature" "-flagm"
7+
// CHECK-SAME: "-target-feature" "-sb"
8+
// CHECK-SAME: "-target-feature" "-ssbs"
9+
10+
// CHECK-NOT: "-target-feature" "+flagm"
11+
// CHECK-NOT: "-target-feature" "+sb"
12+
// CHECK-NOT: "-target-feature" "+ssbs"

clang/test/Driver/arm-sb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@
1111

1212
// RUN: %clang -### -target arm-none-none-eabi %s 2>&1 | FileCheck %s --check-prefix=ABSENT
1313
// RUN: %clang -### -target aarch64-none-elf %s 2>&1 | FileCheck %s --check-prefix=ABSENT
14-
// RUN: %clang -### -target aarch64-none-elf -march=armv8.5a+nosb %s 2>&1 | FileCheck %s --check-prefix=ABSENT
14+
// RUN: %clang -### -target aarch64-none-elf -march=armv8.5a+nosb %s 2>&1 | FileCheck %s --check-prefix=NOSB
1515
// ABSENT-NOT: "-target-feature" "+sb"
1616
// ABSENT-NOT: "-target-feature" "-sb"

clang/test/Driver/print-enabled-extensions/aarch64-apple-a12.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
// CHECK-NEXT: Architecture Feature(s) Description
77
// CHECK-NEXT: FEAT_AES, FEAT_PMULL Enable AES support
88
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
9-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
109
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1110
// CHECK-NEXT: FEAT_DPB Enable Armv8.2-A data Cache Clean to Point of Persistence
1211
// CHECK-NEXT: FEAT_FCMA Enable Armv8.3-A Floating-point complex number support

clang/test/Driver/print-enabled-extensions/aarch64-apple-a13.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
// CHECK-NEXT: FEAT_AES, FEAT_PMULL Enable AES support
88
// CHECK-NEXT: FEAT_AMUv1 Enable Armv8.4-A Activity Monitors extension
99
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
10-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
1110
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1211
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions
1312
// CHECK-NEXT: FEAT_DPB Enable Armv8.2-A data Cache Clean to Point of Persistence

clang/test/Driver/print-enabled-extensions/aarch64-apple-a14.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
// CHECK-NEXT: FEAT_AES, FEAT_PMULL Enable AES support
88
// CHECK-NEXT: FEAT_AMUv1 Enable Armv8.4-A Activity Monitors extension
99
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
10-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
1110
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1211
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1312
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions

clang/test/Driver/print-enabled-extensions/aarch64-apple-a15.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
1111
// CHECK-NEXT: FEAT_BF16 Enable BFloat16 Extension
1212
// CHECK-NEXT: FEAT_BTI Enable Branch Target Identification
13-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
1413
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1514
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1615
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions

clang/test/Driver/print-enabled-extensions/aarch64-apple-a16.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
1111
// CHECK-NEXT: FEAT_BF16 Enable BFloat16 Extension
1212
// CHECK-NEXT: FEAT_BTI Enable Branch Target Identification
13-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
1413
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1514
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1615
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions

clang/test/Driver/print-enabled-extensions/aarch64-apple-a17.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
1111
// CHECK-NEXT: FEAT_BF16 Enable BFloat16 Extension
1212
// CHECK-NEXT: FEAT_BTI Enable Branch Target Identification
13-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
1413
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1514
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1615
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions

clang/test/Driver/print-enabled-extensions/aarch64-apple-m4.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
1111
// CHECK-NEXT: FEAT_BF16 Enable BFloat16 Extension
1212
// CHECK-NEXT: FEAT_BTI Enable Branch Target Identification
13-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
1413
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
1514
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1615
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions
@@ -51,7 +50,6 @@
5150
// CHECK-NEXT: FEAT_SME_F64F64 Enable Scalable Matrix Extension (SME) F64F64 instructions
5251
// CHECK-NEXT: FEAT_SME_I16I64 Enable Scalable Matrix Extension (SME) I16I64 instructions
5352
// CHECK-NEXT: FEAT_SPECRES Enable Armv8.5-A execution and data prediction invalidation instructions
54-
// CHECK-NEXT: FEAT_SSBS, FEAT_SSBS2 Enable Speculative Store Bypass Safe bit
5553
// CHECK-NEXT: FEAT_TLBIOS, FEAT_TLBIRANGE Enable Armv8.4-A TLB Range and Maintenance instructions
5654
// CHECK-NEXT: FEAT_TRF Enable Armv8.4-A Trace extension
5755
// CHECK-NEXT: FEAT_UAO Enable Armv8.2-A UAO PState

clang/test/Driver/print-enabled-extensions/aarch64-cortex-r82.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
// CHECK-EMPTY:
66
// CHECK-NEXT: Architecture Feature(s) Description
77
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
8-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
98
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
109
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1110
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions

clang/test/Driver/print-enabled-extensions/aarch64-cortex-r82ae.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
// CHECK-EMPTY:
66
// CHECK-NEXT: Architecture Feature(s) Description
77
// CHECK-NEXT: FEAT_AdvSIMD Enable Advanced SIMD instructions
8-
// CHECK-NEXT: FEAT_CCIDX Enable Armv8.3-A Extend of the CCSIDR number of sets
98
// CHECK-NEXT: FEAT_CRC32 Enable Armv8.0-A CRC-32 checksum instructions
109
// CHECK-NEXT: FEAT_CSV2_2 Enable architectural speculation restriction
1110
// CHECK-NEXT: FEAT_DIT Enable Armv8.4-A Data Independent Timing instructions

llvm/lib/Target/AArch64/AArch64Features.td

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -787,27 +787,26 @@ def HasV8_2aOps : Architecture64<8, 2, "a", "v8.2a",
787787
[HasV8_1aOps, FeaturePsUAO, FeaturePAN_RWV, FeatureRAS, FeatureCCPP],
788788
!listconcat(HasV8_1aOps.DefaultExts, [FeatureRAS])>;
789789
def HasV8_3aOps : Architecture64<8, 3, "a", "v8.3a",
790-
[HasV8_2aOps, FeatureRCPC, FeaturePAuth, FeatureJS, FeatureCCIDX,
791-
FeatureComplxNum],
790+
[HasV8_2aOps, FeatureRCPC, FeaturePAuth, FeatureJS, FeatureComplxNum],
792791
!listconcat(HasV8_2aOps.DefaultExts, [FeatureComplxNum, FeatureJS,
793-
FeaturePAuth, FeatureRCPC])>;
792+
FeaturePAuth, FeatureRCPC, FeatureCCIDX])>;
794793
def HasV8_4aOps : Architecture64<8, 4, "a", "v8.4a",
795794
[HasV8_3aOps, FeatureDotProd, FeatureNV, FeatureMPAM, FeatureDIT,
796795
FeatureTRACEV8_4, FeatureAM, FeatureSEL2, FeatureTLB_RMI, FeatureFlagM,
797796
FeatureRCPC_IMMO, FeatureLSE2],
798-
!listconcat(HasV8_3aOps.DefaultExts, [FeatureDotProd])>;
797+
!listconcat(HasV8_3aOps.DefaultExts, [FeatureDotProd, FeatureDIT, FeatureFlagM])>;
799798
def HasV8_5aOps : Architecture64<8, 5, "a", "v8.5a",
800799
[HasV8_4aOps, FeatureAltFPCmp, FeatureFRInt3264, FeatureSpecRestrict,
801-
FeatureSSBS, FeatureSB, FeaturePredRes, FeatureCacheDeepPersist,
800+
FeatureSB, FeaturePredRes, FeatureCacheDeepPersist,
802801
FeatureBranchTargetId],
803-
!listconcat(HasV8_4aOps.DefaultExts, [])>;
802+
!listconcat(HasV8_4aOps.DefaultExts, [FeaturePredRes, FeatureSSBS, FeatureBranchTargetId, FeatureSB])>;
804803
def HasV8_6aOps : Architecture64<8, 6, "a", "v8.6a",
805804
[HasV8_5aOps, FeatureAMVS, FeatureBF16, FeatureFineGrainedTraps,
806805
FeatureEnhancedCounterVirtualization, FeatureMatMulInt8],
807806
!listconcat(HasV8_5aOps.DefaultExts, [FeatureBF16, FeatureMatMulInt8])>;
808807
def HasV8_7aOps : Architecture64<8, 7, "a", "v8.7a",
809808
[HasV8_6aOps, FeatureXS, FeatureWFxT, FeatureHCX],
810-
!listconcat(HasV8_6aOps.DefaultExts, [])>;
809+
!listconcat(HasV8_6aOps.DefaultExts, [FeatureWFxT])>;
811810
def HasV8_8aOps : Architecture64<8, 8, "a", "v8.8a",
812811
[HasV8_7aOps, FeatureHBC, FeatureMOPS, FeatureNMI],
813812
!listconcat(HasV8_7aOps.DefaultExts, [FeatureMOPS, FeatureHBC])>;
@@ -825,7 +824,7 @@ def HasV9_1aOps : Architecture64<9, 1, "a", "v9.1a",
825824
!listconcat(HasV9_0aOps.DefaultExts, [FeatureBF16, FeatureMatMulInt8, FeatureRME])>;
826825
def HasV9_2aOps : Architecture64<9, 2, "a", "v9.2a",
827826
[HasV8_7aOps, HasV9_1aOps],
828-
!listconcat(HasV9_1aOps.DefaultExts, [FeatureMEC])>;
827+
!listconcat(HasV9_1aOps.DefaultExts, [FeatureMEC, FeatureWFxT])>;
829828
def HasV9_3aOps : Architecture64<9, 3, "a", "v9.3a",
830829
[HasV8_8aOps, HasV9_2aOps],
831830
!listconcat(HasV9_2aOps.DefaultExts, [FeatureMOPS, FeatureHBC])>;
@@ -842,7 +841,7 @@ def HasV8_0rOps : Architecture64<8, 0, "r", "v8r",
842841
//v8.2
843842
FeatureRAS, FeaturePsUAO, FeatureCCPP, FeaturePAN_RWV,
844843
//v8.3
845-
FeatureCCIDX, FeaturePAuth, FeatureRCPC,
844+
FeaturePAuth, FeatureRCPC,
846845
//v8.4
847846
FeatureTRACEV8_4, FeatureTLB_RMI, FeatureFlagM, FeatureDIT, FeatureSEL2,
848847
FeatureRCPC_IMMO,
@@ -853,7 +852,7 @@ def HasV8_0rOps : Architecture64<8, 0, "r", "v8r",
853852
// For v8-R, we do not enable crypto and align with GCC that enables a more
854853
// minimal set of optional architecture extensions.
855854
!listconcat(
856-
!listremove(HasV8_5aOps.DefaultExts, [FeatureLSE]),
855+
!listremove(HasV8_5aOps.DefaultExts, [FeatureBranchTargetId, FeaturePredRes]),
857856
[FeatureSSBS, FeatureFullFP16, FeatureFP16FML, FeatureSB]
858857
)>;
859858

0 commit comments

Comments
 (0)