From 7796f7e088c5aa878cfb61b5a885b64daf390808 Mon Sep 17 00:00:00 2001 From: iximeow Date: Sat, 3 Jul 2021 13:39:46 -0700 Subject: clean up x86_32 and make interfaces match x86_64 --- src/long_mode/mod.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/long_mode') diff --git a/src/long_mode/mod.rs b/src/long_mode/mod.rs index 0cae4f0..04ad91b 100644 --- a/src/long_mode/mod.rs +++ b/src/long_mode/mod.rs @@ -9154,14 +9154,14 @@ fn unlikely_operands::Address, { - if instruction.prefixes.rep() || instruction.prefixes.repnz() { - return Err(DecodeError::InvalidOperand); - } - let opwidth = imm_width_from_prefixes_64(SizeCode::vq, instruction.prefixes); let modrm = read_modrm(words)?; let r = (modrm >> 3) & 7; if r == 0 { + if instruction.prefixes.rep() || instruction.prefixes.repnz() || instruction.prefixes.operand_size() { + return Err(DecodeError::InvalidOperand); + } + let mod_bits = modrm >> 6; let m = modrm & 7; if mod_bits == 0b11 { -- cgit v1.1