Skip to content

Commit

Permalink
x86emul: correct #UD check for AVX512-FP16 complex multiplications
Browse files Browse the repository at this point in the history
avx512_vlen_check()'s argument was inverted, while the surrounding
conditional wrongly forced the EVEX.L'L check for the scalar forms when
embedded rounding was in effect.

Fixes: d14c52c ("x86emul: handle AVX512-FP16 complex multiplication insns")
Signed-off-by: Jan Beulich <[email protected]>
Acked-by: Andrew Cooper <[email protected]>
  • Loading branch information
jbeulich committed Aug 19, 2024
1 parent 1e2a5f9 commit a30d438
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions xen/arch/x86/x86_emulate/x86_emulate.c
Original file line number Diff line number Diff line change
Expand Up @@ -7852,8 +7852,8 @@ x86_emulate(
generate_exception_if(modrm_reg == src1 ||
(ea.type != OP_MEM && modrm_reg == modrm_rm),
X86_EXC_UD);
if ( ea.type != OP_REG || (b & 1) || !evex.brs )
avx512_vlen_check(!(b & 1));
if ( ea.type != OP_REG || !evex.brs )
avx512_vlen_check(b & 1);
goto simd_zmm;
}

Expand Down

0 comments on commit a30d438

Please sign in to comment.