@samitouri / QOSamiQemu / commits / 85d508c1fc

target/arm: Enable FEAT_SVE2p2 and FEAT_SME2p2 for -cpu max

These features are tied together if both SVE and SME are enabled. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20260826174213.614571-6-richard.henderson@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

Richard Henderson committed Aug 26, 2026 at 10:41 UTC 85d508c1fc2d50ec9d7e859a8d5db7a8d3738911
3 files changed +7 -2
docs/system/arm/emulation.rst
+2
@@ -180,6 +180,7 @@ the following architecture extensions:
180 - FEAT_SME (Scalable Matrix Extension)
181 - FEAT_SME2 (Scalable Matrix Extension version 2)
182 - FEAT_SME2p1 (Scalable Matrix Extension version 2.1)
183 +- FEAT_SME2p2 (Scalable Matrix Extension version 2.2)
184 - FEAT_SME_B16B16 (Non-widening BFloat16 arithmetic for SME2)
185 - FEAT_SME_FA64 (Full A64 instruction set in Streaming SVE mode)
186 - FEAT_SME_F16F16 (Non-widening half-precision FP16 arithmetic for SME2)
@@ -204,6 +205,7 @@ the following architecture extensions:
205 - FEAT_SVE_SM4 (Scalable Vector SM4 instructions)
206 - FEAT_SVE2 (Scalable Vector Extension version 2)
207 - FEAT_SVE2p1 (Scalable Vector Extension version 2.1)
208 +- FEAT_SVE2p2 (Scalable Vector Extension version 2.2)
209 - FEAT_SPECRES (Speculation restriction instructions)
210 - FEAT_SSBS (Speculative Store Bypass Safe)
211 - FEAT_SSBS2 (MRS and MSR instructions for SSBS version 2)
linux-user/aarch64/elfload.c
+2
@@ -178,6 +178,8 @@ abi_ulong get_elf_hwcap(CPUState *cs)
178 GET_FEATURE_ID(aa64_fprcvt, ARM_HWCAP_A64_FPRCVT);
179 GET_FEATURE_ID(aa64_sme_mop4, ARM_HWCAP_A64_SME_SMOP4);
180 GET_FEATURE_ID(aa64_sme_tmop, ARM_HWCAP_A64_SME_STMOP);
181 + GET_FEATURE_ID(aa64_sve2p2, ARM_HWCAP_A64_SVE2P2);
182 + GET_FEATURE_ID(aa64_sme2p2, ARM_HWCAP_A64_SME2P2);
183
184 return hwcaps;
185 }
target/arm/tcg/cpu64.c
+3 -2
@@ -1470,8 +1470,9 @@ void aarch64_max_v9_tcg_initfn(Object *obj)
1470 SET_IDREG(isar, ID_AA64MMFR4, t);
1471
1472 t = GET_IDREG(isar, ID_AA64ZFR0);
1473 - t = FIELD_DP64(t, ID_AA64ZFR0, SVEVER, 2); /* v9.2: FEAT_SVE2p1 */
1473 + t = FIELD_DP64(t, ID_AA64ZFR0, SVEVER, 3); /* v9.4: FEAT_SVE2p2 */
1474 t = FIELD_DP64(t, ID_AA64ZFR0, AES, 2); /* v9.0: FEAT_SVE_PMULL128 */
1475 + t = FIELD_DP64(t, ID_AA64ZFR0, ELTPERM, 1); /* v9.4: FEAT_SVE2p2 */
1476 t = FIELD_DP64(t, ID_AA64ZFR0, BITPERM, 1); /* v9.0: FEAT_SVE_BitPerm */
1477 t = FIELD_DP64(t, ID_AA64ZFR0, B16B16, 1); /* v9.2: FEAT_SVE_B16B16 */
1478 t = FIELD_DP64(t, ID_AA64ZFR0, SHA3, 1); /* v9.0: FEAT_SVE_SHA3 */
@@ -1498,7 +1499,7 @@ void aarch64_max_v9_tcg_initfn(Object *obj)
1499 t = FIELD_DP64(t, ID_AA64SMFR0, I16I32, 5); /* v9.2: FEAT_SME2 */
1500 t = FIELD_DP64(t, ID_AA64SMFR0, F64F64, 1); /* v9.2: FEAT_SME_F64F64 */
1501 t = FIELD_DP64(t, ID_AA64SMFR0, I16I64, 0xf); /* v9.2: FEAT_SME_I16I64 */
1501 - t = FIELD_DP64(t, ID_AA64SMFR0, SMEVER, 2); /* v9.2: FEAT_SME2p1 */
1502 + t = FIELD_DP64(t, ID_AA64SMFR0, SMEVER, 3); /* v9.4: FEAT_SME2p2 */
1503 t = FIELD_DP64(t, ID_AA64SMFR0, LUTv2, 1); /* v9.2: FEAT_SME_LUTv2 */
1504 t = FIELD_DP64(t, ID_AA64SMFR0, FA64, 1); /* v9.2: FEAT_SME_FA64 */
1505 SET_IDREG(isar, ID_AA64SMFR0, t);