]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
target/arm: Handle SME-without-SVE on change of EL
authorPeter Maydell <peter.maydell@linaro.org>
Wed, 18 Feb 2026 18:40:14 +0000 (18:40 +0000)
committerPeter Maydell <peter.maydell@linaro.org>
Wed, 18 Feb 2026 18:40:14 +0000 (18:40 +0000)
aarch64_sve_change_el() currently assumes that SME implies
SVE, and will return without doing anything if SVE is not
implemented, skipping a possible requirement to change
the vector register state because the SME vector length
has changed. Update it to handle SME also.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-id: 20260202133353.2231685-8-peter.maydell@linaro.org

target/arm/helper.c

index ebf185000b85b3f2d997aca3dfab7b5d11eff6d0..e12b2455d3f0dc73000f83878b54fecd7568df42 100644 (file)
@@ -10139,8 +10139,8 @@ void aarch64_sve_change_el(CPUARMState *env, int old_el,
     int old_len, new_len;
     bool old_a64, new_a64, sm;
 
-    /* Nothing to do if no SVE.  */
-    if (!cpu_isar_feature(aa64_sve, cpu)) {
+    /* Nothing to do if no SVE or SME.  */
+    if (!cpu_isar_feature(aa64_sve, cpu) && !cpu_isar_feature(aa64_sme, cpu)) {
         return;
     }