diff options
| author | iximeow <me@iximeow.net> | 2026-04-17 03:02:43 +0000 |
|---|---|---|
| committer | iximeow <me@iximeow.net> | 2026-05-25 00:59:27 +0000 |
| commit | bbdb82bd41234021cc8dbe3337e88bd9f19cade9 (patch) | |
| tree | 9135b6e5113c2e1455b4dcc00ccc4c0e77d6c941 /src/protected_mode/mod.rs | |
| parent | 470ddb9a0329a8f1823674bca2c108e012ca2780 (diff) | |
maskmov{q,dqu} memory access size
Diffstat (limited to 'src/protected_mode/mod.rs')
| -rw-r--r-- | src/protected_mode/mod.rs | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/protected_mode/mod.rs b/src/protected_mode/mod.rs index eeb2942..0cb6674 100644 --- a/src/protected_mode/mod.rs +++ b/src/protected_mode/mod.rs @@ -3943,6 +3943,7 @@ enum OperandCase { G_E_mm_Ib, AbsFar, MOVDIR64B, + MASKMOVDQU, ModRM_0x0f00, ModRM_0x0f01, ModRM_0x0f0d, @@ -4287,6 +4288,7 @@ enum OperandCode { AbsFar = OperandCodeBuilder::new().operand_case(OperandCase::AbsFar).bits(), ModRM_0xc4 = OperandCodeBuilder::new().operand_case(OperandCase::ModRM_0xc4).bits(), ModRM_0xc5 = OperandCodeBuilder::new().operand_case(OperandCase::ModRM_0xc5).bits(), + MASKMOVDQU = OperandCodeBuilder::new().read_E().reg_mem().operand_case(OperandCase::MASKMOVDQU).bits(), } fn base_opcode_map(v: u8) -> Opcode { @@ -6804,6 +6806,14 @@ fn read_operands< instruction.regs[0].bank = RegisterBank::X; instruction.regs[1].bank = RegisterBank::X; }, + OperandCase::MASKMOVDQU => { + if mem_oper != OperandSpec::RegMMM { + return Err(DecodeError::InvalidOperand); + } + instruction.regs[0].bank = RegisterBank::X; + instruction.regs[1].bank = RegisterBank::X; + instruction.mem_size = 16; + } OperandCase::Gv_Ev_Ib => { instruction.imm = read_imm_signed(words, 1)? as u32; @@ -7023,6 +7033,7 @@ fn read_operands< instruction.regs[1].bank = RegisterBank::MM; instruction.regs[1].num &= 0b111; instruction.regs[0].num &= 0b111; + instruction.mem_size = 8; instruction.operand_count = 2; }, OperandCase::E_G_q => { @@ -10555,7 +10566,7 @@ const OPERAND_SIZE_0F_CODES: [OpcodeRecord; 256] = [ OpcodeRecord::new(Interpretation::Instruction(Opcode::PMULUDQ), OperandCode::G_E_xmm), OpcodeRecord::new(Interpretation::Instruction(Opcode::PMADDWD), OperandCode::G_E_xmm), OpcodeRecord::new(Interpretation::Instruction(Opcode::PSADBW), OperandCode::G_E_xmm), - OpcodeRecord::new(Interpretation::Instruction(Opcode::MASKMOVDQU), OperandCode::G_U_xmm), + OpcodeRecord::new(Interpretation::Instruction(Opcode::MASKMOVDQU), OperandCode::MASKMOVDQU), OpcodeRecord::new(Interpretation::Instruction(Opcode::PSUBB), OperandCode::G_E_xmm), OpcodeRecord::new(Interpretation::Instruction(Opcode::PSUBW), OperandCode::G_E_xmm), OpcodeRecord::new(Interpretation::Instruction(Opcode::PSUBD), OperandCode::G_E_xmm), |
