VEX is only forbidden in real and vm86 mode; 16-bit protected mode supports it for some unfathomable reason.
Cc: [email protected] Signed-off-by: Paolo Bonzini <[email protected]> --- target/i386/tcg/decode-new.c.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/i386/tcg/decode-new.c.inc b/target/i386/tcg/decode-new.c.inc index f662364c600..243df7e3735 100644 --- a/target/i386/tcg/decode-new.c.inc +++ b/target/i386/tcg/decode-new.c.inc @@ -2875,7 +2875,7 @@ static void disas_insn(DisasContext *s, CPUState *cpu) * VEX prefixes cannot be used except in 32-bit mode. * Otherwise the instruction is LES or LDS. */ - if (CODE32(s) && !VM86(s)) { + if (PE(s) && !VM86(s)) { static const int pp_prefix[4] = { 0, PREFIX_DATA, PREFIX_REPZ, PREFIX_REPNZ }; -- 2.52.0
