From ae2dd6a1a39e58db83369f83b1dc46e1f3aa0b84 Mon Sep 17 00:00:00 2001 From: iximeow Date: Mon, 1 Jul 2019 16:44:24 -0700 Subject: "support" a few 0f01 instructions --- src/lib.rs | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 7dcfb5a..ca86006 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -3007,7 +3007,10 @@ fn read_operands>( } } else if r == 1 { if mod_bits == 0b11 { - panic!("Unsupported instruction: 0x0f01 with modrm: 11 001 ___"); + // TOOD: MONITOR + instruction.opcode = Opcode::NOP; + instruction.operands[0] = Operand::Nothing; + Ok(()) } else { instruction.opcode = Opcode::SIDT; instruction.operands[1] = Operand::Nothing; @@ -3015,7 +3018,10 @@ fn read_operands>( } } else if r == 2 { if mod_bits == 0b11 { - panic!("Unsupported instruction: 0x0f01 with modrm: 11 010 ___"); + // TOOD: XGETBV + instruction.opcode = Opcode::NOP; + instruction.operands[0] = Operand::Nothing; + Ok(()) } else { instruction.opcode = Opcode::LGDT; instruction.operands[1] = Operand::Nothing; @@ -3023,7 +3029,10 @@ fn read_operands>( } } else if r == 3 { if mod_bits == 0b11 { - panic!("Unsupported instruction: 0x0f01 with modrm: 11 011 ___"); + // TOOD: VMRUN + instruction.opcode = Opcode::NOP; + instruction.operands[0] = Operand::Nothing; + Ok(()) } else { instruction.opcode = Opcode::LIDT; instruction.operands[1] = Operand::Nothing; -- cgit v1.1