From 276c00612993d45580aa07454ee447cb8523236a Mon Sep 17 00:00:00 2001 From: Stanislav Shwartsman Date: Fri, 23 Dec 2005 14:15:13 +0000 Subject: [PATCH] Merge new disasm module with x96-64 support --- bochs/disasm/Makefile.in | 2 +- bochs/disasm/dis_decode.cc | 222 +- bochs/disasm/dis_groups.cc | 763 +++--- bochs/disasm/dis_tables.h | 2790 +------------------- bochs/disasm/dis_tables.inc | 4804 +++++++++++++++++++++++++++++++++++ bochs/disasm/disasm.h | 371 +-- bochs/disasm/opcodes.inc | 1189 +++++++++ bochs/disasm/resolve.cc | 319 ++- bochs/disasm/syntax.cc | 136 +- 9 files changed, 7185 insertions(+), 3411 deletions(-) create mode 100755 bochs/disasm/dis_tables.inc create mode 100755 bochs/disasm/opcodes.inc diff --git a/bochs/disasm/Makefile.in b/bochs/disasm/Makefile.in index 9c598c154..d289c71c7 100644 --- a/bochs/disasm/Makefile.in +++ b/bochs/disasm/Makefile.in @@ -81,7 +81,7 @@ dist-clean: clean # dependencies generated by # gcc -MM -I.. -I../instrument/stubs *.cc | sed 's/\.cc/.@CPP_SUFFIX@/g' ########################################### -dis_decode.o: dis_decode.@CPP_SUFFIX@ disasm.h ../config.h dis_tables.h +dis_decode.o: dis_decode.@CPP_SUFFIX@ disasm.h ../config.h dis_tables.h opcodes.inc dis_tables.inc dis_groups.o: dis_groups.@CPP_SUFFIX@ disasm.h ../config.h resolve.o: resolve.@CPP_SUFFIX@ disasm.h ../config.h syntax.o: syntax.@CPP_SUFFIX@ disasm.h ../config.h diff --git a/bochs/disasm/dis_decode.cc b/bochs/disasm/dis_decode.cc index 660e66c8f..c1f84e787 100644 --- a/bochs/disasm/dis_decode.cc +++ b/bochs/disasm/dis_decode.cc @@ -5,6 +5,9 @@ #include "disasm.h" #include "dis_tables.h" +#define OPCODE(entry) ((BxDisasmOpcodeInfo_t*) entry->OpcodeInfo) +#define OPCODE_TABLE(entry) ((BxDisasmOpcodeTable_t*) entry->OpcodeInfo) + static const unsigned char instruction_has_modrm[512] = { /* 0 1 2 3 4 5 6 7 8 9 a b c d e f */ /* ------------------------------- */ @@ -56,19 +59,21 @@ unsigned disassembler::disasm32(bx_address base, bx_address ip, Bit8u *instr, ch return disasm(1, 0, base, ip, instr, disbuf); } +unsigned disassembler::disasm64(bx_address base, bx_address ip, Bit8u *instr, char *disbuf) +{ + return disasm(1, 1, base, ip, instr, disbuf); +} + unsigned disassembler::disasm(bx_bool is_32, bx_bool is_64, bx_address base, bx_address ip, Bit8u *instr, char *disbuf) { - os_32 = is_32; - as_32 = is_32; + x86_insn insn(is_32, is_64); + Bit8u *instruction_begin = instruction = instr; + resolve_modrm = NULL; + unsigned n_prefixes = 0; + db_eip = ip; db_base = base; // cs linear base (base for PM & cs<<4 for RM & VM) - Bit8u *instruction_begin = instruction = instr; - displacement.displ32 = 0; - resolve_modrm = NULL; - seg_override = NULL; - - n_prefixes = 0; disbufptr = disbuf; // start sprintf()'ing into beginning of buffer #define SSE_PREFIX_NONE 0 @@ -78,71 +83,127 @@ unsigned disassembler::disasm(bx_bool is_32, bx_bool is_64, bx_address base, bx_ static int sse_prefix_index[8] = { 0, 1, 2, -1, 3, -1, -1, -1 }; unsigned sse_prefix = SSE_PREFIX_NONE; - int b1; - const BxDisasmOpcodeInfo_t *entry; - for(;;) { - b1 = fetch_byte(); - entry = &BxDisasmOpcodes[b1]; + insn.b1 = fetch_byte(); + n_prefixes++; - if (entry->Attr == _PREFIX) - { - switch(b1) { - case 0xf3: - sse_prefix |= SSE_PREFIX_F3; - break; + switch(insn.b1) { + case 0xf3: // rep + sse_prefix |= SSE_PREFIX_F3; + continue; - case 0xf2: - sse_prefix |= SSE_PREFIX_F2; - break; + case 0xf2: // repne + sse_prefix |= SSE_PREFIX_F2; + continue; - case 0x2e: - case 0x36: - case 0x3e: - case 0x26: - case 0x64: - case 0x65: - seg_override = entry->Opcode; - break; + case 0x40: // rex + case 0x41: + case 0x42: + case 0x43: + case 0x44: + case 0x45: + case 0x46: + case 0x47: + case 0x48: + case 0x49: + case 0x4A: + case 0x4B: + case 0x4C: + case 0x4D: + case 0x4E: + case 0x4F: + if (! is_64) break; + insn.extend8b = 1; + if (insn.b1 & 0x8) { + insn.os_64 = 1; + insn.os_32 = 1; + } + if (insn.b1 & 0x4) insn.rex_r = 8; + if (insn.b1 & 0x2) insn.rex_x = 8; + if (insn.b1 & 0x1) insn.rex_b = 8; + continue; - case 0x66: - os_32 = !is_32; - sse_prefix |= SSE_PREFIX_66; - break; + case 0x26: // ES: + if (! is_64) insn.seg_override = ES_REG; + continue; - case 0x67: - as_32 = !is_32; - break; + case 0x2e: // CS: + if (! is_64) insn.seg_override = CS_REG; + continue; - case 0xf0: // lock - break; + case 0x36: // SS: + if (! is_64) insn.seg_override = SS_REG; + continue; - default: - printf("Internal disassembler error !\n"); - return 0; - } + case 0x3e: // DS: + if (! is_64) insn.seg_override = DS_REG; + continue; - n_prefixes++; + case 0x64: // FS: + insn.seg_override = FS_REG; + continue; + + case 0x65: // GS: + insn.seg_override = GS_REG; + continue; + + case 0x66: // operand size override + if (!insn.os_64) insn.os_32 = !is_32; + sse_prefix |= SSE_PREFIX_66; + continue; + + case 0x67: // address size override + if (!is_64) insn.as_32 = !is_32; + insn.as_64 = 0; + continue; + + case 0xf0: // lock + continue; + + // no more prefixes + default: + break; } - else break; + + n_prefixes--; + break; } - if (b1 == 0x0f) + if (insn.b1 == 0x0f) { - b1 = 0x100 | fetch_byte(); - entry = &BxDisasmOpcodes[b1]; + insn.b1 = 0x100 | fetch_byte(); } - if (instruction_has_modrm[b1]) - decode_modrm(); + const BxDisasmOpcodeTable_t *opcode_table, *entry; + + if (is_64) { + if (insn.os_64) + opcode_table = BxDisasmOpcodes64q; + else if (insn.os_32) + opcode_table = BxDisasmOpcodes64d; + else + opcode_table = BxDisasmOpcodes64w; + } else { + if (insn.os_32) + opcode_table = BxDisasmOpcodes32; + else + opcode_table = BxDisasmOpcodes16; + } + + entry = opcode_table + insn.b1; + + if (instruction_has_modrm[insn.b1]) + { + decode_modrm(&insn); + } int attr = entry->Attr; while(attr) { switch(attr) { case _GROUPN: - entry = &(entry->AnotherArray[nnn]); + entry = &(OPCODE_TABLE(entry)[insn.nnn]); break; case _GRPSSE: @@ -152,20 +213,24 @@ unsigned disassembler::disasm(bx_bool is_32, bx_bool is_64, bx_address base, bx_ with the opcode prefixes (NONE, 0x66, 0xF2, 0xF3) */ int op = sse_prefix_index[sse_prefix]; if (op < 0) return 0; - entry = &(entry->AnotherArray[op]); + entry = &(OPCODE_TABLE(entry)[op]); } break; case _SPLIT11B: - entry = &(entry->AnotherArray[mod==3]); + entry = &(OPCODE_TABLE(entry)[insn.mod != 3]); /* REG/MEM */ + break; + + case _GRPRM: + entry = &(OPCODE_TABLE(entry)[insn.rm]); break; case _GRPFP: - if(mod != 3) + if(insn.mod != 3) { - entry = &(entry->AnotherArray[nnn]); + entry = &(OPCODE_TABLE(entry)[insn.nnn]); } else { - int index = (b1-0xD8)*64 + (0x3f & modrm); + int index = (insn.b1-0xD8)*64 + (insn.modrm & 0x3f); entry = &(BxDisasmOpcodeInfoFP[index]); } break; @@ -175,7 +240,7 @@ unsigned disassembler::disasm(bx_bool is_32, bx_bool is_64, bx_address base, bx_ break; default: - printf("Internal disassembler error !\n"); + printf("Internal disassembler error - unknown attribute !\n"); return 0; } @@ -183,26 +248,51 @@ unsigned disassembler::disasm(bx_bool is_32, bx_bool is_64, bx_address base, bx_ attr = entry->Attr; } +#define BRANCH_NOT_TAKEN 0x2E +#define BRANCH_TAKEN 0x3E + + unsigned branch_hint = 0; + // print prefixes for(unsigned i=0;iOp3Attr == BRANCH_HINT) + if (prefix_byte == 0xF3 || prefix_byte == 0xF2 || prefix_byte == 0xF0) { - if (*(instr+i) == 0x2E) - dis_sprintf("not taken "); - if (*(instr+i) == 0x3E) - dis_sprintf("taken "); + const BxDisasmOpcodeTable_t *prefix = &(opcode_table[prefix_byte]); + dis_sprintf("%s ", OPCODE(prefix)->IntelOpcode); + } + + // branch hint for jcc instructions + if ((insn.b1 >= 0x070 && insn.b1 <= 0x07F) || + (insn.b1 >= 0x180 && insn.b1 <= 0x18F)) + { + if (prefix_byte == BRANCH_NOT_TAKEN || prefix_byte == BRANCH_TAKEN) + branch_hint = prefix_byte; } } + const BxDisasmOpcodeInfo_t *opcode = OPCODE(entry); + + // patch jecx opcode + if (insn.b1 == 0xE3 && insn.as_32 && !insn.as_64) + opcode = &Ia_jecxz_Jb; + // print instruction disassembly if (intel_mode) - print_disassembly_intel(entry); + print_disassembly_intel(&insn, opcode); else - print_disassembly_att (entry); + print_disassembly_att (&insn, opcode); + + if (branch_hint == BRANCH_NOT_TAKEN) + { + dis_sprintf(", not taken"); + } + else if (branch_hint == BRANCH_TAKEN) + { + dis_sprintf(", taken"); + } return(instruction - instruction_begin); } diff --git a/bochs/disasm/dis_groups.cc b/bochs/disasm/dis_groups.cc index 6dac475fb..bfdc78c47 100644 --- a/bochs/disasm/dis_groups.cc +++ b/bochs/disasm/dis_groups.cc @@ -1,139 +1,379 @@ #include #include "disasm.h" +/* #if BX_DEBUGGER #include "../bx_debug/debug.h" #endif +*/ -// 16/32-bit general purpose register -void disassembler::REG32 (unsigned attr) +void disassembler::Apw(const x86_insn *insn) { - if (os_32) - dis_sprintf("%s", general_32bit_regname[attr]); - else - dis_sprintf("%s", general_16bit_regname[attr]); + Bit16u imm16 = fetch_word(); + Bit16u cs_selector = fetch_word(); + dis_sprintf("%04x:%04x", (unsigned) cs_selector, (unsigned) imm16); } -// 8-bit general purpose register -void disassembler::REG8 (unsigned attr) +void disassembler::Apd(const x86_insn *insn) { - dis_sprintf("%s", general_8bit_regname[attr]); + Bit32u imm32 = fetch_dword(); + Bit16u cs_selector = fetch_word(); + dis_sprintf("%04x:%08x", (unsigned) cs_selector, (unsigned) imm32); +} + +// 8-bit general purpose registers +void disassembler::AL(const x86_insn *insn) { dis_sprintf("%s", general_8bit_regname[rAX_REG]); } +void disassembler::CL(const x86_insn *insn) { dis_sprintf("%s", general_8bit_regname[rCX_REG]); } + +// 16-bit general purpose registers +void disassembler::AX(const x86_insn *insn) { + dis_sprintf("%s", general_16bit_regname[rAX_REG]); +} + +void disassembler::DX(const x86_insn *insn) { + dis_sprintf("%s", general_16bit_regname[rDX_REG]); +} + +// 32-bit general purpose registers +void disassembler::EAX(const x86_insn *insn) +{ + dis_sprintf("%s", general_32bit_regname[rAX_REG]); +} + +// 64-bit general purpose registers +void disassembler::RAX(const x86_insn *insn) +{ + dis_sprintf("%s", general_64bit_regname[rAX_REG]); +} + +// segment registers +void disassembler::CS(const x86_insn *insn) { dis_sprintf("%s", segment_name[CS_REG]); } +void disassembler::DS(const x86_insn *insn) { dis_sprintf("%s", segment_name[DS_REG]); } +void disassembler::ES(const x86_insn *insn) { dis_sprintf("%s", segment_name[ES_REG]); } +void disassembler::SS(const x86_insn *insn) { dis_sprintf("%s", segment_name[SS_REG]); } +void disassembler::FS(const x86_insn *insn) { dis_sprintf("%s", segment_name[FS_REG]); } +void disassembler::GS(const x86_insn *insn) { dis_sprintf("%s", segment_name[GS_REG]); } + +void disassembler::Sw(const x86_insn *insn) { dis_sprintf("%s", segment_name[insn->nnn]); } + +// test registers +void disassembler::Td(const x86_insn *insn) +{ + if (intel_mode) + dis_sprintf ("tr%d", insn->nnn); + else + dis_sprintf("%%tr%d", insn->nnn); +} + +// control register +void disassembler::Cd(const x86_insn *insn) +{ + if (intel_mode) + dis_sprintf ("cr%d", insn->nnn); + else + dis_sprintf("%%cr%d", insn->nnn); +} + +void disassembler::Cq(const x86_insn *insn) { Cd(insn); } + +// debug register +void disassembler::Dd(const x86_insn *insn) +{ + if (intel_mode) + dis_sprintf ("db%d", insn->nnn); + else + dis_sprintf("%%db%d", insn->nnn); +} + +void disassembler::Dq(const x86_insn *insn) { Dd(insn); } + +// 8-bit general purpose register +void disassembler::R8(const x86_insn *insn) +{ + unsigned reg = (insn->b1 & 7) | insn->rex_b; + + if (reg < 4 || insn->extend8b) + dis_sprintf("%s", general_8bit_regname_rex[reg]); + else + dis_sprintf("%s", general_8bit_regname[reg]); } // 16-bit general purpose register -void disassembler::REG16 (unsigned attr) -{ - dis_sprintf("%s", general_16bit_regname[attr]); +void disassembler::RX(const x86_insn *insn) +{ + dis_sprintf("%s", general_16bit_regname[(insn->b1 & 7) | insn->rex_b]); } -// segment register -void disassembler::OP_SEG (unsigned attr) -{ - dis_sprintf("%s", segment_name[attr]); +// 32-bit general purpose register +void disassembler::ERX(const x86_insn *insn) +{ + dis_sprintf("%s", general_32bit_regname[(insn->b1 & 7) | insn->rex_b]); } -// memory operand -void disassembler::OP_MEM (unsigned attr) -{ - if(mod == 3) - dis_sprintf("(bad)"); - else - (this->*resolve_modrm)(attr); +// 64-bit general purpose register +void disassembler::RRX(const x86_insn *insn) +{ + dis_sprintf("%s", general_64bit_regname[(insn->b1 & 7) | insn->rex_b]); } -void disassembler::OP_Q (unsigned attr) +// general purpose register or memory operand +void disassembler::Eb(const x86_insn *insn) { - if (mod == 3) - { - if (intel_mode) - dis_sprintf ("mm%d", rm); + if (insn->mod == 3) { + if (insn->rm < 4 || insn->extend8b) + dis_sprintf("%s", general_8bit_regname_rex[insn->rm]); else - dis_sprintf("%%mm%d", rm); + dis_sprintf("%s", general_8bit_regname[insn->rm]); } else - (this->*resolve_modrm)(attr); + (this->*resolve_modrm)(insn, B_SIZE); } -void disassembler::OP_W (unsigned attr) +void disassembler::Ew(const x86_insn *insn) { - if (mod == 3) + if (insn->mod == 3) + dis_sprintf("%s", general_16bit_regname[insn->rm]); + else + (this->*resolve_modrm)(insn, W_SIZE); +} + +void disassembler::Ed(const x86_insn *insn) +{ + if (insn->mod == 3) + dis_sprintf("%s", general_32bit_regname[insn->rm]); + else + (this->*resolve_modrm)(insn, D_SIZE); +} + +void disassembler::Eq(const x86_insn *insn) +{ + if (insn->mod == 3) + dis_sprintf("%s", general_64bit_regname[insn->rm]); + else + (this->*resolve_modrm)(insn, Q_SIZE); +} + +// general purpose register +void disassembler::Gb(const x86_insn *insn) +{ + if (insn->nnn < 4 || insn->extend8b) + dis_sprintf("%s", general_8bit_regname_rex[insn->nnn]); + else + dis_sprintf("%s", general_8bit_regname[insn->nnn]); +} + +void disassembler::Gw(const x86_insn *insn) +{ + dis_sprintf("%s", general_16bit_regname[insn->nnn]); +} + +void disassembler::Gd(const x86_insn *insn) +{ + dis_sprintf("%s", general_32bit_regname[insn->nnn]); +} + +void disassembler::Gq(const x86_insn *insn) +{ + dis_sprintf("%s", general_64bit_regname[insn->nnn]); +} + +// immediate +void disassembler::I1(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + dis_putc ('1'); +} + +void disassembler::Ib(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + dis_sprintf("0x%02x", (unsigned) fetch_byte()); +} + +void disassembler::Iw(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + dis_sprintf("0x%04x", (unsigned) fetch_word()); +} + +void disassembler::Id(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + dis_sprintf("0x%08x", (unsigned) fetch_dword()); +} + +void disassembler::Iq(const x86_insn *insn) +{ + Bit64u value = fetch_qword(); + + if (! intel_mode) dis_putc('$'); + dis_sprintf("0x%08x%08x", + (unsigned)(value>>32), (unsigned)(value & 0xffffffff)); +} + +// sign extended immediate +void disassembler::sIbw(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + Bit16u imm16 = (Bit8s) fetch_byte(); + dis_sprintf("0x%04x", (unsigned) imm16); +} + +// sign extended immediate +void disassembler::sIbd(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + Bit32u imm32 = (Bit8s) fetch_byte(); + dis_sprintf ("0x%08x", (unsigned) imm32); +} + +// sign extended immediate +void disassembler::sIbq(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + Bit64u imm64 = (Bit8s) fetch_byte(); + dis_sprintf ("0x%08x%08x", + (unsigned)(imm64>>32), (unsigned)(imm64 & 0xffffffff)); +} + +// sign extended immediate +void disassembler::sIdq(const x86_insn *insn) +{ + if (! intel_mode) dis_putc('$'); + Bit64u imm64 = (Bit32s) fetch_dword(); + dis_sprintf ("0x%08x%08x", + (unsigned)(imm64>>32), (unsigned)(imm64 & 0xffffffff)); +} + +// floating point +void disassembler::ST0(const x86_insn *insn) +{ + if (intel_mode) + dis_sprintf ("st(0)"); + else + dis_sprintf("%%st(0)"); +} + +void disassembler::STi(const x86_insn *insn) +{ + if (intel_mode) + dis_sprintf ("st(%d)", insn->rm); + else + dis_sprintf("%%st(%d)", insn->rm); +} + +// 16-bit general purpose register +void disassembler::Rw(const x86_insn *insn) +{ + dis_sprintf("%s", general_16bit_regname[insn->rm]); +} + +// 32-bit general purpose register +void disassembler::Rd(const x86_insn *insn) +{ + dis_sprintf("%s", general_32bit_regname[insn->rm]); +} + +// 64-bit general purpose register +void disassembler::Rq(const x86_insn *insn) +{ + dis_sprintf("%s", general_64bit_regname[insn->rm]); +} + +// mmx register +void disassembler::Pq(const x86_insn *insn) +{ + if (intel_mode) + dis_sprintf ("mm%d", insn->nnn); + else + dis_sprintf("%%mm%d", insn->nnn); +} + +void disassembler::Qd(const x86_insn *insn) +{ + if (insn->mod == 3) { if (intel_mode) - dis_sprintf ("xmm%d", rm); + dis_sprintf ("mm%d", insn->rm); else - dis_sprintf("%%xmm%d", rm); + dis_sprintf("%%mm%d", insn->rm); } else - (this->*resolve_modrm)(attr); + (this->*resolve_modrm)(insn, D_SIZE); } -void disassembler::OP_V (unsigned attr) +void disassembler::Qq(const x86_insn *insn) +{ + if (insn->mod == 3) + { + if (intel_mode) + dis_sprintf ("mm%d", insn->rm); + else + dis_sprintf("%%mm%d", insn->rm); + } + else + (this->*resolve_modrm)(insn, Q_SIZE); +} + +// xmm register +void disassembler::Vq(const x86_insn *insn) { if (intel_mode) - dis_sprintf ("xmm%d", nnn); + dis_sprintf ("xmm%d", insn->nnn); else - dis_sprintf("%%xmm%d", nnn); + dis_sprintf("%%xmm%d", insn->nnn); } -void disassembler::OP_P (unsigned attr) +void disassembler::Vdq(const x86_insn *insn) { Vq(insn); } +void disassembler::Vss(const x86_insn *insn) { Vq(insn); } +void disassembler::Vsd(const x86_insn *insn) { Vq(insn); } +void disassembler::Vps(const x86_insn *insn) { Vq(insn); } +void disassembler::Vpd(const x86_insn *insn) { Vq(insn); } + +void disassembler::Wq(const x86_insn *insn) { - if (intel_mode) - dis_sprintf ("mm%d", nnn); + if (insn->mod == 3) + { + if (intel_mode) + dis_sprintf ("xmm%d", insn->rm); + else + dis_sprintf("%%xmm%d", insn->rm); + } else - dis_sprintf("%%mm%d", nnn); + (this->*resolve_modrm)(insn, Q_SIZE); } -void disassembler::OP_X (unsigned attr) +void disassembler::Wdq(const x86_insn *insn) { - const char *esi, *seg; - - if (as_32) - esi = general_32bit_regname[eSI_REG]; + if (insn->mod == 3) + { + if (intel_mode) + dis_sprintf ("xmm%d", insn->rm); + else + dis_sprintf("%%xmm%d", insn->rm); + } else - esi = general_16bit_regname[eSI_REG]; - - if (seg_override) - seg = seg_override; - else - seg = segment_name[DS_REG]; - - print_datasize(attr); - - if (intel_mode) - dis_sprintf("%s:[%s]", seg, esi); - else - dis_sprintf("%s:(%s)", seg, esi); + (this->*resolve_modrm)(insn, O_SIZE); } -void disassembler::OP_Y (unsigned attr) -{ - const char *edi; +void disassembler::Wss(const x86_insn *insn) { Wdq(insn); } +void disassembler::Wsd(const x86_insn *insn) { Wdq(insn); } +void disassembler::Wps(const x86_insn *insn) { Wdq(insn); } +void disassembler::Wpd(const x86_insn *insn) { Wdq(insn); } - if (as_32) - edi = general_32bit_regname[eDI_REG]; - else - edi = general_16bit_regname[eDI_REG]; - - print_datasize(attr); - - if (intel_mode) - dis_sprintf("%s:[%s]", segment_name[ES_REG], edi); - else - dis_sprintf("%s:(%s)", segment_name[ES_REG], edi); -} - -void disassembler::OP_O (unsigned attr) +// direct memory access +void disassembler::OP_O(const x86_insn *insn, unsigned size) { const char *seg; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else seg = segment_name[DS_REG]; - print_datasize(attr); + print_datasize(size); - if (as_32) { + if (insn->as_32) { Bit32u imm32 = fetch_dword(); dis_sprintf("%s:0x%x", seg, (unsigned) imm32); } @@ -143,248 +383,147 @@ void disassembler::OP_O (unsigned attr) } } -void disassembler::Jb (unsigned attr) +void disassembler::Ob(const x86_insn *insn) { OP_O(insn, B_SIZE); } +void disassembler::Ow(const x86_insn *insn) { OP_O(insn, W_SIZE); } +void disassembler::Od(const x86_insn *insn) { OP_O(insn, D_SIZE); } +void disassembler::Oq(const x86_insn *insn) { OP_O(insn, Q_SIZE); } + +// memory operand +void disassembler::OP_M(const x86_insn *insn, unsigned size) { - Bit8s imm8; /* JMP rel8 is signed */ - imm8 = (Bit8s) fetch_byte(); - if (os_32) { -#if BX_DEBUGGER - char *Sym=bx_dbg_disasm_symbolic_address((Bit32u)(imm8+db_eip), db_base); - if(Sym) { - dis_sprintf("%s", Sym); - } - else // Symbol not found -#endif - dis_sprintf(".+0x%x", (unsigned) (imm8+db_eip)); + if(insn->mod == 3) + dis_sprintf("(bad)"); + else + (this->*resolve_modrm)(insn, size); +} + +void disassembler::Ma(const x86_insn *insn) { OP_M(insn, X_SIZE); } +void disassembler::Mp(const x86_insn *insn) { OP_M(insn, X_SIZE); } +void disassembler::Ms(const x86_insn *insn) { OP_M(insn, X_SIZE); } +void disassembler::Mx(const x86_insn *insn) { OP_M(insn, X_SIZE); } + +void disassembler::Mb(const x86_insn *insn) { OP_M(insn, B_SIZE); } +void disassembler::Mw(const x86_insn *insn) { OP_M(insn, W_SIZE); } +void disassembler::Md(const x86_insn *insn) { OP_M(insn, D_SIZE); } +void disassembler::Mq(const x86_insn *insn) { OP_M(insn, Q_SIZE); } +void disassembler::Mt(const x86_insn *insn) { OP_M(insn, T_SIZE); } + +void disassembler::Mdq(const x86_insn *insn) { OP_M(insn, O_SIZE); } +void disassembler::Mps(const x86_insn *insn) { OP_M(insn, O_SIZE); } +void disassembler::Mpd(const x86_insn *insn) { OP_M(insn, O_SIZE); } + +// string instructions +void disassembler::OP_X(const x86_insn *insn, unsigned size) +{ + const char *rsi, *seg; + + if (insn->as_64) { + rsi = general_64bit_regname[rSI_REG]; } - else - { -#if BX_DEBUGGER - char *Sym=bx_dbg_disasm_symbolic_address((Bit32u)((imm8+db_eip) & 0xFFFF), db_base); - if(Sym) { - dis_sprintf("%s", Sym); - } - else // Symbol not found - #endif - dis_sprintf(".+0x%x", (unsigned) ((imm8+db_eip) & 0xFFFF)); - } -} - -void disassembler::Jv (unsigned attr) -{ - if (os_32) { - Bit32s imm32; /* JMP rel32 is signed */ - imm32 = (Bit32s) fetch_dword(); -#if BX_DEBUGGER - char *Sym=bx_dbg_disasm_symbolic_address((Bit32u)(imm32+db_eip), db_base); - if(Sym) { - dis_sprintf("%s", Sym); - } - else // Symbol not found -#endif - dis_sprintf(".+0x%x", (unsigned) (imm32+db_eip)); - } - else - { - Bit16s imm16; /* JMP rel16 is signed */ - imm16 = (Bit16s) fetch_word(); -#if BX_DEBUGGER - char *Sym=bx_dbg_disasm_symbolic_address((Bit32u)((imm16+db_eip) & 0xFFFF), db_base); - if(Sym) { - dis_sprintf("%s", Sym); - } - else // Symbol not found -#endif - dis_sprintf(".+0x%x", (unsigned) ((imm16+db_eip) & 0xFFFF)); - } -} - -void disassembler::Ap (unsigned attr) -{ - if (os_32) - { - Bit32u imm32 = fetch_dword(); - Bit16u cs_selector = fetch_word(); - dis_sprintf("%04x:%08x", (unsigned) cs_selector, (unsigned) imm32); - } - else - { - Bit16u imm16 = fetch_word(); - Bit16u cs_selector = fetch_word(); - dis_sprintf("%04x:%04x", (unsigned) cs_selector, (unsigned) imm16); - } -} - -// general purpose register or memory operand -void disassembler::Eb (unsigned attr) -{ - if (mod == 3) - dis_sprintf("%s", general_8bit_regname[rm]); - else - (this->*resolve_modrm)(B_SIZE); -} - -void disassembler::Ew (unsigned attr) -{ - if (mod == 3) - dis_sprintf("%s", general_16bit_regname[rm]); - else - (this->*resolve_modrm)(W_SIZE); -} - -void disassembler::Ev (unsigned attr) -{ - if (os_32) - Ed(attr); - else - Ew(attr); -} - -void disassembler::Ed (unsigned attr) -{ - if (mod == 3) - dis_sprintf("%s", general_32bit_regname[rm]); - else - (this->*resolve_modrm)(D_SIZE); -} - -// general purpose register -void disassembler::Gb (unsigned attr) -{ - dis_sprintf("%s", general_8bit_regname[nnn]); -} - -void disassembler::Gv (unsigned attr) -{ - if (os_32) - dis_sprintf("%s", general_32bit_regname[nnn]); - else - dis_sprintf("%s", general_16bit_regname[nnn]); -} - -void disassembler::Gd (unsigned attr) -{ - dis_sprintf("%s", general_32bit_regname[nnn]); -} - -// 32-bit general purpose register -void disassembler::Rd (unsigned attr) -{ - dis_sprintf("%s", general_32bit_regname[rm]); -} - -// 16-bit general purpose register -void disassembler::Rw (unsigned attr) -{ - dis_sprintf("%s", general_16bit_regname[rm]); -} - -// segment register -void disassembler::Sw (unsigned attr) -{ - dis_sprintf("%s", segment_name[nnn]); -} - -// immediate -void disassembler::I1 (unsigned) -{ - if (! intel_mode) dis_putc('$'); - dis_putc ('1'); -} - -void disassembler::Ib (unsigned attr) -{ - if (intel_mode) - dis_sprintf ("0x%x", (unsigned) fetch_byte()); - else - dis_sprintf("$0x%x", (unsigned) fetch_byte()); -} - -void disassembler::Iw (unsigned attr) -{ - if (intel_mode) - dis_sprintf ("0x%x", (unsigned) fetch_word()); - else - dis_sprintf("$0x%x", (unsigned) fetch_word()); -} - -void disassembler::Id (unsigned attr) -{ - if (intel_mode) - dis_sprintf ("0x%x", (unsigned) fetch_dword()); - else - dis_sprintf("$0x%x", (unsigned) fetch_dword()); -} - -void disassembler::Iv (unsigned attr) -{ - if (os_32) - Id(attr); - else - Iw(attr); -} - -// sign extended immediate -void disassembler::sIb(unsigned attr) -{ - if (os_32) - { - Bit32u imm32 = (Bit8s) fetch_byte(); - if (intel_mode) - dis_sprintf ("0x%x", (unsigned) imm32); + else { + if (insn->as_32) + rsi = general_32bit_regname[rSI_REG]; else - dis_sprintf("$0x%x", (unsigned) imm32); + rsi = general_16bit_regname[rSI_REG]; } + + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else - { - Bit16u imm16 = (Bit8s) fetch_byte(); - if (intel_mode) - dis_sprintf ("0x%x", (unsigned) imm16); + seg = segment_name[DS_REG]; + + print_datasize(size); + + if (intel_mode) + dis_sprintf("%s:[%s]", seg, rsi); + else + dis_sprintf("%s:(%s)", seg, rsi); +} + +void disassembler::Xb(const x86_insn *insn) { OP_X(insn, B_SIZE); } +void disassembler::Xw(const x86_insn *insn) { OP_X(insn, W_SIZE); } +void disassembler::Xd(const x86_insn *insn) { OP_X(insn, D_SIZE); } +void disassembler::Xq(const x86_insn *insn) { OP_X(insn, Q_SIZE); } + +void disassembler::OP_Y(const x86_insn *insn, unsigned size) +{ + const char *rdi; + + if (insn->as_64) { + rdi = general_64bit_regname[rDI_REG]; + } + else { + if (insn->as_32) + rdi = general_32bit_regname[rDI_REG]; else - dis_sprintf("$0x%x", (unsigned) imm16); + rdi = general_16bit_regname[rDI_REG]; + } + + print_datasize(size); + + if (intel_mode) + dis_sprintf("%s:[%s]", segment_name[ES_REG], rdi); + else + dis_sprintf("%s:(%s)", segment_name[ES_REG], rdi); +} + +void disassembler::Yb(const x86_insn *insn) { OP_Y(insn, B_SIZE); } +void disassembler::Yw(const x86_insn *insn) { OP_Y(insn, W_SIZE); } +void disassembler::Yd(const x86_insn *insn) { OP_Y(insn, D_SIZE); } +void disassembler::Yq(const x86_insn *insn) { OP_Y(insn, Q_SIZE); } + +// jump offset +void disassembler::Jb(const x86_insn *insn) +{ + Bit8s imm8 = (Bit8s) fetch_byte(); + + if (insn->is_64) { + Bit64u imm64 = (Bit64s) imm8; + dis_sprintf(".+0x%08x%08x", + (unsigned)(imm64>>32), (unsigned)(imm64 & 0xffffffff)); + return; + } + + if (insn->os_32) { + Bit32u imm32 = (Bit32s) imm8; + dis_sprintf(".+0x%08x", (unsigned) imm32); + } + else { + Bit16u imm16 = (Bit16s) imm8; + dis_sprintf(".+0x%04x", (unsigned) imm16); } } -// floating point -void disassembler::ST0 (unsigned attr) -{ - if (intel_mode) - dis_sprintf ("st(0)"); - else - dis_sprintf("%%st(0)"); -} - -void disassembler::STj (unsigned attr) -{ - if (intel_mode) - dis_sprintf ("st(%d)", rm); - else - dis_sprintf("%%st(%d)", rm); -} - -// control register -void disassembler::Cd (unsigned attr) -{ - if (intel_mode) - dis_sprintf ("cr%d", nnn); - else - dis_sprintf("%%cr%d", nnn); -} - -// debug register -void disassembler::Dd (unsigned attr) +void disassembler::Jw(const x86_insn *insn) { - if (intel_mode) - dis_sprintf ("db%d", nnn); - else - dis_sprintf("%%db%d", nnn); + Bit16s imm16 = (Bit16s) fetch_word(); + + if (insn->is_64) { + Bit64u imm64 = (Bit64s) imm16; + dis_sprintf(".+0x%08x%08x", + (unsigned)(imm64>>32), (unsigned)(imm64 & 0xffffffff)); + return; + } + + if (insn->os_32) { + Bit32u imm32 = (Bit32s) imm16; + dis_sprintf(".+0x%08x", (unsigned) imm32); + } + else { + dis_sprintf(".+0x%04x", (unsigned) imm16); + } } -// test registers -void disassembler::Td (unsigned attr) +void disassembler::Jd(const x86_insn *insn) { - if (intel_mode) - dis_sprintf ("tr%d", nnn); - else - dis_sprintf("%%tr%d", nnn); + Bit32s imm32 = (Bit32s) fetch_dword(); + + if (insn->is_64) { + Bit64u imm64 = (Bit64s) imm32; + dis_sprintf(".+0x%08x%08x", + (unsigned)(imm64>>32), (unsigned)(imm64 & 0xffffffff)); + return; + } + + dis_sprintf(".+0x%08x", (unsigned) imm32); } diff --git a/bochs/disasm/dis_tables.h b/bochs/disasm/dis_tables.h index 0d080cf61..2ed9ad86b 100755 --- a/bochs/disasm/dis_tables.h +++ b/bochs/disasm/dis_tables.h @@ -2,2672 +2,138 @@ #define _BX_DISASM_TABLES_ // opcode table attributes -#define _PREFIX 1 -#define _GROUPN 2 -#define _SPLIT11B 3 -#define _GRPFP 4 -#define _GRP3DNOW 5 -#define _GRPSSE 6 +#define _GROUPN 1 +#define _SPLIT11B 2 +#define _GRPFP 3 +#define _GRP3DNOW 4 +#define _GRPSSE 5 +#define _GRPRM 6 /* ************************************************************************ */ -#define GRPSSE(n) "(error)", _GRPSSE, NULL, 0, NULL, 0, NULL, 0, BxDisasmGroupSSE_##n -#define GRPN(n) "(error)", _GROUPN, NULL, 0, NULL, 0, NULL, 0, BxDisasmGroup##n -#define GRPFP(n) "(error)", _GRPFP, NULL, 0, NULL, 0, NULL, 0, BxDisasmFPGroup##n - -#define GRP3DNOW "(error)", _GRP3DNOW, NULL, 0, NULL, 0, NULL, 0, BxDisasm3DNowGroup -#define INVALID "(invalid)", 0, NULL, 0, NULL, 0, NULL, 0, NULL - -#define PREFIX_CS "cs", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_DS "ds", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_ES "es", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_SS "ss", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_FS "fs", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_GS "gs", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_OPSIZE "opsize", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_ADDRSIZE "addrsize", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_LOCK "lock", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_REP "rep", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#define PREFIX_REPNE "repne", _PREFIX, NULL, 0, NULL, 0, NULL, 0 - -#if BX_SUPPORT_X86_64 -#define PREFIX_REX "rex", _PREFIX, NULL, 0, NULL, 0, NULL, 0 -#endif +#define GRPSSE(n) _GRPSSE, BxDisasmGroupSSE_##n +#define GRPN(n) _GROUPN, BxDisasmGroup##n +#define GRPRM(n) _GRPRM, BxDisasmGroupRm##n +#define GRPMOD(n) _SPLIT11B, BxDisasmGroupMod##n +#define GRPFP(n) _GRPFP, BxDisasmFPGroup##n +#define GRP3DNOW _GRP3DNOW, BxDisasm3DNowGroup /* ************************************************************************ */ - // fpu -#define ST0 &disassembler::ST0, 0 -#define STj &disassembler::STj, 0 - - // control/debug register -#define Cd &disassembler::Cd, 0 -#define Dd &disassembler::Dd, 0 -#define Td &disassembler::Td, 0 - -#define Sw &disassembler::Sw, 0 -#define Rw &disassembler::Rw, 0 -#define Rd &disassembler::Rd, 0 - - // segment register -#define CS &disassembler::OP_SEG, CS_REG -#define DS &disassembler::OP_SEG, DS_REG -#define ES &disassembler::OP_SEG, ES_REG -#define SS &disassembler::OP_SEG, SS_REG -#define GS &disassembler::OP_SEG, GS_REG -#define FS &disassembler::OP_SEG, FS_REG - - // 16/32-bit general purpose register -#define eAX &disassembler::REG32, eAX_REG -#define eCX &disassembler::REG32, eCX_REG -#define eDX &disassembler::REG32, eDX_REG -#define eBX &disassembler::REG32, eBX_REG -#define eSI &disassembler::REG32, eSI_REG -#define eDI &disassembler::REG32, eDI_REG -#define eBP &disassembler::REG32, eBP_REG -#define eSP &disassembler::REG32, eSP_REG - - // 16-bit general purpose register -#define AX &disassembler::REG16, AX_REG -#define DX &disassembler::REG16, DX_REG - - // 8-bit general purpose register -#define AL &disassembler::REG8, AL_REG -#define AH &disassembler::REG8, AH_REG -#define BL &disassembler::REG8, BL_REG -#define BH &disassembler::REG8, BH_REG -#define CL &disassembler::REG8, CL_REG -#define CH &disassembler::REG8, CH_REG -#define DL &disassembler::REG8, DL_REG -#define DH &disassembler::REG8, DH_REG - - // mmx -#define Pd &disassembler::OP_P, D_SIZE -#define Pq &disassembler::OP_P, Q_SIZE -#define Qd &disassembler::OP_Q, D_SIZE -#define Qq &disassembler::OP_Q, Q_SIZE - - // xmm -#define Vd &disassembler::OP_V, D_SIZE -#define Vq &disassembler::OP_V, Q_SIZE -#define Vdq &disassembler::OP_V, O_SIZE -#define Vss &disassembler::OP_V, D_SIZE -#define Vsd &disassembler::OP_V, Q_SIZE -#define Vps &disassembler::OP_V, O_SIZE -#define Vpd &disassembler::OP_V, O_SIZE - -#define Wq &disassembler::OP_W, Q_SIZE -#define Wdq &disassembler::OP_W, O_SIZE -#define Wss &disassembler::OP_W, D_SIZE -#define Wsd &disassembler::OP_W, Q_SIZE -#define Wps &disassembler::OP_W, O_SIZE -#define Wpd &disassembler::OP_W, O_SIZE - - // string instructions -#define Xb &disassembler::OP_X, B_SIZE -#define Yb &disassembler::OP_Y, B_SIZE -#define Xv &disassembler::OP_X, V_SIZE -#define Yv &disassembler::OP_Y, V_SIZE - - // mov -#define OX &disassembler::OP_O, 0 - - // immediate -#define I1 &disassembler::I1, 0 -#define Ib &disassembler::Ib, B_SIZE -#define Iw &disassembler::Iw, W_SIZE -#define Id &disassembler::Id, D_SIZE -#define Iv &disassembler::Iv, V_SIZE - - // sign-extended immediate -#define sIb &disassembler::sIb, 0 - - // memory only -#define Mb &disassembler::OP_MEM, B_SIZE -#define Mw &disassembler::OP_MEM, W_SIZE -#define Mv &disassembler::OP_MEM, V_SIZE -#define Md &disassembler::OP_MEM, D_SIZE -#define Mp &disassembler::OP_MEM, P_SIZE -#define Mq &disassembler::OP_MEM, Q_SIZE -#define Mt &disassembler::OP_MEM, T_SIZE -#define Ms &disassembler::OP_MEM, S_SIZE -#define Mx &disassembler::OP_MEM, X_SIZE -#define Mdq &disassembler::OP_MEM, O_SIZE -#define Mps &disassembler::OP_MEM, O_SIZE -#define Mpd &disassembler::OP_MEM, O_SIZE - - // general purpose register -#define Gb &disassembler::Gb, B_SIZE -#define Gv &disassembler::Gv, V_SIZE -#define Gd &disassembler::Gd, D_SIZE - - // general purpose register or memory operand -#define Eb &disassembler::Eb, B_SIZE -#define Ew &disassembler::Ew, W_SIZE -#define Ed &disassembler::Ed, D_SIZE -#define Ev &disassembler::Ev, V_SIZE - - // jump/call -#define Jb &disassembler::Jb, 0 -#define Jv &disassembler::Jv, 0 - - // branch hint -#define Cond_Jump NULL, BRANCH_HINT - - // jump/call far -#define Ap &disassembler::Ap, 0 - - // no operand -#define XX NULL, 0 - -// -// Capital letters in opcode name suffix are macroses: -// -// B - print 'b' suffix for this instruction (in AT&T syntax mode) -// W - print 'w' suffix for this instruction (in AT&T syntax mode) -// L - print 'l' suffix for this instruction (in AT&T syntax mode) -// V - print 'w' or 'l' suffix for this instruction depending on -// operands size (in AT&T syntax mode) -// Q - print 'q' suffix for this instruction (in AT&T syntax mode) -// S - print 'w' or 'd' suffix for this instruction depending on -// its operands size (for string instructions) -// T - print 't' suffix for this instruction (in AT&T syntax mode) -// X - print 'bl', 'bw', "wl", "bq", "wq" or 'lq' suffix for this -// instruction depending on its operands sizes in AT&T syntax -// mode and 'x' suffix in Intel syntax mode (for movsx and -// movzx instructions) -// D - print 'd' for 32-bit operand size in Intel syntax mode or -// 'l' AT&T syntax mode and 'q' for 64-bit operand size. -// - -/* ************************************************************************ */ -/* SSE opcodes */ - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f10[4] = { - /* -- */ { "movups", 0, Vps, Wps, XX }, - /* 66 */ { "movupd", 0, Vpd, Wpd, XX }, - /* F2 */ { "movsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "movss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f11[4] = { - /* -- */ { "movups", 0, Wps, Vps, XX }, - /* 66 */ { "movupd", 0, Wpd, Vpd, XX }, - /* F2 */ { "movsd", 0, Wsd, Vsd, XX }, - /* F3 */ { "movss", 0, Wss, Vss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f12[4] = { - /* -- */ { "movlps", 0, Vps, Mq, XX }, - /* 66 */ { "movlpd", 0, Vpd, Mq, XX }, - /* F2 */ { "movddup", 0, Vdq, Wq, XX }, - /* F3 */ { "movsldup", 0, Vdq, Wdq, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f13[4] = { - /* -- */ { "movlps", 0, Mq, Vps, XX }, - /* 66 */ { "movlpd", 0, Mq, Vpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f14[4] = { - /* -- */ { "unpcklps", 0, Vps, Wq, XX }, - /* 66 */ { "unpcklpd", 0, Vpd, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f15[4] = { - /* -- */ { "unpckhps", 0, Vps, Wq, XX }, - /* 66 */ { "unpckhpd", 0, Vpd, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f16[4] = { - /* -- */ { "movhps", 0, Vps, Mq, XX }, - /* 66 */ { "movhpd", 0, Vpd, Mq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { "movshdup", 0, Vdq, Wdq, XX }, -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f17[4] = { - /* -- */ { "movhps", 0, Mq, Vps, XX }, - /* 66 */ { "movhpd", 0, Mq, Vpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f28[4] = { - /* -- */ { "movaps", 0, Vps, Wps, XX }, - /* 66 */ { "movapd", 0, Vpd, Wpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f29[4] = { - /* -- */ { "movaps", 0, Wps, Vps, XX }, - /* 66 */ { "movapd", 0, Wpd, Vpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f2a[4] = { - /* -- */ { "cvtpi2ps", 0, Vps, Qq, XX }, - /* 66 */ { "cvtpi2pd", 0, Vpd, Qq, XX }, - /* F2 */ { "cvtsi2sd", 0, Vsd, Ed, XX }, - /* F3 */ { "cvtsi2ss", 0, Vss, Ed, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f2b[4] = { - /* -- */ { "movntps", 0, Mps, Vps, XX }, - /* 66 */ { "movntpd", 0, Mpd, Vpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f2c[4] = { - /* -- */ { "cvtps2pi", 0, Pq, Wps, XX }, - /* 66 */ { "cvtpd2pi", 0, Pq, Wpd, XX }, - /* F2 */ { "cvtsd2si", 0, Gd, Wsd, XX }, - /* F3 */ { "cvtss2ss", 0, Gd, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f2d[4] = { - /* -- */ { "cvtps2pi", 0, Pq, Wps, XX }, - /* 66 */ { "cvtpd2pi", 0, Pq, Wpd, XX }, - /* F2 */ { "cvtsd2si", 0, Gd, Wsd, XX }, - /* F3 */ { "cvtss2si", 0, Gd, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f2e[4] = { - /* -- */ { "ucomiss", 0, Vss, Wss, XX }, - /* 66 */ { "ucomisd", 0, Vsd, Wss, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f2f[4] = { - /* -- */ { "comiss", 0, Vss, Wss, XX }, - /* 66 */ { "comisd", 0, Vsd, Wsd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f50[4] = { - /* -- */ { "movmskps", 0, Gd, Vps, XX }, - /* 66 */ { "movmskpd", 0, Gd, Vpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f51[4] = { - /* -- */ { "sqrtps", 0, Vps, Wps, XX }, - /* 66 */ { "sqrtpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "sqrtsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "sqrtss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f52[4] = { - /* -- */ { "rsqrtps", 0, Vps, Wps, XX }, - /* 66 */ { INVALID }, - /* F2 */ { INVALID }, - /* F3 */ { "rsqrtss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f53[4] = { - /* -- */ { "rcpps", 0, Vps, Wps, XX }, - /* 66 */ { INVALID }, - /* F2 */ { INVALID }, - /* F3 */ { "rcpss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f54[4] = { - /* -- */ { "andps", 0, Vps, Wps, XX }, - /* 66 */ { "andpd", 0, Vpd, Wpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f55[4] = { - /* -- */ { "andnps", 0, Vps, Wps, XX }, - /* 66 */ { "andnpd", 0, Vpd, Wpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f56[4] = { - /* -- */ { "orps", 0, Vps, Wps, XX }, - /* 66 */ { "orpd", 0, Vpd, Wpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f57[4] = { - /* -- */ { "xorps", 0, Vps, Wps, XX }, - /* 66 */ { "xorpd", 0, Vpd, Wpd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f58[4] = { - /* -- */ { "addps", 0, Vps, Wps, XX }, - /* 66 */ { "addpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "addsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "addss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f59[4] = { - /* -- */ { "mulps", 0, Vps, Wps, XX }, - /* 66 */ { "mulpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "mulsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "mulss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f5a[4] = { - /* -- */ { "cvtps2pd", 0, Vpd, Wps, XX }, - /* 66 */ { "cvtpd2ps", 0, Vps, Wpd, XX }, - /* F2 */ { "cvtsd2ss", 0, Vss, Wss, XX }, - /* F3 */ { "cvtss2sd", 0, Vsd, Wsd, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f5b[4] = { - /* -- */ { "cvtdq2ps", 0, Vps, Wdq, XX }, - /* 66 */ { "cvtps2dq", 0, Vdq, Wps, XX }, - /* F2 */ { INVALID }, - /* F3 */ { "cvttps2dq", 0, Vdq, Wps, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f5c[4] = { - /* -- */ { "subps", 0, Vps, Wps, XX }, - /* 66 */ { "subpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "subsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "subss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f5d[4] = { - /* -- */ { "minps", 0, Vps, Wps, XX }, - /* 66 */ { "minpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "minsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "minss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f5e[4] = { - /* -- */ { "divps", 0, Vps, Wps, XX }, - /* 66 */ { "divpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "divsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "divss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f5f[4] = { - /* -- */ { "maxps", 0, Vps, Wps, XX }, - /* 66 */ { "maxpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "maxsd", 0, Vsd, Wsd, XX }, - /* F3 */ { "maxss", 0, Vss, Wss, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f60[4] = { - /* -- */ { "punpcklbw", 0, Pq, Qd, XX }, - /* 66 */ { "punpcklbw", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f61[4] = { - /* -- */ { "punpcklwd", 0, Pq, Qd, XX }, - /* 66 */ { "punpcklwd", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f62[4] = { - /* -- */ { "punpckldq", 0, Pq, Qd, XX }, - /* 66 */ { "punpckldq", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f63[4] = { - /* -- */ { "packsswb", 0, Pq, Qq, XX }, - /* 66 */ { "packsswb", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f64[4] = { - /* -- */ { "pcmpgtb", 0, Pq, Qq, XX }, - /* 66 */ { "pcmpgtb", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f65[4] = { - /* -- */ { "pcmpgtw", 0, Pq, Qq, XX }, - /* 66 */ { "pcmpgtw", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f66[4] = { - /* -- */ { "pcmpgtd", 0, Pq, Qq, XX }, - /* 66 */ { "pcmpgtd", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f67[4] = { - /* -- */ { "packuswb", 0, Pq, Qq, XX }, - /* 66 */ { "packuswb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f68[4] = { - /* -- */ { "punpckhbw", 0, Pq, Qq, XX }, - /* 66 */ { "punpckhbw", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f69[4] = { - /* -- */ { "punpckhwd", 0, Pq, Qq, XX }, - /* 66 */ { "punpckhwd", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f6a[4] = { - /* -- */ { "punpckhdq", 0, Pq, Qq, XX }, - /* 66 */ { "punpckhdq", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f6b[4] = { - /* -- */ { "packssdw", 0, Pq, Qq, XX }, - /* 66 */ { "packssdw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f6c[4] = { - /* -- */ { INVALID }, - /* 66 */ { "punpcklqdq", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f6d[4] = { - /* -- */ { INVALID }, - /* 66 */ { "punpckhqdq", 0, Vdq, Wq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f6e[4] = { - /* -- */ { "movd", 0, Pq, Ed, XX }, - /* 66 */ { "movd", 0, Vdq, Ed, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f6f[4] = { - /* -- */ { "movq", 0, Pq, Qq, XX }, - /* 66 */ { "movdqa", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { "movdqu", 0, Vdq, Wdq, XX }, -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f70[4] = { - /* -- */ { "pshufw", 0, Pq, Qq, Ib }, - /* 66 */ { "pshufd", 0, Vdq, Wdq, Ib }, - /* F2 */ { "pshufhw", 0, Vq, Wq, Ib }, - /* F3 */ { "pshuflw", 0, Vq, Wq, Ib } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f74[4] = { - /* -- */ { "pcmpeqb", 0, Pq, Qq, XX }, - /* 66 */ { "pcmpeqb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f75[4] = { - /* -- */ { "pcmpeqw", 0, Pq, Qq, XX }, - /* 66 */ { "pcmpeqw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f76[4] = { - /* -- */ { "pcmpeqd", 0, Pq, Qq, XX }, - /* 66 */ { "pcmpeqd", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f7c[4] = { - /* -- */ { INVALID }, - /* 66 */ { "haddpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "haddps", 0, Vps, Wps, XX }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f7d[4] = { - /* -- */ { INVALID }, - /* 66 */ { "hsubpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "hsubps", 0, Vps, Wps, XX }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f7e[4] = { - /* -- */ { "movd", 0, Ed, Pq, XX }, - /* 66 */ { "movd", 0, Ed, Vd, XX }, - /* F2 */ { INVALID }, - /* F3 */ { "movq", 0, Vq, Wq, XX }, -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0f7f[4] = { - /* -- */ { "movq", 0, Qq, Pq, XX }, - /* 66 */ { "movdqa", 0, Wdq, Vdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { "movdqu", 0, Wdq, Vdq, XX }, -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fc2[4] = { - /* -- */ { "cmpps", 0, Vps, Wps, Ib }, - /* 66 */ { "cmppd", 0, Vpd, Wpd, Ib }, - /* F2 */ { "cmpsd", 0, Vsd, Wsd, Ib }, - /* F3 */ { "cmpss", 0, Vss, Wss, Ib } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fc3[4] = { - /* -- */ { "movnti", 0, Md, Gd, XX }, - /* 66 */ { INVALID }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fc4[4] = { - /* -- */ { "pinsrw", 0, Pq, Ed, Ib }, - /* 66 */ { "pinsrw", 0, Vdq, Ed, Ib }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fc5[4] = { - /* -- */ { "pextrw", 0, Gd, Pq, Ib }, - /* 66 */ { "pextrw", 0, Gd, Vdq, Ib }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fc6[4] = { - /* -- */ { "shufps", 0, Vps, Wps, Ib }, - /* 66 */ { "shufpd", 0, Vpd, Wpd, Ib }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd0[4] = { - /* -- */ { INVALID }, - /* 66 */ { "addsubpd", 0, Vpd, Wpd, XX }, - /* F2 */ { "addsubps", 0, Vps, Wps, XX }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd1[4] = { - /* -- */ { "psrlw", 0, Pq, Qq, XX }, - /* 66 */ { "psrlw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd2[4] = { - /* -- */ { "psrld", 0, Pq, Qq, XX }, - /* 66 */ { "psrld", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd3[4] = { - /* -- */ { "psrlq", 0, Pq, Qq, XX }, - /* 66 */ { "psrlq", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd4[4] = { - /* -- */ { "paddq", 0, Pq, Qq, XX }, - /* 66 */ { "paddq", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd5[4] = { - /* -- */ { "pmullw", 0, Pq, Qq, XX }, - /* 66 */ { "pmullw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd6[4] = { - /* -- */ { INVALID }, - /* 66 */ { "movq", 0, Wq, Vq, XX }, - /* F2 */ { "movdq2q", 0, Pq, Vq, XX }, - /* F3 */ { "movq2dq", 0, Vdq, Qq, XX }, -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd7[4] = { - /* -- */ { "pmovmskb", 0, Gd, Pq, XX }, - /* 66 */ { "pmovmskb", 0, Gd, Vdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd8[4] = { - /* -- */ { "psubusb", 0, Pq, Qq, XX }, - /* 66 */ { "psubusb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fd9[4] = { - /* -- */ { "psubusw", 0, Pq, Qq, XX }, - /* 66 */ { "psubusw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fda[4] = { - /* -- */ { "pminub", 0, Pq, Qq, XX }, - /* 66 */ { "pminub", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fdb[4] = { - /* -- */ { "pand", 0, Pq, Qq, XX }, - /* 66 */ { "pand", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fdc[4] = { - /* -- */ { "paddusb", 0, Pq, Qq, XX }, - /* 66 */ { "paddusb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fdd[4] = { - /* -- */ { "paddusw", 0, Pq, Qq, XX }, - /* 66 */ { "paddusw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fde[4] = { - /* -- */ { "pmaxub", 0, Pq, Qq, XX }, - /* 66 */ { "pmaxub", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fdf[4] = { - /* -- */ { "pandn", 0, Pq, Qq, XX }, - /* 66 */ { "pandn", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe0[4] = { - /* -- */ { "pavgb", 0, Pq, Qq, XX }, - /* 66 */ { "pavgb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe1[4] = { - /* -- */ { "psraw", 0, Pq, Qq, XX }, - /* 66 */ { "psraw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe2[4] = { - /* -- */ { "psrad", 0, Pq, Qq, XX }, - /* 66 */ { "psrad", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe3[4] = { - /* -- */ { "pavgw", 0, Pq, Qq, XX }, - /* 66 */ { "pavgw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe4[4] = { - /* -- */ { "pmulhuw", 0, Pq, Qq, XX }, - /* 66 */ { "pmulhuw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe5[4] = { - /* -- */ { "pmulhw", 0, Pq, Qq, XX }, - /* 66 */ { "pmulhw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe6[4] = { - /* -- */ { INVALID }, - /* 66 */ { "cvttpd2dq", 0, Vq, Wpd, XX }, - /* F2 */ { "cvtpd2dq", 0, Vq, Wpd, XX }, - /* F3 */ { "cvtdq2pd", 0, Vpd, Wq, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe7[4] = { - /* -- */ { "movntq", 0, Mq, Pq, XX }, - /* 66 */ { "movntdq", 0, Mdq, Vdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe8[4] = { - /* -- */ { "psubsb", 0, Pq, Qq, XX }, - /* 66 */ { "psubsb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fe9[4] = { - /* -- */ { "psubsw", 0, Pq, Qq, XX }, - /* 66 */ { "psubsw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fea[4] = { - /* -- */ { "pminsw", 0, Pq, Qq, XX }, - /* 66 */ { "pminsw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0feb[4] = { - /* -- */ { "por", 0, Pq, Qq, XX }, - /* 66 */ { "por", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fec[4] = { - /* -- */ { "paddsb", 0, Pq, Qq, XX }, - /* 66 */ { "paddsb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fed[4] = { - /* -- */ { "paddsw", 0, Pq, Qq, XX }, - /* 66 */ { "paddsw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fee[4] = { - /* -- */ { "pmaxuw", 0, Pq, Qq, XX }, - /* 66 */ { "pmaxuw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0fef[4] = { - /* -- */ { "pxor", 0, Pq, Qq, XX }, - /* 66 */ { "pxor", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff0[4] = { - /* -- */ { INVALID }, - /* 66 */ { INVALID }, - /* F3 */ { "lddqu", 0, Vdq, Mdq, XX }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff1[4] = { - /* -- */ { "psllw", 0, Pq, Qq, XX }, - /* 66 */ { "psllw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff2[4] = { - /* -- */ { "pslld", 0, Pq, Qq, XX }, - /* 66 */ { "pslld", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff3[4] = { - /* -- */ { "psllq", 0, Pq, Qq, XX }, - /* 66 */ { "psllq", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff4[4] = { - /* -- */ { "pmuludq", 0, Pq, Qq, XX }, - /* 66 */ { "pmuludq", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff5[4] = { - /* -- */ { "pmaddwd", 0, Pq, Qq, XX }, - /* 66 */ { "pmaddwd", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff6[4] = { - /* -- */ { "psadbw", 0, Pq, Qq, XX }, - /* 66 */ { "psadbw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff7[4] = { - /* -- */ { "maskmovq", 0, Pq, Qq, XX }, - /* 66 */ { "maskmovdqu", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff8[4] = { - /* -- */ { "psubb", 0, Pq, Qq, XX }, - /* 66 */ { "psubb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ff9[4] = { - /* -- */ { "psubw", 0, Pq, Qq, XX }, - /* 66 */ { "psubw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ffa[4] = { - /* -- */ { "psubd", 0, Pq, Qq, XX }, - /* 66 */ { "psubd", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ffb[4] = { - /* -- */ { "psubq", 0, Pq, Qq, XX }, - /* 66 */ { "psubq", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ffc[4] = { - /* -- */ { "paddb", 0, Pq, Qq, XX }, - /* 66 */ { "paddb", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ffd[4] = { - /* -- */ { "paddw", 0, Pq, Qq, XX }, - /* 66 */ { "paddw", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_0ffe[4] = { - /* -- */ { "paddd", 0, Pq, Qq, XX }, - /* 66 */ { "paddd", 0, Vdq, Wdq, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1202[4] = { - /* -- */ { "psrlw", 0, Pq, Ib, XX }, - /* 66 */ { "psrlw", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1204[4] = { - /* -- */ { "psraw", 0, Pq, Ib, XX }, - /* 66 */ { "psraw", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1206[4] = { - /* -- */ { "psllw", 0, Pq, Ib, XX }, - /* 66 */ { "psllw", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1302[4] = { - /* -- */ { "psrld", 0, Pq, Ib, XX }, - /* 66 */ { "psrld", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1304[4] = { - /* -- */ { "psrad", 0, Pq, Ib, XX }, - /* 66 */ { "psrad", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1306[4] = { - /* -- */ { "pslld", 0, Pq, Ib, XX }, - /* 66 */ { "pslld", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1402[4] = { - /* -- */ { "psrlq", 0, Pq, Ib, XX }, - /* 66 */ { "psrlq", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1403[4] = { - /* -- */ { INVALID }, - /* 66 */ { "psrldq", 0, Wdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1406[4] = { - /* -- */ { "psllq", 0, Pq, Ib, XX }, - /* 66 */ { "psllq", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupSSE_G1407[4] = { - /* -- */ { INVALID }, - /* 66 */ { "pslldq", 0, Vdq, Ib, XX }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID } -}; - - -/* ************************************************************************ */ -/* Opcode GroupN */ - -static BxDisasmOpcodeInfo_t BxDisasmGroupG1EbIb[8] = { - /* 0 */ { "addB", 0, Eb, Ib, XX }, - /* 1 */ { "orB", 0, Eb, Ib, XX }, - /* 2 */ { "adcB", 0, Eb, Ib, XX }, - /* 3 */ { "sbbB", 0, Eb, Ib, XX }, - /* 4 */ { "andB", 0, Eb, Ib, XX }, - /* 5 */ { "subB", 0, Eb, Ib, XX }, - /* 6 */ { "xorB", 0, Eb, Ib, XX }, - /* 7 */ { "cmpB", 0, Eb, Ib, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG1EvIv[8] = { - /* 0 */ { "addV", 0, Ev, Iv, XX }, - /* 1 */ { "orV", 0, Ev, Iv, XX }, - /* 2 */ { "adcV", 0, Ev, Iv, XX }, - /* 3 */ { "sbbV", 0, Ev, Iv, XX }, - /* 4 */ { "andV", 0, Ev, Iv, XX }, - /* 5 */ { "subV", 0, Ev, Iv, XX }, - /* 6 */ { "xorV", 0, Ev, Iv, XX }, - /* 7 */ { "cmpV", 0, Ev, Iv, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG1EvIb[8] = { - /* 0 */ { "addV", 0, Ev, sIb, XX }, // sign-extend byte - /* 1 */ { "orV", 0, Ev, sIb, XX }, - /* 2 */ { "adcV", 0, Ev, sIb, XX }, - /* 3 */ { "sbbV", 0, Ev, sIb, XX }, - /* 4 */ { "andV", 0, Ev, sIb, XX }, - /* 5 */ { "subV", 0, Ev, sIb, XX }, - /* 6 */ { "xorV", 0, Ev, sIb, XX }, - /* 7 */ { "cmpV", 0, Ev, sIb, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG2Eb[8] = { - /* 0 */ { "rolB", 0, Eb, Ib, XX }, - /* 1 */ { "rorB", 0, Eb, Ib, XX }, - /* 2 */ { "rclB", 0, Eb, Ib, XX }, - /* 3 */ { "rcrB", 0, Eb, Ib, XX }, - /* 4 */ { "shlB", 0, Eb, Ib, XX }, - /* 5 */ { "shrB", 0, Eb, Ib, XX }, - /* 6 */ { "shlB", 0, Eb, Ib, XX }, - /* 7 */ { "sarB", 0, Eb, Ib, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG2Eb1[8] = { - /* 0 */ { "rolB", 0, Eb, I1, XX }, - /* 1 */ { "rorB", 0, Eb, I1, XX }, - /* 2 */ { "rclB", 0, Eb, I1, XX }, - /* 3 */ { "rcrB", 0, Eb, I1, XX }, - /* 4 */ { "shlB", 0, Eb, I1, XX }, - /* 5 */ { "shrB", 0, Eb, I1, XX }, - /* 6 */ { "shlB", 0, Eb, I1, XX }, - /* 7 */ { "sarB", 0, Eb, I1, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG2EbCL[8] = { - /* 0 */ { "rolB", 0, Eb, CL, XX }, - /* 1 */ { "rorB", 0, Eb, CL, XX }, - /* 2 */ { "rclB", 0, Eb, CL, XX }, - /* 3 */ { "rcrB", 0, Eb, CL, XX }, - /* 4 */ { "shlB", 0, Eb, CL, XX }, - /* 5 */ { "shrB", 0, Eb, CL, XX }, - /* 6 */ { "shlB", 0, Eb, CL, XX }, - /* 7 */ { "sarB", 0, Eb, CL, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG2Ev[8] = { - /* 0 */ { "rolV", 0, Ev, Ib, XX }, - /* 1 */ { "rorV", 0, Ev, Ib, XX }, - /* 2 */ { "rclV", 0, Ev, Ib, XX }, - /* 3 */ { "rcrV", 0, Ev, Ib, XX }, - /* 4 */ { "shlV", 0, Ev, Ib, XX }, - /* 5 */ { "shrV", 0, Ev, Ib, XX }, - /* 6 */ { "shlV", 0, Ev, Ib, XX }, - /* 7 */ { "sarV", 0, Ev, Ib, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG2Ev1[8] = { - /* 0 */ { "rolV", 0, Ev, I1, XX }, - /* 1 */ { "rorV", 0, Ev, I1, XX }, - /* 2 */ { "rclV", 0, Ev, I1, XX }, - /* 3 */ { "rcrV", 0, Ev, I1, XX }, - /* 4 */ { "shlV", 0, Ev, I1, XX }, - /* 5 */ { "shrV", 0, Ev, I1, XX }, - /* 6 */ { "shlV", 0, Ev, I1, XX }, - /* 7 */ { "sarV", 0, Ev, I1, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG2EvCL[8] = { - /* 0 */ { "rolV", 0, Ev, CL, XX }, - /* 1 */ { "rorV", 0, Ev, CL, XX }, - /* 2 */ { "rclV", 0, Ev, CL, XX }, - /* 3 */ { "rcrV", 0, Ev, CL, XX }, - /* 4 */ { "shlV", 0, Ev, CL, XX }, - /* 5 */ { "shrV", 0, Ev, CL, XX }, - /* 6 */ { "shlV", 0, Ev, CL, XX }, - /* 7 */ { "sarV", 0, Ev, CL, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG3Eb[8] = { - /* 0 */ { "testB", 0, Eb, Ib, XX }, - /* 1 */ { "testB", 0, Eb, Ib, XX }, - /* 2 */ { "notB", 0, Eb, XX, XX }, - /* 3 */ { "negB", 0, Eb, XX, XX }, - /* 4 */ { "mulB", 0, AL, Eb, XX }, - /* 5 */ { "imulB", 0, AL, Eb, XX }, - /* 6 */ { "divB", 0, AL, Eb, XX }, - /* 7 */ { "idivB", 0, AL, Eb, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG3Ev[8] = { - /* 0 */ { "testV", 0, Ev, Iv, XX }, - /* 1 */ { "testV", 0, Ev, Iv, XX }, - /* 2 */ { "notV", 0, Ev, XX, XX }, - /* 3 */ { "negV", 0, Ev, XX, XX }, - /* 4 */ { "mulV", 0, eAX, Ev, XX }, - /* 5 */ { "imulV", 0, eAX, Ev, XX }, - /* 6 */ { "divV", 0, eAX, Ev, XX }, - /* 7 */ { "idivV", 0, eAX, Ev, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG4[8] = { - /* 0 */ { "incB", 0, Eb, XX, XX }, - /* 1 */ { "decB", 0, Eb, XX, XX }, - /* 2 */ { INVALID }, - /* 3 */ { INVALID }, - /* 4 */ { INVALID }, - /* 5 */ { INVALID }, - /* 6 */ { INVALID }, - /* 7 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG5[8] = { - /* 0 */ { "incV", 0, Ev, XX, XX }, - /* 1 */ { "decV", 0, Ev, XX, XX }, - /* 2 */ { "callV", 0, Ev, XX, XX }, - /* 3 */ { "call far", 0, Mp, XX, XX }, - /* 4 */ { "jmpV", 0, Ev, XX, XX }, - /* 5 */ { "jmp far", 0, Mp, XX, XX }, - /* 6 */ { "pushV", 0, Ev, XX, XX }, - /* 7 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG6[8] = { - /* 0 */ { "sldtW", 0, Ew, XX, XX }, - /* 1 */ { "strW", 0, Ew, XX, XX }, - /* 2 */ { "lldtW", 0, Ew, XX, XX }, - /* 3 */ { "ltrW", 0, Ew, XX, XX }, - /* 4 */ { "verrW", 0, Ew, XX, XX }, - /* 5 */ { "verwW", 0, Ew, XX, XX }, - /* 6 */ { INVALID }, - /* 7 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG7[8] = { - /* 0 */ { "sgdt", 0, Ms, XX, XX }, - /* 1 */ { "sidt", 0, Ms, XX, XX }, - /* 2 */ { "lgdt", 0, Ms, XX, XX }, - /* 3 */ { "lidt", 0, Ms, XX, XX }, - /* 4 */ { "smsw", 0, Ew, XX, XX }, - /* 5 */ { INVALID }, - /* 6 */ { "lmsw", 0, Ew, XX, XX }, - /* 7 */ { "invlpg", 0, XX, XX, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG8EvIb[8] = { - /* 0 */ { INVALID }, - /* 1 */ { INVALID }, - /* 2 */ { INVALID }, - /* 3 */ { INVALID }, - /* 4 */ { "btV", 0, Ev, Ib, XX }, - /* 5 */ { "btsV", 0, Ev, Ib, XX }, - /* 6 */ { "btrV", 0, Ev, Ib, XX }, - /* 7 */ { "btcV", 0, Ev, Ib, XX } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG9[8] = { - /* 0 */ { INVALID }, - /* 1 */ { "cmpxchg8b", 0, Mq, XX, XX }, - /* 2 */ { INVALID }, - /* 3 */ { INVALID }, - /* 4 */ { INVALID }, - /* 5 */ { INVALID }, - /* 6 */ { INVALID }, - /* 7 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG12[8] = { - /* 0 */ { INVALID }, - /* 1 */ { INVALID }, - /* 2 */ { GRPSSE(G1202) }, - /* 3 */ { INVALID }, - /* 4 */ { GRPSSE(G1204) }, - /* 5 */ { INVALID }, - /* 6 */ { GRPSSE(G1206) }, - /* 7 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG13[8] = { - /* 0 */ { INVALID }, - /* 1 */ { INVALID }, - /* 2 */ { GRPSSE(G1302) }, - /* 3 */ { INVALID }, - /* 4 */ { GRPSSE(G1304) }, - /* 5 */ { INVALID }, - /* 6 */ { GRPSSE(G1306) }, - /* 7 */ { INVALID } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG14[8] = { - /* 0 */ { INVALID }, - /* 1 */ { INVALID }, - /* 2 */ { GRPSSE(G1402) }, - /* 3 */ { GRPSSE(G1403) }, - /* 4 */ { INVALID }, - /* 5 */ { INVALID }, - /* 6 */ { GRPSSE(G1406) }, - /* 7 */ { GRPSSE(G1407) } -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG15[8] = { - /* 0 */ { "fxsave", 0, Mx, XX, XX }, - /* 1 */ { "fxrstor", 0, Mx, XX, XX }, - /* 2 */ { "ldmxcsr", 0, Md, XX, XX }, - /* 3 */ { "stmxcsr", 0, Md, XX, XX }, - /* 4 */ { INVALID }, - /* 5 */ { "lfence", 0, XX, XX, XX }, - /* 6 */ { "mfence", 0, XX, XX, XX }, - /* 7 */ { "sfence", 0, XX, XX, XX } /* SFENCE/CFLUSH */ -}; - -static BxDisasmOpcodeInfo_t BxDisasmGroupG16[8] = -{ - /* 0 */ { "prefetchnta", 0, Mb, XX, XX }, - /* 1 */ { "prefetcht0", 0, Mb, XX, XX }, - /* 2 */ { "prefetcht1", 0, Mb, XX, XX }, - /* 3 */ { "prefetcht2", 0, Mb, XX, XX }, - /* 4 */ { INVALID }, - /* 5 */ { INVALID }, - /* 6 */ { INVALID }, - /* 7 */ { INVALID } -}; - -/* ************************************************************************ */ -/* 3DNow! opcodes */ - -static BxDisasmOpcodeInfo_t BxDisasm3DNowGroup[256] = { - // 256 entries for 3DNow opcodes, by suffix - /* 00 */ { INVALID }, - /* 01 */ { INVALID }, - /* 02 */ { INVALID }, - /* 03 */ { INVALID }, - /* 04 */ { INVALID }, - /* 05 */ { INVALID }, - /* 06 */ { INVALID }, - /* 07 */ { INVALID }, - /* 08 */ { INVALID }, - /* 09 */ { INVALID }, - /* 0A */ { INVALID }, - /* 0B */ { INVALID }, - /* 0C */ { "pi2fw", 0, Pq, Qq, XX }, - /* 0D */ { "pi2fd", 0, Pq, Qq, XX }, - /* 0E */ { INVALID }, - /* 0F */ { INVALID }, - /* 10 */ { INVALID }, - /* 11 */ { INVALID }, - /* 12 */ { INVALID }, - /* 13 */ { INVALID }, - /* 14 */ { INVALID }, - /* 15 */ { INVALID }, - /* 16 */ { INVALID }, - /* 17 */ { INVALID }, - /* 18 */ { INVALID }, - /* 19 */ { INVALID }, - /* 1A */ { INVALID }, - /* 1B */ { INVALID }, - /* 1C */ { "pf2iw", 0, Pq, Qq, XX }, - /* 1D */ { "pf2id", 0, Pq, Qq, XX }, - /* 1E */ { INVALID }, - /* 1F */ { INVALID }, - /* 20 */ { INVALID }, - /* 21 */ { INVALID }, - /* 22 */ { INVALID }, - /* 23 */ { INVALID }, - /* 24 */ { INVALID }, - /* 25 */ { INVALID }, - /* 26 */ { INVALID }, - /* 27 */ { INVALID }, - /* 28 */ { INVALID }, - /* 29 */ { INVALID }, - /* 2A */ { INVALID }, - /* 2B */ { INVALID }, - /* 2C */ { INVALID }, - /* 2D */ { INVALID }, - /* 2E */ { INVALID }, - /* 2F */ { INVALID }, - /* 30 */ { INVALID }, - /* 31 */ { INVALID }, - /* 32 */ { INVALID }, - /* 33 */ { INVALID }, - /* 34 */ { INVALID }, - /* 35 */ { INVALID }, - /* 36 */ { INVALID }, - /* 37 */ { INVALID }, - /* 38 */ { INVALID }, - /* 39 */ { INVALID }, - /* 3A */ { INVALID }, - /* 3B */ { INVALID }, - /* 3C */ { INVALID }, - /* 3D */ { INVALID }, - /* 3E */ { INVALID }, - /* 3F */ { INVALID }, - /* 40 */ { INVALID }, - /* 41 */ { INVALID }, - /* 42 */ { INVALID }, - /* 43 */ { INVALID }, - /* 44 */ { INVALID }, - /* 45 */ { INVALID }, - /* 46 */ { INVALID }, - /* 47 */ { INVALID }, - /* 48 */ { INVALID }, - /* 49 */ { INVALID }, - /* 4A */ { INVALID }, - /* 4B */ { INVALID }, - /* 4C */ { INVALID }, - /* 4D */ { INVALID }, - /* 4E */ { INVALID }, - /* 4F */ { INVALID }, - /* 50 */ { INVALID }, - /* 51 */ { INVALID }, - /* 52 */ { INVALID }, - /* 53 */ { INVALID }, - /* 54 */ { INVALID }, - /* 55 */ { INVALID }, - /* 56 */ { INVALID }, - /* 57 */ { INVALID }, - /* 58 */ { INVALID }, - /* 59 */ { INVALID }, - /* 5A */ { INVALID }, - /* 5B */ { INVALID }, - /* 5C */ { INVALID }, - /* 5D */ { INVALID }, - /* 5E */ { INVALID }, - /* 5F */ { INVALID }, - /* 60 */ { INVALID }, - /* 61 */ { INVALID }, - /* 62 */ { INVALID }, - /* 63 */ { INVALID }, - /* 64 */ { INVALID }, - /* 65 */ { INVALID }, - /* 66 */ { INVALID }, - /* 67 */ { INVALID }, - /* 68 */ { INVALID }, - /* 69 */ { INVALID }, - /* 6A */ { INVALID }, - /* 6B */ { INVALID }, - /* 6C */ { INVALID }, - /* 6D */ { INVALID }, - /* 6E */ { INVALID }, - /* 6F */ { INVALID }, - /* 70 */ { INVALID }, - /* 71 */ { INVALID }, - /* 72 */ { INVALID }, - /* 73 */ { INVALID }, - /* 74 */ { INVALID }, - /* 75 */ { INVALID }, - /* 76 */ { INVALID }, - /* 77 */ { INVALID }, - /* 78 */ { INVALID }, - /* 79 */ { INVALID }, - /* 7A */ { INVALID }, - /* 7B */ { INVALID }, - /* 7C */ { INVALID }, - /* 7D */ { INVALID }, - /* 7E */ { INVALID }, - /* 7F */ { INVALID }, - /* 80 */ { INVALID }, - /* 81 */ { INVALID }, - /* 82 */ { INVALID }, - /* 83 */ { INVALID }, - /* 84 */ { INVALID }, - /* 85 */ { INVALID }, - /* 86 */ { INVALID }, - /* 87 */ { INVALID }, - /* 88 */ { INVALID }, - /* 89 */ { INVALID }, - /* 8A */ { "pfnacc", 0, Pq, Qq, XX }, - /* 8B */ { INVALID }, - /* 8C */ { INVALID }, - /* 8D */ { INVALID }, - /* 8E */ { "pfpnacc", 0, Pq, Qq, XX }, - /* 8F */ { INVALID }, - /* 90 */ { "pfcmpge", 0, Pq, Qq, XX }, - /* 91 */ { INVALID }, - /* 92 */ { INVALID }, - /* 93 */ { INVALID }, - /* 94 */ { "pfmin", 0, Pq, Qq, XX }, - /* 95 */ { INVALID }, - /* 96 */ { "pfrcp", 0, Pq, Qq, XX }, - /* 97 */ { "pfrsqrt", 0, Pq, Qq, XX }, - /* 98 */ { INVALID }, - /* 99 */ { INVALID }, - /* 9A */ { "pfsub", 0, Pq, Qq, XX }, - /* 9B */ { INVALID }, - /* 9C */ { INVALID }, - /* 9D */ { INVALID }, - /* 9E */ { "pfadd", 0, Pq, Qq, XX }, - /* 9F */ { INVALID }, - /* A0 */ { "pfcmpgt", 0, Pq, Qq, XX }, - /* A1 */ { INVALID }, - /* A2 */ { INVALID }, - /* A3 */ { INVALID }, - /* A4 */ { "pfmax", 0, Pq, Qq, XX }, - /* A5 */ { INVALID }, - /* A6 */ { "pfrcpit1", 0, Pq, Qq, XX }, - /* A7 */ { "pfrsqit1", 0, Pq, Qq, XX }, - /* A8 */ { INVALID }, - /* A9 */ { INVALID }, - /* AA */ { "pfsubr", 0, Pq, Qq, XX }, - /* AB */ { INVALID }, - /* AC */ { INVALID }, - /* AD */ { INVALID }, - /* AE */ { "pfacc", 0, Pq, Qq, XX }, - /* AF */ { INVALID }, - /* B0 */ { "pfcmpeq", 0, Pq, Qq, XX }, - /* B1 */ { INVALID }, - /* B2 */ { INVALID }, - /* B3 */ { INVALID }, - /* B4 */ { "pfmul", 0, Pq, Qq, XX }, - /* B5 */ { INVALID }, - /* B6 */ { "pfrcpit2", 0, Pq, Qq, XX }, - /* B7 */ { "pmulhrw", 0, Pq, Qq, XX }, - /* B8 */ { INVALID }, - /* B9 */ { INVALID }, - /* BA */ { INVALID }, - /* BB */ { "pswapd", 0, Pq, Qq, XX }, - /* BC */ { INVALID }, - /* BD */ { INVALID }, - /* BE */ { INVALID }, - /* BF */ { "pavgb", 0, Pq, Qq, XX }, - /* C0 */ { INVALID }, - /* C1 */ { INVALID }, - /* C2 */ { INVALID }, - /* C3 */ { INVALID }, - /* C4 */ { INVALID }, - /* C5 */ { INVALID }, - /* C6 */ { INVALID }, - /* C7 */ { INVALID }, - /* C8 */ { INVALID }, - /* C9 */ { INVALID }, - /* CA */ { INVALID }, - /* CB */ { INVALID }, - /* CC */ { INVALID }, - /* CD */ { INVALID }, - /* CE */ { INVALID }, - /* CF */ { INVALID }, - /* D0 */ { INVALID }, - /* D1 */ { INVALID }, - /* D2 */ { INVALID }, - /* D3 */ { INVALID }, - /* D4 */ { INVALID }, - /* D5 */ { INVALID }, - /* D6 */ { INVALID }, - /* D7 */ { INVALID }, - /* D8 */ { INVALID }, - /* D9 */ { INVALID }, - /* DA */ { INVALID }, - /* DB */ { INVALID }, - /* DC */ { INVALID }, - /* DD */ { INVALID }, - /* DE */ { INVALID }, - /* DF */ { INVALID }, - /* E0 */ { INVALID }, - /* E1 */ { INVALID }, - /* E2 */ { INVALID }, - /* E3 */ { INVALID }, - /* E4 */ { INVALID }, - /* E5 */ { INVALID }, - /* E6 */ { INVALID }, - /* E7 */ { INVALID }, - /* E8 */ { INVALID }, - /* E9 */ { INVALID }, - /* EA */ { INVALID }, - /* EB */ { INVALID }, - /* EC */ { INVALID }, - /* ED */ { INVALID }, - /* EE */ { INVALID }, - /* EF */ { INVALID }, - /* F0 */ { INVALID }, - /* F1 */ { INVALID }, - /* F2 */ { INVALID }, - /* F3 */ { INVALID }, - /* F4 */ { INVALID }, - /* F5 */ { INVALID }, - /* F6 */ { INVALID }, - /* F7 */ { INVALID }, - /* F8 */ { INVALID }, - /* F9 */ { INVALID }, - /* FA */ { INVALID }, - /* FB */ { INVALID }, - /* FC */ { INVALID }, - /* FD */ { INVALID }, - /* FE */ { INVALID }, - /* FF */ { INVALID } -}; - -/* ************************************************************************ */ -/* FPU Opcodes */ - -// floating point instructions when mod!=11b. -// the following tables will be accessed like groups using the nnn (reg) field of -// the modrm byte. (the first byte is D8-DF) - - // D8 (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupD8[8] = { - /* 0 */ { "faddL", 0, Md, XX, XX }, - /* 1 */ { "fmulL", 0, Md, XX, XX }, - /* 2 */ { "fcomL", 0, Md, XX, XX }, - /* 3 */ { "fcompL", 0, Md, XX, XX }, - /* 4 */ { "fsubL", 0, Md, XX, XX }, - /* 5 */ { "fsubrL", 0, Md, XX, XX }, - /* 6 */ { "fdivL", 0, Md, XX, XX }, - /* 7 */ { "fdivprL", 0, Md, XX, XX } -}; - - // D9 (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupD9[8] = { - /* 0 */ { "fldL", 0, Md, XX, XX }, - /* 1 */ { INVALID }, - /* 2 */ { "fstL", 0, Md, XX, XX }, - /* 3 */ { "fstpL", 0, Md, XX, XX }, - /* 4 */ { "fldenv", 0, Mx, XX, XX }, - /* 5 */ { "fldcwW", 0, Ew, XX, XX }, - /* 6 */ { "fnstenv", 0, Mx, XX, XX }, - /* 7 */ { "fnstcwW", 0, Mw, XX, XX } -}; - - // DA (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupDA[8] = { - /* 0 */ { "fiaddL", 0, Md, XX, XX }, - /* 1 */ { "fimulL", 0, Md, XX, XX }, - /* 2 */ { "ficomL", 0, Md, XX, XX }, - /* 3 */ { "ficompL", 0, Md, XX, XX }, - /* 4 */ { "fisubL", 0, Md, XX, XX }, - /* 5 */ { "fisubrL", 0, Md, XX, XX }, - /* 6 */ { "fidivL", 0, Md, XX, XX }, - /* 7 */ { "fidivrL", 0, Md, XX, XX } -}; - - // DB (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupDB[8] = { - /* 0 */ { "fildL", 0, Md, XX, XX }, - /* 1 */ { "fisttpL", 0, Md, XX, XX }, - /* 2 */ { "fistL", 0, Md, XX, XX }, - /* 3 */ { "fistpL", 0, Md, XX, XX }, - /* 4 */ { INVALID }, - /* 5 */ { "fldT", 0, Mt, XX, XX }, - /* 6 */ { INVALID }, - /* 7 */ { "fstpT", 0, Mt, XX, XX } -}; - - // DC (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupDC[8] = { - /* 0 */ { "faddQ", 0, Mq, XX, XX }, - /* 1 */ { "fmulQ", 0, Mq, XX, XX }, - /* 2 */ { "fcomQ", 0, Mq, XX, XX }, - /* 3 */ { "fcompQ", 0, Mq, XX, XX }, - /* 4 */ { "fsubQ", 0, Mq, XX, XX }, - /* 5 */ { "fsubrQ", 0, Mq, XX, XX }, - /* 6 */ { "fdivQ", 0, Mq, XX, XX }, - /* 7 */ { "fdivrQ", 0, Mq, XX, XX } -}; - - // DD (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupDD[8] = { - /* 0 */ { "fldQ", 0, Mq, XX, XX }, - /* 1 */ { "fisttpQ", 0, Mq, XX, XX }, - /* 2 */ { "fstQ", 0, Mq, XX, XX }, - /* 3 */ { "fstpQ", 0, Mq, XX, XX }, - /* 4 */ { "frstor", 0, Mx, XX, XX }, - /* 5 */ { INVALID }, - /* 6 */ { "fnsave", 0, Mx, XX, XX }, - /* 7 */ { "fnstswW", 0, Mw, XX, XX } -}; - - // DE (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupDE[8] = { - /* 0 */ { "fiaddW", 0, Mw, XX, XX }, - /* 1 */ { "fimulW", 0, Mw, XX, XX }, - /* 2 */ { "ficomW", 0, Mw, XX, XX }, - /* 3 */ { "ficompW", 0, Mw, XX, XX }, - /* 4 */ { "fisubW", 0, Mw, XX, XX }, - /* 5 */ { "fisubrW", 0, Mw, XX, XX }, - /* 6 */ { "fidivW", 0, Mw, XX, XX }, - /* 7 */ { "fidivrW", 0, Mw, XX, XX } -}; - - // DF (modrm is outside 00h - BFh) (mod != 11) -static BxDisasmOpcodeInfo_t BxDisasmFPGroupDF[8] = { - /* 0 */ { "fildW", 0, Mw, XX, XX }, - /* 1 */ { "fisttpW", 0, Mw, XX, XX }, - /* 2 */ { "fistW", 0, Mw, XX, XX }, - /* 3 */ { "fistpW", 0, Mw, XX, XX }, - /* 4 */ { "fbldT", 0, Mt, XX, XX }, - /* 5 */ { "fildQ", 0, Mq, XX, XX }, - /* 6 */ { "fbstpT", 0, Mt, XX, XX }, - /* 7 */ { "fistpQ", 0, Mq, XX, XX } -}; - -// 512 entries for second byte of floating point instructions. (when mod==11b) -static BxDisasmOpcodeInfo_t BxDisasmOpcodeInfoFP[512] = { - // D8 (modrm is outside 00h - BFh) (mod == 11) - /* D8 C0 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C1 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C2 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C3 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C4 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C5 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C6 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C7 */ { "fadd", 0, ST0, STj, XX }, - /* D8 C8 */ { "fmul", 0, ST0, STj, XX }, - /* D8 C9 */ { "fmul", 0, ST0, STj, XX }, - /* D8 CA */ { "fmul", 0, ST0, STj, XX }, - /* D8 CB */ { "fmul", 0, ST0, STj, XX }, - /* D8 CC */ { "fmul", 0, ST0, STj, XX }, - /* D8 CD */ { "fmul", 0, ST0, STj, XX }, - /* D8 CE */ { "fmul", 0, ST0, STj, XX }, - /* D8 CF */ { "fmul", 0, ST0, STj, XX }, - /* D8 D0 */ { "fcom", 0, STj, XX, XX }, - /* D8 D1 */ { "fcom", 0, STj, XX, XX }, - /* D8 D2 */ { "fcom", 0, STj, XX, XX }, - /* D8 D3 */ { "fcom", 0, STj, XX, XX }, - /* D8 D4 */ { "fcom", 0, STj, XX, XX }, - /* D8 D5 */ { "fcom", 0, STj, XX, XX }, - /* D8 D6 */ { "fcom", 0, STj, XX, XX }, - /* D8 D7 */ { "fcom", 0, STj, XX, XX }, - /* D8 D8 */ { "fcomp", 0, STj, XX, XX }, - /* D8 D9 */ { "fcomp", 0, STj, XX, XX }, - /* D8 DA */ { "fcomp", 0, STj, XX, XX }, - /* D8 DB */ { "fcomp", 0, STj, XX, XX }, - /* D8 DC */ { "fcomp", 0, STj, XX, XX }, - /* D8 DD */ { "fcomp", 0, STj, XX, XX }, - /* D8 DE */ { "fcomp", 0, STj, XX, XX }, - /* D8 DF */ { "fcomp", 0, STj, XX, XX }, - /* D8 E0 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E1 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E2 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E3 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E4 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E5 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E6 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E7 */ { "fsub", 0, ST0, STj, XX }, - /* D8 E8 */ { "fsubr", 0, ST0, STj, XX }, - /* D8 E9 */ { "fsubr", 0, ST0, STj, XX }, - /* D8 EA */ { "fsubr", 0, ST0, STj, XX }, - /* D8 EB */ { "fsubr", 0, ST0, STj, XX }, - /* D8 EC */ { "fsubr", 0, ST0, STj, XX }, - /* D8 ED */ { "fsubr", 0, ST0, STj, XX }, - /* D8 EE */ { "fsubr", 0, ST0, STj, XX }, - /* D8 EF */ { "fsubr", 0, ST0, STj, XX }, - /* D8 F0 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F1 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F2 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F3 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F4 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F5 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F6 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F7 */ { "fdiv", 0, ST0, STj, XX }, - /* D8 F8 */ { "fsubr", 0, ST0, STj, XX }, - /* D8 F9 */ { "fsubr", 0, ST0, STj, XX }, - /* D8 FA */ { "fsubr", 0, ST0, STj, XX }, - /* D8 FB */ { "fsubr", 0, ST0, STj, XX }, - /* D8 FC */ { "fsubr", 0, ST0, STj, XX }, - /* D8 FD */ { "fsubr", 0, ST0, STj, XX }, - /* D8 FE */ { "fsubr", 0, ST0, STj, XX }, - /* D8 FF */ { "fsubr", 0, ST0, STj, XX }, - - // D9 (modrm is outside 00h - BFh) (mod == 11) - /* D9 C0 */ { "fld", 0, STj, XX, XX }, - /* D9 C1 */ { "fld", 0, STj, XX, XX }, - /* D9 C2 */ { "fld", 0, STj, XX, XX }, - /* D9 C3 */ { "fld", 0, STj, XX, XX }, - /* D9 C4 */ { "fld", 0, STj, XX, XX }, - /* D9 C5 */ { "fld", 0, STj, XX, XX }, - /* D9 C6 */ { "fld", 0, STj, XX, XX }, - /* D9 C7 */ { "fld", 0, STj, XX, XX }, - /* D9 C8 */ { "fxch", 0, STj, XX, XX }, - /* D9 C9 */ { "fxch", 0, STj, XX, XX }, - /* D9 CA */ { "fxch", 0, STj, XX, XX }, - /* D9 CB */ { "fxch", 0, STj, XX, XX }, - /* D9 CC */ { "fxch", 0, STj, XX, XX }, - /* D9 CD */ { "fxch", 0, STj, XX, XX }, - /* D9 CE */ { "fxch", 0, STj, XX, XX }, - /* D9 CF */ { "fxch", 0, STj, XX, XX }, - /* D9 D0 */ { "fnop", 0, XX, XX, XX }, - /* D9 D1 */ { INVALID }, - /* D9 D2 */ { INVALID }, - /* D9 D3 */ { INVALID }, - /* D9 D4 */ { INVALID }, - /* D9 D5 */ { INVALID }, - /* D9 D6 */ { INVALID }, - /* D9 D7 */ { INVALID }, - /* D9 D8 */ { INVALID }, - /* D9 D9 */ { INVALID }, - /* D9 DA */ { INVALID }, - /* D9 DB */ { INVALID }, - /* D9 DC */ { INVALID }, - /* D9 DD */ { INVALID }, - /* D9 DE */ { INVALID }, - /* D9 DF */ { INVALID }, - /* D9 E0 */ { "fchs", 0, XX, XX, XX }, - /* D9 E1 */ { "fabs", 0, XX, XX, XX }, - /* D9 E2 */ { INVALID }, - /* D9 E3 */ { INVALID }, - /* D9 E4 */ { "ftst", 0, XX, XX, XX }, - /* D9 E5 */ { "fxam", 0, XX, XX, XX }, - /* D9 E6 */ { INVALID }, - /* D9 E7 */ { INVALID }, - /* D9 E8 */ { "fld1", 0, XX, XX, XX }, - /* D9 E9 */ { "fldl2t", 0, XX, XX, XX }, - /* D9 EA */ { "fldl2e", 0, XX, XX, XX }, - /* D9 EB */ { "fldpi", 0, XX, XX, XX }, - /* D9 EC */ { "fldlg2", 0, XX, XX, XX }, - /* D9 ED */ { "fldln2", 0, XX, XX, XX }, - /* D9 EE */ { "fldz", 0, XX, XX, XX }, - /* D9 EF */ { INVALID }, - /* D9 F0 */ { "f2xm1", 0, XX, XX, XX }, - /* D9 F1 */ { "fyl2x", 0, XX, XX, XX }, - /* D9 F2 */ { "fptan", 0, XX, XX, XX }, - /* D9 F3 */ { "fpatan", 0, XX, XX, XX }, - /* D9 F4 */ { "fxtract", 0, XX, XX, XX }, - /* D9 F5 */ { "fprem1", 0, XX, XX, XX }, - /* D9 F6 */ { "fdecstp", 0, XX, XX, XX }, - /* D9 F7 */ { "fincstp", 0, XX, XX, XX }, - /* D9 F8 */ { "fprem", 0, XX, XX, XX }, - /* D9 F9 */ { "fyl2xp1", 0, XX, XX, XX }, - /* D9 FA */ { "fsqrt", 0, XX, XX, XX }, - /* D9 FB */ { "fsincos", 0, XX, XX, XX }, - /* D9 FC */ { "frndint", 0, XX, XX, XX }, - /* D9 FD */ { "fscale", 0, XX, XX, XX }, - /* D9 FE */ { "fsin", 0, XX, XX, XX }, - /* D9 FF */ { "fcos", 0, XX, XX, XX }, - - // DA (modrm is outside 00h - BFh) (mod == 11) - /* DA C0 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C1 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C2 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C3 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C4 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C5 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C6 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C7 */ { "fcmovb", 0, ST0, STj, XX }, - /* DA C8 */ { "fcmove", 0, ST0, STj, XX }, - /* DA C9 */ { "fcmove", 0, ST0, STj, XX }, - /* DA CA */ { "fcmove", 0, ST0, STj, XX }, - /* DA CB */ { "fcmove", 0, ST0, STj, XX }, - /* DA CC */ { "fcmove", 0, ST0, STj, XX }, - /* DA CD */ { "fcmove", 0, ST0, STj, XX }, - /* DA CE */ { "fcmove", 0, ST0, STj, XX }, - /* DA CF */ { "fcmove", 0, ST0, STj, XX }, - /* DA D0 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D1 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D2 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D3 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D4 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D5 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D6 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D7 */ { "fcmovbe", 0, ST0, STj, XX }, - /* DA D8 */ { "fcmovu", 0, ST0, STj, XX }, - /* DA D9 */ { "fcmovu", 0, ST0, STj, XX }, - /* DA DA */ { "fcmovu", 0, ST0, STj, XX }, - /* DA DB */ { "fcmovu", 0, ST0, STj, XX }, - /* DA DC */ { "fcmovu", 0, ST0, STj, XX }, - /* DA DD */ { "fcmovu", 0, ST0, STj, XX }, - /* DA DE */ { "fcmovu", 0, ST0, STj, XX }, - /* DA DF */ { "fcmovu", 0, ST0, STj, XX }, - /* DA E0 */ { INVALID }, - /* DA E1 */ { INVALID }, - /* DA E2 */ { INVALID }, - /* DA E3 */ { INVALID }, - /* DA E4 */ { INVALID }, - /* DA E5 */ { INVALID }, - /* DA E6 */ { INVALID }, - /* DA E7 */ { INVALID }, - /* DA E8 */ { INVALID }, - /* DA E9 */ { "fucompp", 0, XX, XX, XX }, - /* DA EA */ { INVALID }, - /* DA EB */ { INVALID }, - /* DA EC */ { INVALID }, - /* DA ED */ { INVALID }, - /* DA EE */ { INVALID }, - /* DA EF */ { INVALID }, - /* DA F0 */ { INVALID }, - /* DA F1 */ { INVALID }, - /* DA F2 */ { INVALID }, - /* DA F3 */ { INVALID }, - /* DA F4 */ { INVALID }, - /* DA F5 */ { INVALID }, - /* DA F6 */ { INVALID }, - /* DA F7 */ { INVALID }, - /* DA F8 */ { INVALID }, - /* DA F9 */ { INVALID }, - /* DA FA */ { INVALID }, - /* DA FB */ { INVALID }, - /* DA FC */ { INVALID }, - /* DA FD */ { INVALID }, - /* DA FE */ { INVALID }, - /* DA FF */ { INVALID }, - - // DB (modrm is outside 00h - BFh) (mod == 11) - /* DB C0 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C1 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C2 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C3 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C4 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C5 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C6 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C7 */ { "fcmovnb", 0, ST0, STj, XX }, - /* DB C8 */ { "fcmovne", 0, ST0, STj, XX }, - /* DB C9 */ { "fcmovne", 0, ST0, STj, XX }, - /* DB CA */ { "fcmovne", 0, ST0, STj, XX }, - /* DB CB */ { "fcmovne", 0, ST0, STj, XX }, - /* DB CC */ { "fcmovne", 0, ST0, STj, XX }, - /* DB CD */ { "fcmovne", 0, ST0, STj, XX }, - /* DB CE */ { "fcmovne", 0, ST0, STj, XX }, - /* DB CF */ { "fcmovne", 0, ST0, STj, XX }, - /* DB D0 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D1 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D2 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D3 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D4 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D5 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D6 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D7 */ { "fcmovnbe", 0, ST0, STj, XX }, - /* DB D8 */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB D9 */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB DA */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB DB */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB DC */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB DD */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB DE */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB DF */ { "fcmovnu", 0, ST0, STj, XX }, - /* DB E0 */ { "feni (287 only)", 0, XX, XX, XX }, - /* DB E1 */ { "fdisi (287 only)", 0, XX, XX, XX }, - /* DB E2 */ { "fnclex", 0, XX, XX, XX }, - /* DB E3 */ { "fninit", 0, XX, XX, XX }, - /* DB E4 */ { "fsetpm (287 only)", 0, XX, XX, XX }, - /* DB E5 */ { INVALID }, - /* DB E6 */ { INVALID }, - /* DB E7 */ { INVALID }, - /* DB E8 */ { "fucomi", 0, ST0, STj, XX }, - /* DB E9 */ { "fucomi", 0, ST0, STj, XX }, - /* DB EA */ { "fucomi", 0, ST0, STj, XX }, - /* DB EB */ { "fucomi", 0, ST0, STj, XX }, - /* DB EC */ { "fucomi", 0, ST0, STj, XX }, - /* DB ED */ { "fucomi", 0, ST0, STj, XX }, - /* DB EE */ { "fucomi", 0, ST0, STj, XX }, - /* DB EF */ { "fucomi", 0, ST0, STj, XX }, - /* DB F0 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F1 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F2 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F3 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F4 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F5 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F6 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F7 */ { "fcomi", 0, ST0, STj, XX }, - /* DB F8 */ { INVALID }, - /* DB F9 */ { INVALID }, - /* DB FA */ { INVALID }, - /* DB FB */ { INVALID }, - /* DB FC */ { INVALID }, - /* DB FD */ { INVALID }, - /* DB FE */ { INVALID }, - /* DB FF */ { INVALID }, - - // DC (modrm is outside 00h - BFh) (mod == 11) - /* DC C0 */ { "fadd", 0, STj, ST0, XX }, - /* DC C1 */ { "fadd", 0, STj, ST0, XX }, - /* DC C2 */ { "fadd", 0, STj, ST0, XX }, - /* DC C3 */ { "fadd", 0, STj, ST0, XX }, - /* DC C4 */ { "fadd", 0, STj, ST0, XX }, - /* DC C5 */ { "fadd", 0, STj, ST0, XX }, - /* DC C6 */ { "fadd", 0, STj, ST0, XX }, - /* DC C7 */ { "fadd", 0, STj, ST0, XX }, - /* DC C8 */ { "fmul", 0, STj, ST0, XX }, - /* DC C9 */ { "fmul", 0, STj, ST0, XX }, - /* DC CA */ { "fmul", 0, STj, ST0, XX }, - /* DC CB */ { "fmul", 0, STj, ST0, XX }, - /* DC CC */ { "fmul", 0, STj, ST0, XX }, - /* DC CD */ { "fmul", 0, STj, ST0, XX }, - /* DC CE */ { "fmul", 0, STj, ST0, XX }, - /* DC CF */ { "fmul", 0, STj, ST0, XX }, - /* DC D0 */ { INVALID }, - /* DC D1 */ { INVALID }, - /* DC D2 */ { INVALID }, - /* DC D3 */ { INVALID }, - /* DC D4 */ { INVALID }, - /* DC D5 */ { INVALID }, - /* DC D6 */ { INVALID }, - /* DC D7 */ { INVALID }, - /* DC D8 */ { INVALID }, - /* DC D9 */ { INVALID }, - /* DC DA */ { INVALID }, - /* DC DB */ { INVALID }, - /* DC DC */ { INVALID }, - /* DC DD */ { INVALID }, - /* DC DE */ { INVALID }, - /* DC DF */ { INVALID }, - /* DC E0 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E1 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E2 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E3 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E4 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E5 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E6 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E7 */ { "fsubr", 0, STj, ST0, XX }, - /* DC E8 */ { "fsub", 0, STj, ST0, XX }, - /* DC E9 */ { "fsub", 0, STj, ST0, XX }, - /* DC EA */ { "fsub", 0, STj, ST0, XX }, - /* DC EB */ { "fsub", 0, STj, ST0, XX }, - /* DC EC */ { "fsub", 0, STj, ST0, XX }, - /* DC ED */ { "fsub", 0, STj, ST0, XX }, - /* DC EE */ { "fsub", 0, STj, ST0, XX }, - /* DC EF */ { "fsub", 0, STj, ST0, XX }, - /* DC F0 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F1 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F2 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F3 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F4 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F5 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F6 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F7 */ { "fdivr", 0, STj, ST0, XX }, - /* DC F8 */ { "fdiv", 0, STj, ST0, XX }, - /* DC F9 */ { "fdiv", 0, STj, ST0, XX }, - /* DC FA */ { "fdiv", 0, STj, ST0, XX }, - /* DC FB */ { "fdiv", 0, STj, ST0, XX }, - /* DC FC */ { "fdiv", 0, STj, ST0, XX }, - /* DC FD */ { "fdiv", 0, STj, ST0, XX }, - /* DC FE */ { "fdiv", 0, STj, ST0, XX }, - /* DC FF */ { "fdiv", 0, STj, ST0, XX }, - - // DD (modrm is outside 00h - BFh) (mod == 11) - /* DD C0 */ { "ffree", 0, STj, XX, XX }, - /* DD C1 */ { "ffree", 0, STj, XX, XX }, - /* DD C2 */ { "ffree", 0, STj, XX, XX }, - /* DD C3 */ { "ffree", 0, STj, XX, XX }, - /* DD C4 */ { "ffree", 0, STj, XX, XX }, - /* DD C5 */ { "ffree", 0, STj, XX, XX }, - /* DD C6 */ { "ffree", 0, STj, XX, XX }, - /* DD C7 */ { "ffree", 0, STj, XX, XX }, - /* DD C8 */ { INVALID }, - /* DD C9 */ { INVALID }, - /* DD CA */ { INVALID }, - /* DD CB */ { INVALID }, - /* DD CC */ { INVALID }, - /* DD CD */ { INVALID }, - /* DD CE */ { INVALID }, - /* DD CF */ { INVALID }, - /* DD D0 */ { "fst", 0, STj, XX, XX }, - /* DD D1 */ { "fst", 0, STj, XX, XX }, - /* DD D2 */ { "fst", 0, STj, XX, XX }, - /* DD D3 */ { "fst", 0, STj, XX, XX }, - /* DD D4 */ { "fst", 0, STj, XX, XX }, - /* DD D5 */ { "fst", 0, STj, XX, XX }, - /* DD D6 */ { "fst", 0, STj, XX, XX }, - /* DD D7 */ { "fst", 0, STj, XX, XX }, - /* DD D8 */ { "fstp", 0, STj, XX, XX }, - /* DD D9 */ { "fstp", 0, STj, XX, XX }, - /* DD DA */ { "fstp", 0, STj, XX, XX }, - /* DD DB */ { "fstp", 0, STj, XX, XX }, - /* DD DC */ { "fstp", 0, STj, XX, XX }, - /* DD DD */ { "fstp", 0, STj, XX, XX }, - /* DD DE */ { "fstp", 0, STj, XX, XX }, - /* DD DF */ { "fstp", 0, STj, XX, XX }, - /* DD E0 */ { "fucom", 0, STj, XX, XX }, - /* DD E1 */ { "fucom", 0, STj, XX, XX }, - /* DD E2 */ { "fucom", 0, STj, XX, XX }, - /* DD E3 */ { "fucom", 0, STj, XX, XX }, - /* DD E4 */ { "fucom", 0, STj, XX, XX }, - /* DD E5 */ { "fucom", 0, STj, XX, XX }, - /* DD E6 */ { "fucom", 0, STj, XX, XX }, - /* DD E7 */ { "fucom", 0, STj, XX, XX }, - /* DD E8 */ { "fucomp", 0, STj, XX, XX }, - /* DD E9 */ { "fucomp", 0, STj, XX, XX }, - /* DD EA */ { "fucomp", 0, STj, XX, XX }, - /* DD EB */ { "fucomp", 0, STj, XX, XX }, - /* DD EC */ { "fucomp", 0, STj, XX, XX }, - /* DD ED */ { "fucomp", 0, STj, XX, XX }, - /* DD EE */ { "fucomp", 0, STj, XX, XX }, - /* DD EF */ { "fucomp", 0, STj, XX, XX }, - /* DD F0 */ { INVALID }, - /* DD F1 */ { INVALID }, - /* DD F2 */ { INVALID }, - /* DD F3 */ { INVALID }, - /* DD F4 */ { INVALID }, - /* DD F5 */ { INVALID }, - /* DD F6 */ { INVALID }, - /* DD F7 */ { INVALID }, - /* DD F8 */ { INVALID }, - /* DD F9 */ { INVALID }, - /* DD FA */ { INVALID }, - /* DD FB */ { INVALID }, - /* DD FC */ { INVALID }, - /* DD FD */ { INVALID }, - /* DD FE */ { INVALID }, - /* DD FF */ { INVALID }, - - // DE (modrm is outside 00h - BFh) (mod == 11) - /* DE C0 */ { "faddp", 0, STj, ST0, XX }, - /* DE C1 */ { "faddp", 0, STj, ST0, XX }, - /* DE C2 */ { "faddp", 0, STj, ST0, XX }, - /* DE C3 */ { "faddp", 0, STj, ST0, XX }, - /* DE C4 */ { "faddp", 0, STj, ST0, XX }, - /* DE C5 */ { "faddp", 0, STj, ST0, XX }, - /* DE C6 */ { "faddp", 0, STj, ST0, XX }, - /* DE C7 */ { "faddp", 0, STj, ST0, XX }, - /* DE C8 */ { "fmulp", 0, STj, ST0, XX }, - /* DE C9 */ { "fmulp", 0, STj, ST0, XX }, - /* DE CA */ { "fmulp", 0, STj, ST0, XX }, - /* DE CB */ { "fmulp", 0, STj, ST0, XX }, - /* DE CC */ { "fmulp", 0, STj, ST0, XX }, - /* DE CD */ { "fmulp", 0, STj, ST0, XX }, - /* DE CE */ { "fmulp", 0, STj, ST0, XX }, - /* DE CF */ { "fmulp", 0, STj, ST0, XX }, - /* DE D0 */ { INVALID }, - /* DE D1 */ { INVALID }, - /* DE D2 */ { INVALID }, - /* DE D3 */ { INVALID }, - /* DE D4 */ { INVALID }, - /* DE D5 */ { INVALID }, - /* DE D6 */ { INVALID }, - /* DE D7 */ { INVALID }, - /* DE D8 */ { INVALID }, - /* DE D9 */ { "fcompp", 0, XX, XX, XX }, - /* DE DA */ { INVALID }, - /* DE DB */ { INVALID }, - /* DE DC */ { INVALID }, - /* DE DD */ { INVALID }, - /* DE DE */ { INVALID }, - /* DE DF */ { INVALID }, - /* DE E0 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E1 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E2 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E3 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E4 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E5 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E6 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E7 */ { "fsubrp", 0, STj, ST0, XX }, - /* DE E8 */ { "fsubp", 0, STj, ST0, XX }, - /* DE E9 */ { "fsubp", 0, STj, ST0, XX }, - /* DE EA */ { "fsubp", 0, STj, ST0, XX }, - /* DE EB */ { "fsubp", 0, STj, ST0, XX }, - /* DE EC */ { "fsubp", 0, STj, ST0, XX }, - /* DE ED */ { "fsubp", 0, STj, ST0, XX }, - /* DE EE */ { "fsubp", 0, STj, ST0, XX }, - /* DE EF */ { "fsubp", 0, STj, ST0, XX }, - /* DE F0 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F1 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F2 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F3 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F4 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F5 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F6 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F7 */ { "fdivrp", 0, STj, ST0, XX }, - /* DE F8 */ { "fdivp", 0, STj, ST0, XX }, - /* DE F9 */ { "fdivp", 0, STj, ST0, XX }, - /* DE FA */ { "fdivp", 0, STj, ST0, XX }, - /* DE FB */ { "fdivp", 0, STj, ST0, XX }, - /* DE FC */ { "fdivp", 0, STj, ST0, XX }, - /* DE FD */ { "fdivp", 0, STj, ST0, XX }, - /* DE FE */ { "fdivp", 0, STj, ST0, XX }, - /* DE FF */ { "fdivp", 0, STj, ST0, XX }, - - // DF (modrm is outside 00h - BFh) (mod == 11) - /* DF C0 */ { "ffreep", 0, STj, XX, XX }, // 287+ compatibility opcode - /* DF C1 */ { "ffreep", 0, STj, XX, XX }, - /* DF C2 */ { "ffreep", 0, STj, XX, XX }, - /* DF C3 */ { "ffreep", 0, STj, XX, XX }, - /* DF C4 */ { "ffreep", 0, STj, XX, XX }, - /* DF C5 */ { "ffreep", 0, STj, XX, XX }, - /* DF C6 */ { "ffreep", 0, STj, XX, XX }, - /* DF C7 */ { "ffreep", 0, STj, XX, XX }, - /* DF C8 */ { INVALID }, - /* DF C9 */ { INVALID }, - /* DF CA */ { INVALID }, - /* DF CB */ { INVALID }, - /* DF CC */ { INVALID }, - /* DF CD */ { INVALID }, - /* DF CE */ { INVALID }, - /* DF CF */ { INVALID }, - /* DF D0 */ { INVALID }, - /* DF D1 */ { INVALID }, - /* DF D2 */ { INVALID }, - /* DF D3 */ { INVALID }, - /* DF D4 */ { INVALID }, - /* DF D5 */ { INVALID }, - /* DF D6 */ { INVALID }, - /* DF D7 */ { INVALID }, - /* DF D8 */ { INVALID }, - /* DF D9 */ { INVALID }, - /* DF DA */ { INVALID }, - /* DF DB */ { INVALID }, - /* DF DC */ { INVALID }, - /* DF DD */ { INVALID }, - /* DF DE */ { INVALID }, - /* DF DF */ { INVALID }, - /* DF E0 */ { "fnstsw", 0, AX, XX, XX }, - /* DF E1 */ { INVALID }, - /* DF E2 */ { INVALID }, - /* DF E3 */ { INVALID }, - /* DF E4 */ { INVALID }, - /* DF E5 */ { INVALID }, - /* DF E6 */ { INVALID }, - /* DF E7 */ { INVALID }, - /* DF E8 */ { "fucomip", 0, ST0, STj, XX }, - /* DF E9 */ { "fucomip", 0, ST0, STj, XX }, - /* DF EA */ { "fucomip", 0, ST0, STj, XX }, - /* DF EB */ { "fucomip", 0, ST0, STj, XX }, - /* DF EC */ { "fucomip", 0, ST0, STj, XX }, - /* DF ED */ { "fucomip", 0, ST0, STj, XX }, - /* DF EE */ { "fucomip", 0, ST0, STj, XX }, - /* DF EF */ { "fucomip", 0, ST0, STj, XX }, - /* DF F0 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F1 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F2 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F3 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F4 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F5 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F6 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F7 */ { "fcomip", 0, ST0, STj, XX }, - /* DF F8 */ { INVALID }, - /* DF F9 */ { INVALID }, - /* DF FA */ { INVALID }, - /* DF FB */ { INVALID }, - /* DF FC */ { INVALID }, - /* DF FD */ { INVALID }, - /* DF FE */ { INVALID }, - /* DF FF */ { INVALID }, -}; - -static BxDisasmOpcodeInfo_t BxDisasmOpcodes[256*2] = { - // 256 entries for single byte opcodes - /* 00 */ { "addB", 0, Eb, Gb, XX }, - /* 01 */ { "addV", 0, Ev, Gv, XX }, - /* 02 */ { "addB", 0, Gb, Eb, XX }, - /* 03 */ { "addV", 0, Gv, Ev, XX }, - /* 04 */ { "addB", 0, AL, Ib, XX }, - /* 05 */ { "addV", 0, eAX, Iv, XX }, - /* 06 */ { "pushV", 0, ES, XX, XX }, - /* 07 */ { "popV", 0, ES, XX, XX }, - /* 08 */ { "orB", 0, Eb, Gb, XX }, - /* 09 */ { "orV", 0, Ev, Gv, XX }, - /* 0A */ { "orB", 0, Gb, Eb, XX }, - /* 0B */ { "orV", 0, Gv, Ev, XX }, - /* 0C */ { "orB", 0, AL, Ib, XX }, - /* 0D */ { "orV", 0, eAX, Iv, XX }, - /* 0E */ { "pushV", 0, CS, XX, XX }, - /* 0F */ { "(error)", 0, XX, XX, XX }, // 2 byte escape - /* 10 */ { "adcB", 0, Eb, Gb, XX }, - /* 11 */ { "adcV", 0, Ev, Gv, XX }, - /* 12 */ { "adcB", 0, Gb, Eb, XX }, - /* 13 */ { "adcV", 0, Gv, Ev, XX }, - /* 14 */ { "adcB", 0, AL, Ib, XX }, - /* 15 */ { "adcV", 0, eAX, Iv, XX }, - /* 16 */ { "pushV", 0, SS, XX, XX }, - /* 17 */ { "popV", 0, SS, XX, XX }, - /* 18 */ { "sbbB", 0, Eb, Gb, XX }, - /* 19 */ { "sbbV", 0, Ev, Gv, XX }, - /* 1A */ { "sbbB", 0, Gb, Eb, XX }, - /* 1B */ { "sbbV", 0, Gv, Ev, XX }, - /* 1C */ { "sbbB", 0, AL, Ib, XX }, - /* 1D */ { "sbbV", 0, eAX, Iv, XX }, - /* 1E */ { "pushV", 0, DS, XX, XX }, - /* 1F */ { "popV", 0, DS, XX, XX }, - /* 20 */ { "andB", 0, Eb, Gb, XX }, - /* 21 */ { "andV", 0, Ev, Gv, XX }, - /* 22 */ { "andB", 0, Gb, Eb, XX }, - /* 23 */ { "andV", 0, Gv, Ev, XX }, - /* 24 */ { "andB", 0, AL, Ib, XX }, - /* 25 */ { "andV", 0, eAX, Iv, XX }, - /* 26 */ { PREFIX_ES }, // ES: - /* 27 */ { "daa", 0, XX, XX, XX }, - /* 28 */ { "subB", 0, Eb, Gb, XX }, - /* 29 */ { "subV", 0, Ev, Gv, XX }, - /* 2A */ { "subB", 0, Gb, Eb, XX }, - /* 2B */ { "subV", 0, Gv, Ev, XX }, - /* 2C */ { "subB", 0, AL, Ib, XX }, - /* 2D */ { "subV", 0, eAX, Iv, XX }, - /* 2E */ { PREFIX_CS }, // CS: - /* 2F */ { "das", 0, XX, XX, XX }, - /* 30 */ { "xorB", 0, Eb, Gb, XX }, - /* 31 */ { "xorV", 0, Ev, Gv, XX }, - /* 32 */ { "xorB", 0, Gb, Eb, XX }, - /* 33 */ { "xorV", 0, Gv, Ev, XX }, - /* 34 */ { "xorB", 0, AL, Ib, XX }, - /* 35 */ { "xorV", 0, eAX, Iv, XX }, - /* 36 */ { PREFIX_SS }, // SS: - /* 37 */ { "aaa", 0, XX, XX, XX }, - /* 38 */ { "cmpB", 0, Eb, Gb, XX }, - /* 39 */ { "cmpV", 0, Ev, Gv, XX }, - /* 3A */ { "cmpB", 0, Gb, Eb, XX }, - /* 3B */ { "cmpV", 0, Gv, Ev, XX }, - /* 3C */ { "cmpB", 0, AL, Ib, XX }, - /* 3D */ { "cmpV", 0, eAX, Iv, XX }, - /* 3E */ { PREFIX_DS }, // DS: - /* 3F */ { "aas", 0, XX, XX, XX }, - /* 40 */ { "incV", 0, eAX, XX, XX }, - /* 41 */ { "incV", 0, eCX, XX, XX }, - /* 42 */ { "incV", 0, eDX, XX, XX }, - /* 43 */ { "incV", 0, eBX, XX, XX }, - /* 44 */ { "incV", 0, eSP, XX, XX }, - /* 45 */ { "incV", 0, eBP, XX, XX }, - /* 46 */ { "incV", 0, eSI, XX, XX }, - /* 47 */ { "incV", 0, eDI, XX, XX }, - /* 48 */ { "decV", 0, eAX, XX, XX }, - /* 49 */ { "decV", 0, eCX, XX, XX }, - /* 4A */ { "decV", 0, eDX, XX, XX }, - /* 4B */ { "decV", 0, eBX, XX, XX }, - /* 4C */ { "decV", 0, eSP, XX, XX }, - /* 4D */ { "decV", 0, eBP, XX, XX }, - /* 4E */ { "decV", 0, eSI, XX, XX }, - /* 4F */ { "decV", 0, eDI, XX, XX }, - /* 50 */ { "pushV", 0, eAX, XX, XX }, - /* 51 */ { "pushV", 0, eCX, XX, XX }, - /* 52 */ { "pushV", 0, eDX, XX, XX }, - /* 53 */ { "pushV", 0, eBX, XX, XX }, - /* 54 */ { "pushV", 0, eSP, XX, XX }, - /* 55 */ { "pushV", 0, eBP, XX, XX }, - /* 56 */ { "pushV", 0, eSI, XX, XX }, - /* 57 */ { "pushV", 0, eDI, XX, XX }, - /* 58 */ { "popV", 0, eAX, XX, XX }, - /* 59 */ { "popV", 0, eCX, XX, XX }, - /* 5A */ { "popV", 0, eDX, XX, XX }, - /* 5B */ { "popV", 0, eBX, XX, XX }, - /* 5C */ { "popV", 0, eSP, XX, XX }, - /* 5D */ { "popV", 0, eBP, XX, XX }, - /* 5E */ { "popV", 0, eSI, XX, XX }, - /* 5F */ { "popV", 0, eDI, XX, XX }, - /* 60 */ { "pushaD", 0, XX, XX, XX }, - /* 61 */ { "popaD", 0, XX, XX, XX }, - /* 62 */ { "boundW", 0, Gv, Mx, XX }, - /* 63 */ { "arplW", 0, Ew, Rw, XX }, - /* 64 */ { PREFIX_FS }, // FS: - /* 65 */ { PREFIX_GS }, // GS: - /* 66 */ { PREFIX_OPSIZE }, - /* 67 */ { PREFIX_ADDRSIZE }, - /* 68 */ { "pushV", 0, Iv, XX, XX }, - /* 69 */ { "imulV", 0, Gv, Ev, Iv }, - /* 6A */ { "pushV", 0, sIb, XX, XX }, // sign extended immediate - /* 6B */ { "imulV", 0, Gv, Ev, sIb }, - /* 6C */ { "insb", 0, Yb, DX, XX }, - /* 6D */ { "insS", 0, Yv, DX, XX }, - /* 6E */ { "outsb", 0, DX, Xb, XX }, - /* 6F */ { "outsS", 0, DX, Xv, XX }, - /* 70 */ { "jo", 0, Jb, XX, Cond_Jump }, - /* 71 */ { "jno", 0, Jb, XX, Cond_Jump }, - /* 72 */ { "jb", 0, Jb, XX, Cond_Jump }, - /* 73 */ { "jnb", 0, Jb, XX, Cond_Jump }, - /* 74 */ { "jz", 0, Jb, XX, Cond_Jump }, - /* 75 */ { "jnz", 0, Jb, XX, Cond_Jump }, - /* 76 */ { "jbe", 0, Jb, XX, Cond_Jump }, - /* 77 */ { "jnbe", 0, Jb, XX, Cond_Jump }, - /* 78 */ { "js", 0, Jb, XX, Cond_Jump }, - /* 79 */ { "jns", 0, Jb, XX, Cond_Jump }, - /* 7A */ { "jp", 0, Jb, XX, Cond_Jump }, - /* 7B */ { "jnp", 0, Jb, XX, Cond_Jump }, - /* 7C */ { "jl", 0, Jb, XX, Cond_Jump }, - /* 7D */ { "jnl", 0, Jb, XX, Cond_Jump }, - /* 7E */ { "jle", 0, Jb, XX, Cond_Jump }, - /* 7F */ { "jnle", 0, Jb, XX, Cond_Jump }, - /* 80 */ { GRPN(G1EbIb) }, - /* 81 */ { GRPN(G1EvIv) }, - /* 82 */ { GRPN(G1EbIb) }, - /* 83 */ { GRPN(G1EvIb) }, - /* 84 */ { "testB", 0, Eb, Gb, XX }, - /* 85 */ { "testV", 0, Ev, Gv, XX }, - /* 86 */ { "xchgB", 0, Eb, Gb, XX }, - /* 87 */ { "xchgV", 0, Ev, Gv, XX }, - /* 88 */ { "movB", 0, Eb, Gb, XX }, - /* 89 */ { "movV", 0, Ev, Gv, XX }, - /* 8A */ { "movB", 0, Gb, Eb, XX }, - /* 8B */ { "movV", 0, Gv, Ev, XX }, - /* 8C */ { "movW", 0, Ew, Sw, XX }, - /* 8D */ { "leaV", 0, Gv, Mv, XX }, - /* 8E */ { "movW", 0, Sw, Ew, XX }, - /* 8F */ { "popV", 0, Ev, XX, XX }, - /* 90 */ { "nop", 0, XX, XX, XX }, - /* 91 */ { "xchgV", 0, eCX, eAX, XX }, - /* 92 */ { "xchgV", 0, eDX, eAX, XX }, - /* 93 */ { "xchgV", 0, eBX, eAX, XX }, - /* 94 */ { "xchgV", 0, eSP, eAX, XX }, - /* 95 */ { "xchgV", 0, eBP, eAX, XX }, - /* 96 */ { "xchgV", 0, eSI, eAX, XX }, - /* 97 */ { "xchgV", 0, eDI, eAX, XX }, - /* 98 */ { "cbw|cwde", 0, XX, XX, XX }, - /* 99 */ { "cwd|cdq", 0, XX, XX, XX }, - /* 9A */ { "call far", 0, Ap, XX, XX }, - /* 9B */ { "fwait", 0, XX, XX, XX }, - /* 9C */ { "pushfD", 0, XX, XX, XX }, - /* 9D */ { "popfD", 0, XX, XX, XX }, - /* 9E */ { "sahf", 0, XX, XX, XX }, - /* 9F */ { "lahf", 0, XX, XX, XX }, - /* A0 */ { "movB", 0, AL, OX, XX }, - /* A1 */ { "movV", 0, eAX, OX, XX }, - /* A2 */ { "movB", 0, OX, AL, XX }, - /* A3 */ { "movV", 0, OX, eAX, XX }, - /* A4 */ { "movsb", 0, Yb, Xb, XX }, - /* A5 */ { "movsS", 0, Yv, Xv, XX }, - /* A6 */ { "cmpsb", 0, Yb, Xb, XX }, - /* A7 */ { "cmpsS", 0, Yv, Xv, XX }, - /* A8 */ { "testB", 0, AL, Ib, XX }, - /* A9 */ { "testV", 0, eAX, Iv, XX }, - /* AA */ { "stosb", 0, Yb, AL, XX }, - /* AB */ { "stosS", 0, Yv, eAX, XX }, - /* AC */ { "lodsb", 0, AL, Xb, XX }, - /* AD */ { "lodsS", 0, eAX, Xv, XX }, - /* AE */ { "scasb", 0, Yb, AL, XX }, - /* AF */ { "scasS", 0, Yv, eAX, XX }, - /* B0 */ { "movB", 0, AL, Ib, XX }, - /* B1 */ { "movB", 0, CL, Ib, XX }, - /* B2 */ { "movB", 0, DL, Ib, XX }, - /* B3 */ { "movB", 0, BL, Ib, XX }, - /* B4 */ { "movB", 0, AH, Ib, XX }, - /* B5 */ { "movB", 0, CH, Ib, XX }, - /* B6 */ { "movB", 0, DH, Ib, XX }, - /* B7 */ { "movB", 0, BH, Ib, XX }, - /* B8 */ { "movV", 0, eAX, Iv, XX }, - /* B9 */ { "movV", 0, eCX, Iv, XX }, - /* BA */ { "movV", 0, eDX, Iv, XX }, - /* BB */ { "movV", 0, eBX, Iv, XX }, - /* BC */ { "movV", 0, eSP, Iv, XX }, - /* BD */ { "movV", 0, eBP, Iv, XX }, - /* BE */ { "movV", 0, eSI, Iv, XX }, - /* BF */ { "movV", 0, eDI, Iv, XX }, - /* C0 */ { GRPN(G2Eb) }, - /* C1 */ { GRPN(G2Ev) }, - /* C2 */ { "retnW", 0, Iw, XX, XX }, - /* C3 */ { "retn", 0, XX, XX, XX }, - /* C4 */ { "les", 0, Gv, Mp, XX }, - /* C5 */ { "lds", 0, Gv, Mp, XX }, - /* C6 */ { "movB", 0, Eb, Ib, XX }, - /* C7 */ { "movV", 0, Ev, Iv, XX }, - /* C8 */ { "enter", 0, Iw, Ib, XX }, - /* C9 */ { "leave", 0, XX, XX, XX }, - /* CA */ { "retfW", 0, Iw, XX, XX }, - /* CB */ { "retf", 0, XX, XX, XX }, - /* CC */ { "int3", 0, XX, XX, XX }, - /* CD */ { "int", 0, Ib, XX, XX }, - /* CE */ { "into", 0, XX, XX, XX }, - /* CF */ { "iretD", 0, XX, XX, XX }, - /* D0 */ { GRPN(G2Eb1) }, - /* D1 */ { GRPN(G2Ev1) }, - /* D2 */ { GRPN(G2EbCL) }, - /* D3 */ { GRPN(G2EvCL) }, - /* D4 */ { "aam", 0, Ib, XX, XX }, - /* D5 */ { "aad", 0, Ib, XX, XX }, - /* D6 */ { "salc", 0, XX, XX, XX }, - /* D7 */ { "xlat", 0, XX, XX, XX }, - /* D8 */ { GRPFP(D8) }, - /* D9 */ { GRPFP(D9) }, - /* DA */ { GRPFP(DA) }, - /* DB */ { GRPFP(DB) }, - /* DC */ { GRPFP(DC) }, - /* DD */ { GRPFP(DD) }, - /* DE */ { GRPFP(DE) }, - /* DF */ { GRPFP(DF) }, - /* E0 */ { "loopne", 0, Jb, XX, XX }, - /* E1 */ { "loope", 0, Jb, XX, XX }, - /* E2 */ { "loop", 0, Jb, XX, XX }, - /* E3 */ { "jcxz", 0, Jb, XX, XX }, - /* E4 */ { "inB", 0, AL, Ib, XX }, - /* E5 */ { "inV", 0, eAX, Ib, XX }, - /* E6 */ { "outB", 0, Ib, AL, XX }, - /* E7 */ { "outV", 0, Ib, eAX, XX }, - /* E8 */ { "callV", 0, Jv, XX, XX }, - /* E9 */ { "jmpV", 0, Jv, XX, XX }, - /* EA */ { "jmp far", 0, Ap, XX, XX }, - /* EB */ { "jmpB", 0, Jb, XX, XX }, - /* EC */ { "inB", 0, AL, DX, XX }, - /* ED */ { "inV", 0, eAX, DX, XX }, - /* EE */ { "outB", 0, DX, AL, XX }, - /* EF */ { "outV", 0, DX, eAX, XX }, - /* F0 */ { PREFIX_LOCK }, // LOCK: - /* F1 */ { "int1", 0, XX, XX, XX }, - /* F2 */ { PREFIX_REPNE }, // REPNE: - /* F3 */ { PREFIX_REP }, // REP: - /* F4 */ { "hlt", 0, XX, XX, XX }, - /* F5 */ { "cmc", 0, XX, XX, XX }, - /* F6 */ { GRPN(G3Eb) }, - /* F7 */ { GRPN(G3Ev) }, - /* F8 */ { "clc", 0, XX, XX, XX }, - /* F9 */ { "stc", 0, XX, XX, XX }, - /* FA */ { "cli", 0, XX, XX, XX }, - /* FB */ { "sti", 0, XX, XX, XX }, - /* FC */ { "cld", 0, XX, XX, XX }, - /* FD */ { "std", 0, XX, XX, XX }, - /* FE */ { GRPN(G4) }, - /* FF */ { GRPN(G5) }, - - // 256 entries for two byte opcodes - /* 0F 00 */ { GRPN(G6) }, - /* 0F 01 */ { GRPN(G7) }, - /* 0F 02 */ { "larV", 0, Gv, Ew, XX }, - /* 0F 03 */ { "lslV", 0, Gv, Ew, XX }, - /* 0F 04 */ { INVALID }, - /* 0F 05 */ { "syscall", 0, XX, XX, XX }, - /* 0F 06 */ { "clts", 0, XX, XX, XX }, - /* 0F 07 */ { "sysret", 0, XX, XX, XX }, - /* 0F 08 */ { "invd", 0, XX, XX, XX }, - /* 0F 09 */ { "wbinvd", 0, XX, XX, XX }, - /* 0F 0A */ { INVALID }, - /* 0F 0B */ { "ud2a", 0, XX, XX, XX }, - /* 0F 0C */ { INVALID }, - /* 0F 0D */ { "prefetch", 0, Mb, XX, XX }, // 3DNow! - /* 0F 0E */ { "femms", 0, XX, XX, XX }, // 3DNow! - /* 0F 0F */ { GRP3DNOW }, - /* 0F 10 */ { GRPSSE(0f10) }, - /* 0F 11 */ { GRPSSE(0f11) }, - /* 0F 12 */ { GRPSSE(0f12) }, - /* 0F 13 */ { GRPSSE(0f13) }, - /* 0F 14 */ { GRPSSE(0f14) }, - /* 0F 15 */ { GRPSSE(0f15) }, - /* 0F 16 */ { GRPSSE(0f16) }, - /* 0F 17 */ { GRPSSE(0f17) }, - /* 0F 18 */ { GRPN(G16) }, - /* 0F 19 */ { INVALID }, - /* 0F 1A */ { INVALID }, - /* 0F 1B */ { INVALID }, - /* 0F 1C */ { INVALID }, - /* 0F 1D */ { INVALID }, - /* 0F 1E */ { INVALID }, - /* 0F 1F */ { INVALID }, - /* 0F 20 */ { "mov", 0, Rd, Cd, XX }, - /* 0F 21 */ { "mov", 0, Rd, Dd, XX }, - /* 0F 22 */ { "mov", 0, Cd, Rd, XX }, - /* 0F 23 */ { "mov", 0, Dd, Rd, XX }, - /* 0F 24 */ { "mov", 0, Rd, Td, XX }, - /* 0F 25 */ { INVALID }, - /* 0F 26 */ { "mov", 0, Td, Rd, XX }, - /* 0F 27 */ { INVALID }, - /* 0F 28 */ { GRPSSE(0f28) }, - /* 0F 29 */ { GRPSSE(0f29) }, - /* 0F 2A */ { GRPSSE(0f2a) }, - /* 0F 2B */ { GRPSSE(0f2b) }, - /* 0F 2C */ { GRPSSE(0f2c) }, - /* 0F 2D */ { GRPSSE(0f2d) }, - /* 0F 2E */ { GRPSSE(0f2e) }, - /* 0F 2F */ { GRPSSE(0f2f) }, - /* 0F 30 */ { "wrmsr", 0, XX, XX, XX }, - /* 0F 31 */ { "rdtsc", 0, XX, XX, XX }, - /* 0F 32 */ { "rdmsr", 0, XX, XX, XX }, - /* 0F 33 */ { "rdpmc", 0, XX, XX, XX }, - /* 0F 34 */ { "sysenter", 0, XX, XX, XX }, - /* 0F 35 */ { "sysexit", 0, XX, XX, XX }, - /* 0F 36 */ { INVALID }, - /* 0F 37 */ { INVALID }, - /* 0F 38 */ { INVALID }, - /* 0F 39 */ { INVALID }, - /* 0F 3A */ { INVALID }, - /* 0F 3B */ { INVALID }, - /* 0F 3C */ { INVALID }, - /* 0F 3D */ { INVALID }, - /* 0F 3E */ { INVALID }, - /* 0F 3F */ { INVALID }, - /* 0F 40 */ { "cmovo", 0, Gv, Ev, XX }, - /* 0F 41 */ { "cmovno", 0, Gv, Ev, XX }, - /* 0F 42 */ { "cmovc", 0, Gv, Ev, XX }, - /* 0F 43 */ { "cmovnc", 0, Gv, Ev, XX }, - /* 0F 44 */ { "cmovz", 0, Gv, Ev, XX }, - /* 0F 45 */ { "cmovnz", 0, Gv, Ev, XX }, - /* 0F 46 */ { "cmovna", 0, Gv, Ev, XX }, - /* 0F 47 */ { "cmova", 0, Gv, Ev, XX }, - /* 0F 48 */ { "cmovs", 0, Gv, Ev, XX }, - /* 0F 49 */ { "cmovns", 0, Gv, Ev, XX }, - /* 0F 4A */ { "cmovp", 0, Gv, Ev, XX }, - /* 0F 4B */ { "cmocnp", 0, Gv, Ev, XX }, - /* 0F 4C */ { "cmovl", 0, Gv, Ev, XX }, - /* 0F 4D */ { "cmovnl", 0, Gv, Ev, XX }, - /* 0F 4E */ { "cmovng", 0, Gv, Ev, XX }, - /* 0F 4F */ { "cmovg", 0, Gv, Ev, XX }, - /* 0F 50 */ { GRPSSE(0f50) }, - /* 0F 51 */ { GRPSSE(0f51) }, - /* 0F 52 */ { GRPSSE(0f52) }, - /* 0F 53 */ { GRPSSE(0f53) }, - /* 0F 54 */ { GRPSSE(0f54) }, - /* 0F 55 */ { GRPSSE(0f55) }, - /* 0F 56 */ { GRPSSE(0f56) }, - /* 0F 57 */ { GRPSSE(0f57) }, - /* 0F 58 */ { GRPSSE(0f58) }, - /* 0F 59 */ { GRPSSE(0f59) }, - /* 0F 5A */ { GRPSSE(0f5a) }, - /* 0F 5B */ { GRPSSE(0f5b) }, - /* 0F 5C */ { GRPSSE(0f5c) }, - /* 0F 5D */ { GRPSSE(0f5d) }, - /* 0F 5E */ { GRPSSE(0f5e) }, - /* 0F 5F */ { GRPSSE(0f5f) }, - /* 0F 60 */ { GRPSSE(0f60) }, - /* 0F 61 */ { GRPSSE(0f61) }, - /* 0F 62 */ { GRPSSE(0f62) }, - /* 0F 63 */ { GRPSSE(0f63) }, - /* 0F 64 */ { GRPSSE(0f64) }, - /* 0F 65 */ { GRPSSE(0f65) }, - /* 0F 66 */ { GRPSSE(0f66) }, - /* 0F 67 */ { GRPSSE(0f67) }, - /* 0F 68 */ { GRPSSE(0f68) }, - /* 0F 69 */ { GRPSSE(0f69) }, - /* 0F 6A */ { GRPSSE(0f6a) }, - /* 0F 6B */ { GRPSSE(0f6b) }, - /* 0F 6C */ { GRPSSE(0f6c) }, - /* 0F 6D */ { GRPSSE(0f6d) }, - /* 0F 6E */ { GRPSSE(0f6e) }, - /* 0F 6F */ { GRPSSE(0f6f) }, - /* 0F 70 */ { GRPSSE(0f70) }, - /* 0F 71 */ { GRPN(G12) }, - /* 0F 72 */ { GRPN(G13) }, - /* 0F 73 */ { GRPN(G14) }, - /* 0F 74 */ { GRPSSE(0f74) }, - /* 0F 75 */ { GRPSSE(0f75) }, - /* 0F 76 */ { GRPSSE(0f76) }, - /* 0F 77 */ { "emms", 0, XX, XX, XX }, - /* 0F 78 */ { INVALID }, - /* 0F 79 */ { INVALID }, - /* 0F 7A */ { INVALID }, - /* 0F 7B */ { INVALID }, - /* 0F 7C */ { GRPSSE(0f7c) }, - /* 0F 7D */ { GRPSSE(0f7d) }, - /* 0F 7E */ { GRPSSE(0f7e) }, - /* 0F 7F */ { GRPSSE(0f7f) }, - /* 0F 80 */ { "jo", 0, Jv, XX, Cond_Jump }, - /* 0F 81 */ { "jno", 0, Jv, XX, Cond_Jump }, - /* 0F 82 */ { "jb", 0, Jv, XX, Cond_Jump }, - /* 0F 83 */ { "jnb", 0, Jv, XX, Cond_Jump }, - /* 0F 84 */ { "jz", 0, Jv, XX, Cond_Jump }, - /* 0F 85 */ { "jnz", 0, Jv, XX, Cond_Jump }, - /* 0F 86 */ { "jbe", 0, Jv, XX, Cond_Jump }, - /* 0F 87 */ { "jnbe", 0, Jv, XX, Cond_Jump }, - /* 0F 88 */ { "js", 0, Jv, XX, Cond_Jump }, - /* 0F 89 */ { "jns", 0, Jv, XX, Cond_Jump }, - /* 0F 8A */ { "jp", 0, Jv, XX, Cond_Jump }, - /* 0F 8B */ { "jnp", 0, Jv, XX, Cond_Jump }, - /* 0F 8C */ { "jl", 0, Jv, XX, Cond_Jump }, - /* 0F 8D */ { "jnl", 0, Jv, XX, Cond_Jump }, - /* 0F 8E */ { "jle", 0, Jv, XX, Cond_Jump }, - /* 0F 8F */ { "jnle", 0, Jv, XX, Cond_Jump }, - /* 0F 90 */ { "setoB", 0, Eb, XX, XX }, - /* 0F 91 */ { "setnoB", 0, Eb, XX, XX }, - /* 0F 92 */ { "setbB", 0, Eb, XX, XX }, - /* 0F 93 */ { "setnbB", 0, Eb, XX, XX }, - /* 0F 94 */ { "setzB", 0, Eb, XX, XX }, - /* 0F 95 */ { "setnzB", 0, Eb, XX, XX }, - /* 0F 96 */ { "setbeB", 0, Eb, XX, XX }, - /* 0F 97 */ { "setnbeB", 0, Eb, XX, XX }, - /* 0F 98 */ { "setsB", 0, Eb, XX, XX }, - /* 0F 99 */ { "setnsB", 0, Eb, XX, XX }, - /* 0F 9A */ { "setpB", 0, Eb, XX, XX }, - /* 0F 9B */ { "setnpB", 0, Eb, XX, XX }, - /* 0F 9C */ { "setlB", 0, Eb, XX, XX }, - /* 0F 9D */ { "setnlB", 0, Eb, XX, XX }, - /* 0F 9E */ { "setleB", 0, Eb, XX, XX }, - /* 0F 9F */ { "setnleB", 0, Eb, XX, XX }, - /* 0F A0 */ { "pushV", 0, FS, XX, XX }, - /* 0F A1 */ { "popV", 0, FS, XX, XX }, - /* 0F A2 */ { "cpuid", 0, XX, XX, XX }, - /* 0F A3 */ { "btV", 0, Ev, Gv, XX }, - /* 0F A4 */ { "shldV", 0, Ev, Gv, Ib }, - /* 0F A5 */ { "shldV", 0, Ev, Gv, CL }, - /* 0F A6 */ { INVALID }, - /* 0F A7 */ { INVALID }, - /* 0F A8 */ { "pushV", 0, GS, XX, XX }, - /* 0F A9 */ { "popV", 0, GS, XX, XX }, - /* 0F AA */ { "rsm", 0, XX, XX, XX }, - /* 0F AB */ { "btsV", 0, Ev, Gv, XX }, - /* 0F AC */ { "shrdV", 0, Ev, Gv, Ib }, - /* 0F AD */ { "shrdV", 0, Ev, Gv, CL }, - /* 0F AE */ { GRPN(G15) }, - /* 0F AF */ { "imulV", 0, Gv, Ev, XX }, - /* 0F B0 */ { "cmpxchgB", 0, Eb, Gb, XX }, - /* 0F B1 */ { "cmpxchgV", 0, Ev, Gv, XX }, - /* 0F B2 */ { "lss", 0, Gv, Mp, XX }, - /* 0F B3 */ { "btrV", 0, Ev, Gv, XX }, - /* 0F B4 */ { "lfs", 0, Gv, Mp, XX }, - /* 0F B5 */ { "lgs", 0, Gv, Mp, XX }, - /* 0F B6 */ { "movzX", 0, Gv, Eb, XX }, - /* 0F B7 */ { "movzX", 0, Gv, Ew, XX }, - /* 0F B8 */ { INVALID }, - /* 0F B9 */ { "ud2b", 0, XX, XX, XX }, - /* 0F BA */ { GRPN(G8EvIb) }, - /* 0F BB */ { "btcV", 0, Ev, Gv, XX }, - /* 0F BC */ { "bsfV", 0, Gv, Ev, XX }, - /* 0F BD */ { "bsrV", 0, Gv, Ev, XX }, - /* 0F BE */ { "movsX", 0, Gv, Eb, XX }, - /* 0F BF */ { "movsX", 0, Gv, Ew, XX }, - /* 0F C0 */ { "xaddB", 0, Eb, Gb, XX }, - /* 0F C1 */ { "xaddV", 0, Ev, Gv, XX }, - /* 0F C2 */ { GRPSSE(0fc2) }, - /* 0F C3 */ { GRPSSE(0fc3) }, - /* 0F C4 */ { GRPSSE(0fc4) }, - /* 0F C5 */ { GRPSSE(0fc5) }, - /* 0F C6 */ { GRPSSE(0fc6) }, - /* 0F C7 */ { GRPN(G9) }, - /* 0F C8 */ { "bswapV", 0, eAX, XX, XX }, - /* 0F C9 */ { "bswapV", 0, eCX, XX, XX }, - /* 0F CA */ { "bswapV", 0, eDX, XX, XX }, - /* 0F CB */ { "bswapV", 0, eBX, XX, XX }, - /* 0F CC */ { "bswapV", 0, eSP, XX, XX }, - /* 0F CD */ { "bswapV", 0, eBP, XX, XX }, - /* 0F CE */ { "bswapV", 0, eSI, XX, XX }, - /* 0F CF */ { "bswapV", 0, eDI, XX, XX }, - /* 0F D0 */ { GRPSSE(0fd0) }, - /* 0F D1 */ { GRPSSE(0fd1) }, - /* 0F D2 */ { GRPSSE(0fd2) }, - /* 0F D3 */ { GRPSSE(0fd3) }, - /* 0F D4 */ { GRPSSE(0fd4) }, - /* 0F D5 */ { GRPSSE(0fd5) }, - /* 0F D6 */ { GRPSSE(0fd6) }, - /* 0F D7 */ { GRPSSE(0fd7) }, - /* 0F D8 */ { GRPSSE(0fd8) }, - /* 0F D9 */ { GRPSSE(0fd9) }, - /* 0F DA */ { GRPSSE(0fda) }, - /* 0F DB */ { GRPSSE(0fdb) }, - /* 0F DC */ { GRPSSE(0fdc) }, - /* 0F DD */ { GRPSSE(0fdd) }, - /* 0F DE */ { GRPSSE(0fde) }, - /* 0F DF */ { GRPSSE(0fdf) }, - /* 0F E0 */ { GRPSSE(0fe0) }, - /* 0F E1 */ { GRPSSE(0fe1) }, - /* 0F E2 */ { GRPSSE(0fe2) }, - /* 0F E3 */ { GRPSSE(0fe3) }, - /* 0F E4 */ { GRPSSE(0fe4) }, - /* 0F E5 */ { GRPSSE(0fe5) }, - /* 0F E6 */ { GRPSSE(0fe6) }, - /* 0F E7 */ { GRPSSE(0fe7) }, - /* 0F E8 */ { GRPSSE(0fe8) }, - /* 0F E9 */ { GRPSSE(0fe9) }, - /* 0F EA */ { GRPSSE(0fea) }, - /* 0F EB */ { GRPSSE(0feb) }, - /* 0F EC */ { GRPSSE(0fec) }, - /* 0F ED */ { GRPSSE(0fed) }, - /* 0F EE */ { GRPSSE(0fee) }, - /* 0F EF */ { GRPSSE(0fef) }, - /* 0F F0 */ { GRPSSE(0ff0) }, - /* 0F F1 */ { GRPSSE(0ff1) }, - /* 0F F2 */ { GRPSSE(0ff2) }, - /* 0F F3 */ { GRPSSE(0ff3) }, - /* 0F F4 */ { GRPSSE(0ff4) }, - /* 0F F5 */ { GRPSSE(0ff5) }, - /* 0F F6 */ { GRPSSE(0ff6) }, - /* 0F F7 */ { GRPSSE(0ff7) }, - /* 0F F8 */ { GRPSSE(0ff8) }, - /* 0F F9 */ { GRPSSE(0ff9) }, - /* 0F FA */ { GRPSSE(0ffa) }, - /* 0F FB */ { GRPSSE(0ffb) }, - /* 0F FC */ { GRPSSE(0ffc) }, - /* 0F FD */ { GRPSSE(0ffd) }, - /* 0F FE */ { GRPSSE(0ffe) }, - /* 0F FF */ { INVALID } -}; +#define Apw &disassembler::Apw +#define Apd &disassembler::Apd + +#define AL &disassembler::AL +#define CL &disassembler::CL +#define AX &disassembler::AX +#define DX &disassembler::DX + +#define EAX &disassembler::EAX +#define RAX &disassembler::RAX + +#define CS &disassembler::CS +#define DS &disassembler::DS +#define ES &disassembler::ES +#define SS &disassembler::SS +#define FS &disassembler::FS +#define GS &disassembler::GS + +#define Sw &disassembler::Sw + +#define Td &disassembler::Td + +#define Cd &disassembler::Cd +#define Cq &disassembler::Cq + +#define Dd &disassembler::Dd +#define Dq &disassembler::Dq + +#define R8 &disassembler::R8 +#define RX &disassembler::RX +#define ERX &disassembler::ERX +#define RRX &disassembler::RRX + +#define Eb &disassembler::Eb +#define Ew &disassembler::Ew +#define Ed &disassembler::Ed +#define Eq &disassembler::Eq + +#define Gb &disassembler::Gb +#define Gw &disassembler::Gw +#define Gd &disassembler::Gd +#define Gq &disassembler::Gq + +#define I1 &disassembler::I1 +#define Ib &disassembler::Ib +#define Iw &disassembler::Iw +#define Id &disassembler::Id +#define Iq &disassembler::Iq + +#define sIbw &disassembler::sIbw +#define sIbd &disassembler::sIbd +#define sIbq &disassembler::sIbq +#define sIdq &disassembler::sIdq + +#define ST0 &disassembler::ST0 +#define STi &disassembler::STi + +#define Rw &disassembler::Rw +#define Rd &disassembler::Rd +#define Rq &disassembler::Rq + +#define Pq &disassembler::Pq +#define Qd &disassembler::Qd +#define Qq &disassembler::Qq + +#define Vq &disassembler::Vq +#define Vdq &disassembler::Vdq +#define Vss &disassembler::Vss +#define Vsd &disassembler::Vsd +#define Vps &disassembler::Vps +#define Vpd &disassembler::Vpd + +#define Wq &disassembler::Wq +#define Wdq &disassembler::Wdq +#define Wss &disassembler::Wss +#define Wsd &disassembler::Wsd +#define Wps &disassembler::Wps +#define Wpd &disassembler::Wpd + +#define Ob &disassembler::Ob +#define Ow &disassembler::Ow +#define Od &disassembler::Od +#define Oq &disassembler::Oq + +#define Ma &disassembler::Ma +#define Mp &disassembler::Mp +#define Ms &disassembler::Ms +#define Mx &disassembler::Mx +#define Mb &disassembler::Mb +#define Mw &disassembler::Mw +#define Md &disassembler::Md +#define Mq &disassembler::Mq +#define Mt &disassembler::Mt +#define Mdq &disassembler::Mdq +#define Mps &disassembler::Mps +#define Mpd &disassembler::Mpd + +#define Xb &disassembler::Xb +#define Xw &disassembler::Xw +#define Xd &disassembler::Xd +#define Xq &disassembler::Xq + +#define Yb &disassembler::Yb +#define Yw &disassembler::Yw +#define Yd &disassembler::Yd +#define Yq &disassembler::Yq + +#define Jb &disassembler::Jb +#define Jw &disassembler::Jw +#define Jd &disassembler::Jd + +#define XX 0 + +const struct BxDisasmOpcodeInfo_t +#include "opcodes.inc" +#include "dis_tables.inc" #undef XX diff --git a/bochs/disasm/dis_tables.inc b/bochs/disasm/dis_tables.inc new file mode 100755 index 000000000..d992e0aee --- /dev/null +++ b/bochs/disasm/dis_tables.inc @@ -0,0 +1,4804 @@ +/* ************************************************************************ */ +/* SSE opcodes */ + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f10[4] = { + /* -- */ { 0, &Ia_movups_Vps_Wps }, + /* 66 */ { 0, &Ia_movupd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_movsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_movss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f11[4] = { + /* -- */ { 0, &Ia_movups_Wps_Vps }, + /* 66 */ { 0, &Ia_movupd_Wpd_Vpd }, + /* F2 */ { 0, &Ia_movsd_Wsd_Vsd }, + /* F3 */ { 0, &Ia_movss_Wss_Vss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f12[4] = { + /* -- */ { 0, &Ia_movlps_Vps_Mq }, + /* 66 */ { 0, &Ia_movlpd_Vpd_Mq }, + /* F2 */ { 0, &Ia_movddup_Vdq_Wq }, + /* F3 */ { 0, &Ia_movsldup_Vdq_Wdq } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f13[4] = { + /* -- */ { 0, &Ia_movlps_Mq_Vps }, + /* 66 */ { 0, &Ia_movlpd_Mq_Vpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f14[4] = { + /* -- */ { 0, &Ia_unpcklps_Vps_Wq }, + /* 66 */ { 0, &Ia_unpcklpd_Vpd_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f15[4] = { + /* -- */ { 0, &Ia_unpckhps_Vps_Wq }, + /* 66 */ { 0, &Ia_unpckhpd_Vpd_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f16[4] = { + /* -- */ { 0, &Ia_movhps_Vps_Mq }, + /* 66 */ { 0, &Ia_movhpd_Vpd_Mq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_movshdup_Vdq_Wdq }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f17[4] = { + /* -- */ { 0, &Ia_movhps_Mq_Vps }, + /* 66 */ { 0, &Ia_movhpd_Mq_Vpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f28[4] = { + /* -- */ { 0, &Ia_movaps_Vps_Wps }, + /* 66 */ { 0, &Ia_movapd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f29[4] = { + /* -- */ { 0, &Ia_movaps_Wps_Vps }, + /* 66 */ { 0, &Ia_movapd_Wpd_Vpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f2a[4] = { + /* -- */ { 0, &Ia_cvtpi2ps_Vps_Qq }, + /* 66 */ { 0, &Ia_cvtpi2pd_Vpd_Qq }, + /* F2 */ { 0, &Ia_cvtsi2sd_Vsd_Ed }, + /* F3 */ { 0, &Ia_cvtsi2ss_Vss_Ed } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_640f2a[4] = { + /* -- */ { 0, &Ia_cvtpi2ps_Vps_Qq }, + /* 66 */ { 0, &Ia_cvtpi2pd_Vpd_Qq }, + /* F2 */ { 0, &Ia_cvtsi2sd_Vsd_Eq }, + /* F3 */ { 0, &Ia_cvtsi2ss_Vss_Eq } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f2b[4] = { + /* -- */ { 0, &Ia_movntps_Mps_Vps }, + /* 66 */ { 0, &Ia_movntpd_Mpd_Vpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f2c[4] = { + /* -- */ { 0, &Ia_cvtps2pi_Pq_Wps }, + /* 66 */ { 0, &Ia_cvtpd2pi_Pq_Wpd }, + /* F2 */ { 0, &Ia_cvtsd2si_Gd_Wsd }, + /* F3 */ { 0, &Ia_cvtss2ss_Gd_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f2d[4] = { + /* -- */ { 0, &Ia_cvtps2pi_Pq_Wps }, + /* 66 */ { 0, &Ia_cvtpd2pi_Pq_Wpd }, + /* F2 */ { 0, &Ia_cvtsd2si_Gd_Wsd }, + /* F3 */ { 0, &Ia_cvtss2si_Gd_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f2e[4] = { + /* -- */ { 0, &Ia_ucomiss_Vss_Wss }, + /* 66 */ { 0, &Ia_ucomisd_Vsd_Wss }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f2f[4] = { + /* -- */ { 0, &Ia_comiss_Vss_Wss }, + /* 66 */ { 0, &Ia_comisd_Vsd_Wsd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f50[4] = { + /* -- */ { 0, &Ia_movmskps_Gd_Vps }, + /* 66 */ { 0, &Ia_movmskpd_Gd_Vpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f51[4] = { + /* -- */ { 0, &Ia_sqrtps_Vps_Wps }, + /* 66 */ { 0, &Ia_sqrtpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_sqrtsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_sqrtss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f52[4] = { + /* -- */ { 0, &Ia_rsqrtps_Vps_Wps }, + /* 66 */ { 0, &Ia_Invalid }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_rsqrtss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f53[4] = { + /* -- */ { 0, &Ia_rcpps_Vps_Wps }, + /* 66 */ { 0, &Ia_Invalid }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_rcpss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f54[4] = { + /* -- */ { 0, &Ia_andps_Vps_Wps }, + /* 66 */ { 0, &Ia_andpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f55[4] = { + /* -- */ { 0, &Ia_andnps_Vps_Wps }, + /* 66 */ { 0, &Ia_andnpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f56[4] = { + /* -- */ { 0, &Ia_orps_Vps_Wps }, + /* 66 */ { 0, &Ia_orpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f57[4] = { + /* -- */ { 0, &Ia_xorps_Vps_Wps }, + /* 66 */ { 0, &Ia_xorpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f58[4] = { + /* -- */ { 0, &Ia_addps_Vps_Wps }, + /* 66 */ { 0, &Ia_addpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_addsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_addss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f59[4] = { + /* -- */ { 0, &Ia_mulps_Vps_Wps }, + /* 66 */ { 0, &Ia_mulpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_mulsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_mulss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f5a[4] = { + /* -- */ { 0, &Ia_cvtps2pd_Vpd_Wps }, + /* 66 */ { 0, &Ia_cvtpd2ps_Vps_Wpd }, + /* F2 */ { 0, &Ia_cvtsd2ss_Vss_Wsd }, + /* F3 */ { 0, &Ia_cvtss2sd_Vsd_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f5b[4] = { + /* -- */ { 0, &Ia_cvtdq2ps_Vps_Wdq }, + /* 66 */ { 0, &Ia_cvtps2dq_Vdq_Wps }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_cvttps2dq_Vdq_Wps } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f5c[4] = { + /* -- */ { 0, &Ia_subps_Vps_Wps }, + /* 66 */ { 0, &Ia_subpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_subsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_subss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f5d[4] = { + /* -- */ { 0, &Ia_minps_Vps_Wps }, + /* 66 */ { 0, &Ia_minpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_minsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_minss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f5e[4] = { + /* -- */ { 0, &Ia_divps_Vps_Wps }, + /* 66 */ { 0, &Ia_divpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_divsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_divss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f5f[4] = { + /* -- */ { 0, &Ia_maxps_Vps_Wps }, + /* 66 */ { 0, &Ia_maxpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_maxsd_Vsd_Wsd }, + /* F3 */ { 0, &Ia_maxss_Vss_Wss } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f60[4] = { + /* -- */ { 0, &Ia_punpcklbw_Pq_Qd }, + /* 66 */ { 0, &Ia_punpcklbw_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f61[4] = { + /* -- */ { 0, &Ia_punpcklwd_Pq_Qd }, + /* 66 */ { 0, &Ia_punpcklwd_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f62[4] = { + /* -- */ { 0, &Ia_punpckldq_Pq_Qd }, + /* 66 */ { 0, &Ia_punpckldq_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f63[4] = { + /* -- */ { 0, &Ia_packsswb_Pq_Qq }, + /* 66 */ { 0, &Ia_packsswb_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f64[4] = { + /* -- */ { 0, &Ia_pcmpgtb_Pq_Qq }, + /* 66 */ { 0, &Ia_pcmpgtb_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f65[4] = { + /* -- */ { 0, &Ia_pcmpgtw_Pq_Qq }, + /* 66 */ { 0, &Ia_pcmpgtw_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f66[4] = { + /* -- */ { 0, &Ia_pcmpgtd_Pq_Qq }, + /* 66 */ { 0, &Ia_pcmpgtd_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f67[4] = { + /* -- */ { 0, &Ia_packuswb_Pq_Qq }, + /* 66 */ { 0, &Ia_packuswb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f68[4] = { + /* -- */ { 0, &Ia_punpckhbw_Pq_Qq }, + /* 66 */ { 0, &Ia_punpckhbw_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f69[4] = { + /* -- */ { 0, &Ia_punpckhwd_Pq_Qq }, + /* 66 */ { 0, &Ia_punpckhwd_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f6a[4] = { + /* -- */ { 0, &Ia_punpckhdq_Pq_Qq }, + /* 66 */ { 0, &Ia_punpckhdq_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f6b[4] = { + /* -- */ { 0, &Ia_packssdw_Pq_Qq }, + /* 66 */ { 0, &Ia_packssdw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f6c[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_punpcklqdq_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f6d[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_punpckhqdq_Vdq_Wq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f6e[4] = { + /* -- */ { 0, &Ia_movd_Pq_Ed }, + /* 66 */ { 0, &Ia_movd_Vdq_Ed }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f6f[4] = { + /* -- */ { 0, &Ia_movq_Pq_Qq }, + /* 66 */ { 0, &Ia_movdqa_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_movdqu_Vdq_Wdq }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f70[4] = { + /* -- */ { 0, &Ia_pshufw_Pq_Qq_Ib }, + /* 66 */ { 0, &Ia_pshufd_Vdq_Wdq_Ib }, + /* F2 */ { 0, &Ia_pshufhw_Vq_Wq_Ib }, + /* F3 */ { 0, &Ia_pshuflw_Vq_Wq_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f74[4] = { + /* -- */ { 0, &Ia_pcmpeqb_Pq_Qq }, + /* 66 */ { 0, &Ia_pcmpeqb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f75[4] = { + /* -- */ { 0, &Ia_pcmpeqw_Pq_Qq }, + /* 66 */ { 0, &Ia_pcmpeqw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f76[4] = { + /* -- */ { 0, &Ia_pcmpeqd_Pq_Qq }, + /* 66 */ { 0, &Ia_pcmpeqd_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f7c[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_haddpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_haddps_Vps_Wps }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f7d[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_hsubpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_hsubps_Vps_Wps }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f7e[4] = { + /* -- */ { 0, &Ia_movd_Ed_Pq }, + /* 66 */ { 0, &Ia_movd_Ed_Vd }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_movq_Vq_Wq }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0f7f[4] = { + /* -- */ { 0, &Ia_movq_Qq_Pq }, + /* 66 */ { 0, &Ia_movdqa_Wdq_Vdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_movdqu_Wdq_Vdq }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fc2[4] = { + /* -- */ { 0, &Ia_cmpps_Vps_Wps_Ib }, + /* 66 */ { 0, &Ia_cmppd_Vpd_Wpd_Ib }, + /* F2 */ { 0, &Ia_cmpsd_Vsd_Wsd_Ib }, + /* F3 */ { 0, &Ia_cmpss_Vss_Wss_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fc3[4] = { + /* -- */ { 0, &Ia_movnti_Md_Gd }, + /* 66 */ { 0, &Ia_Invalid }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_640fc3[4] = { + /* -- */ { 0, &Ia_movntiq_Mq_Gq }, + /* 66 */ { 0, &Ia_Invalid }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fc4[4] = { + /* -- */ { 0, &Ia_pinsrw_Pq_Ed_Ib }, + /* 66 */ { 0, &Ia_pinsrw_Vdq_Ed_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fc5[4] = { + /* -- */ { 0, &Ia_pextrw_Gd_Pq_Ib }, + /* 66 */ { 0, &Ia_pextrw_Gd_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fc6[4] = { + /* -- */ { 0, &Ia_shufps_Vps_Wps_Ib }, + /* 66 */ { 0, &Ia_shufpd_Vpd_Wpd_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd0[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_addsubpd_Vpd_Wpd }, + /* F2 */ { 0, &Ia_addsubps_Vps_Wps }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd1[4] = { + /* -- */ { 0, &Ia_psrlw_Pq_Qq }, + /* 66 */ { 0, &Ia_psrlw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd2[4] = { + /* -- */ { 0, &Ia_psrld_Pq_Qq }, + /* 66 */ { 0, &Ia_psrld_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd3[4] = { + /* -- */ { 0, &Ia_psrlq_Pq_Qq }, + /* 66 */ { 0, &Ia_psrlq_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd4[4] = { + /* -- */ { 0, &Ia_paddq_Pq_Qq }, + /* 66 */ { 0, &Ia_paddq_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd5[4] = { + /* -- */ { 0, &Ia_pmullw_Pq_Qq }, + /* 66 */ { 0, &Ia_pmullw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd6[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_movq_Wq_Vq }, + /* F2 */ { 0, &Ia_movdq2q_Pq_Vq }, + /* F3 */ { 0, &Ia_movq2dq_Vdq_Qq }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd7[4] = { + /* -- */ { 0, &Ia_pmovmskb_Gd_Pq }, + /* 66 */ { 0, &Ia_pmovmskb_Gd_Vdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd8[4] = { + /* -- */ { 0, &Ia_psubusb_Pq_Qq }, + /* 66 */ { 0, &Ia_psubusb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fd9[4] = { + /* -- */ { 0, &Ia_psubusw_Pq_Qq }, + /* 66 */ { 0, &Ia_psubusw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fda[4] = { + /* -- */ { 0, &Ia_pminub_Pq_Qq }, + /* 66 */ { 0, &Ia_pminub_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fdb[4] = { + /* -- */ { 0, &Ia_pand_Pq_Qq }, + /* 66 */ { 0, &Ia_pand_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fdc[4] = { + /* -- */ { 0, &Ia_paddusb_Pq_Qq }, + /* 66 */ { 0, &Ia_paddusb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fdd[4] = { + /* -- */ { 0, &Ia_paddusw_Pq_Qq }, + /* 66 */ { 0, &Ia_paddusw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fde[4] = { + /* -- */ { 0, &Ia_pmaxub_Pq_Qq }, + /* 66 */ { 0, &Ia_pmaxub_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fdf[4] = { + /* -- */ { 0, &Ia_pandn_Pq_Qq }, + /* 66 */ { 0, &Ia_pandn_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe0[4] = { + /* -- */ { 0, &Ia_pavgb_Pq_Qq }, + /* 66 */ { 0, &Ia_pavgb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe1[4] = { + /* -- */ { 0, &Ia_psraw_Pq_Qq }, + /* 66 */ { 0, &Ia_psraw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe2[4] = { + /* -- */ { 0, &Ia_psrad_Pq_Qq }, + /* 66 */ { 0, &Ia_psrad_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe3[4] = { + /* -- */ { 0, &Ia_pavgw_Pq_Qq }, + /* 66 */ { 0, &Ia_pavgw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe4[4] = { + /* -- */ { 0, &Ia_pmulhuw_Pq_Qq }, + /* 66 */ { 0, &Ia_pmulhuw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe5[4] = { + /* -- */ { 0, &Ia_pmulhw_Pq_Qq }, + /* 66 */ { 0, &Ia_pmulhw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe6[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_cvttpd2dq_Vq_Wpd }, + /* F2 */ { 0, &Ia_cvtpd2dq_Vq_Wpd }, + /* F3 */ { 0, &Ia_cvtdq2pd_Vpd_Wq } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe7[4] = { + /* -- */ { 0, &Ia_movntq_Mq_Pq }, + /* 66 */ { 0, &Ia_movntdq_Mdq_Vdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe8[4] = { + /* -- */ { 0, &Ia_psubsb_Pq_Qq }, + /* 66 */ { 0, &Ia_psubsb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fe9[4] = { + /* -- */ { 0, &Ia_psubsw_Pq_Qq }, + /* 66 */ { 0, &Ia_psubsw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fea[4] = { + /* -- */ { 0, &Ia_pminsw_Pq_Qq }, + /* 66 */ { 0, &Ia_pminsw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0feb[4] = { + /* -- */ { 0, &Ia_por_Pq_Qq }, + /* 66 */ { 0, &Ia_por_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fec[4] = { + /* -- */ { 0, &Ia_paddsb_Pq_Qq }, + /* 66 */ { 0, &Ia_paddsb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fed[4] = { + /* -- */ { 0, &Ia_paddsw_Pq_Qq }, + /* 66 */ { 0, &Ia_paddsw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fee[4] = { + /* -- */ { 0, &Ia_pmaxuw_Pq_Qq }, + /* 66 */ { 0, &Ia_pmaxuw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0fef[4] = { + /* -- */ { 0, &Ia_pxor_Pq_Qq }, + /* 66 */ { 0, &Ia_pxor_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff0[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_lddqu_Vdq_Mdq }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff1[4] = { + /* -- */ { 0, &Ia_psllw_Pq_Qq }, + /* 66 */ { 0, &Ia_psllw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff2[4] = { + /* -- */ { 0, &Ia_pslld_Pq_Qq }, + /* 66 */ { 0, &Ia_pslld_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff3[4] = { + /* -- */ { 0, &Ia_psllq_Pq_Qq }, + /* 66 */ { 0, &Ia_psllq_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff4[4] = { + /* -- */ { 0, &Ia_pmuludq_Pq_Qq }, + /* 66 */ { 0, &Ia_pmuludq_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff5[4] = { + /* -- */ { 0, &Ia_pmaddwd_Pq_Qq }, + /* 66 */ { 0, &Ia_pmaddwd_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff6[4] = { + /* -- */ { 0, &Ia_psadbw_Pq_Qq }, + /* 66 */ { 0, &Ia_psadbw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff7[4] = { + /* -- */ { 0, &Ia_maskmovq_Pq_Qq }, + /* 66 */ { 0, &Ia_maskmovdqu_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff8[4] = { + /* -- */ { 0, &Ia_psubb_Pq_Qq }, + /* 66 */ { 0, &Ia_psubb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ff9[4] = { + /* -- */ { 0, &Ia_psubw_Pq_Qq }, + /* 66 */ { 0, &Ia_psubw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ffa[4] = { + /* -- */ { 0, &Ia_psubd_Pq_Qq }, + /* 66 */ { 0, &Ia_psubd_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ffb[4] = { + /* -- */ { 0, &Ia_psubq_Pq_Qq }, + /* 66 */ { 0, &Ia_psubq_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ffc[4] = { + /* -- */ { 0, &Ia_paddb_Pq_Qq }, + /* 66 */ { 0, &Ia_paddb_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ffd[4] = { + /* -- */ { 0, &Ia_paddw_Pq_Qq }, + /* 66 */ { 0, &Ia_paddw_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_0ffe[4] = { + /* -- */ { 0, &Ia_paddd_Pq_Qq }, + /* 66 */ { 0, &Ia_paddd_Vdq_Wdq }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1202[4] = { + /* -- */ { 0, &Ia_psrlw_Pq_Ib }, + /* 66 */ { 0, &Ia_psrlw_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1204[4] = { + /* -- */ { 0, &Ia_psraw_Pq_Ib }, + /* 66 */ { 0, &Ia_psraw_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1206[4] = { + /* -- */ { 0, &Ia_psllw_Pq_Ib }, + /* 66 */ { 0, &Ia_psllw_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1302[4] = { + /* -- */ { 0, &Ia_psrld_Pq_Ib }, + /* 66 */ { 0, &Ia_psrld_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1304[4] = { + /* -- */ { 0, &Ia_psrad_Pq_Ib }, + /* 66 */ { 0, &Ia_psrad_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1306[4] = { + /* -- */ { 0, &Ia_pslld_Pq_Ib }, + /* 66 */ { 0, &Ia_pslld_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1402[4] = { + /* -- */ { 0, &Ia_psrlq_Pq_Ib }, + /* 66 */ { 0, &Ia_psrlq_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1403[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_psrldq_Wdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1406[4] = { + /* -- */ { 0, &Ia_psllq_Pq_Ib }, + /* 66 */ { 0, &Ia_psllq_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupSSE_G1407[4] = { + /* -- */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_pslldq_Vdq_Ib }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid } +}; + + +/* ************************************************************************ */ +/* Opcode GroupN */ + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EbIb[8] = { + /* 0 */ { 0, &Ia_addb_Eb_Ib }, + /* 1 */ { 0, &Ia_orb_Eb_Ib }, + /* 2 */ { 0, &Ia_adcb_Eb_Ib }, + /* 3 */ { 0, &Ia_sbbb_Eb_Ib }, + /* 4 */ { 0, &Ia_andb_Eb_Ib }, + /* 5 */ { 0, &Ia_subb_Eb_Ib }, + /* 6 */ { 0, &Ia_xorb_Eb_Ib }, + /* 7 */ { 0, &Ia_cmpb_Eb_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EwIw[8] = { + /* 0 */ { 0, &Ia_addw_Ew_Iw }, + /* 1 */ { 0, &Ia_orw_Ew_Iw }, + /* 2 */ { 0, &Ia_adcw_Ew_Iw }, + /* 3 */ { 0, &Ia_sbbw_Ew_Iw }, + /* 4 */ { 0, &Ia_andw_Ew_Iw }, + /* 5 */ { 0, &Ia_subw_Ew_Iw }, + /* 6 */ { 0, &Ia_xorw_Ew_Iw }, + /* 7 */ { 0, &Ia_cmpw_Ew_Iw } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EdId[8] = { + /* 0 */ { 0, &Ia_addl_Ed_Id }, + /* 1 */ { 0, &Ia_orl_Ed_Id }, + /* 2 */ { 0, &Ia_adcl_Ed_Id }, + /* 3 */ { 0, &Ia_sbbl_Ed_Id }, + /* 4 */ { 0, &Ia_andl_Ed_Id }, + /* 5 */ { 0, &Ia_subl_Ed_Id }, + /* 6 */ { 0, &Ia_xorl_Ed_Id }, + /* 7 */ { 0, &Ia_cmpl_Ed_Id } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EqId[8] = { + /* 0 */ { 0, &Ia_addq_Eq_sId }, + /* 1 */ { 0, &Ia_orq_Eq_sId }, + /* 2 */ { 0, &Ia_adcq_Eq_sId }, + /* 3 */ { 0, &Ia_sbbq_Eq_sId }, + /* 4 */ { 0, &Ia_andq_Eq_sId }, + /* 5 */ { 0, &Ia_subq_Eq_sId }, + /* 6 */ { 0, &Ia_xorq_Eq_sId }, + /* 7 */ { 0, &Ia_cmpq_Eq_sId } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EwIb[8] = { + /* 0 */ { 0, &Ia_addw_Ew_sIb }, // sign-extend byte + /* 1 */ { 0, &Ia_orw_Ew_sIb }, + /* 2 */ { 0, &Ia_adcw_Ew_sIb }, + /* 3 */ { 0, &Ia_sbbw_Ew_sIb }, + /* 4 */ { 0, &Ia_andw_Ew_sIb }, + /* 5 */ { 0, &Ia_subw_Ew_sIb }, + /* 6 */ { 0, &Ia_xorw_Ew_sIb }, + /* 7 */ { 0, &Ia_cmpw_Ew_sIb } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EdIb[8] = { + /* 0 */ { 0, &Ia_addl_Ed_sIb }, // sign-extend byte + /* 1 */ { 0, &Ia_orl_Ed_sIb }, + /* 2 */ { 0, &Ia_adcl_Ed_sIb }, + /* 3 */ { 0, &Ia_sbbl_Ed_sIb }, + /* 4 */ { 0, &Ia_andl_Ed_sIb }, + /* 5 */ { 0, &Ia_subl_Ed_sIb }, + /* 6 */ { 0, &Ia_xorl_Ed_sIb }, + /* 7 */ { 0, &Ia_cmpl_Ed_sIb } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG1EqIb[8] = { + /* 0 */ { 0, &Ia_addq_Eq_sIb }, // sign-extend byte + /* 1 */ { 0, &Ia_orq_Eq_sIb }, + /* 2 */ { 0, &Ia_adcq_Eq_sIb }, + /* 3 */ { 0, &Ia_sbbq_Eq_sIb }, + /* 4 */ { 0, &Ia_andq_Eq_sIb }, + /* 5 */ { 0, &Ia_subq_Eq_sIb }, + /* 6 */ { 0, &Ia_xorq_Eq_sIb }, + /* 7 */ { 0, &Ia_cmpq_Eq_sIb } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2Eb[8] = { + /* 0 */ { 0, &Ia_rolb_Eb_Ib }, + /* 1 */ { 0, &Ia_rorb_Eb_Ib }, + /* 2 */ { 0, &Ia_rclb_Eb_Ib }, + /* 3 */ { 0, &Ia_rcrb_Eb_Ib }, + /* 4 */ { 0, &Ia_shlb_Eb_Ib }, + /* 5 */ { 0, &Ia_shrb_Eb_Ib }, + /* 6 */ { 0, &Ia_shlb_Eb_Ib }, + /* 7 */ { 0, &Ia_sarb_Eb_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EbI1[8] = { + /* 0 */ { 0, &Ia_rolb_Eb_I1 }, + /* 1 */ { 0, &Ia_rorb_Eb_I1 }, + /* 2 */ { 0, &Ia_rclb_Eb_I1 }, + /* 3 */ { 0, &Ia_rcrb_Eb_I1 }, + /* 4 */ { 0, &Ia_shlb_Eb_I1 }, + /* 5 */ { 0, &Ia_shrb_Eb_I1 }, + /* 6 */ { 0, &Ia_shlb_Eb_I1 }, + /* 7 */ { 0, &Ia_sarb_Eb_I1 } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EbCL[8] = { + /* 0 */ { 0, &Ia_rolb_Eb_CL }, + /* 1 */ { 0, &Ia_rorb_Eb_CL }, + /* 2 */ { 0, &Ia_rclb_Eb_CL }, + /* 3 */ { 0, &Ia_rcrb_Eb_CL }, + /* 4 */ { 0, &Ia_shlb_Eb_CL }, + /* 5 */ { 0, &Ia_shrb_Eb_CL }, + /* 6 */ { 0, &Ia_shlb_Eb_CL }, + /* 7 */ { 0, &Ia_sarb_Eb_CL } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2Ew[8] = { + /* 0 */ { 0, &Ia_rolw_Ew_Ib }, + /* 1 */ { 0, &Ia_rorw_Ew_Ib }, + /* 2 */ { 0, &Ia_rclw_Ew_Ib }, + /* 3 */ { 0, &Ia_rcrw_Ew_Ib }, + /* 4 */ { 0, &Ia_shlw_Ew_Ib }, + /* 5 */ { 0, &Ia_shrw_Ew_Ib }, + /* 6 */ { 0, &Ia_shlw_Ew_Ib }, + /* 7 */ { 0, &Ia_sarw_Ew_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2Ed[8] = { + /* 0 */ { 0, &Ia_roll_Ed_Ib }, + /* 1 */ { 0, &Ia_rorl_Ed_Ib }, + /* 2 */ { 0, &Ia_rcll_Ed_Ib }, + /* 3 */ { 0, &Ia_rcrl_Ed_Ib }, + /* 4 */ { 0, &Ia_shll_Ed_Ib }, + /* 5 */ { 0, &Ia_shrl_Ed_Ib }, + /* 6 */ { 0, &Ia_shll_Ed_Ib }, + /* 7 */ { 0, &Ia_sarl_Ed_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2Eq[8] = { + /* 0 */ { 0, &Ia_rolq_Eq_Ib }, + /* 1 */ { 0, &Ia_rorq_Eq_Ib }, + /* 2 */ { 0, &Ia_rclq_Eq_Ib }, + /* 3 */ { 0, &Ia_rcrq_Eq_Ib }, + /* 4 */ { 0, &Ia_shlq_Eq_Ib }, + /* 5 */ { 0, &Ia_shrq_Eq_Ib }, + /* 6 */ { 0, &Ia_shlq_Eq_Ib }, + /* 7 */ { 0, &Ia_sarq_Eq_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EwI1[8] = { + /* 0 */ { 0, &Ia_rolw_Ew_I1 }, + /* 1 */ { 0, &Ia_rorw_Ew_I1 }, + /* 2 */ { 0, &Ia_rclw_Ew_I1 }, + /* 3 */ { 0, &Ia_rcrw_Ew_I1 }, + /* 4 */ { 0, &Ia_shlw_Ew_I1 }, + /* 5 */ { 0, &Ia_shrw_Ew_I1 }, + /* 6 */ { 0, &Ia_shlw_Ew_I1 }, + /* 7 */ { 0, &Ia_sarw_Ew_I1 } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EdI1[8] = { + /* 0 */ { 0, &Ia_roll_Ed_I1 }, + /* 1 */ { 0, &Ia_rorl_Ed_I1 }, + /* 2 */ { 0, &Ia_rcll_Ed_I1 }, + /* 3 */ { 0, &Ia_rcrl_Ed_I1 }, + /* 4 */ { 0, &Ia_shll_Ed_I1 }, + /* 5 */ { 0, &Ia_shrl_Ed_I1 }, + /* 6 */ { 0, &Ia_shll_Ed_I1 }, + /* 7 */ { 0, &Ia_sarl_Ed_I1 } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EqI1[8] = { + /* 0 */ { 0, &Ia_rolq_Eq_I1 }, + /* 1 */ { 0, &Ia_rorq_Eq_I1 }, + /* 2 */ { 0, &Ia_rclq_Eq_I1 }, + /* 3 */ { 0, &Ia_rcrq_Eq_I1 }, + /* 4 */ { 0, &Ia_shlq_Eq_I1 }, + /* 5 */ { 0, &Ia_shrq_Eq_I1 }, + /* 6 */ { 0, &Ia_shlq_Eq_I1 }, + /* 7 */ { 0, &Ia_sarq_Eq_I1 } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EwCL[8] = { + /* 0 */ { 0, &Ia_rolw_Ew_CL }, + /* 1 */ { 0, &Ia_rorw_Ew_CL }, + /* 2 */ { 0, &Ia_rclw_Ew_CL }, + /* 3 */ { 0, &Ia_rcrw_Ew_CL }, + /* 4 */ { 0, &Ia_shlw_Ew_CL }, + /* 5 */ { 0, &Ia_shrw_Ew_CL }, + /* 6 */ { 0, &Ia_shlw_Ew_CL }, + /* 7 */ { 0, &Ia_sarw_Ew_CL } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EdCL[8] = { + /* 0 */ { 0, &Ia_roll_Ed_CL }, + /* 1 */ { 0, &Ia_rorl_Ed_CL }, + /* 2 */ { 0, &Ia_rcll_Ed_CL }, + /* 3 */ { 0, &Ia_rcrl_Ed_CL }, + /* 4 */ { 0, &Ia_shll_Ed_CL }, + /* 5 */ { 0, &Ia_shrl_Ed_CL }, + /* 6 */ { 0, &Ia_shll_Ed_CL }, + /* 7 */ { 0, &Ia_sarl_Ed_CL } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG2EqCL[8] = { + /* 0 */ { 0, &Ia_rolq_Eq_CL }, + /* 1 */ { 0, &Ia_rorq_Eq_CL }, + /* 2 */ { 0, &Ia_rclq_Eq_CL }, + /* 3 */ { 0, &Ia_rcrq_Eq_CL }, + /* 4 */ { 0, &Ia_shlq_Eq_CL }, + /* 5 */ { 0, &Ia_shrq_Eq_CL }, + /* 6 */ { 0, &Ia_shlq_Eq_CL }, + /* 7 */ { 0, &Ia_sarq_Eq_CL } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG3Eb[8] = { + /* 0 */ { 0, &Ia_testb_Eb_Ib }, + /* 1 */ { 0, &Ia_testb_Eb_Ib }, + /* 2 */ { 0, &Ia_notb_Eb }, + /* 3 */ { 0, &Ia_negb_Eb }, + /* 4 */ { 0, &Ia_mulb_AL_Eb }, + /* 5 */ { 0, &Ia_imulb_AL_Eb }, + /* 6 */ { 0, &Ia_divb_AL_Eb }, + /* 7 */ { 0, &Ia_idivb_AL_Eb } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG3Ew[8] = { + /* 0 */ { 0, &Ia_testw_Ew_Iw }, + /* 1 */ { 0, &Ia_testw_Ew_Iw }, + /* 2 */ { 0, &Ia_notw_Ew }, + /* 3 */ { 0, &Ia_negw_Ew }, + /* 4 */ { 0, &Ia_mulw_AX_Ew }, + /* 5 */ { 0, &Ia_imulw_AX_Ew }, + /* 6 */ { 0, &Ia_divw_AX_Ew }, + /* 7 */ { 0, &Ia_idivw_AX_Ew } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG3Ed[8] = { + /* 0 */ { 0, &Ia_testl_Ed_Id }, + /* 1 */ { 0, &Ia_testl_Ed_Id }, + /* 2 */ { 0, &Ia_notl_Ed }, + /* 3 */ { 0, &Ia_negl_Ed }, + /* 4 */ { 0, &Ia_mull_EAX_Ed }, + /* 5 */ { 0, &Ia_imull_EAX_Ed }, + /* 6 */ { 0, &Ia_divl_EAX_Ed }, + /* 7 */ { 0, &Ia_idivl_EAX_Ed } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG3Eq[8] = { + /* 0 */ { 0, &Ia_testq_Eq_sId }, + /* 1 */ { 0, &Ia_testq_Eq_sId }, + /* 2 */ { 0, &Ia_notq_Eq }, + /* 3 */ { 0, &Ia_negq_Eq }, + /* 4 */ { 0, &Ia_mulq_RAX_Eq }, + /* 5 */ { 0, &Ia_imulq_RAX_Eq }, + /* 6 */ { 0, &Ia_divq_RAX_Eq }, + /* 7 */ { 0, &Ia_idivq_RAX_Eq } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG4[8] = { + /* 0 */ { 0, &Ia_incb_Eb }, + /* 1 */ { 0, &Ia_decb_Eb }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG5w[8] = { + /* 0 */ { 0, &Ia_incw_Ew }, + /* 1 */ { 0, &Ia_decw_Ew }, + /* 2 */ { 0, &Ia_call_Ew }, + /* 3 */ { 0, &Ia_lcall_Mp }, + /* 4 */ { 0, &Ia_jmp_Ew }, + /* 5 */ { 0, &Ia_ljmp_Mp }, + /* 6 */ { 0, &Ia_pushw_Ew }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG5d[8] = { + /* 0 */ { 0, &Ia_incl_Ed }, + /* 1 */ { 0, &Ia_decl_Ed }, + /* 2 */ { 0, &Ia_call_Ed }, + /* 3 */ { 0, &Ia_lcall_Mp }, + /* 4 */ { 0, &Ia_jmp_Ed }, + /* 5 */ { 0, &Ia_ljmp_Mp }, + /* 6 */ { 0, &Ia_pushl_Ed }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroup64G5d[8] = { + /* 0 */ { 0, &Ia_incl_Ed }, + /* 1 */ { 0, &Ia_decl_Ed }, + /* 2 */ { 0, &Ia_call_Eq }, + /* 3 */ { 0, &Ia_lcall_Mp }, + /* 4 */ { 0, &Ia_jmp_Eq }, + /* 5 */ { 0, &Ia_ljmp_Mp }, + /* 6 */ { 0, &Ia_pushq_Eq }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroup64G5q[8] = { + /* 0 */ { 0, &Ia_incq_Eq }, + /* 1 */ { 0, &Ia_decq_Eq }, + /* 2 */ { 0, &Ia_call_Eq }, + /* 3 */ { 0, &Ia_lcall_Mp }, + /* 4 */ { 0, &Ia_jmp_Eq }, + /* 5 */ { 0, &Ia_ljmp_Mp }, + /* 6 */ { 0, &Ia_pushq_Eq }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG6[8] = { + /* 0 */ { 0, &Ia_sldt }, + /* 1 */ { 0, &Ia_str }, + /* 2 */ { 0, &Ia_lldt }, + /* 3 */ { 0, &Ia_ltr }, + /* 4 */ { 0, &Ia_verr }, + /* 5 */ { 0, &Ia_verw }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupRmINVLPG[8] = { + /* 0 */ { 0, &Ia_swapgs }, + /* 1 */ { 0, &Ia_rdtscp }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_Invalid }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupModINVLPG[2] = { + /* R */ { GRPRM(INVLPG) }, + /* M */ { 0, &Ia_invlpg } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG7[8] = { + /* 0 */ { 0, &Ia_sgdt }, + /* 1 */ { 0, &Ia_sidt }, + /* 2 */ { 0, &Ia_lgdt }, + /* 3 */ { 0, &Ia_lidt }, + /* 4 */ { 0, &Ia_smsw_Ew }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_lmsw_Ew }, + /* 7 */ { GRPMOD(INVLPG) }, +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG8EwIb[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_btw_Ew_Ib }, + /* 5 */ { 0, &Ia_btsw_Ew_Ib }, + /* 6 */ { 0, &Ia_btrw_Ew_Ib }, + /* 7 */ { 0, &Ia_btcw_Ew_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG8EdIb[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_btl_Ed_Ib }, + /* 5 */ { 0, &Ia_btsl_Ed_Ib }, + /* 6 */ { 0, &Ia_btrl_Ed_Ib }, + /* 7 */ { 0, &Ia_btcl_Ed_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG8EqIb[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_btq_Eq_Ib }, + /* 5 */ { 0, &Ia_btsq_Eq_Ib }, + /* 6 */ { 0, &Ia_btrq_Eq_Ib }, + /* 7 */ { 0, &Ia_btcq_Eq_Ib } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG9[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_cmpxchg8b }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG9q[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_cmpxchg16b }, + /* 2 */ { 0, &Ia_Invalid }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG12[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { GRPSSE(G1202) }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { GRPSSE(G1204) }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { GRPSSE(G1206) }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG13[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { GRPSSE(G1302) }, + /* 3 */ { 0, &Ia_Invalid }, + /* 4 */ { GRPSSE(G1304) }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { GRPSSE(G1306) }, + /* 7 */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG14[8] = { + /* 0 */ { 0, &Ia_Invalid }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { GRPSSE(G1402) }, + /* 3 */ { GRPSSE(G1403) }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { GRPSSE(G1406) }, + /* 7 */ { GRPSSE(G1407) } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupModCFLUSH[2] = { + /* R */ { 0, &Ia_sfence }, + /* M */ { 0, &Ia_cflush } +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG15[8] = { + /* 0 */ { 0, &Ia_fxsave }, + /* 1 */ { 0, &Ia_fxrstor }, + /* 2 */ { 0, &Ia_ldmxcsr }, + /* 3 */ { 0, &Ia_stmxcsr }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_lfence }, + /* 6 */ { 0, &Ia_mfence }, + /* 7 */ { GRPMOD(CFLUSH) } /* SFENCE/CFLUSH */ +}; + +static BxDisasmOpcodeTable_t BxDisasmGroupG16[8] = +{ + /* 0 */ { 0, &Ia_prefetchnta }, + /* 1 */ { 0, &Ia_prefetcht0 }, + /* 2 */ { 0, &Ia_prefetcht1 }, + /* 3 */ { 0, &Ia_prefetcht2 }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_Invalid } +}; + +/* ************************************************************************ */ +/* 3DNow! opcodes */ + +static BxDisasmOpcodeTable_t BxDisasm3DNowGroup[256] = { + // 256 entries for 3DNow opcodes_by suffix + /* 00 */ { 0, &Ia_Invalid }, + /* 01 */ { 0, &Ia_Invalid }, + /* 02 */ { 0, &Ia_Invalid }, + /* 03 */ { 0, &Ia_Invalid }, + /* 04 */ { 0, &Ia_Invalid }, + /* 05 */ { 0, &Ia_Invalid }, + /* 06 */ { 0, &Ia_Invalid }, + /* 07 */ { 0, &Ia_Invalid }, + /* 08 */ { 0, &Ia_Invalid }, + /* 09 */ { 0, &Ia_Invalid }, + /* 0A */ { 0, &Ia_Invalid }, + /* 0B */ { 0, &Ia_Invalid }, + /* 0C */ { 0, &Ia_pi2fw_Pq_Qq }, + /* 0D */ { 0, &Ia_pi2fd_Pq_Qq }, + /* 0E */ { 0, &Ia_Invalid }, + /* 0F */ { 0, &Ia_Invalid }, + /* 10 */ { 0, &Ia_Invalid }, + /* 11 */ { 0, &Ia_Invalid }, + /* 12 */ { 0, &Ia_Invalid }, + /* 13 */ { 0, &Ia_Invalid }, + /* 14 */ { 0, &Ia_Invalid }, + /* 15 */ { 0, &Ia_Invalid }, + /* 16 */ { 0, &Ia_Invalid }, + /* 17 */ { 0, &Ia_Invalid }, + /* 18 */ { 0, &Ia_Invalid }, + /* 19 */ { 0, &Ia_Invalid }, + /* 1A */ { 0, &Ia_Invalid }, + /* 1B */ { 0, &Ia_Invalid }, + /* 1C */ { 0, &Ia_pf2iw_Pq_Qq }, + /* 1D */ { 0, &Ia_pf2id_Pq_Qq }, + /* 1E */ { 0, &Ia_Invalid }, + /* 1F */ { 0, &Ia_Invalid }, + /* 20 */ { 0, &Ia_Invalid }, + /* 21 */ { 0, &Ia_Invalid }, + /* 22 */ { 0, &Ia_Invalid }, + /* 23 */ { 0, &Ia_Invalid }, + /* 24 */ { 0, &Ia_Invalid }, + /* 25 */ { 0, &Ia_Invalid }, + /* 26 */ { 0, &Ia_Invalid }, + /* 27 */ { 0, &Ia_Invalid }, + /* 28 */ { 0, &Ia_Invalid }, + /* 29 */ { 0, &Ia_Invalid }, + /* 2A */ { 0, &Ia_Invalid }, + /* 2B */ { 0, &Ia_Invalid }, + /* 2C */ { 0, &Ia_Invalid }, + /* 2D */ { 0, &Ia_Invalid }, + /* 2E */ { 0, &Ia_Invalid }, + /* 2F */ { 0, &Ia_Invalid }, + /* 30 */ { 0, &Ia_Invalid }, + /* 31 */ { 0, &Ia_Invalid }, + /* 32 */ { 0, &Ia_Invalid }, + /* 33 */ { 0, &Ia_Invalid }, + /* 34 */ { 0, &Ia_Invalid }, + /* 35 */ { 0, &Ia_Invalid }, + /* 36 */ { 0, &Ia_Invalid }, + /* 37 */ { 0, &Ia_Invalid }, + /* 38 */ { 0, &Ia_Invalid }, + /* 39 */ { 0, &Ia_Invalid }, + /* 3A */ { 0, &Ia_Invalid }, + /* 3B */ { 0, &Ia_Invalid }, + /* 3C */ { 0, &Ia_Invalid }, + /* 3D */ { 0, &Ia_Invalid }, + /* 3E */ { 0, &Ia_Invalid }, + /* 3F */ { 0, &Ia_Invalid }, + /* 40 */ { 0, &Ia_Invalid }, + /* 41 */ { 0, &Ia_Invalid }, + /* 42 */ { 0, &Ia_Invalid }, + /* 43 */ { 0, &Ia_Invalid }, + /* 44 */ { 0, &Ia_Invalid }, + /* 45 */ { 0, &Ia_Invalid }, + /* 46 */ { 0, &Ia_Invalid }, + /* 47 */ { 0, &Ia_Invalid }, + /* 48 */ { 0, &Ia_Invalid }, + /* 49 */ { 0, &Ia_Invalid }, + /* 4A */ { 0, &Ia_Invalid }, + /* 4B */ { 0, &Ia_Invalid }, + /* 4C */ { 0, &Ia_Invalid }, + /* 4D */ { 0, &Ia_Invalid }, + /* 4E */ { 0, &Ia_Invalid }, + /* 4F */ { 0, &Ia_Invalid }, + /* 50 */ { 0, &Ia_Invalid }, + /* 51 */ { 0, &Ia_Invalid }, + /* 52 */ { 0, &Ia_Invalid }, + /* 53 */ { 0, &Ia_Invalid }, + /* 54 */ { 0, &Ia_Invalid }, + /* 55 */ { 0, &Ia_Invalid }, + /* 56 */ { 0, &Ia_Invalid }, + /* 57 */ { 0, &Ia_Invalid }, + /* 58 */ { 0, &Ia_Invalid }, + /* 59 */ { 0, &Ia_Invalid }, + /* 5A */ { 0, &Ia_Invalid }, + /* 5B */ { 0, &Ia_Invalid }, + /* 5C */ { 0, &Ia_Invalid }, + /* 5D */ { 0, &Ia_Invalid }, + /* 5E */ { 0, &Ia_Invalid }, + /* 5F */ { 0, &Ia_Invalid }, + /* 60 */ { 0, &Ia_Invalid }, + /* 61 */ { 0, &Ia_Invalid }, + /* 62 */ { 0, &Ia_Invalid }, + /* 63 */ { 0, &Ia_Invalid }, + /* 64 */ { 0, &Ia_Invalid }, + /* 65 */ { 0, &Ia_Invalid }, + /* 66 */ { 0, &Ia_Invalid }, + /* 67 */ { 0, &Ia_Invalid }, + /* 68 */ { 0, &Ia_Invalid }, + /* 69 */ { 0, &Ia_Invalid }, + /* 6A */ { 0, &Ia_Invalid }, + /* 6B */ { 0, &Ia_Invalid }, + /* 6C */ { 0, &Ia_Invalid }, + /* 6D */ { 0, &Ia_Invalid }, + /* 6E */ { 0, &Ia_Invalid }, + /* 6F */ { 0, &Ia_Invalid }, + /* 70 */ { 0, &Ia_Invalid }, + /* 71 */ { 0, &Ia_Invalid }, + /* 72 */ { 0, &Ia_Invalid }, + /* 73 */ { 0, &Ia_Invalid }, + /* 74 */ { 0, &Ia_Invalid }, + /* 75 */ { 0, &Ia_Invalid }, + /* 76 */ { 0, &Ia_Invalid }, + /* 77 */ { 0, &Ia_Invalid }, + /* 78 */ { 0, &Ia_Invalid }, + /* 79 */ { 0, &Ia_Invalid }, + /* 7A */ { 0, &Ia_Invalid }, + /* 7B */ { 0, &Ia_Invalid }, + /* 7C */ { 0, &Ia_Invalid }, + /* 7D */ { 0, &Ia_Invalid }, + /* 7E */ { 0, &Ia_Invalid }, + /* 7F */ { 0, &Ia_Invalid }, + /* 80 */ { 0, &Ia_Invalid }, + /* 81 */ { 0, &Ia_Invalid }, + /* 82 */ { 0, &Ia_Invalid }, + /* 83 */ { 0, &Ia_Invalid }, + /* 84 */ { 0, &Ia_Invalid }, + /* 85 */ { 0, &Ia_Invalid }, + /* 86 */ { 0, &Ia_Invalid }, + /* 87 */ { 0, &Ia_Invalid }, + /* 88 */ { 0, &Ia_Invalid }, + /* 89 */ { 0, &Ia_Invalid }, + /* 8A */ { 0, &Ia_pfnacc_Pq_Qq }, + /* 8B */ { 0, &Ia_Invalid }, + /* 8C */ { 0, &Ia_Invalid }, + /* 8D */ { 0, &Ia_Invalid }, + /* 8E */ { 0, &Ia_pfpnacc_Pq_Qq }, + /* 8F */ { 0, &Ia_Invalid }, + /* 90 */ { 0, &Ia_pfcmpge_Pq_Qq }, + /* 91 */ { 0, &Ia_Invalid }, + /* 92 */ { 0, &Ia_Invalid }, + /* 93 */ { 0, &Ia_Invalid }, + /* 94 */ { 0, &Ia_pfmin_Pq_Qq }, + /* 95 */ { 0, &Ia_Invalid }, + /* 96 */ { 0, &Ia_pfrcp_Pq_Qq }, + /* 97 */ { 0, &Ia_pfrsqrt_Pq_Qq }, + /* 98 */ { 0, &Ia_Invalid }, + /* 99 */ { 0, &Ia_Invalid }, + /* 9A */ { 0, &Ia_pfsub_Pq_Qq }, + /* 9B */ { 0, &Ia_Invalid }, + /* 9C */ { 0, &Ia_Invalid }, + /* 9D */ { 0, &Ia_Invalid }, + /* 9E */ { 0, &Ia_pfadd_Pq_Qq }, + /* 9F */ { 0, &Ia_Invalid }, + /* A0 */ { 0, &Ia_pfcmpgt_Pq_Qq }, + /* A1 */ { 0, &Ia_Invalid }, + /* A2 */ { 0, &Ia_Invalid }, + /* A3 */ { 0, &Ia_Invalid }, + /* A4 */ { 0, &Ia_pfmax_Pq_Qq }, + /* A5 */ { 0, &Ia_Invalid }, + /* A6 */ { 0, &Ia_pfrcpit1_Pq_Qq }, + /* A7 */ { 0, &Ia_pfrsqit1_Pq_Qq }, + /* A8 */ { 0, &Ia_Invalid }, + /* A9 */ { 0, &Ia_Invalid }, + /* AA */ { 0, &Ia_pfsubr_Pq_Qq }, + /* AB */ { 0, &Ia_Invalid }, + /* AC */ { 0, &Ia_Invalid }, + /* AD */ { 0, &Ia_Invalid }, + /* AE */ { 0, &Ia_pfacc_Pq_Qq }, + /* AF */ { 0, &Ia_Invalid }, + /* B0 */ { 0, &Ia_pfcmpeq_Pq_Qq }, + /* B1 */ { 0, &Ia_Invalid }, + /* B2 */ { 0, &Ia_Invalid }, + /* B3 */ { 0, &Ia_Invalid }, + /* B4 */ { 0, &Ia_pfmul_Pq_Qq }, + /* B5 */ { 0, &Ia_Invalid }, + /* B6 */ { 0, &Ia_pfrcpit2_Pq_Qq }, + /* B7 */ { 0, &Ia_pmulhrw_Pq_Qq }, + /* B8 */ { 0, &Ia_Invalid }, + /* B9 */ { 0, &Ia_Invalid }, + /* BA */ { 0, &Ia_Invalid }, + /* BB */ { 0, &Ia_pswapd_Pq_Qq }, + /* BC */ { 0, &Ia_Invalid }, + /* BD */ { 0, &Ia_Invalid }, + /* BE */ { 0, &Ia_Invalid }, + /* BF */ { 0, &Ia_pavgb_Pq_Qq }, + /* C0 */ { 0, &Ia_Invalid }, + /* C1 */ { 0, &Ia_Invalid }, + /* C2 */ { 0, &Ia_Invalid }, + /* C3 */ { 0, &Ia_Invalid }, + /* C4 */ { 0, &Ia_Invalid }, + /* C5 */ { 0, &Ia_Invalid }, + /* C6 */ { 0, &Ia_Invalid }, + /* C7 */ { 0, &Ia_Invalid }, + /* C8 */ { 0, &Ia_Invalid }, + /* C9 */ { 0, &Ia_Invalid }, + /* CA */ { 0, &Ia_Invalid }, + /* CB */ { 0, &Ia_Invalid }, + /* CC */ { 0, &Ia_Invalid }, + /* CD */ { 0, &Ia_Invalid }, + /* CE */ { 0, &Ia_Invalid }, + /* CF */ { 0, &Ia_Invalid }, + /* D0 */ { 0, &Ia_Invalid }, + /* D1 */ { 0, &Ia_Invalid }, + /* D2 */ { 0, &Ia_Invalid }, + /* D3 */ { 0, &Ia_Invalid }, + /* D4 */ { 0, &Ia_Invalid }, + /* D5 */ { 0, &Ia_Invalid }, + /* D6 */ { 0, &Ia_Invalid }, + /* D7 */ { 0, &Ia_Invalid }, + /* D8 */ { 0, &Ia_Invalid }, + /* D9 */ { 0, &Ia_Invalid }, + /* DA */ { 0, &Ia_Invalid }, + /* DB */ { 0, &Ia_Invalid }, + /* DC */ { 0, &Ia_Invalid }, + /* DD */ { 0, &Ia_Invalid }, + /* DE */ { 0, &Ia_Invalid }, + /* DF */ { 0, &Ia_Invalid }, + /* E0 */ { 0, &Ia_Invalid }, + /* E1 */ { 0, &Ia_Invalid }, + /* E2 */ { 0, &Ia_Invalid }, + /* E3 */ { 0, &Ia_Invalid }, + /* E4 */ { 0, &Ia_Invalid }, + /* E5 */ { 0, &Ia_Invalid }, + /* E6 */ { 0, &Ia_Invalid }, + /* E7 */ { 0, &Ia_Invalid }, + /* E8 */ { 0, &Ia_Invalid }, + /* E9 */ { 0, &Ia_Invalid }, + /* EA */ { 0, &Ia_Invalid }, + /* EB */ { 0, &Ia_Invalid }, + /* EC */ { 0, &Ia_Invalid }, + /* ED */ { 0, &Ia_Invalid }, + /* EE */ { 0, &Ia_Invalid }, + /* EF */ { 0, &Ia_Invalid }, + /* F0 */ { 0, &Ia_Invalid }, + /* F1 */ { 0, &Ia_Invalid }, + /* F2 */ { 0, &Ia_Invalid }, + /* F3 */ { 0, &Ia_Invalid }, + /* F4 */ { 0, &Ia_Invalid }, + /* F5 */ { 0, &Ia_Invalid }, + /* F6 */ { 0, &Ia_Invalid }, + /* F7 */ { 0, &Ia_Invalid }, + /* F8 */ { 0, &Ia_Invalid }, + /* F9 */ { 0, &Ia_Invalid }, + /* FA */ { 0, &Ia_Invalid }, + /* FB */ { 0, &Ia_Invalid }, + /* FC */ { 0, &Ia_Invalid }, + /* FD */ { 0, &Ia_Invalid }, + /* FE */ { 0, &Ia_Invalid }, + /* FF */ { 0, &Ia_Invalid } +}; + +/* ************************************************************************ */ +/* FPU Opcodes */ + +// floating point instructions when mod!=11b. +// the following tables will be accessed like groups using the nnn (reg) field of +// the modrm byte. (the first byte is D8-DF) + + // D8 (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupD8[8] = { + /* 0 */ { 0, &Ia_fadds_Md }, + /* 1 */ { 0, &Ia_fmuls_Md }, + /* 2 */ { 0, &Ia_fcoms_Md }, + /* 3 */ { 0, &Ia_fcomps_Md }, + /* 4 */ { 0, &Ia_fsubs_Md }, + /* 5 */ { 0, &Ia_fsubrs_Md }, + /* 6 */ { 0, &Ia_fdivs_Md }, + /* 7 */ { 0, &Ia_fdivprs_Md } +}; + + // D9 (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupD9[8] = { + /* 0 */ { 0, &Ia_flds_Md }, + /* 1 */ { 0, &Ia_Invalid }, + /* 2 */ { 0, &Ia_fsts_Md }, + /* 3 */ { 0, &Ia_fstps_Md }, + /* 4 */ { 0, &Ia_fldenv }, + /* 5 */ { 0, &Ia_fldcw }, + /* 6 */ { 0, &Ia_fnstenv }, + /* 7 */ { 0, &Ia_fnstcw } +}; + + // DA (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupDA[8] = { + /* 0 */ { 0, &Ia_fiaddl_Md }, + /* 1 */ { 0, &Ia_fimull_Md }, + /* 2 */ { 0, &Ia_ficoml_Md }, + /* 3 */ { 0, &Ia_ficompl_Md }, + /* 4 */ { 0, &Ia_fisubl_Md }, + /* 5 */ { 0, &Ia_fisubrl_Md }, + /* 6 */ { 0, &Ia_fidivl_Md }, + /* 7 */ { 0, &Ia_fidivrl_Md } +}; + + // DB (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupDB[8] = { + /* 0 */ { 0, &Ia_fildl_Md }, + /* 1 */ { 0, &Ia_fisttpl_Md }, + /* 2 */ { 0, &Ia_fistl_Md }, + /* 3 */ { 0, &Ia_fistpl_Md }, + /* 4 */ { 0, &Ia_Invalid }, + /* 5 */ { 0, &Ia_fldt_Mt }, + /* 6 */ { 0, &Ia_Invalid }, + /* 7 */ { 0, &Ia_fstpt_Mt } +}; + + // DC (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupDC[8] = { + /* 0 */ { 0, &Ia_faddl_Mq }, + /* 1 */ { 0, &Ia_fmull_Mq }, + /* 2 */ { 0, &Ia_fcoml_Mq }, + /* 3 */ { 0, &Ia_fcompl_Mq }, + /* 4 */ { 0, &Ia_fsubl_Mq }, + /* 5 */ { 0, &Ia_fsubrl_Mq }, + /* 6 */ { 0, &Ia_fdivl_Mq }, + /* 7 */ { 0, &Ia_fdivrl_Mq } +}; + + // DD (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupDD[8] = { + /* 0 */ { 0, &Ia_fldl_Mq }, + /* 1 */ { 0, &Ia_fisttpq_Mq }, + /* 2 */ { 0, &Ia_fstl_Mq }, + /* 3 */ { 0, &Ia_fstpl_Mq }, + /* 4 */ { 0, &Ia_frstor }, + /* 5 */ { 0, &Ia_Invalid }, + /* 6 */ { 0, &Ia_fnsave }, + /* 7 */ { 0, &Ia_fnstsw } +}; + + // DE (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupDE[8] = { + /* 0 */ { 0, &Ia_fiadds_Mw }, + /* 1 */ { 0, &Ia_fimuls_Mw }, + /* 2 */ { 0, &Ia_ficoms_Mw }, + /* 3 */ { 0, &Ia_ficomps_Mw }, + /* 4 */ { 0, &Ia_fisubs_Mw }, + /* 5 */ { 0, &Ia_fisubrs_Mw }, + /* 6 */ { 0, &Ia_fidivs_Mw }, + /* 7 */ { 0, &Ia_fidivrs_Mw } +}; + + // DF (modrm is outside 00h - BFh) (mod != 11) +static BxDisasmOpcodeTable_t BxDisasmFPGroupDF[8] = { + /* 0 */ { 0, &Ia_filds_Mw }, + /* 1 */ { 0, &Ia_fisttps_Mw }, + /* 2 */ { 0, &Ia_fists_Mw }, + /* 3 */ { 0, &Ia_fistps_Mw }, + /* 4 */ { 0, &Ia_fbldt_Mt }, + /* 5 */ { 0, &Ia_fildq_Mq }, + /* 6 */ { 0, &Ia_fbstpt_Mt }, + /* 7 */ { 0, &Ia_fistpq_Mq } +}; + +// 512 entries for second byte of floating point instructions. (when mod==11b) +static BxDisasmOpcodeTable_t BxDisasmOpcodeInfoFP[512] = { + // D8 (modrm is outside 00h - BFh) (mod == 11) + /* D8 C0 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C1 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C2 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C3 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C4 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C5 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C6 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C7 */ { 0, &Ia_fadd_ST0_STi }, + /* D8 C8 */ { 0, &Ia_fmul_ST0_STi }, + /* D8 C9 */ { 0, &Ia_fmul_ST0_STi }, + /* D8 CA */ { 0, &Ia_fmul_ST0_STi }, + /* D8 CB */ { 0, &Ia_fmul_ST0_STi }, + /* D8 CC */ { 0, &Ia_fmul_ST0_STi }, + /* D8 CD */ { 0, &Ia_fmul_ST0_STi }, + /* D8 CE */ { 0, &Ia_fmul_ST0_STi }, + /* D8 CF */ { 0, &Ia_fmul_ST0_STi }, + /* D8 D0 */ { 0, &Ia_fcom_STi }, + /* D8 D1 */ { 0, &Ia_fcom_STi }, + /* D8 D2 */ { 0, &Ia_fcom_STi }, + /* D8 D3 */ { 0, &Ia_fcom_STi }, + /* D8 D4 */ { 0, &Ia_fcom_STi }, + /* D8 D5 */ { 0, &Ia_fcom_STi }, + /* D8 D6 */ { 0, &Ia_fcom_STi }, + /* D8 D7 */ { 0, &Ia_fcom_STi }, + /* D8 D8 */ { 0, &Ia_fcomp_STi }, + /* D8 D9 */ { 0, &Ia_fcomp_STi }, + /* D8 DA */ { 0, &Ia_fcomp_STi }, + /* D8 DB */ { 0, &Ia_fcomp_STi }, + /* D8 DC */ { 0, &Ia_fcomp_STi }, + /* D8 DD */ { 0, &Ia_fcomp_STi }, + /* D8 DE */ { 0, &Ia_fcomp_STi }, + /* D8 DF */ { 0, &Ia_fcomp_STi }, + /* D8 E0 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E1 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E2 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E3 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E4 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E5 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E6 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E7 */ { 0, &Ia_fsub_ST0_STi }, + /* D8 E8 */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 E9 */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 EA */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 EB */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 EC */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 ED */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 EE */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 EF */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 F0 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F1 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F2 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F3 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F4 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F5 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F6 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F7 */ { 0, &Ia_fdiv_ST0_STi }, + /* D8 F8 */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 F9 */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 FA */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 FB */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 FC */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 FD */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 FE */ { 0, &Ia_fsubr_ST0_STi }, + /* D8 FF */ { 0, &Ia_fsubr_ST0_STi }, + + // D9 (modrm is outside 00h - BFh) (mod == 11) + /* D9 C0 */ { 0, &Ia_fld_STi }, + /* D9 C1 */ { 0, &Ia_fld_STi }, + /* D9 C2 */ { 0, &Ia_fld_STi }, + /* D9 C3 */ { 0, &Ia_fld_STi }, + /* D9 C4 */ { 0, &Ia_fld_STi }, + /* D9 C5 */ { 0, &Ia_fld_STi }, + /* D9 C6 */ { 0, &Ia_fld_STi }, + /* D9 C7 */ { 0, &Ia_fld_STi }, + /* D9 C8 */ { 0, &Ia_fxch }, + /* D9 C9 */ { 0, &Ia_fxch }, + /* D9 CA */ { 0, &Ia_fxch }, + /* D9 CB */ { 0, &Ia_fxch }, + /* D9 CC */ { 0, &Ia_fxch }, + /* D9 CD */ { 0, &Ia_fxch }, + /* D9 CE */ { 0, &Ia_fxch }, + /* D9 CF */ { 0, &Ia_fxch }, + /* D9 D0 */ { 0, &Ia_fnop }, + /* D9 D1 */ { 0, &Ia_Invalid }, + /* D9 D2 */ { 0, &Ia_Invalid }, + /* D9 D3 */ { 0, &Ia_Invalid }, + /* D9 D4 */ { 0, &Ia_Invalid }, + /* D9 D5 */ { 0, &Ia_Invalid }, + /* D9 D6 */ { 0, &Ia_Invalid }, + /* D9 D7 */ { 0, &Ia_Invalid }, + /* D9 D8 */ { 0, &Ia_Invalid }, + /* D9 D9 */ { 0, &Ia_Invalid }, + /* D9 DA */ { 0, &Ia_Invalid }, + /* D9 DB */ { 0, &Ia_Invalid }, + /* D9 DC */ { 0, &Ia_Invalid }, + /* D9 DD */ { 0, &Ia_Invalid }, + /* D9 DE */ { 0, &Ia_Invalid }, + /* D9 DF */ { 0, &Ia_Invalid }, + /* D9 E0 */ { 0, &Ia_fchs }, + /* D9 E1 */ { 0, &Ia_fabs }, + /* D9 E2 */ { 0, &Ia_Invalid }, + /* D9 E3 */ { 0, &Ia_Invalid }, + /* D9 E4 */ { 0, &Ia_ftst }, + /* D9 E5 */ { 0, &Ia_fxam }, + /* D9 E6 */ { 0, &Ia_Invalid }, + /* D9 E7 */ { 0, &Ia_Invalid }, + /* D9 E8 */ { 0, &Ia_fld1 }, + /* D9 E9 */ { 0, &Ia_fldl2t }, + /* D9 EA */ { 0, &Ia_fldl2e }, + /* D9 EB */ { 0, &Ia_fldpi }, + /* D9 EC */ { 0, &Ia_fldlg2 }, + /* D9 ED */ { 0, &Ia_fldln2 }, + /* D9 EE */ { 0, &Ia_fldz }, + /* D9 EF */ { 0, &Ia_Invalid }, + /* D9 F0 */ { 0, &Ia_f2xm1 }, + /* D9 F1 */ { 0, &Ia_fyl2x }, + /* D9 F2 */ { 0, &Ia_fptan }, + /* D9 F3 */ { 0, &Ia_fpatan }, + /* D9 F4 */ { 0, &Ia_fxtract }, + /* D9 F5 */ { 0, &Ia_fprem1 }, + /* D9 F6 */ { 0, &Ia_fdecstp }, + /* D9 F7 */ { 0, &Ia_fincstp }, + /* D9 F8 */ { 0, &Ia_fprem }, + /* D9 F9 */ { 0, &Ia_fyl2xp1 }, + /* D9 FA */ { 0, &Ia_fsqrt }, + /* D9 FB */ { 0, &Ia_fsincos }, + /* D9 FC */ { 0, &Ia_frndint }, + /* D9 FD */ { 0, &Ia_fscale }, + /* D9 FE */ { 0, &Ia_fsin }, + /* D9 FF */ { 0, &Ia_fcos }, + + // DA (modrm is outside 00h - BFh) (mod == 11) + /* DA C0 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C1 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C2 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C3 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C4 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C5 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C6 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C7 */ { 0, &Ia_fcmovb_ST0_STi }, + /* DA C8 */ { 0, &Ia_fcmove_ST0_STi }, + /* DA C9 */ { 0, &Ia_fcmove_ST0_STi }, + /* DA CA */ { 0, &Ia_fcmove_ST0_STi }, + /* DA CB */ { 0, &Ia_fcmove_ST0_STi }, + /* DA CC */ { 0, &Ia_fcmove_ST0_STi }, + /* DA CD */ { 0, &Ia_fcmove_ST0_STi }, + /* DA CE */ { 0, &Ia_fcmove_ST0_STi }, + /* DA CF */ { 0, &Ia_fcmove_ST0_STi }, + /* DA D0 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D1 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D2 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D3 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D4 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D5 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D6 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D7 */ { 0, &Ia_fcmovbe_ST0_STi }, + /* DA D8 */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA D9 */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA DA */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA DB */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA DC */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA DD */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA DE */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA DF */ { 0, &Ia_fcmovu_ST0_STi }, + /* DA E0 */ { 0, &Ia_Invalid }, + /* DA E1 */ { 0, &Ia_Invalid }, + /* DA E2 */ { 0, &Ia_Invalid }, + /* DA E3 */ { 0, &Ia_Invalid }, + /* DA E4 */ { 0, &Ia_Invalid }, + /* DA E5 */ { 0, &Ia_Invalid }, + /* DA E6 */ { 0, &Ia_Invalid }, + /* DA E7 */ { 0, &Ia_Invalid }, + /* DA E8 */ { 0, &Ia_Invalid }, + /* DA E9 */ { 0, &Ia_fucompp }, + /* DA EA */ { 0, &Ia_Invalid }, + /* DA EB */ { 0, &Ia_Invalid }, + /* DA EC */ { 0, &Ia_Invalid }, + /* DA ED */ { 0, &Ia_Invalid }, + /* DA EE */ { 0, &Ia_Invalid }, + /* DA EF */ { 0, &Ia_Invalid }, + /* DA F0 */ { 0, &Ia_Invalid }, + /* DA F1 */ { 0, &Ia_Invalid }, + /* DA F2 */ { 0, &Ia_Invalid }, + /* DA F3 */ { 0, &Ia_Invalid }, + /* DA F4 */ { 0, &Ia_Invalid }, + /* DA F5 */ { 0, &Ia_Invalid }, + /* DA F6 */ { 0, &Ia_Invalid }, + /* DA F7 */ { 0, &Ia_Invalid }, + /* DA F8 */ { 0, &Ia_Invalid }, + /* DA F9 */ { 0, &Ia_Invalid }, + /* DA FA */ { 0, &Ia_Invalid }, + /* DA FB */ { 0, &Ia_Invalid }, + /* DA FC */ { 0, &Ia_Invalid }, + /* DA FD */ { 0, &Ia_Invalid }, + /* DA FE */ { 0, &Ia_Invalid }, + /* DA FF */ { 0, &Ia_Invalid }, + + // DB (modrm is outside 00h - BFh) (mod == 11) + /* DB C0 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C1 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C2 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C3 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C4 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C5 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C6 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C7 */ { 0, &Ia_fcmovnb_ST0_STi }, + /* DB C8 */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB C9 */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB CA */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB CB */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB CC */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB CD */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB CE */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB CF */ { 0, &Ia_fcmovne_ST0_STi }, + /* DB D0 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D1 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D2 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D3 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D4 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D5 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D6 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D7 */ { 0, &Ia_fcmovnbe_ST0_STi }, + /* DB D8 */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB D9 */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB DA */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB DB */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB DC */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB DD */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB DE */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB DF */ { 0, &Ia_fcmovnu_ST0_STi }, + /* DB E0 */ { 0, &Ia_feni }, + /* DB E1 */ { 0, &Ia_fdisi }, + /* DB E2 */ { 0, &Ia_fnclex }, + /* DB E3 */ { 0, &Ia_fninit }, + /* DB E4 */ { 0, &Ia_fsetpm }, + /* DB E5 */ { 0, &Ia_Invalid }, + /* DB E6 */ { 0, &Ia_Invalid }, + /* DB E7 */ { 0, &Ia_Invalid }, + /* DB E8 */ { 0, &Ia_fucomi_ST0_STi }, + /* DB E9 */ { 0, &Ia_fucomi_ST0_STi }, + /* DB EA */ { 0, &Ia_fucomi_ST0_STi }, + /* DB EB */ { 0, &Ia_fucomi_ST0_STi }, + /* DB EC */ { 0, &Ia_fucomi_ST0_STi }, + /* DB ED */ { 0, &Ia_fucomi_ST0_STi }, + /* DB EE */ { 0, &Ia_fucomi_ST0_STi }, + /* DB EF */ { 0, &Ia_fucomi_ST0_STi }, + /* DB F0 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F1 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F2 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F3 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F4 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F5 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F6 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F7 */ { 0, &Ia_fcomi_ST0_STi }, + /* DB F8 */ { 0, &Ia_Invalid }, + /* DB F9 */ { 0, &Ia_Invalid }, + /* DB FA */ { 0, &Ia_Invalid }, + /* DB FB */ { 0, &Ia_Invalid }, + /* DB FC */ { 0, &Ia_Invalid }, + /* DB FD */ { 0, &Ia_Invalid }, + /* DB FE */ { 0, &Ia_Invalid }, + /* DB FF */ { 0, &Ia_Invalid }, + + // DC (modrm is outside 00h - BFh) (mod == 11) + /* DC C0 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C1 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C2 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C3 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C4 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C5 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C6 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C7 */ { 0, &Ia_fadd_STi_ST0 }, + /* DC C8 */ { 0, &Ia_fmul_STi_ST0 }, + /* DC C9 */ { 0, &Ia_fmul_STi_ST0 }, + /* DC CA */ { 0, &Ia_fmul_STi_ST0 }, + /* DC CB */ { 0, &Ia_fmul_STi_ST0 }, + /* DC CC */ { 0, &Ia_fmul_STi_ST0 }, + /* DC CD */ { 0, &Ia_fmul_STi_ST0 }, + /* DC CE */ { 0, &Ia_fmul_STi_ST0 }, + /* DC CF */ { 0, &Ia_fmul_STi_ST0 }, + /* DC D0 */ { 0, &Ia_Invalid }, + /* DC D1 */ { 0, &Ia_Invalid }, + /* DC D2 */ { 0, &Ia_Invalid }, + /* DC D3 */ { 0, &Ia_Invalid }, + /* DC D4 */ { 0, &Ia_Invalid }, + /* DC D5 */ { 0, &Ia_Invalid }, + /* DC D6 */ { 0, &Ia_Invalid }, + /* DC D7 */ { 0, &Ia_Invalid }, + /* DC D8 */ { 0, &Ia_Invalid }, + /* DC D9 */ { 0, &Ia_Invalid }, + /* DC DA */ { 0, &Ia_Invalid }, + /* DC DB */ { 0, &Ia_Invalid }, + /* DC DC */ { 0, &Ia_Invalid }, + /* DC DD */ { 0, &Ia_Invalid }, + /* DC DE */ { 0, &Ia_Invalid }, + /* DC DF */ { 0, &Ia_Invalid }, + /* DC E0 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E1 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E2 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E3 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E4 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E5 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E6 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E7 */ { 0, &Ia_fsubr_STi_ST0 }, + /* DC E8 */ { 0, &Ia_fsub_STi_ST0 }, + /* DC E9 */ { 0, &Ia_fsub_STi_ST0 }, + /* DC EA */ { 0, &Ia_fsub_STi_ST0 }, + /* DC EB */ { 0, &Ia_fsub_STi_ST0 }, + /* DC EC */ { 0, &Ia_fsub_STi_ST0 }, + /* DC ED */ { 0, &Ia_fsub_STi_ST0 }, + /* DC EE */ { 0, &Ia_fsub_STi_ST0 }, + /* DC EF */ { 0, &Ia_fsub_STi_ST0 }, + /* DC F0 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F1 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F2 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F3 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F4 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F5 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F6 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F7 */ { 0, &Ia_fdivr_STi_ST0 }, + /* DC F8 */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC F9 */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC FA */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC FB */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC FC */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC FD */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC FE */ { 0, &Ia_fdiv_STi_ST0 }, + /* DC FF */ { 0, &Ia_fdiv_STi_ST0 }, + + // DD (modrm is outside 00h - BFh) (mod == 11) + /* DD C0 */ { 0, &Ia_ffree_STi }, + /* DD C1 */ { 0, &Ia_ffree_STi }, + /* DD C2 */ { 0, &Ia_ffree_STi }, + /* DD C3 */ { 0, &Ia_ffree_STi }, + /* DD C4 */ { 0, &Ia_ffree_STi }, + /* DD C5 */ { 0, &Ia_ffree_STi }, + /* DD C6 */ { 0, &Ia_ffree_STi }, + /* DD C7 */ { 0, &Ia_ffree_STi }, + /* DD C8 */ { 0, &Ia_Invalid }, + /* DD C9 */ { 0, &Ia_Invalid }, + /* DD CA */ { 0, &Ia_Invalid }, + /* DD CB */ { 0, &Ia_Invalid }, + /* DD CC */ { 0, &Ia_Invalid }, + /* DD CD */ { 0, &Ia_Invalid }, + /* DD CE */ { 0, &Ia_Invalid }, + /* DD CF */ { 0, &Ia_Invalid }, + /* DD D0 */ { 0, &Ia_fst_STi }, + /* DD D1 */ { 0, &Ia_fst_STi }, + /* DD D2 */ { 0, &Ia_fst_STi }, + /* DD D3 */ { 0, &Ia_fst_STi }, + /* DD D4 */ { 0, &Ia_fst_STi }, + /* DD D5 */ { 0, &Ia_fst_STi }, + /* DD D6 */ { 0, &Ia_fst_STi }, + /* DD D7 */ { 0, &Ia_fst_STi }, + /* DD D8 */ { 0, &Ia_fstp_STi }, + /* DD D9 */ { 0, &Ia_fstp_STi }, + /* DD DA */ { 0, &Ia_fstp_STi }, + /* DD DB */ { 0, &Ia_fstp_STi }, + /* DD DC */ { 0, &Ia_fstp_STi }, + /* DD DD */ { 0, &Ia_fstp_STi }, + /* DD DE */ { 0, &Ia_fstp_STi }, + /* DD DF */ { 0, &Ia_fstp_STi }, + /* DD E0 */ { 0, &Ia_fucom_STi }, + /* DD E1 */ { 0, &Ia_fucom_STi }, + /* DD E2 */ { 0, &Ia_fucom_STi }, + /* DD E3 */ { 0, &Ia_fucom_STi }, + /* DD E4 */ { 0, &Ia_fucom_STi }, + /* DD E5 */ { 0, &Ia_fucom_STi }, + /* DD E6 */ { 0, &Ia_fucom_STi }, + /* DD E7 */ { 0, &Ia_fucom_STi }, + /* DD E8 */ { 0, &Ia_fucomp_STi }, + /* DD E9 */ { 0, &Ia_fucomp_STi }, + /* DD EA */ { 0, &Ia_fucomp_STi }, + /* DD EB */ { 0, &Ia_fucomp_STi }, + /* DD EC */ { 0, &Ia_fucomp_STi }, + /* DD ED */ { 0, &Ia_fucomp_STi }, + /* DD EE */ { 0, &Ia_fucomp_STi }, + /* DD EF */ { 0, &Ia_fucomp_STi }, + /* DD F0 */ { 0, &Ia_Invalid }, + /* DD F1 */ { 0, &Ia_Invalid }, + /* DD F2 */ { 0, &Ia_Invalid }, + /* DD F3 */ { 0, &Ia_Invalid }, + /* DD F4 */ { 0, &Ia_Invalid }, + /* DD F5 */ { 0, &Ia_Invalid }, + /* DD F6 */ { 0, &Ia_Invalid }, + /* DD F7 */ { 0, &Ia_Invalid }, + /* DD F8 */ { 0, &Ia_Invalid }, + /* DD F9 */ { 0, &Ia_Invalid }, + /* DD FA */ { 0, &Ia_Invalid }, + /* DD FB */ { 0, &Ia_Invalid }, + /* DD FC */ { 0, &Ia_Invalid }, + /* DD FD */ { 0, &Ia_Invalid }, + /* DD FE */ { 0, &Ia_Invalid }, + /* DD FF */ { 0, &Ia_Invalid }, + + // DE (modrm is outside 00h - BFh) (mod == 11) + /* DE C0 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C1 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C2 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C3 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C4 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C5 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C6 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C7 */ { 0, &Ia_faddp_STi_ST0 }, + /* DE C8 */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE C9 */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE CA */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE CB */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE CC */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE CD */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE CE */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE CF */ { 0, &Ia_fmulp_STi_ST0 }, + /* DE D0 */ { 0, &Ia_Invalid }, + /* DE D1 */ { 0, &Ia_Invalid }, + /* DE D2 */ { 0, &Ia_Invalid }, + /* DE D3 */ { 0, &Ia_Invalid }, + /* DE D4 */ { 0, &Ia_Invalid }, + /* DE D5 */ { 0, &Ia_Invalid }, + /* DE D6 */ { 0, &Ia_Invalid }, + /* DE D7 */ { 0, &Ia_Invalid }, + /* DE D8 */ { 0, &Ia_Invalid }, + /* DE D9 */ { 0, &Ia_fcompp }, + /* DE DA */ { 0, &Ia_Invalid }, + /* DE DB */ { 0, &Ia_Invalid }, + /* DE DC */ { 0, &Ia_Invalid }, + /* DE DD */ { 0, &Ia_Invalid }, + /* DE DE */ { 0, &Ia_Invalid }, + /* DE DF */ { 0, &Ia_Invalid }, + /* DE E0 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E1 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E2 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E3 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E4 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E5 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E6 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E7 */ { 0, &Ia_fsubrp_STi_ST0 }, + /* DE E8 */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE E9 */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE EA */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE EB */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE EC */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE ED */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE EE */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE EF */ { 0, &Ia_fsubp_STi_ST0 }, + /* DE F0 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F1 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F2 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F3 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F4 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F5 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F6 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F7 */ { 0, &Ia_fdivrp_STi_ST0 }, + /* DE F8 */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE F9 */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE FA */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE FB */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE FC */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE FD */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE FE */ { 0, &Ia_fdivp_STi_ST0 }, + /* DE FF */ { 0, &Ia_fdivp_STi_ST0 }, + + // DF (modrm is outside 00h - BFh) (mod == 11) + /* DF C0 */ { 0, &Ia_ffreep_STi }, // 287 compatibility opcode + /* DF C1 */ { 0, &Ia_ffreep_STi }, + /* DF C2 */ { 0, &Ia_ffreep_STi }, + /* DF C3 */ { 0, &Ia_ffreep_STi }, + /* DF C4 */ { 0, &Ia_ffreep_STi }, + /* DF C5 */ { 0, &Ia_ffreep_STi }, + /* DF C6 */ { 0, &Ia_ffreep_STi }, + /* DF C7 */ { 0, &Ia_ffreep_STi }, + /* DF C8 */ { 0, &Ia_Invalid }, + /* DF C9 */ { 0, &Ia_Invalid }, + /* DF CA */ { 0, &Ia_Invalid }, + /* DF CB */ { 0, &Ia_Invalid }, + /* DF CC */ { 0, &Ia_Invalid }, + /* DF CD */ { 0, &Ia_Invalid }, + /* DF CE */ { 0, &Ia_Invalid }, + /* DF CF */ { 0, &Ia_Invalid }, + /* DF D0 */ { 0, &Ia_Invalid }, + /* DF D1 */ { 0, &Ia_Invalid }, + /* DF D2 */ { 0, &Ia_Invalid }, + /* DF D3 */ { 0, &Ia_Invalid }, + /* DF D4 */ { 0, &Ia_Invalid }, + /* DF D5 */ { 0, &Ia_Invalid }, + /* DF D6 */ { 0, &Ia_Invalid }, + /* DF D7 */ { 0, &Ia_Invalid }, + /* DF D8 */ { 0, &Ia_Invalid }, + /* DF D9 */ { 0, &Ia_Invalid }, + /* DF DA */ { 0, &Ia_Invalid }, + /* DF DB */ { 0, &Ia_Invalid }, + /* DF DC */ { 0, &Ia_Invalid }, + /* DF DD */ { 0, &Ia_Invalid }, + /* DF DE */ { 0, &Ia_Invalid }, + /* DF DF */ { 0, &Ia_Invalid }, + /* DF E0 */ { 0, &Ia_fnstsw_AX }, + /* DF E1 */ { 0, &Ia_Invalid }, + /* DF E2 */ { 0, &Ia_Invalid }, + /* DF E3 */ { 0, &Ia_Invalid }, + /* DF E4 */ { 0, &Ia_Invalid }, + /* DF E5 */ { 0, &Ia_Invalid }, + /* DF E6 */ { 0, &Ia_Invalid }, + /* DF E7 */ { 0, &Ia_Invalid }, + /* DF E8 */ { 0, &Ia_fucomip_ST0_STi }, + /* DF E9 */ { 0, &Ia_fucomip_ST0_STi }, + /* DF EA */ { 0, &Ia_fucomip_ST0_STi }, + /* DF EB */ { 0, &Ia_fucomip_ST0_STi }, + /* DF EC */ { 0, &Ia_fucomip_ST0_STi }, + /* DF ED */ { 0, &Ia_fucomip_ST0_STi }, + /* DF EE */ { 0, &Ia_fucomip_ST0_STi }, + /* DF EF */ { 0, &Ia_fucomip_ST0_STi }, + /* DF F0 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F1 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F2 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F3 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F4 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F5 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F6 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F7 */ { 0, &Ia_fcomip_ST0_STi }, + /* DF F8 */ { 0, &Ia_Invalid }, + /* DF F9 */ { 0, &Ia_Invalid }, + /* DF FA */ { 0, &Ia_Invalid }, + /* DF FB */ { 0, &Ia_Invalid }, + /* DF FC */ { 0, &Ia_Invalid }, + /* DF FD */ { 0, &Ia_Invalid }, + /* DF FE */ { 0, &Ia_Invalid }, + /* DF FF */ { 0, &Ia_Invalid }, +}; + +/* ************************************************************************ */ +/* 16-bit operand size */ + +static BxDisasmOpcodeTable_t BxDisasmOpcodes16[256*2] = { + // 256 entries for single byte opcodes + /* 00 */ { 0, &Ia_addb_Eb_Gb }, + /* 01 */ { 0, &Ia_addw_Ew_Gw }, + /* 02 */ { 0, &Ia_addb_Gb_Eb }, + /* 03 */ { 0, &Ia_addw_Gw_Ew }, + /* 04 */ { 0, &Ia_addb_AL_Ib }, + /* 05 */ { 0, &Ia_addw_AX_Iw }, + /* 06 */ { 0, &Ia_pushw_ES }, + /* 07 */ { 0, &Ia_popw_ES }, + /* 08 */ { 0, &Ia_orb_Eb_Gb }, + /* 09 */ { 0, &Ia_orw_Ew_Gw }, + /* 0A */ { 0, &Ia_orb_Gb_Eb }, + /* 0B */ { 0, &Ia_orw_Gw_Ew }, + /* 0C */ { 0, &Ia_orb_AL_Ib }, + /* 0D */ { 0, &Ia_orw_AX_Iw }, + /* 0E */ { 0, &Ia_pushw_CS }, + /* 0F */ { 0, &Ia_error }, // 2 byte escape + /* 10 */ { 0, &Ia_adcb_Eb_Gb }, + /* 11 */ { 0, &Ia_adcw_Ew_Gw }, + /* 12 */ { 0, &Ia_adcb_Gb_Eb }, + /* 13 */ { 0, &Ia_adcw_Gw_Ew }, + /* 14 */ { 0, &Ia_adcb_AL_Ib }, + /* 15 */ { 0, &Ia_adcw_AX_Iw }, + /* 16 */ { 0, &Ia_pushw_SS }, + /* 17 */ { 0, &Ia_popw_SS }, + /* 18 */ { 0, &Ia_sbbb_Eb_Gb }, + /* 19 */ { 0, &Ia_sbbw_Ew_Gw }, + /* 1A */ { 0, &Ia_sbbb_Gb_Eb }, + /* 1B */ { 0, &Ia_sbbw_Gw_Ew }, + /* 1C */ { 0, &Ia_sbbb_AL_Ib }, + /* 1D */ { 0, &Ia_sbbw_AX_Iw }, + /* 1E */ { 0, &Ia_pushw_DS }, + /* 1F */ { 0, &Ia_popw_DS }, + /* 20 */ { 0, &Ia_andb_Eb_Gb }, + /* 21 */ { 0, &Ia_andw_Ew_Gw }, + /* 22 */ { 0, &Ia_andb_Gb_Eb }, + /* 23 */ { 0, &Ia_andw_Gw_Ew }, + /* 24 */ { 0, &Ia_andb_AL_Ib }, + /* 25 */ { 0, &Ia_andw_AX_Iw }, + /* 26 */ { 0, &Ia_prefix_es }, // ES: + /* 27 */ { 0, &Ia_daa }, + /* 28 */ { 0, &Ia_subb_Eb_Gb }, + /* 29 */ { 0, &Ia_subw_Ew_Gw }, + /* 2A */ { 0, &Ia_subb_Gb_Eb }, + /* 2B */ { 0, &Ia_subw_Gw_Ew }, + /* 2C */ { 0, &Ia_subb_AL_Ib }, + /* 2D */ { 0, &Ia_subw_AX_Iw }, + /* 2E */ { 0, &Ia_prefix_cs }, // CS: + /* 2F */ { 0, &Ia_das }, + /* 30 */ { 0, &Ia_xorb_Eb_Gb }, + /* 31 */ { 0, &Ia_xorw_Ew_Gw }, + /* 32 */ { 0, &Ia_xorb_Gb_Eb }, + /* 33 */ { 0, &Ia_xorw_Gw_Ew }, + /* 34 */ { 0, &Ia_xorb_AL_Ib }, + /* 35 */ { 0, &Ia_xorw_AX_Iw }, + /* 36 */ { 0, &Ia_prefix_ss }, // SS: + /* 37 */ { 0, &Ia_aaa }, + /* 38 */ { 0, &Ia_cmpb_Eb_Gb }, + /* 39 */ { 0, &Ia_cmpw_Ew_Gw }, + /* 3A */ { 0, &Ia_cmpb_Gb_Eb }, + /* 3B */ { 0, &Ia_cmpw_Gw_Ew }, + /* 3C */ { 0, &Ia_cmpb_AL_Ib }, + /* 3D */ { 0, &Ia_cmpw_AX_Iw }, + /* 3E */ { 0, &Ia_prefix_ds }, // DS: + /* 3F */ { 0, &Ia_aas }, + /* 40 */ { 0, &Ia_incw_RX }, + /* 41 */ { 0, &Ia_incw_RX }, + /* 42 */ { 0, &Ia_incw_RX }, + /* 43 */ { 0, &Ia_incw_RX }, + /* 44 */ { 0, &Ia_incw_RX }, + /* 45 */ { 0, &Ia_incw_RX }, + /* 46 */ { 0, &Ia_incw_RX }, + /* 47 */ { 0, &Ia_incw_RX }, + /* 48 */ { 0, &Ia_decw_RX }, + /* 49 */ { 0, &Ia_decw_RX }, + /* 4A */ { 0, &Ia_decw_RX }, + /* 4B */ { 0, &Ia_decw_RX }, + /* 4C */ { 0, &Ia_decw_RX }, + /* 4D */ { 0, &Ia_decw_RX }, + /* 4E */ { 0, &Ia_decw_RX }, + /* 4F */ { 0, &Ia_decw_RX }, + /* 50 */ { 0, &Ia_pushw_RX }, + /* 51 */ { 0, &Ia_pushw_RX }, + /* 52 */ { 0, &Ia_pushw_RX }, + /* 53 */ { 0, &Ia_pushw_RX }, + /* 54 */ { 0, &Ia_pushw_RX }, + /* 55 */ { 0, &Ia_pushw_RX }, + /* 56 */ { 0, &Ia_pushw_RX }, + /* 57 */ { 0, &Ia_pushw_RX }, + /* 58 */ { 0, &Ia_popw_RX }, + /* 59 */ { 0, &Ia_popw_RX }, + /* 5A */ { 0, &Ia_popw_RX }, + /* 5B */ { 0, &Ia_popw_RX }, + /* 5C */ { 0, &Ia_popw_RX }, + /* 5D */ { 0, &Ia_popw_RX }, + /* 5E */ { 0, &Ia_popw_RX }, + /* 5F */ { 0, &Ia_popw_RX }, + /* 60 */ { 0, &Ia_pushaw }, + /* 61 */ { 0, &Ia_popaw }, + /* 62 */ { 0, &Ia_boundw_Gw_Ma }, + /* 63 */ { 0, &Ia_arpl_Ew_Rw }, + /* 64 */ { 0, &Ia_prefix_fs }, // FS: + /* 65 */ { 0, &Ia_prefix_gs }, // GS: + /* 66 */ { 0, &Ia_prefix_osize }, // OSIZE: + /* 67 */ { 0, &Ia_prefix_asize }, // ASIZE: + /* 68 */ { 0, &Ia_pushw_Iw }, + /* 69 */ { 0, &Ia_imulw_Gw_Ew_Iw }, + /* 6A */ { 0, &Ia_pushw_Iw }, + /* 6B */ { 0, &Ia_imulw_Gw_Ew_Iw }, + /* 6C */ { 0, &Ia_insb_Yb_DX }, + /* 6D */ { 0, &Ia_insw_Yw_DX }, + /* 6E */ { 0, &Ia_outsb_DX_Xb }, + /* 6F */ { 0, &Ia_outsw_DX_Xw }, + /* 70 */ { 0, &Ia_jo_Jb }, + /* 71 */ { 0, &Ia_jno_Jb }, + /* 72 */ { 0, &Ia_jb_Jb }, + /* 73 */ { 0, &Ia_jnb_Jb }, + /* 74 */ { 0, &Ia_jz_Jb }, + /* 75 */ { 0, &Ia_jnz_Jb }, + /* 76 */ { 0, &Ia_jbe_Jb }, + /* 77 */ { 0, &Ia_jnbe_Jb }, + /* 78 */ { 0, &Ia_js_Jb }, + /* 79 */ { 0, &Ia_jns_Jb }, + /* 7A */ { 0, &Ia_jp_Jb }, + /* 7B */ { 0, &Ia_jnp_Jb }, + /* 7C */ { 0, &Ia_jl_Jb }, + /* 7D */ { 0, &Ia_jnl_Jb }, + /* 7E */ { 0, &Ia_jle_Jb }, + /* 7F */ { 0, &Ia_jnle_Jb }, + /* 80 */ { GRPN(G1EbIb) }, + /* 81 */ { GRPN(G1EwIw) }, + /* 82 */ { GRPN(G1EbIb) }, + /* 83 */ { GRPN(G1EwIb) }, + /* 84 */ { 0, &Ia_testb_Eb_Gb }, + /* 85 */ { 0, &Ia_testw_Ew_Gw }, + /* 86 */ { 0, &Ia_xchgb_Eb_Gb }, + /* 87 */ { 0, &Ia_xchgw_Ew_Gw }, + /* 88 */ { 0, &Ia_movb_Eb_Gb }, + /* 89 */ { 0, &Ia_movw_Ew_Gw }, + /* 8A */ { 0, &Ia_movb_Gb_Eb }, + /* 8B */ { 0, &Ia_movw_Gw_Ew }, + /* 8C */ { 0, &Ia_movw_Ew_Sw }, + /* 8D */ { 0, &Ia_leaw_Gw_Mw }, + /* 8E */ { 0, &Ia_movw_Sw_Ew }, + /* 8F */ { 0, &Ia_popw_Ew }, + /* 90 */ { 0, &Ia_nop }, + /* 91 */ { 0, &Ia_xchgw_RX_AX }, + /* 92 */ { 0, &Ia_xchgw_RX_AX }, + /* 93 */ { 0, &Ia_xchgw_RX_AX }, + /* 94 */ { 0, &Ia_xchgw_RX_AX }, + /* 95 */ { 0, &Ia_xchgw_RX_AX }, + /* 96 */ { 0, &Ia_xchgw_RX_AX }, + /* 97 */ { 0, &Ia_xchgw_RX_AX }, + /* 98 */ { 0, &Ia_cbw }, + /* 99 */ { 0, &Ia_cwd }, + /* 9A */ { 0, &Ia_lcall_Apw }, + /* 9B */ { 0, &Ia_fwait }, + /* 9C */ { 0, &Ia_pushfw }, + /* 9D */ { 0, &Ia_popfw }, + /* 9E */ { 0, &Ia_sahf }, + /* 9F */ { 0, &Ia_lahf }, + /* A0 */ { 0, &Ia_movb_AL_Ob }, + /* A1 */ { 0, &Ia_movw_AX_Ow }, + /* A0 */ { 0, &Ia_movb_Ob_AL }, + /* A1 */ { 0, &Ia_movw_Ow_AX }, + /* A4 */ { 0, &Ia_movsb_Yb_Xb }, + /* A5 */ { 0, &Ia_movsw_Yw_Xw }, + /* A6 */ { 0, &Ia_cmpsb_Yb_Xb }, + /* A7 */ { 0, &Ia_cmpsw_Yw_Xw }, + /* A8 */ { 0, &Ia_testb_AL_Ib }, + /* A9 */ { 0, &Ia_testw_AX_Iw }, + /* AA */ { 0, &Ia_stosb_Yb_AL }, + /* AB */ { 0, &Ia_stosw_Yw_AX }, + /* AC */ { 0, &Ia_lodsb_AL_Xb }, + /* AD */ { 0, &Ia_lodsw_AX_Xw }, + /* AE */ { 0, &Ia_scasb_Yb_AL }, + /* AF */ { 0, &Ia_scasw_Yw_AX }, + /* B0 */ { 0, &Ia_movb_R8_Ib }, + /* B1 */ { 0, &Ia_movb_R8_Ib }, + /* B2 */ { 0, &Ia_movb_R8_Ib }, + /* B3 */ { 0, &Ia_movb_R8_Ib }, + /* B4 */ { 0, &Ia_movb_R8_Ib }, + /* B5 */ { 0, &Ia_movb_R8_Ib }, + /* B6 */ { 0, &Ia_movb_R8_Ib }, + /* B7 */ { 0, &Ia_movb_R8_Ib }, + /* B8 */ { 0, &Ia_movw_RX_Iw }, + /* B9 */ { 0, &Ia_movw_RX_Iw }, + /* BA */ { 0, &Ia_movw_RX_Iw }, + /* BB */ { 0, &Ia_movw_RX_Iw }, + /* BC */ { 0, &Ia_movw_RX_Iw }, + /* BD */ { 0, &Ia_movw_RX_Iw }, + /* BE */ { 0, &Ia_movw_RX_Iw }, + /* BF */ { 0, &Ia_movw_RX_Iw }, + /* C0 */ { GRPN(G2Eb) }, + /* C1 */ { GRPN(G2Ew) }, + /* C2 */ { 0, &Ia_ret_Iw }, + /* C3 */ { 0, &Ia_ret }, + /* C4 */ { 0, &Ia_lesw_Gw_Mp }, + /* C5 */ { 0, &Ia_ldsw_Gw_Mp }, + /* C6 */ { 0, &Ia_movb_Eb_Ib }, + /* C7 */ { 0, &Ia_movw_Ew_Iw }, + /* C8 */ { 0, &Ia_enter }, + /* C9 */ { 0, &Ia_leave }, + /* CA */ { 0, &Ia_lret_Iw }, + /* CB */ { 0, &Ia_lret }, + /* CC */ { 0, &Ia_int3 }, + /* CD */ { 0, &Ia_int_Ib }, + /* CE */ { 0, &Ia_into }, + /* CF */ { 0, &Ia_iretw }, + /* D0 */ { GRPN(G2EbI1) }, + /* D1 */ { GRPN(G2EwI1) }, + /* D2 */ { GRPN(G2EbCL) }, + /* D3 */ { GRPN(G2EwCL) }, + /* D4 */ { 0, &Ia_aam }, + /* D5 */ { 0, &Ia_aad }, + /* D6 */ { 0, &Ia_salc }, + /* D7 */ { 0, &Ia_xlat }, + /* D8 */ { GRPFP(D8) }, + /* D9 */ { GRPFP(D9) }, + /* DA */ { GRPFP(DA) }, + /* DB */ { GRPFP(DB) }, + /* DC */ { GRPFP(DC) }, + /* DD */ { GRPFP(DD) }, + /* DE */ { GRPFP(DE) }, + /* DF */ { GRPFP(DF) }, + /* E0 */ { 0, &Ia_loopne_Jb }, + /* E1 */ { 0, &Ia_loope_Jb }, + /* E2 */ { 0, &Ia_loop_Jb }, + /* E3 */ { 0, &Ia_jcxz_Jb }, + /* E4 */ { 0, &Ia_inb_AL_Ib }, + /* E5 */ { 0, &Ia_inw_AX_Ib }, + /* E6 */ { 0, &Ia_outb_Ib_AL }, + /* E7 */ { 0, &Ia_outw_Ib_AX }, + /* E8 */ { 0, &Ia_call_Jw }, + /* E9 */ { 0, &Ia_jmp_Jw }, + /* EA */ { 0, &Ia_ljmp_Apw }, + /* EB */ { 0, &Ia_jmp_Jb }, + /* EC */ { 0, &Ia_inb_AL_DX }, + /* ED */ { 0, &Ia_inw_AX_DX }, + /* EE */ { 0, &Ia_outb_DX_AL }, + /* EF */ { 0, &Ia_outw_DX_AX }, + /* F0 */ { 0, &Ia_prefix_lock }, // LOCK: + /* F1 */ { 0, &Ia_int1 }, + /* F2 */ { 0, &Ia_prefix_repne }, // REPNE: + /* F3 */ { 0, &Ia_prefix_rep }, // REP: + /* F4 */ { 0, &Ia_hlt }, + /* F5 */ { 0, &Ia_cmc }, + /* F6 */ { GRPN(G3Eb) }, + /* F7 */ { GRPN(G3Ew) }, + /* F8 */ { 0, &Ia_clc }, + /* F9 */ { 0, &Ia_stc }, + /* FA */ { 0, &Ia_cli }, + /* FB */ { 0, &Ia_sti }, + /* FC */ { 0, &Ia_cld }, + /* FD */ { 0, &Ia_std }, + /* FE */ { GRPN(G4) }, + /* FF */ { GRPN(G5w) }, + + // 256 entries for two byte opcodes + /* 0F 00 */ { GRPN(G6) }, + /* 0F 01 */ { GRPN(G7) }, + /* 0F 02 */ { 0, &Ia_larw_Gw_Ew }, + /* 0F 03 */ { 0, &Ia_lslw_Gw_Ew }, + /* 0F 04 */ { 0, &Ia_Invalid }, + /* 0F 05 */ { 0, &Ia_syscall }, + /* 0F 06 */ { 0, &Ia_clts }, + /* 0F 07 */ { 0, &Ia_sysret }, + /* 0F 08 */ { 0, &Ia_invd }, + /* 0F 09 */ { 0, &Ia_wbinvd }, + /* 0F 0A */ { 0, &Ia_Invalid }, + /* 0F 0B */ { 0, &Ia_ud2a }, + /* 0F 0C */ { 0, &Ia_Invalid }, + /* 0F 0D */ { 0, &Ia_prefetch }, // 3DNow! + /* 0F 0E */ { 0, &Ia_femms }, // 3DNow! + /* 0F 0F */ { GRP3DNOW }, + /* 0F 10 */ { GRPSSE(0f10) }, + /* 0F 11 */ { GRPSSE(0f11) }, + /* 0F 12 */ { GRPSSE(0f12) }, + /* 0F 13 */ { GRPSSE(0f13) }, + /* 0F 14 */ { GRPSSE(0f14) }, + /* 0F 15 */ { GRPSSE(0f15) }, + /* 0F 16 */ { GRPSSE(0f16) }, + /* 0F 17 */ { GRPSSE(0f17) }, + /* 0F 18 */ { GRPN(G16) }, + /* 0F 19 */ { 0, &Ia_Invalid }, + /* 0F 1A */ { 0, &Ia_Invalid }, + /* 0F 1B */ { 0, &Ia_Invalid }, + /* 0F 1C */ { 0, &Ia_Invalid }, + /* 0F 1D */ { 0, &Ia_Invalid }, + /* 0F 1E */ { 0, &Ia_Invalid }, + /* 0F 1F */ { 0, &Ia_Invalid }, + /* 0F 20 */ { 0, &Ia_movl_Rd_Cd }, + /* 0F 21 */ { 0, &Ia_movl_Rd_Dd }, + /* 0F 22 */ { 0, &Ia_movl_Cd_Rd }, + /* 0F 23 */ { 0, &Ia_movl_Dd_Rd }, + /* 0F 24 */ { 0, &Ia_movl_Rd_Td }, + /* 0F 25 */ { 0, &Ia_Invalid }, + /* 0F 26 */ { 0, &Ia_movl_Td_Rd }, + /* 0F 27 */ { 0, &Ia_Invalid }, + /* 0F 28 */ { GRPSSE(0f28) }, + /* 0F 29 */ { GRPSSE(0f29) }, + /* 0F 2A */ { GRPSSE(0f2a) }, + /* 0F 2B */ { GRPSSE(0f2b) }, + /* 0F 2C */ { GRPSSE(0f2c) }, + /* 0F 2D */ { GRPSSE(0f2d) }, + /* 0F 2E */ { GRPSSE(0f2e) }, + /* 0F 2F */ { GRPSSE(0f2f) }, + /* 0F 30 */ { 0, &Ia_wrmsr }, + /* 0F 31 */ { 0, &Ia_rdtsc }, + /* 0F 32 */ { 0, &Ia_rdmsr }, + /* 0F 33 */ { 0, &Ia_rdpmc }, + /* 0F 34 */ { 0, &Ia_sysenter }, + /* 0F 35 */ { 0, &Ia_sysexit }, + /* 0F 36 */ { 0, &Ia_Invalid }, + /* 0F 37 */ { 0, &Ia_Invalid }, + /* 0F 38 */ { 0, &Ia_Invalid }, + /* 0F 39 */ { 0, &Ia_Invalid }, + /* 0F 3A */ { 0, &Ia_Invalid }, + /* 0F 3B */ { 0, &Ia_Invalid }, + /* 0F 3C */ { 0, &Ia_Invalid }, + /* 0F 3D */ { 0, &Ia_Invalid }, + /* 0F 3E */ { 0, &Ia_Invalid }, + /* 0F 3F */ { 0, &Ia_Invalid }, + /* 0F 40 */ { 0, &Ia_cmovow_Gw_Ew }, + /* 0F 41 */ { 0, &Ia_cmovnow_Gw_Ew }, + /* 0F 42 */ { 0, &Ia_cmovcw_Gw_Ew }, + /* 0F 43 */ { 0, &Ia_cmovncw_Gw_Ew }, + /* 0F 44 */ { 0, &Ia_cmovzw_Gw_Ew }, + /* 0F 45 */ { 0, &Ia_cmovnzw_Gw_Ew }, + /* 0F 46 */ { 0, &Ia_cmovnaw_Gw_Ew }, + /* 0F 47 */ { 0, &Ia_cmovaw_Gw_Ew }, + /* 0F 48 */ { 0, &Ia_cmovsw_Gw_Ew }, + /* 0F 49 */ { 0, &Ia_cmovnsw_Gw_Ew }, + /* 0F 4A */ { 0, &Ia_cmovpw_Gw_Ew }, + /* 0F 4B */ { 0, &Ia_cmovnpw_Gw_Ew }, + /* 0F 4C */ { 0, &Ia_cmovlw_Gw_Ew }, + /* 0F 4D */ { 0, &Ia_cmovnlw_Gw_Ew }, + /* 0F 4E */ { 0, &Ia_cmovngw_Gw_Ew }, + /* 0F 4F */ { 0, &Ia_cmovgw_Gw_Ew }, + /* 0F 50 */ { GRPSSE(0f50) }, + /* 0F 51 */ { GRPSSE(0f51) }, + /* 0F 52 */ { GRPSSE(0f52) }, + /* 0F 53 */ { GRPSSE(0f53) }, + /* 0F 54 */ { GRPSSE(0f54) }, + /* 0F 55 */ { GRPSSE(0f55) }, + /* 0F 56 */ { GRPSSE(0f56) }, + /* 0F 57 */ { GRPSSE(0f57) }, + /* 0F 58 */ { GRPSSE(0f58) }, + /* 0F 59 */ { GRPSSE(0f59) }, + /* 0F 5A */ { GRPSSE(0f5a) }, + /* 0F 5B */ { GRPSSE(0f5b) }, + /* 0F 5C */ { GRPSSE(0f5c) }, + /* 0F 5D */ { GRPSSE(0f5d) }, + /* 0F 5E */ { GRPSSE(0f5e) }, + /* 0F 5F */ { GRPSSE(0f5f) }, + /* 0F 60 */ { GRPSSE(0f60) }, + /* 0F 61 */ { GRPSSE(0f61) }, + /* 0F 62 */ { GRPSSE(0f62) }, + /* 0F 63 */ { GRPSSE(0f63) }, + /* 0F 64 */ { GRPSSE(0f64) }, + /* 0F 65 */ { GRPSSE(0f65) }, + /* 0F 66 */ { GRPSSE(0f66) }, + /* 0F 67 */ { GRPSSE(0f67) }, + /* 0F 68 */ { GRPSSE(0f68) }, + /* 0F 69 */ { GRPSSE(0f69) }, + /* 0F 6A */ { GRPSSE(0f6a) }, + /* 0F 6B */ { GRPSSE(0f6b) }, + /* 0F 6C */ { GRPSSE(0f6c) }, + /* 0F 6D */ { GRPSSE(0f6d) }, + /* 0F 6E */ { GRPSSE(0f6e) }, + /* 0F 6F */ { GRPSSE(0f6f) }, + /* 0F 70 */ { GRPSSE(0f70) }, + /* 0F 71 */ { GRPN(G12) }, + /* 0F 72 */ { GRPN(G13) }, + /* 0F 73 */ { GRPN(G14) }, + /* 0F 74 */ { GRPSSE(0f74) }, + /* 0F 75 */ { GRPSSE(0f75) }, + /* 0F 76 */ { GRPSSE(0f76) }, + /* 0F 77 */ { 0, &Ia_emms }, + /* 0F 78 */ { 0, &Ia_Invalid }, + /* 0F 79 */ { 0, &Ia_Invalid }, + /* 0F 7A */ { 0, &Ia_Invalid }, + /* 0F 7B */ { 0, &Ia_Invalid }, + /* 0F 7C */ { GRPSSE(0f7c) }, + /* 0F 7D */ { GRPSSE(0f7d) }, + /* 0F 7E */ { GRPSSE(0f7e) }, + /* 0F 7F */ { GRPSSE(0f7f) }, + /* 0F 80 */ { 0, &Ia_jo_Jw }, + /* 0F 81 */ { 0, &Ia_jno_Jw }, + /* 0F 82 */ { 0, &Ia_jb_Jw }, + /* 0F 83 */ { 0, &Ia_jnb_Jw }, + /* 0F 84 */ { 0, &Ia_jz_Jw }, + /* 0F 85 */ { 0, &Ia_jnz_Jw }, + /* 0F 86 */ { 0, &Ia_jbe_Jw }, + /* 0F 87 */ { 0, &Ia_jnbe_Jw }, + /* 0F 88 */ { 0, &Ia_js_Jw }, + /* 0F 89 */ { 0, &Ia_jns_Jw }, + /* 0F 8A */ { 0, &Ia_jp_Jw }, + /* 0F 8B */ { 0, &Ia_jnp_Jw }, + /* 0F 8C */ { 0, &Ia_jl_Jw }, + /* 0F 8D */ { 0, &Ia_jnl_Jw }, + /* 0F 8E */ { 0, &Ia_jle_Jw }, + /* 0F 8F */ { 0, &Ia_jnle_Jw }, + /* 0F 90 */ { 0, &Ia_seto_Eb }, + /* 0F 91 */ { 0, &Ia_setno_Eb }, + /* 0F 92 */ { 0, &Ia_setb_Eb }, + /* 0F 93 */ { 0, &Ia_setnb_Eb }, + /* 0F 94 */ { 0, &Ia_setz_Eb }, + /* 0F 95 */ { 0, &Ia_setnz_Eb }, + /* 0F 96 */ { 0, &Ia_setbe_Eb }, + /* 0F 97 */ { 0, &Ia_setnbe_Eb }, + /* 0F 98 */ { 0, &Ia_sets_Eb }, + /* 0F 99 */ { 0, &Ia_setns_Eb }, + /* 0F 9A */ { 0, &Ia_setp_Eb }, + /* 0F 9B */ { 0, &Ia_setnp_Eb }, + /* 0F 9C */ { 0, &Ia_setl_Eb }, + /* 0F 9D */ { 0, &Ia_setnl_Eb }, + /* 0F 9E */ { 0, &Ia_setle_Eb }, + /* 0F 9F */ { 0, &Ia_setnle_Eb }, + /* 0F A0 */ { 0, &Ia_pushw_FS }, + /* 0F A1 */ { 0, &Ia_popw_FS }, + /* 0F A2 */ { 0, &Ia_cpuid }, + /* 0F A3 */ { 0, &Ia_btw_Ew_Gw }, + /* 0F A4 */ { 0, &Ia_shldw_Ew_Gw_Ib }, + /* 0F A5 */ { 0, &Ia_shldw_Ew_Gw_CL }, + /* 0F A6 */ { 0, &Ia_Invalid }, + /* 0F A7 */ { 0, &Ia_Invalid }, + /* 0F A8 */ { 0, &Ia_pushw_GS }, + /* 0F A9 */ { 0, &Ia_popw_GS }, + /* 0F AA */ { 0, &Ia_rsm }, + /* 0F AB */ { 0, &Ia_btsw_Ew_Gw }, + /* 0F AC */ { 0, &Ia_shrdw_Ew_Gw_Ib }, + /* 0F AD */ { 0, &Ia_shrdw_Ew_Gw_CL }, + /* 0F AE */ { GRPN(G15) }, + /* 0F AF */ { 0, &Ia_imulw_Gw_Ew }, + /* 0F B0 */ { 0, &Ia_cmpxchgb_Eb_Gb }, + /* 0F B1 */ { 0, &Ia_cmpxchgw_Ew_Gw }, + /* 0F B2 */ { 0, &Ia_lssw_Gw_Mp }, + /* 0F B3 */ { 0, &Ia_btrw_Ew_Gw }, + /* 0F B4 */ { 0, &Ia_lfsw_Gw_Mp }, + /* 0F B5 */ { 0, &Ia_lgsw_Gw_Mp }, + /* 0F B6 */ { 0, &Ia_movzbw_Gw_Eb }, + /* 0F B7 */ { 0, &Ia_movw_Gw_Ew }, + /* 0F B8 */ { 0, &Ia_Invalid }, + /* 0F B9 */ { 0, &Ia_ud2b }, + /* 0F BA */ { GRPN(G8EwIb) }, + /* 0F BB */ { 0, &Ia_btcw_Ew_Gw }, + /* 0F BC */ { 0, &Ia_bsfw_Gw_Ew }, + /* 0F BD */ { 0, &Ia_bsrw_Gw_Ew }, + /* 0F BE */ { 0, &Ia_movsbw_Gw_Eb }, + /* 0F BF */ { 0, &Ia_movw_Gw_Ew }, + /* 0F C0 */ { 0, &Ia_xaddb_Eb_Gb }, + /* 0F C0 */ { 0, &Ia_xaddw_Ew_Gw }, + /* 0F C2 */ { GRPSSE(0fc2) }, + /* 0F C3 */ { GRPSSE(0fc3) }, + /* 0F C4 */ { GRPSSE(0fc4) }, + /* 0F C5 */ { GRPSSE(0fc5) }, + /* 0F C6 */ { GRPSSE(0fc6) }, + /* 0F C7 */ { GRPN(G9) }, + /* 0F C8 */ { 0, &Ia_bswapw_RX }, + /* 0F C9 */ { 0, &Ia_bswapw_RX }, + /* 0F CA */ { 0, &Ia_bswapw_RX }, + /* 0F CB */ { 0, &Ia_bswapw_RX }, + /* 0F CC */ { 0, &Ia_bswapw_RX }, + /* 0F CD */ { 0, &Ia_bswapw_RX }, + /* 0F CE */ { 0, &Ia_bswapw_RX }, + /* 0F CF */ { 0, &Ia_bswapw_RX }, + /* 0F D0 */ { GRPSSE(0fd0) }, + /* 0F D1 */ { GRPSSE(0fd1) }, + /* 0F D2 */ { GRPSSE(0fd2) }, + /* 0F D3 */ { GRPSSE(0fd3) }, + /* 0F D4 */ { GRPSSE(0fd4) }, + /* 0F D5 */ { GRPSSE(0fd5) }, + /* 0F D6 */ { GRPSSE(0fd6) }, + /* 0F D7 */ { GRPSSE(0fd7) }, + /* 0F D8 */ { GRPSSE(0fd8) }, + /* 0F D9 */ { GRPSSE(0fd9) }, + /* 0F DA */ { GRPSSE(0fda) }, + /* 0F DB */ { GRPSSE(0fdb) }, + /* 0F DC */ { GRPSSE(0fdc) }, + /* 0F DD */ { GRPSSE(0fdd) }, + /* 0F DE */ { GRPSSE(0fde) }, + /* 0F DF */ { GRPSSE(0fdf) }, + /* 0F E0 */ { GRPSSE(0fe0) }, + /* 0F E1 */ { GRPSSE(0fe1) }, + /* 0F E2 */ { GRPSSE(0fe2) }, + /* 0F E3 */ { GRPSSE(0fe3) }, + /* 0F E4 */ { GRPSSE(0fe4) }, + /* 0F E5 */ { GRPSSE(0fe5) }, + /* 0F E6 */ { GRPSSE(0fe6) }, + /* 0F E7 */ { GRPSSE(0fe7) }, + /* 0F E8 */ { GRPSSE(0fe8) }, + /* 0F E9 */ { GRPSSE(0fe9) }, + /* 0F EA */ { GRPSSE(0fea) }, + /* 0F EB */ { GRPSSE(0feb) }, + /* 0F EC */ { GRPSSE(0fec) }, + /* 0F ED */ { GRPSSE(0fed) }, + /* 0F EE */ { GRPSSE(0fee) }, + /* 0F EF */ { GRPSSE(0fef) }, + /* 0F F0 */ { GRPSSE(0ff0) }, + /* 0F F1 */ { GRPSSE(0ff1) }, + /* 0F F2 */ { GRPSSE(0ff2) }, + /* 0F F3 */ { GRPSSE(0ff3) }, + /* 0F F4 */ { GRPSSE(0ff4) }, + /* 0F F5 */ { GRPSSE(0ff5) }, + /* 0F F6 */ { GRPSSE(0ff6) }, + /* 0F F7 */ { GRPSSE(0ff7) }, + /* 0F F8 */ { GRPSSE(0ff8) }, + /* 0F F9 */ { GRPSSE(0ff9) }, + /* 0F FA */ { GRPSSE(0ffa) }, + /* 0F FB */ { GRPSSE(0ffb) }, + /* 0F FC */ { GRPSSE(0ffc) }, + /* 0F FD */ { GRPSSE(0ffd) }, + /* 0F FE */ { GRPSSE(0ffe) }, + /* 0F FF */ { 0, &Ia_Invalid } +}; + +/* ************************************************************************ */ +/* 32-bit operand size */ + +static BxDisasmOpcodeTable_t BxDisasmOpcodes32[256*2] = { + // 256 entries for single byte opcodes + /* 00 */ { 0, &Ia_addb_Eb_Gb }, + /* 01 */ { 0, &Ia_addl_Ed_Gd }, + /* 02 */ { 0, &Ia_addb_Gb_Eb }, + /* 03 */ { 0, &Ia_addl_Gd_Ed }, + /* 04 */ { 0, &Ia_addb_AL_Ib, }, + /* 05 */ { 0, &Ia_addl_EAX_Id, }, + /* 06 */ { 0, &Ia_pushl_ES }, + /* 07 */ { 0, &Ia_popl_ES }, + /* 08 */ { 0, &Ia_orb_Eb_Gb }, + /* 09 */ { 0, &Ia_orl_Ed_Gd }, + /* 0A */ { 0, &Ia_orb_Gb_Eb }, + /* 0B */ { 0, &Ia_orl_Gd_Ed }, + /* 0C */ { 0, &Ia_orb_AL_Ib }, + /* 0D */ { 0, &Ia_orl_EAX_Id }, + /* 0E */ { 0, &Ia_pushl_CS }, + /* 0F */ { 0, &Ia_error }, // 2 byte escape + /* 10 */ { 0, &Ia_adcb_Eb_Gb }, + /* 11 */ { 0, &Ia_adcl_Ed_Gd }, + /* 12 */ { 0, &Ia_adcb_Gb_Eb }, + /* 13 */ { 0, &Ia_adcl_Gd_Ed }, + /* 14 */ { 0, &Ia_adcb_AL_Ib }, + /* 15 */ { 0, &Ia_adcl_EAX_Id }, + /* 16 */ { 0, &Ia_pushl_SS }, + /* 17 */ { 0, &Ia_popl_SS }, + /* 18 */ { 0, &Ia_sbbb_Eb_Gb }, + /* 19 */ { 0, &Ia_sbbl_Ed_Gd }, + /* 1A */ { 0, &Ia_sbbb_Gb_Eb }, + /* 1B */ { 0, &Ia_sbbl_Gd_Ed }, + /* 1C */ { 0, &Ia_sbbb_AL_Ib }, + /* 1D */ { 0, &Ia_sbbl_EAX_Id }, + /* 1E */ { 0, &Ia_pushl_DS }, + /* 1F */ { 0, &Ia_popl_DS }, + /* 20 */ { 0, &Ia_andb_Eb_Gb }, + /* 21 */ { 0, &Ia_andl_Ed_Gd }, + /* 22 */ { 0, &Ia_andb_Gb_Eb }, + /* 23 */ { 0, &Ia_andl_Gd_Ed }, + /* 24 */ { 0, &Ia_andb_AL_Ib }, + /* 25 */ { 0, &Ia_andl_EAX_Id }, + /* 26 */ { 0, &Ia_prefix_es }, // ES: + /* 27 */ { 0, &Ia_daa }, + /* 28 */ { 0, &Ia_subb_Eb_Gb }, + /* 29 */ { 0, &Ia_subl_Ed_Gd }, + /* 2A */ { 0, &Ia_subb_Gb_Eb }, + /* 2B */ { 0, &Ia_subl_Gd_Ed }, + /* 2C */ { 0, &Ia_subb_AL_Ib }, + /* 2D */ { 0, &Ia_subl_EAX_Id }, + /* 2E */ { 0, &Ia_prefix_cs }, // CS: + /* 2F */ { 0, &Ia_das }, + /* 30 */ { 0, &Ia_xorb_Eb_Gb }, + /* 31 */ { 0, &Ia_xorl_Ed_Gd }, + /* 32 */ { 0, &Ia_xorb_Gb_Eb }, + /* 33 */ { 0, &Ia_xorl_Gd_Ed }, + /* 34 */ { 0, &Ia_xorb_AL_Ib }, + /* 35 */ { 0, &Ia_xorl_EAX_Id }, + /* 36 */ { 0, &Ia_prefix_ss }, // SS: + /* 37 */ { 0, &Ia_aaa }, + /* 38 */ { 0, &Ia_cmpb_Eb_Gb }, + /* 39 */ { 0, &Ia_cmpl_Ed_Gd }, + /* 3A */ { 0, &Ia_cmpb_Gb_Eb }, + /* 3B */ { 0, &Ia_cmpl_Gd_Ed }, + /* 3C */ { 0, &Ia_cmpb_AL_Ib }, + /* 3D */ { 0, &Ia_cmpl_EAX_Id }, + /* 3E */ { 0, &Ia_prefix_ds }, // DS: + /* 3F */ { 0, &Ia_aas }, + /* 40 */ { 0, &Ia_incl_ERX }, + /* 41 */ { 0, &Ia_incl_ERX }, + /* 42 */ { 0, &Ia_incl_ERX }, + /* 43 */ { 0, &Ia_incl_ERX }, + /* 44 */ { 0, &Ia_incl_ERX }, + /* 45 */ { 0, &Ia_incl_ERX }, + /* 46 */ { 0, &Ia_incl_ERX }, + /* 47 */ { 0, &Ia_incl_ERX }, + /* 48 */ { 0, &Ia_decl_ERX }, + /* 49 */ { 0, &Ia_decl_ERX }, + /* 4A */ { 0, &Ia_decl_ERX }, + /* 4B */ { 0, &Ia_decl_ERX }, + /* 4C */ { 0, &Ia_decl_ERX }, + /* 4D */ { 0, &Ia_decl_ERX }, + /* 4E */ { 0, &Ia_decl_ERX }, + /* 4F */ { 0, &Ia_decl_ERX }, + /* 50 */ { 0, &Ia_pushl_ERX }, + /* 51 */ { 0, &Ia_pushl_ERX }, + /* 52 */ { 0, &Ia_pushl_ERX }, + /* 53 */ { 0, &Ia_pushl_ERX }, + /* 54 */ { 0, &Ia_pushl_ERX }, + /* 55 */ { 0, &Ia_pushl_ERX }, + /* 56 */ { 0, &Ia_pushl_ERX }, + /* 57 */ { 0, &Ia_pushl_ERX }, + /* 58 */ { 0, &Ia_popl_ERX }, + /* 59 */ { 0, &Ia_popl_ERX }, + /* 5A */ { 0, &Ia_popl_ERX }, + /* 5B */ { 0, &Ia_popl_ERX }, + /* 5C */ { 0, &Ia_popl_ERX }, + /* 5D */ { 0, &Ia_popl_ERX }, + /* 5E */ { 0, &Ia_popl_ERX }, + /* 5F */ { 0, &Ia_popl_ERX }, + /* 60 */ { 0, &Ia_pushal }, + /* 61 */ { 0, &Ia_popal }, + /* 62 */ { 0, &Ia_boundl_Gd_Ma }, + /* 63 */ { 0, &Ia_arpl_Ew_Rw }, + /* 64 */ { 0, &Ia_prefix_fs }, // FS: + /* 65 */ { 0, &Ia_prefix_gs }, // GS: + /* 66 */ { 0, &Ia_prefix_osize }, // OSIZE: + /* 67 */ { 0, &Ia_prefix_asize }, // ASIZE: + /* 68 */ { 0, &Ia_pushl_Id }, + /* 69 */ { 0, &Ia_imull_Gd_Ed_Id }, + /* 6A */ { 0, &Ia_pushl_sIb }, + /* 6B */ { 0, &Ia_imull_Gd_Ed_sIb }, + /* 6C */ { 0, &Ia_insb_Yb_DX }, + /* 6D */ { 0, &Ia_insl_Yd_DX }, + /* 6E */ { 0, &Ia_outsb_DX_Xb }, + /* 6F */ { 0, &Ia_outsl_DX_Xd }, + /* 70 */ { 0, &Ia_jo_Jb }, + /* 71 */ { 0, &Ia_jno_Jb }, + /* 72 */ { 0, &Ia_jb_Jb }, + /* 73 */ { 0, &Ia_jnb_Jb }, + /* 74 */ { 0, &Ia_jz_Jb }, + /* 75 */ { 0, &Ia_jnz_Jb }, + /* 76 */ { 0, &Ia_jbe_Jb }, + /* 77 */ { 0, &Ia_jnbe_Jb }, + /* 78 */ { 0, &Ia_js_Jb }, + /* 79 */ { 0, &Ia_jns_Jb }, + /* 7A */ { 0, &Ia_jp_Jb }, + /* 7B */ { 0, &Ia_jnp_Jb }, + /* 7C */ { 0, &Ia_jl_Jb }, + /* 7D */ { 0, &Ia_jnl_Jb }, + /* 7E */ { 0, &Ia_jle_Jb }, + /* 7F */ { 0, &Ia_jnle_Jb }, + /* 80 */ { GRPN(G1EbIb) }, + /* 81 */ { GRPN(G1EdId) }, + /* 82 */ { GRPN(G1EbIb) }, + /* 83 */ { GRPN(G1EdIb) }, + /* 84 */ { 0, &Ia_testb_Eb_Gb }, + /* 85 */ { 0, &Ia_testl_Ed_Gd }, + /* 86 */ { 0, &Ia_xchgb_Eb_Gb }, + /* 87 */ { 0, &Ia_xchgl_Ed_Gd }, + /* 88 */ { 0, &Ia_movb_Eb_Gb }, + /* 89 */ { 0, &Ia_movl_Ed_Gd }, + /* 8A */ { 0, &Ia_movb_Gb_Eb }, + /* 8B */ { 0, &Ia_movl_Gd_Ed }, + /* 8C */ { 0, &Ia_movw_Ew_Sw }, + /* 8D */ { 0, &Ia_leal_Gd_Md }, + /* 8E */ { 0, &Ia_movw_Sw_Ew }, + /* 8F */ { 0, &Ia_popl_Ed }, + /* 90 */ { 0, &Ia_nop }, + /* 91 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 92 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 93 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 94 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 95 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 96 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 97 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 98 */ { 0, &Ia_cwde }, + /* 99 */ { 0, &Ia_cdq }, + /* 9A */ { 0, &Ia_lcall_Apd }, + /* 9B */ { 0, &Ia_fwait }, + /* 9C */ { 0, &Ia_pushfl }, + /* 9D */ { 0, &Ia_popfl }, + /* 9E */ { 0, &Ia_sahf }, + /* 9F */ { 0, &Ia_lahf }, + /* A0 */ { 0, &Ia_movb_AL_Ob }, + /* A1 */ { 0, &Ia_movl_EAX_Od }, + /* A0 */ { 0, &Ia_movb_Ob_AL }, + /* A1 */ { 0, &Ia_movl_Od_EAX }, + /* A4 */ { 0, &Ia_movsb_Yb_Xb }, + /* A5 */ { 0, &Ia_movsl_Yd_Xd }, + /* A6 */ { 0, &Ia_cmpsb_Yb_Xb }, + /* A7 */ { 0, &Ia_cmpsl_Yd_Xd }, + /* A8 */ { 0, &Ia_testb_AL_Ib }, + /* A9 */ { 0, &Ia_testl_EAX_Id }, + /* AA */ { 0, &Ia_stosb_Yb_AL }, + /* AB */ { 0, &Ia_stosl_Yd_EAX }, + /* AC */ { 0, &Ia_lodsb_AL_Xb }, + /* AD */ { 0, &Ia_lodsl_EAX_Xd }, + /* AE */ { 0, &Ia_scasb_Yb_AL }, + /* AF */ { 0, &Ia_scasl_Yd_EAX }, + /* B0 */ { 0, &Ia_movb_R8_Ib }, + /* B1 */ { 0, &Ia_movb_R8_Ib }, + /* B2 */ { 0, &Ia_movb_R8_Ib }, + /* B3 */ { 0, &Ia_movb_R8_Ib }, + /* B4 */ { 0, &Ia_movb_R8_Ib }, + /* B5 */ { 0, &Ia_movb_R8_Ib }, + /* B6 */ { 0, &Ia_movb_R8_Ib }, + /* B7 */ { 0, &Ia_movb_R8_Ib }, + /* B8 */ { 0, &Ia_movl_ERX_Id }, + /* B9 */ { 0, &Ia_movl_ERX_Id }, + /* BA */ { 0, &Ia_movl_ERX_Id }, + /* BB */ { 0, &Ia_movl_ERX_Id }, + /* BC */ { 0, &Ia_movl_ERX_Id }, + /* BD */ { 0, &Ia_movl_ERX_Id }, + /* BE */ { 0, &Ia_movl_ERX_Id }, + /* BF */ { 0, &Ia_movl_ERX_Id }, + /* C0 */ { GRPN(G2Eb) }, + /* C1 */ { GRPN(G2Ed) }, + /* C2 */ { 0, &Ia_ret_Iw }, + /* C3 */ { 0, &Ia_ret }, + /* C4 */ { 0, &Ia_lesl_Gd_Mp }, + /* C5 */ { 0, &Ia_ldsl_Gd_Mp }, + /* C6 */ { 0, &Ia_movb_Eb_Ib }, + /* C7 */ { 0, &Ia_movl_Ed_Id }, + /* C8 */ { 0, &Ia_enter }, + /* C9 */ { 0, &Ia_leave }, + /* CA */ { 0, &Ia_lret_Iw }, + /* CB */ { 0, &Ia_lret }, + /* CC */ { 0, &Ia_int3 }, + /* CD */ { 0, &Ia_int_Ib }, + /* CE */ { 0, &Ia_into }, + /* CF */ { 0, &Ia_iretl }, + /* D0 */ { GRPN(G2EbI1) }, + /* D1 */ { GRPN(G2EdI1) }, + /* D2 */ { GRPN(G2EbCL) }, + /* D3 */ { GRPN(G2EdCL) }, + /* D4 */ { 0, &Ia_aam }, + /* D5 */ { 0, &Ia_aad }, + /* D6 */ { 0, &Ia_salc }, + /* D7 */ { 0, &Ia_xlat }, + /* D8 */ { GRPFP(D8) }, + /* D9 */ { GRPFP(D9) }, + /* DA */ { GRPFP(DA) }, + /* DB */ { GRPFP(DB) }, + /* DC */ { GRPFP(DC) }, + /* DD */ { GRPFP(DD) }, + /* DE */ { GRPFP(DE) }, + /* DF */ { GRPFP(DF) }, + /* E0 */ { 0, &Ia_loopne_Jb }, + /* E1 */ { 0, &Ia_loope_Jb }, + /* E2 */ { 0, &Ia_loop_Jb }, + /* E3 */ { 0, &Ia_jcxz_Jb }, + /* E4 */ { 0, &Ia_inb_AL_Ib }, + /* E5 */ { 0, &Ia_inl_EAX_Ib }, + /* E6 */ { 0, &Ia_outb_Ib_AL }, + /* E7 */ { 0, &Ia_outl_Ib_EAX }, + /* E8 */ { 0, &Ia_call_Jd }, + /* E9 */ { 0, &Ia_jmp_Jd }, + /* EA */ { 0, &Ia_ljmp_Apd }, + /* EB */ { 0, &Ia_jmp_Jb }, + /* EC */ { 0, &Ia_inb_AL_Ib }, + /* ED */ { 0, &Ia_inl_EAX_DX }, + /* EE */ { 0, &Ia_outb_DX_AL }, + /* EF */ { 0, &Ia_outl_DX_EAX }, + /* F0 */ { 0, &Ia_prefix_lock }, // LOCK: + /* F1 */ { 0, &Ia_int1 }, + /* F2 */ { 0, &Ia_prefix_repne }, // REPNE: + /* F3 */ { 0, &Ia_prefix_rep }, // REP: + /* F4 */ { 0, &Ia_hlt }, + /* F5 */ { 0, &Ia_cmc }, + /* F6 */ { GRPN(G3Eb) }, + /* F7 */ { GRPN(G3Ed) }, + /* F8 */ { 0, &Ia_clc }, + /* F9 */ { 0, &Ia_stc }, + /* FA */ { 0, &Ia_cli }, + /* FB */ { 0, &Ia_sti }, + /* FC */ { 0, &Ia_cld }, + /* FD */ { 0, &Ia_std }, + /* FE */ { GRPN(G4) }, + /* FF */ { GRPN(G5d) }, + + // 256 entries for two byte opcodes + /* 0F 00 */ { GRPN(G6) }, + /* 0F 01 */ { GRPN(G7) }, + /* 0F 02 */ { 0, &Ia_larl_Gd_Ew }, + /* 0F 03 */ { 0, &Ia_lsll_Gd_Ew }, + /* 0F 04 */ { 0, &Ia_Invalid }, + /* 0F 05 */ { 0, &Ia_syscall }, + /* 0F 06 */ { 0, &Ia_clts }, + /* 0F 07 */ { 0, &Ia_sysret }, + /* 0F 08 */ { 0, &Ia_invd }, + /* 0F 09 */ { 0, &Ia_wbinvd }, + /* 0F 0A */ { 0, &Ia_Invalid }, + /* 0F 0B */ { 0, &Ia_ud2a }, + /* 0F 0C */ { 0, &Ia_Invalid }, + /* 0F 0D */ { 0, &Ia_prefetch }, // 3DNow! + /* 0F 0E */ { 0, &Ia_femms }, // 3DNow! + /* 0F 0F */ { GRP3DNOW }, + /* 0F 10 */ { GRPSSE(0f10) }, + /* 0F 11 */ { GRPSSE(0f11) }, + /* 0F 12 */ { GRPSSE(0f12) }, + /* 0F 13 */ { GRPSSE(0f13) }, + /* 0F 14 */ { GRPSSE(0f14) }, + /* 0F 15 */ { GRPSSE(0f15) }, + /* 0F 16 */ { GRPSSE(0f16) }, + /* 0F 17 */ { GRPSSE(0f17) }, + /* 0F 18 */ { GRPN(G16) }, + /* 0F 19 */ { 0, &Ia_Invalid }, + /* 0F 1A */ { 0, &Ia_Invalid }, + /* 0F 1B */ { 0, &Ia_Invalid }, + /* 0F 1C */ { 0, &Ia_Invalid }, + /* 0F 1D */ { 0, &Ia_Invalid }, + /* 0F 1E */ { 0, &Ia_Invalid }, + /* 0F 1F */ { 0, &Ia_Invalid }, + /* 0F 20 */ { 0, &Ia_movl_Rd_Cd }, + /* 0F 21 */ { 0, &Ia_movl_Rd_Dd }, + /* 0F 22 */ { 0, &Ia_movl_Cd_Rd }, + /* 0F 23 */ { 0, &Ia_movl_Dd_Rd }, + /* 0F 24 */ { 0, &Ia_movl_Rd_Td }, + /* 0F 25 */ { 0, &Ia_Invalid }, + /* 0F 26 */ { 0, &Ia_movl_Td_Rd }, + /* 0F 27 */ { 0, &Ia_Invalid }, + /* 0F 28 */ { GRPSSE(0f28) }, + /* 0F 29 */ { GRPSSE(0f29) }, + /* 0F 2A */ { GRPSSE(0f2a) }, + /* 0F 2B */ { GRPSSE(0f2b) }, + /* 0F 2C */ { GRPSSE(0f2c) }, + /* 0F 2D */ { GRPSSE(0f2d) }, + /* 0F 2E */ { GRPSSE(0f2e) }, + /* 0F 2F */ { GRPSSE(0f2f) }, + /* 0F 30 */ { 0, &Ia_wrmsr }, + /* 0F 31 */ { 0, &Ia_rdtsc }, + /* 0F 32 */ { 0, &Ia_rdmsr }, + /* 0F 33 */ { 0, &Ia_rdpmc }, + /* 0F 34 */ { 0, &Ia_sysenter }, + /* 0F 35 */ { 0, &Ia_sysexit }, + /* 0F 36 */ { 0, &Ia_Invalid }, + /* 0F 37 */ { 0, &Ia_Invalid }, + /* 0F 38 */ { 0, &Ia_Invalid }, + /* 0F 39 */ { 0, &Ia_Invalid }, + /* 0F 3A */ { 0, &Ia_Invalid }, + /* 0F 3B */ { 0, &Ia_Invalid }, + /* 0F 3C */ { 0, &Ia_Invalid }, + /* 0F 3D */ { 0, &Ia_Invalid }, + /* 0F 3E */ { 0, &Ia_Invalid }, + /* 0F 3F */ { 0, &Ia_Invalid }, + /* 0F 40 */ { 0, &Ia_cmovol_Gd_Ed }, + /* 0F 41 */ { 0, &Ia_cmovnol_Gd_Ed }, + /* 0F 42 */ { 0, &Ia_cmovcl_Gd_Ed }, + /* 0F 43 */ { 0, &Ia_cmovncl_Gd_Ed }, + /* 0F 44 */ { 0, &Ia_cmovzl_Gd_Ed }, + /* 0F 45 */ { 0, &Ia_cmovnzl_Gd_Ed }, + /* 0F 46 */ { 0, &Ia_cmovnal_Gd_Ed }, + /* 0F 47 */ { 0, &Ia_cmoval_Gd_Ed }, + /* 0F 48 */ { 0, &Ia_cmovsl_Gd_Ed }, + /* 0F 49 */ { 0, &Ia_cmovnsl_Gd_Ed }, + /* 0F 4A */ { 0, &Ia_cmovpl_Gd_Ed }, + /* 0F 4B */ { 0, &Ia_cmovnpl_Gd_Ed }, + /* 0F 4C */ { 0, &Ia_cmovll_Gd_Ed }, + /* 0F 4D */ { 0, &Ia_cmovnll_Gd_Ed }, + /* 0F 4E */ { 0, &Ia_cmovngl_Gd_Ed }, + /* 0F 4F */ { 0, &Ia_cmovgl_Gd_Ed }, + /* 0F 50 */ { GRPSSE(0f50) }, + /* 0F 51 */ { GRPSSE(0f51) }, + /* 0F 52 */ { GRPSSE(0f52) }, + /* 0F 53 */ { GRPSSE(0f53) }, + /* 0F 54 */ { GRPSSE(0f54) }, + /* 0F 55 */ { GRPSSE(0f55) }, + /* 0F 56 */ { GRPSSE(0f56) }, + /* 0F 57 */ { GRPSSE(0f57) }, + /* 0F 58 */ { GRPSSE(0f58) }, + /* 0F 59 */ { GRPSSE(0f59) }, + /* 0F 5A */ { GRPSSE(0f5a) }, + /* 0F 5B */ { GRPSSE(0f5b) }, + /* 0F 5C */ { GRPSSE(0f5c) }, + /* 0F 5D */ { GRPSSE(0f5d) }, + /* 0F 5E */ { GRPSSE(0f5e) }, + /* 0F 5F */ { GRPSSE(0f5f) }, + /* 0F 60 */ { GRPSSE(0f60) }, + /* 0F 61 */ { GRPSSE(0f61) }, + /* 0F 62 */ { GRPSSE(0f62) }, + /* 0F 63 */ { GRPSSE(0f63) }, + /* 0F 64 */ { GRPSSE(0f64) }, + /* 0F 65 */ { GRPSSE(0f65) }, + /* 0F 66 */ { GRPSSE(0f66) }, + /* 0F 67 */ { GRPSSE(0f67) }, + /* 0F 68 */ { GRPSSE(0f68) }, + /* 0F 69 */ { GRPSSE(0f69) }, + /* 0F 6A */ { GRPSSE(0f6a) }, + /* 0F 6B */ { GRPSSE(0f6b) }, + /* 0F 6C */ { GRPSSE(0f6c) }, + /* 0F 6D */ { GRPSSE(0f6d) }, + /* 0F 6E */ { GRPSSE(0f6e) }, + /* 0F 6F */ { GRPSSE(0f6f) }, + /* 0F 70 */ { GRPSSE(0f70) }, + /* 0F 71 */ { GRPN(G12) }, + /* 0F 72 */ { GRPN(G13) }, + /* 0F 73 */ { GRPN(G14) }, + /* 0F 74 */ { GRPSSE(0f74) }, + /* 0F 75 */ { GRPSSE(0f75) }, + /* 0F 76 */ { GRPSSE(0f76) }, + /* 0F 77 */ { 0, &Ia_emms }, + /* 0F 78 */ { 0, &Ia_Invalid }, + /* 0F 79 */ { 0, &Ia_Invalid }, + /* 0F 7A */ { 0, &Ia_Invalid }, + /* 0F 7B */ { 0, &Ia_Invalid }, + /* 0F 7C */ { GRPSSE(0f7c) }, + /* 0F 7D */ { GRPSSE(0f7d) }, + /* 0F 7E */ { GRPSSE(0f7e) }, + /* 0F 7F */ { GRPSSE(0f7f) }, + /* 0F 80 */ { 0, &Ia_jo_Jd }, + /* 0F 81 */ { 0, &Ia_jno_Jd }, + /* 0F 82 */ { 0, &Ia_jb_Jd }, + /* 0F 83 */ { 0, &Ia_jnb_Jd }, + /* 0F 84 */ { 0, &Ia_jz_Jd }, + /* 0F 85 */ { 0, &Ia_jnz_Jd }, + /* 0F 86 */ { 0, &Ia_jbe_Jd }, + /* 0F 87 */ { 0, &Ia_jnbe_Jd }, + /* 0F 88 */ { 0, &Ia_js_Jd }, + /* 0F 89 */ { 0, &Ia_jns_Jd }, + /* 0F 8A */ { 0, &Ia_jp_Jd }, + /* 0F 8B */ { 0, &Ia_jnp_Jd }, + /* 0F 8C */ { 0, &Ia_jl_Jd }, + /* 0F 8D */ { 0, &Ia_jnl_Jd }, + /* 0F 8E */ { 0, &Ia_jle_Jd }, + /* 0F 8F */ { 0, &Ia_jnle_Jd }, + /* 0F 90 */ { 0, &Ia_seto_Eb }, + /* 0F 91 */ { 0, &Ia_setno_Eb }, + /* 0F 92 */ { 0, &Ia_setb_Eb }, + /* 0F 93 */ { 0, &Ia_setnb_Eb }, + /* 0F 94 */ { 0, &Ia_setz_Eb }, + /* 0F 95 */ { 0, &Ia_setnz_Eb }, + /* 0F 96 */ { 0, &Ia_setbe_Eb }, + /* 0F 97 */ { 0, &Ia_setnbe_Eb }, + /* 0F 98 */ { 0, &Ia_sets_Eb }, + /* 0F 99 */ { 0, &Ia_setns_Eb }, + /* 0F 9A */ { 0, &Ia_setp_Eb }, + /* 0F 9B */ { 0, &Ia_setnp_Eb }, + /* 0F 9C */ { 0, &Ia_setl_Eb }, + /* 0F 9D */ { 0, &Ia_setnl_Eb }, + /* 0F 9E */ { 0, &Ia_setle_Eb }, + /* 0F 9F */ { 0, &Ia_setnle_Eb }, + /* 0F A0 */ { 0, &Ia_pushl_FS }, + /* 0F A1 */ { 0, &Ia_popl_FS }, + /* 0F A2 */ { 0, &Ia_cpuid }, + /* 0F A3 */ { 0, &Ia_btl_Ed_Gd }, + /* 0F A4 */ { 0, &Ia_shldl_Ed_Gd_Ib }, + /* 0F A5 */ { 0, &Ia_shldl_Ed_Gd_CL }, + /* 0F A6 */ { 0, &Ia_Invalid }, + /* 0F A7 */ { 0, &Ia_Invalid }, + /* 0F A8 */ { 0, &Ia_pushl_GS }, + /* 0F A9 */ { 0, &Ia_popl_GS }, + /* 0F AA */ { 0, &Ia_rsm }, + /* 0F AB */ { 0, &Ia_btsl_Ed_Gd }, + /* 0F AC */ { 0, &Ia_shrdl_Ed_Gd_Ib }, + /* 0F AD */ { 0, &Ia_shrdl_Ed_Gd_CL }, + /* 0F AE */ { GRPN(G15) }, + /* 0F AF */ { 0, &Ia_imull_Gd_Ed }, + /* 0F B0 */ { 0, &Ia_cmpxchgb_Eb_Gb }, + /* 0F B1 */ { 0, &Ia_cmpxchgl_Ed_Gd }, + /* 0F B2 */ { 0, &Ia_lssl_Gd_Mp }, + /* 0F B3 */ { 0, &Ia_btrl_Ed_Gd }, + /* 0F B4 */ { 0, &Ia_lfsl_Gd_Mp }, + /* 0F B5 */ { 0, &Ia_lgsl_Gd_Mp }, + /* 0F B6 */ { 0, &Ia_movzbl_Gd_Eb }, + /* 0F B7 */ { 0, &Ia_movzwl_Gd_Ew }, + /* 0F B8 */ { 0, &Ia_Invalid }, + /* 0F B9 */ { 0, &Ia_ud2b }, + /* 0F BA */ { GRPN(G8EdIb) }, + /* 0F BB */ { 0, &Ia_btcl_Ed_Gd }, + /* 0F BC */ { 0, &Ia_bsfl_Gd_Ed }, + /* 0F BD */ { 0, &Ia_bsrl_Gd_Ed }, + /* 0F BE */ { 0, &Ia_movsbl_Gd_Eb }, + /* 0F BF */ { 0, &Ia_movswl_Gd_Ew }, + /* 0F C0 */ { 0, &Ia_xaddb_Eb_Gb }, + /* 0F C0 */ { 0, &Ia_xaddl_Ed_Gd }, + /* 0F C2 */ { GRPSSE(0fc2) }, + /* 0F C3 */ { GRPSSE(0fc3) }, + /* 0F C4 */ { GRPSSE(0fc4) }, + /* 0F C5 */ { GRPSSE(0fc5) }, + /* 0F C6 */ { GRPSSE(0fc6) }, + /* 0F C7 */ { GRPN(G9) }, + /* 0F C8 */ { 0, &Ia_bswapl_ERX }, + /* 0F C9 */ { 0, &Ia_bswapl_ERX }, + /* 0F CA */ { 0, &Ia_bswapl_ERX }, + /* 0F CB */ { 0, &Ia_bswapl_ERX }, + /* 0F CC */ { 0, &Ia_bswapl_ERX }, + /* 0F CD */ { 0, &Ia_bswapl_ERX }, + /* 0F CE */ { 0, &Ia_bswapl_ERX }, + /* 0F CF */ { 0, &Ia_bswapl_ERX }, + /* 0F D0 */ { GRPSSE(0fd0) }, + /* 0F D1 */ { GRPSSE(0fd1) }, + /* 0F D2 */ { GRPSSE(0fd2) }, + /* 0F D3 */ { GRPSSE(0fd3) }, + /* 0F D4 */ { GRPSSE(0fd4) }, + /* 0F D5 */ { GRPSSE(0fd5) }, + /* 0F D6 */ { GRPSSE(0fd6) }, + /* 0F D7 */ { GRPSSE(0fd7) }, + /* 0F D8 */ { GRPSSE(0fd8) }, + /* 0F D9 */ { GRPSSE(0fd9) }, + /* 0F DA */ { GRPSSE(0fda) }, + /* 0F DB */ { GRPSSE(0fdb) }, + /* 0F DC */ { GRPSSE(0fdc) }, + /* 0F DD */ { GRPSSE(0fdd) }, + /* 0F DE */ { GRPSSE(0fde) }, + /* 0F DF */ { GRPSSE(0fdf) }, + /* 0F E0 */ { GRPSSE(0fe0) }, + /* 0F E1 */ { GRPSSE(0fe1) }, + /* 0F E2 */ { GRPSSE(0fe2) }, + /* 0F E3 */ { GRPSSE(0fe3) }, + /* 0F E4 */ { GRPSSE(0fe4) }, + /* 0F E5 */ { GRPSSE(0fe5) }, + /* 0F E6 */ { GRPSSE(0fe6) }, + /* 0F E7 */ { GRPSSE(0fe7) }, + /* 0F E8 */ { GRPSSE(0fe8) }, + /* 0F E9 */ { GRPSSE(0fe9) }, + /* 0F EA */ { GRPSSE(0fea) }, + /* 0F EB */ { GRPSSE(0feb) }, + /* 0F EC */ { GRPSSE(0fec) }, + /* 0F ED */ { GRPSSE(0fed) }, + /* 0F EE */ { GRPSSE(0fee) }, + /* 0F EF */ { GRPSSE(0fef) }, + /* 0F F0 */ { GRPSSE(0ff0) }, + /* 0F F1 */ { GRPSSE(0ff1) }, + /* 0F F2 */ { GRPSSE(0ff2) }, + /* 0F F3 */ { GRPSSE(0ff3) }, + /* 0F F4 */ { GRPSSE(0ff4) }, + /* 0F F5 */ { GRPSSE(0ff5) }, + /* 0F F6 */ { GRPSSE(0ff6) }, + /* 0F F7 */ { GRPSSE(0ff7) }, + /* 0F F8 */ { GRPSSE(0ff8) }, + /* 0F F9 */ { GRPSSE(0ff9) }, + /* 0F FA */ { GRPSSE(0ffa) }, + /* 0F FB */ { GRPSSE(0ffb) }, + /* 0F FC */ { GRPSSE(0ffc) }, + /* 0F FD */ { GRPSSE(0ffd) }, + /* 0F FE */ { GRPSSE(0ffe) }, + /* 0F FF */ { 0, &Ia_Invalid } +}; + +/* ************************************************************************ */ +/* Long mode */ + +static BxDisasmOpcodeTable_t BxDisasmOpcodes64w[256*2] = { + // 256 entries for single byte opcodes + /* 00 */ { 0, &Ia_addb_Eb_Gb }, + /* 01 */ { 0, &Ia_addw_Ew_Gw }, + /* 02 */ { 0, &Ia_addb_Gb_Eb }, + /* 03 */ { 0, &Ia_addw_Gw_Ew }, + /* 04 */ { 0, &Ia_addb_AL_Ib }, + /* 05 */ { 0, &Ia_addw_AX_Iw }, + /* 06 */ { 0, &Ia_Invalid }, + /* 07 */ { 0, &Ia_Invalid }, + /* 08 */ { 0, &Ia_orb_Eb_Gb }, + /* 09 */ { 0, &Ia_orw_Ew_Gw }, + /* 0A */ { 0, &Ia_orb_Gb_Eb }, + /* 0B */ { 0, &Ia_orw_Gw_Ew }, + /* 0C */ { 0, &Ia_orb_AL_Ib }, + /* 0D */ { 0, &Ia_orw_AX_Iw }, + /* 0E */ { 0, &Ia_Invalid }, + /* 0F */ { 0, &Ia_error }, // 2 byte escape + /* 10 */ { 0, &Ia_adcb_Eb_Gb }, + /* 11 */ { 0, &Ia_adcw_Ew_Gw }, + /* 12 */ { 0, &Ia_adcb_Gb_Eb }, + /* 13 */ { 0, &Ia_adcw_Gw_Ew }, + /* 14 */ { 0, &Ia_adcb_AL_Ib }, + /* 15 */ { 0, &Ia_adcw_AX_Iw }, + /* 16 */ { 0, &Ia_Invalid }, + /* 17 */ { 0, &Ia_Invalid }, + /* 18 */ { 0, &Ia_sbbb_Eb_Gb }, + /* 19 */ { 0, &Ia_sbbw_Ew_Gw }, + /* 1A */ { 0, &Ia_sbbb_Gb_Eb }, + /* 1B */ { 0, &Ia_sbbw_Gw_Ew }, + /* 1C */ { 0, &Ia_sbbb_AL_Ib }, + /* 1D */ { 0, &Ia_sbbw_AX_Iw }, + /* 1E */ { 0, &Ia_Invalid }, + /* 1F */ { 0, &Ia_Invalid }, + /* 20 */ { 0, &Ia_andb_Eb_Gb }, + /* 21 */ { 0, &Ia_andw_Ew_Gw }, + /* 22 */ { 0, &Ia_andb_Gb_Eb }, + /* 23 */ { 0, &Ia_andw_Gw_Ew }, + /* 24 */ { 0, &Ia_andb_AL_Ib }, + /* 25 */ { 0, &Ia_andw_AX_Iw }, + /* 26 */ { 0, &Ia_prefix_es }, // ES: + /* 27 */ { 0, &Ia_Invalid }, + /* 28 */ { 0, &Ia_subb_Eb_Gb }, + /* 29 */ { 0, &Ia_subw_Ew_Gw }, + /* 2A */ { 0, &Ia_subb_Gb_Eb }, + /* 2B */ { 0, &Ia_subw_Gw_Ew }, + /* 2C */ { 0, &Ia_subb_AL_Ib }, + /* 2D */ { 0, &Ia_subw_AX_Iw }, + /* 2E */ { 0, &Ia_prefix_cs }, // CS: + /* 2F */ { 0, &Ia_Invalid }, + /* 30 */ { 0, &Ia_xorb_Eb_Gb }, + /* 31 */ { 0, &Ia_xorw_Ew_Gw }, + /* 32 */ { 0, &Ia_xorb_Gb_Eb }, + /* 33 */ { 0, &Ia_xorw_Gw_Ew }, + /* 34 */ { 0, &Ia_xorb_AL_Ib }, + /* 35 */ { 0, &Ia_xorw_AX_Iw }, + /* 36 */ { 0, &Ia_prefix_ss }, // SS: + /* 37 */ { 0, &Ia_Invalid }, + /* 38 */ { 0, &Ia_cmpb_Eb_Gb }, + /* 39 */ { 0, &Ia_cmpw_Ew_Gw }, + /* 3A */ { 0, &Ia_cmpb_Gb_Eb }, + /* 3B */ { 0, &Ia_cmpw_Gw_Ew }, + /* 3C */ { 0, &Ia_cmpb_AL_Ib }, + /* 3D */ { 0, &Ia_cmpw_AX_Iw }, + /* 3E */ { 0, &Ia_prefix_ds }, // DS: + /* 3F */ { 0, &Ia_Invalid }, + /* 40 */ { 0, &Ia_prefix_rex }, // REX: + /* 41 */ { 0, &Ia_prefix_rex }, // REX: + /* 42 */ { 0, &Ia_prefix_rex }, // REX: + /* 43 */ { 0, &Ia_prefix_rex }, // REX: + /* 44 */ { 0, &Ia_prefix_rex }, // REX: + /* 45 */ { 0, &Ia_prefix_rex }, // REX: + /* 46 */ { 0, &Ia_prefix_rex }, // REX: + /* 47 */ { 0, &Ia_prefix_rex }, // REX: + /* 48 */ { 0, &Ia_prefix_rex }, // REX: + /* 49 */ { 0, &Ia_prefix_rex }, // REX: + /* 4A */ { 0, &Ia_prefix_rex }, // REX: + /* 4B */ { 0, &Ia_prefix_rex }, // REX: + /* 4C */ { 0, &Ia_prefix_rex }, // REX: + /* 4D */ { 0, &Ia_prefix_rex }, // REX: + /* 4E */ { 0, &Ia_prefix_rex }, // REX: + /* 4F */ { 0, &Ia_prefix_rex }, // REX: + /* 50 */ { 0, &Ia_pushw_RX }, + /* 51 */ { 0, &Ia_pushw_RX }, + /* 52 */ { 0, &Ia_pushw_RX }, + /* 53 */ { 0, &Ia_pushw_RX }, + /* 54 */ { 0, &Ia_pushw_RX }, + /* 55 */ { 0, &Ia_pushw_RX }, + /* 56 */ { 0, &Ia_pushw_RX }, + /* 57 */ { 0, &Ia_pushw_RX }, + /* 58 */ { 0, &Ia_popw_RX }, + /* 59 */ { 0, &Ia_popw_RX }, + /* 5A */ { 0, &Ia_popw_RX }, + /* 5B */ { 0, &Ia_popw_RX }, + /* 5C */ { 0, &Ia_popw_RX }, + /* 5D */ { 0, &Ia_popw_RX }, + /* 5E */ { 0, &Ia_popw_RX }, + /* 5F */ { 0, &Ia_popw_RX }, + /* 60 */ { 0, &Ia_Invalid }, + /* 61 */ { 0, &Ia_Invalid }, + /* 62 */ { 0, &Ia_Invalid }, + /* 63 */ { 0, &Ia_movw_Gw_Ew }, + /* 64 */ { 0, &Ia_prefix_fs }, // FS: + /* 65 */ { 0, &Ia_prefix_gs }, // GS: + /* 66 */ { 0, &Ia_prefix_osize }, // OSIZE: + /* 67 */ { 0, &Ia_prefix_asize }, // ASIZE: + /* 68 */ { 0, &Ia_pushw_Iw }, + /* 69 */ { 0, &Ia_imulw_Gw_Ew_Iw }, + /* 6A */ { 0, &Ia_pushw_Iw }, + /* 6B */ { 0, &Ia_imulw_Gw_Ew_Iw }, + /* 6C */ { 0, &Ia_insb_Yb_DX }, + /* 6D */ { 0, &Ia_insw_Yw_DX }, + /* 6E */ { 0, &Ia_outsb_DX_Xb }, + /* 6F */ { 0, &Ia_outsw_DX_Xw }, + /* 70 */ { 0, &Ia_jo_Jb }, + /* 71 */ { 0, &Ia_jno_Jb }, + /* 72 */ { 0, &Ia_jb_Jb }, + /* 73 */ { 0, &Ia_jnb_Jb }, + /* 74 */ { 0, &Ia_jz_Jb }, + /* 75 */ { 0, &Ia_jnz_Jb }, + /* 76 */ { 0, &Ia_jbe_Jb }, + /* 77 */ { 0, &Ia_jnbe_Jb }, + /* 78 */ { 0, &Ia_js_Jb }, + /* 79 */ { 0, &Ia_jns_Jb }, + /* 7A */ { 0, &Ia_jp_Jb }, + /* 7B */ { 0, &Ia_jnp_Jb }, + /* 7C */ { 0, &Ia_jl_Jb }, + /* 7D */ { 0, &Ia_jnl_Jb }, + /* 7E */ { 0, &Ia_jle_Jb }, + /* 7F */ { 0, &Ia_jnle_Jb }, + /* 80 */ { GRPN(G1EbIb) }, + /* 81 */ { GRPN(G1EwIw) }, + /* 82 */ { 9, &Ia_Invalid }, + /* 83 */ { GRPN(G1EwIb) }, + /* 84 */ { 0, &Ia_testb_Eb_Gb }, + /* 85 */ { 0, &Ia_testw_Ew_Gw }, + /* 86 */ { 0, &Ia_xchgb_Eb_Gb }, + /* 87 */ { 0, &Ia_xchgw_Ew_Gw }, + /* 88 */ { 0, &Ia_movb_Eb_Gb }, + /* 89 */ { 0, &Ia_movw_Ew_Gw }, + /* 8A */ { 0, &Ia_movb_Gb_Eb }, + /* 8B */ { 0, &Ia_movw_Gw_Ew }, + /* 8C */ { 0, &Ia_movw_Ew_Sw }, + /* 8D */ { 0, &Ia_leaw_Gw_Mw }, + /* 8E */ { 0, &Ia_movw_Sw_Ew }, + /* 8F */ { 0, &Ia_popw_Ew }, + /* 90 */ { 0, &Ia_nop }, + /* 91 */ { 0, &Ia_xchgw_RX_AX }, + /* 92 */ { 0, &Ia_xchgw_RX_AX }, + /* 93 */ { 0, &Ia_xchgw_RX_AX }, + /* 94 */ { 0, &Ia_xchgw_RX_AX }, + /* 95 */ { 0, &Ia_xchgw_RX_AX }, + /* 96 */ { 0, &Ia_xchgw_RX_AX }, + /* 97 */ { 0, &Ia_xchgw_RX_AX }, + /* 98 */ { 0, &Ia_cbw }, + /* 99 */ { 0, &Ia_cwd }, + /* 9A */ { 0, &Ia_Invalid }, + /* 9B */ { 0, &Ia_fwait }, + /* 9C */ { 0, &Ia_pushfw }, + /* 9D */ { 0, &Ia_popfw }, + /* 9E */ { 0, &Ia_sahf }, + /* 9F */ { 0, &Ia_lahf }, + /* A0 */ { 0, &Ia_movb_AL_Ob }, + /* A1 */ { 0, &Ia_movw_AX_Ow }, + /* A0 */ { 0, &Ia_movb_Ob_AL }, + /* A1 */ { 0, &Ia_movw_Ow_AX }, + /* A4 */ { 0, &Ia_movsb_Yb_Xb }, + /* A5 */ { 0, &Ia_movsw_Yw_Xw }, + /* A6 */ { 0, &Ia_cmpsb_Yb_Xb }, + /* A7 */ { 0, &Ia_cmpsw_Yw_Xw }, + /* A8 */ { 0, &Ia_testb_AL_Ib }, + /* A9 */ { 0, &Ia_testw_AX_Iw }, + /* AA */ { 0, &Ia_stosb_Yb_AL }, + /* AB */ { 0, &Ia_stosw_Yw_AX }, + /* AC */ { 0, &Ia_lodsb_AL_Xb }, + /* AD */ { 0, &Ia_lodsw_AX_Xw }, + /* AE */ { 0, &Ia_scasb_Yb_AL }, + /* AF */ { 0, &Ia_scasw_Yw_AX }, + /* B0 */ { 0, &Ia_movb_R8_Ib }, + /* B1 */ { 0, &Ia_movb_R8_Ib }, + /* B2 */ { 0, &Ia_movb_R8_Ib }, + /* B3 */ { 0, &Ia_movb_R8_Ib }, + /* B4 */ { 0, &Ia_movb_R8_Ib }, + /* B5 */ { 0, &Ia_movb_R8_Ib }, + /* B6 */ { 0, &Ia_movb_R8_Ib }, + /* B7 */ { 0, &Ia_movb_R8_Ib }, + /* B8 */ { 0, &Ia_movw_RX_Iw }, + /* B9 */ { 0, &Ia_movw_RX_Iw }, + /* BA */ { 0, &Ia_movw_RX_Iw }, + /* BB */ { 0, &Ia_movw_RX_Iw }, + /* BC */ { 0, &Ia_movw_RX_Iw }, + /* BD */ { 0, &Ia_movw_RX_Iw }, + /* BE */ { 0, &Ia_movw_RX_Iw }, + /* BF */ { 0, &Ia_movw_RX_Iw }, + /* C0 */ { GRPN(G2Eb) }, + /* C1 */ { GRPN(G2Ew) }, + /* C2 */ { 0, &Ia_ret_Iw }, + /* C3 */ { 0, &Ia_ret }, + /* C4 */ { 0, &Ia_Invalid }, + /* C5 */ { 0, &Ia_Invalid }, + /* C6 */ { 0, &Ia_movb_Eb_Ib }, + /* C7 */ { 0, &Ia_movw_Ew_Iw }, + /* C8 */ { 0, &Ia_enter }, + /* C9 */ { 0, &Ia_leave }, + /* CA */ { 0, &Ia_lret_Iw }, + /* CB */ { 0, &Ia_lret }, + /* CC */ { 0, &Ia_int3 }, + /* CD */ { 0, &Ia_int_Ib }, + /* CE */ { 0, &Ia_Invalid }, + /* CF */ { 0, &Ia_iretw }, + /* D0 */ { GRPN(G2EbI1) }, + /* D1 */ { GRPN(G2EwI1) }, + /* D2 */ { GRPN(G2EbCL) }, + /* D3 */ { GRPN(G2EwCL) }, + /* D4 */ { 0, &Ia_Invalid }, + /* D5 */ { 0, &Ia_Invalid }, + /* D6 */ { 0, &Ia_Invalid }, + /* D7 */ { 0, &Ia_xlat }, + /* D8 */ { GRPFP(D8) }, + /* D9 */ { GRPFP(D9) }, + /* DA */ { GRPFP(DA) }, + /* DB */ { GRPFP(DB) }, + /* DC */ { GRPFP(DC) }, + /* DD */ { GRPFP(DD) }, + /* DE */ { GRPFP(DE) }, + /* DF */ { GRPFP(DF) }, + /* E0 */ { 0, &Ia_loopne_Jb }, + /* E1 */ { 0, &Ia_loope_Jb }, + /* E2 */ { 0, &Ia_loop_Jb }, + /* E3 */ { 0, &Ia_jrcxz_Jb }, + /* E4 */ { 0, &Ia_inb_AL_Ib }, + /* E5 */ { 0, &Ia_inw_AX_Ib }, + /* E6 */ { 0, &Ia_outb_Ib_AL }, + /* E7 */ { 0, &Ia_outw_Ib_AX }, + /* E8 */ { 0, &Ia_call_Jd }, + /* E9 */ { 0, &Ia_jmp_Jd }, + /* EA */ { 0, &Ia_Invalid }, + /* EB */ { 0, &Ia_jmp_Jb }, + /* EC */ { 0, &Ia_inb_AL_DX }, + /* ED */ { 0, &Ia_inw_AX_DX }, + /* EE */ { 0, &Ia_outb_DX_AL }, + /* EF */ { 0, &Ia_outw_DX_AX }, + /* F0 */ { 0, &Ia_prefix_lock }, // LOCK: + /* F1 */ { 0, &Ia_int1 }, + /* F2 */ { 0, &Ia_prefix_repne }, // REPNE: + /* F3 */ { 0, &Ia_prefix_rep }, // REP: + /* F4 */ { 0, &Ia_hlt }, + /* F5 */ { 0, &Ia_cmc }, + /* F6 */ { GRPN(G3Eb) }, + /* F7 */ { GRPN(G3Ew) }, + /* F8 */ { 0, &Ia_clc }, + /* F9 */ { 0, &Ia_stc }, + /* FA */ { 0, &Ia_cli }, + /* FB */ { 0, &Ia_sti }, + /* FC */ { 0, &Ia_cld }, + /* FD */ { 0, &Ia_std }, + /* FE */ { GRPN(G4) }, + /* FF */ { GRPN(G5w) }, + + // 256 entries for two byte opcodes + /* 0F 00 */ { GRPN(G6) }, + /* 0F 01 */ { GRPN(G7) }, + /* 0F 02 */ { 0, &Ia_larw_Gw_Ew }, + /* 0F 03 */ { 0, &Ia_lslw_Gw_Ew }, + /* 0F 04 */ { 0, &Ia_Invalid }, + /* 0F 05 */ { 0, &Ia_syscall }, + /* 0F 06 */ { 0, &Ia_clts }, + /* 0F 07 */ { 0, &Ia_sysret }, + /* 0F 08 */ { 0, &Ia_invd }, + /* 0F 09 */ { 0, &Ia_wbinvd }, + /* 0F 0A */ { 0, &Ia_Invalid }, + /* 0F 0B */ { 0, &Ia_ud2a }, + /* 0F 0C */ { 0, &Ia_Invalid }, + /* 0F 0D */ { 0, &Ia_prefetch }, // 3DNow! + /* 0F 0E */ { 0, &Ia_femms }, // 3DNow! + /* 0F 0F */ { GRP3DNOW }, + /* 0F 10 */ { GRPSSE(0f10) }, + /* 0F 11 */ { GRPSSE(0f11) }, + /* 0F 12 */ { GRPSSE(0f12) }, + /* 0F 13 */ { GRPSSE(0f13) }, + /* 0F 14 */ { GRPSSE(0f14) }, + /* 0F 15 */ { GRPSSE(0f15) }, + /* 0F 16 */ { GRPSSE(0f16) }, + /* 0F 17 */ { GRPSSE(0f17) }, + /* 0F 18 */ { GRPN(G16) }, + /* 0F 19 */ { 0, &Ia_Invalid }, + /* 0F 1A */ { 0, &Ia_Invalid }, + /* 0F 1B */ { 0, &Ia_Invalid }, + /* 0F 1C */ { 0, &Ia_Invalid }, + /* 0F 1D */ { 0, &Ia_Invalid }, + /* 0F 1E */ { 0, &Ia_Invalid }, + /* 0F 1F */ { 0, &Ia_Invalid }, + /* 0F 20 */ { 0, &Ia_movq_Rq_Cq }, + /* 0F 21 */ { 0, &Ia_movl_Rd_Dd }, + /* 0F 22 */ { 0, &Ia_movq_Cq_Rq }, + /* 0F 23 */ { 0, &Ia_movl_Dd_Rd }, + /* 0F 24 */ { 0, &Ia_Invalid }, + /* 0F 25 */ { 0, &Ia_Invalid }, + /* 0F 26 */ { 0, &Ia_Invalid }, + /* 0F 27 */ { 0, &Ia_Invalid }, + /* 0F 28 */ { GRPSSE(0f28) }, + /* 0F 29 */ { GRPSSE(0f29) }, + /* 0F 2A */ { GRPSSE(0f2a) }, + /* 0F 2B */ { GRPSSE(0f2b) }, + /* 0F 2C */ { GRPSSE(0f2c) }, + /* 0F 2D */ { GRPSSE(0f2d) }, + /* 0F 2E */ { GRPSSE(0f2e) }, + /* 0F 2F */ { GRPSSE(0f2f) }, + /* 0F 30 */ { 0, &Ia_wrmsr }, + /* 0F 31 */ { 0, &Ia_rdtsc }, + /* 0F 32 */ { 0, &Ia_rdmsr }, + /* 0F 33 */ { 0, &Ia_rdpmc }, + /* 0F 34 */ { 0, &Ia_sysenter }, + /* 0F 35 */ { 0, &Ia_sysexit }, + /* 0F 36 */ { 0, &Ia_Invalid }, + /* 0F 37 */ { 0, &Ia_Invalid }, + /* 0F 38 */ { 0, &Ia_Invalid }, + /* 0F 39 */ { 0, &Ia_Invalid }, + /* 0F 3A */ { 0, &Ia_Invalid }, + /* 0F 3B */ { 0, &Ia_Invalid }, + /* 0F 3C */ { 0, &Ia_Invalid }, + /* 0F 3D */ { 0, &Ia_Invalid }, + /* 0F 3E */ { 0, &Ia_Invalid }, + /* 0F 3F */ { 0, &Ia_Invalid }, + /* 0F 40 */ { 0, &Ia_cmovow_Gw_Ew }, + /* 0F 41 */ { 0, &Ia_cmovnow_Gw_Ew }, + /* 0F 42 */ { 0, &Ia_cmovcw_Gw_Ew }, + /* 0F 43 */ { 0, &Ia_cmovncw_Gw_Ew }, + /* 0F 44 */ { 0, &Ia_cmovzw_Gw_Ew }, + /* 0F 45 */ { 0, &Ia_cmovnzw_Gw_Ew }, + /* 0F 46 */ { 0, &Ia_cmovnaw_Gw_Ew }, + /* 0F 47 */ { 0, &Ia_cmovaw_Gw_Ew }, + /* 0F 48 */ { 0, &Ia_cmovsw_Gw_Ew }, + /* 0F 49 */ { 0, &Ia_cmovnsw_Gw_Ew }, + /* 0F 4A */ { 0, &Ia_cmovpw_Gw_Ew }, + /* 0F 4B */ { 0, &Ia_cmovnpw_Gw_Ew }, + /* 0F 4C */ { 0, &Ia_cmovlw_Gw_Ew }, + /* 0F 4D */ { 0, &Ia_cmovnlw_Gw_Ew }, + /* 0F 4E */ { 0, &Ia_cmovngw_Gw_Ew }, + /* 0F 4F */ { 0, &Ia_cmovgw_Gw_Ew }, + /* 0F 50 */ { GRPSSE(0f50) }, + /* 0F 51 */ { GRPSSE(0f51) }, + /* 0F 52 */ { GRPSSE(0f52) }, + /* 0F 53 */ { GRPSSE(0f53) }, + /* 0F 54 */ { GRPSSE(0f54) }, + /* 0F 55 */ { GRPSSE(0f55) }, + /* 0F 56 */ { GRPSSE(0f56) }, + /* 0F 57 */ { GRPSSE(0f57) }, + /* 0F 58 */ { GRPSSE(0f58) }, + /* 0F 59 */ { GRPSSE(0f59) }, + /* 0F 5A */ { GRPSSE(0f5a) }, + /* 0F 5B */ { GRPSSE(0f5b) }, + /* 0F 5C */ { GRPSSE(0f5c) }, + /* 0F 5D */ { GRPSSE(0f5d) }, + /* 0F 5E */ { GRPSSE(0f5e) }, + /* 0F 5F */ { GRPSSE(0f5f) }, + /* 0F 60 */ { GRPSSE(0f60) }, + /* 0F 61 */ { GRPSSE(0f61) }, + /* 0F 62 */ { GRPSSE(0f62) }, + /* 0F 63 */ { GRPSSE(0f63) }, + /* 0F 64 */ { GRPSSE(0f64) }, + /* 0F 65 */ { GRPSSE(0f65) }, + /* 0F 66 */ { GRPSSE(0f66) }, + /* 0F 67 */ { GRPSSE(0f67) }, + /* 0F 68 */ { GRPSSE(0f68) }, + /* 0F 69 */ { GRPSSE(0f69) }, + /* 0F 6A */ { GRPSSE(0f6a) }, + /* 0F 6B */ { GRPSSE(0f6b) }, + /* 0F 6C */ { GRPSSE(0f6c) }, + /* 0F 6D */ { GRPSSE(0f6d) }, + /* 0F 6E */ { GRPSSE(0f6e) }, + /* 0F 6F */ { GRPSSE(0f6f) }, + /* 0F 70 */ { GRPSSE(0f70) }, + /* 0F 71 */ { GRPN(G12) }, + /* 0F 72 */ { GRPN(G13) }, + /* 0F 73 */ { GRPN(G14) }, + /* 0F 74 */ { GRPSSE(0f74) }, + /* 0F 75 */ { GRPSSE(0f75) }, + /* 0F 76 */ { GRPSSE(0f76) }, + /* 0F 77 */ { 0, &Ia_emms }, + /* 0F 78 */ { 0, &Ia_Invalid }, + /* 0F 79 */ { 0, &Ia_Invalid }, + /* 0F 7A */ { 0, &Ia_Invalid }, + /* 0F 7B */ { 0, &Ia_Invalid }, + /* 0F 7C */ { GRPSSE(0f7c) }, + /* 0F 7D */ { GRPSSE(0f7d) }, + /* 0F 7E */ { GRPSSE(0f7e) }, + /* 0F 7F */ { GRPSSE(0f7f) }, + /* 0F 80 */ { 0, &Ia_jo_Jd }, + /* 0F 81 */ { 0, &Ia_jno_Jd }, + /* 0F 82 */ { 0, &Ia_jb_Jd }, + /* 0F 83 */ { 0, &Ia_jnb_Jd }, + /* 0F 84 */ { 0, &Ia_jz_Jd }, + /* 0F 85 */ { 0, &Ia_jnz_Jd }, + /* 0F 86 */ { 0, &Ia_jbe_Jd }, + /* 0F 87 */ { 0, &Ia_jnbe_Jd }, + /* 0F 88 */ { 0, &Ia_js_Jd }, + /* 0F 89 */ { 0, &Ia_jns_Jd }, + /* 0F 8A */ { 0, &Ia_jp_Jd }, + /* 0F 8B */ { 0, &Ia_jnp_Jd }, + /* 0F 8C */ { 0, &Ia_jl_Jd }, + /* 0F 8D */ { 0, &Ia_jnl_Jd }, + /* 0F 8E */ { 0, &Ia_jle_Jd }, + /* 0F 8F */ { 0, &Ia_jnle_Jd }, + /* 0F 90 */ { 0, &Ia_seto_Eb }, + /* 0F 91 */ { 0, &Ia_setno_Eb }, + /* 0F 92 */ { 0, &Ia_setb_Eb }, + /* 0F 93 */ { 0, &Ia_setnb_Eb }, + /* 0F 94 */ { 0, &Ia_setz_Eb }, + /* 0F 95 */ { 0, &Ia_setnz_Eb }, + /* 0F 96 */ { 0, &Ia_setbe_Eb }, + /* 0F 97 */ { 0, &Ia_setnbe_Eb }, + /* 0F 98 */ { 0, &Ia_sets_Eb }, + /* 0F 99 */ { 0, &Ia_setns_Eb }, + /* 0F 9A */ { 0, &Ia_setp_Eb }, + /* 0F 9B */ { 0, &Ia_setnp_Eb }, + /* 0F 9C */ { 0, &Ia_setl_Eb }, + /* 0F 9D */ { 0, &Ia_setnl_Eb }, + /* 0F 9E */ { 0, &Ia_setle_Eb }, + /* 0F 9F */ { 0, &Ia_setnle_Eb }, + /* 0F A0 */ { 0, &Ia_pushw_FS }, + /* 0F A1 */ { 0, &Ia_popw_FS }, + /* 0F A2 */ { 0, &Ia_cpuid }, + /* 0F A3 */ { 0, &Ia_btw_Ew_Gw }, + /* 0F A4 */ { 0, &Ia_shldw_Ew_Gw_Ib }, + /* 0F A5 */ { 0, &Ia_shldw_Ew_Gw_CL }, + /* 0F A6 */ { 0, &Ia_Invalid }, + /* 0F A7 */ { 0, &Ia_Invalid }, + /* 0F A8 */ { 0, &Ia_pushw_GS }, + /* 0F A9 */ { 0, &Ia_popw_GS }, + /* 0F AA */ { 0, &Ia_rsm }, + /* 0F AB */ { 0, &Ia_btsw_Ew_Gw }, + /* 0F AC */ { 0, &Ia_shrdw_Ew_Gw_Ib }, + /* 0F AD */ { 0, &Ia_shrdw_Ew_Gw_CL }, + /* 0F AE */ { GRPN(G15) }, + /* 0F AF */ { 0, &Ia_imulw_Gw_Ew }, + /* 0F B0 */ { 0, &Ia_cmpxchgb_Eb_Gb }, + /* 0F B1 */ { 0, &Ia_cmpxchgw_Ew_Gw }, + /* 0F B2 */ { 0, &Ia_lssw_Gw_Mp }, + /* 0F B3 */ { 0, &Ia_btrw_Ew_Gw }, + /* 0F B4 */ { 0, &Ia_lfsw_Gw_Mp }, + /* 0F B5 */ { 0, &Ia_lgsw_Gw_Mp }, + /* 0F B6 */ { 0, &Ia_movzbw_Gw_Eb }, + /* 0F B7 */ { 0, &Ia_movw_Gw_Ew }, + /* 0F B8 */ { 0, &Ia_Invalid }, + /* 0F B9 */ { 0, &Ia_ud2b }, + /* 0F BA */ { GRPN(G8EwIb) }, + /* 0F BB */ { 0, &Ia_btcw_Ew_Gw }, + /* 0F BC */ { 0, &Ia_bsfw_Gw_Ew }, + /* 0F BD */ { 0, &Ia_bsrw_Gw_Ew }, + /* 0F BE */ { 0, &Ia_movsbw_Gw_Eb }, + /* 0F BF */ { 0, &Ia_movw_Gw_Ew }, + /* 0F C0 */ { 0, &Ia_xaddb_Eb_Gb }, + /* 0F C0 */ { 0, &Ia_xaddw_Ew_Gw }, + /* 0F C2 */ { GRPSSE(0fc2) }, + /* 0F C3 */ { GRPSSE(0fc3) }, + /* 0F C4 */ { GRPSSE(0fc4) }, + /* 0F C5 */ { GRPSSE(0fc5) }, + /* 0F C6 */ { GRPSSE(0fc6) }, + /* 0F C7 */ { GRPN(G9) }, + /* 0F C8 */ { 0, &Ia_bswapw_RX }, + /* 0F C9 */ { 0, &Ia_bswapw_RX }, + /* 0F CA */ { 0, &Ia_bswapw_RX }, + /* 0F CB */ { 0, &Ia_bswapw_RX }, + /* 0F CC */ { 0, &Ia_bswapw_RX }, + /* 0F CD */ { 0, &Ia_bswapw_RX }, + /* 0F CE */ { 0, &Ia_bswapw_RX }, + /* 0F CF */ { 0, &Ia_bswapw_RX }, + /* 0F D0 */ { GRPSSE(0fd0) }, + /* 0F D1 */ { GRPSSE(0fd1) }, + /* 0F D2 */ { GRPSSE(0fd2) }, + /* 0F D3 */ { GRPSSE(0fd3) }, + /* 0F D4 */ { GRPSSE(0fd4) }, + /* 0F D5 */ { GRPSSE(0fd5) }, + /* 0F D6 */ { GRPSSE(0fd6) }, + /* 0F D7 */ { GRPSSE(0fd7) }, + /* 0F D8 */ { GRPSSE(0fd8) }, + /* 0F D9 */ { GRPSSE(0fd9) }, + /* 0F DA */ { GRPSSE(0fda) }, + /* 0F DB */ { GRPSSE(0fdb) }, + /* 0F DC */ { GRPSSE(0fdc) }, + /* 0F DD */ { GRPSSE(0fdd) }, + /* 0F DE */ { GRPSSE(0fde) }, + /* 0F DF */ { GRPSSE(0fdf) }, + /* 0F E0 */ { GRPSSE(0fe0) }, + /* 0F E1 */ { GRPSSE(0fe1) }, + /* 0F E2 */ { GRPSSE(0fe2) }, + /* 0F E3 */ { GRPSSE(0fe3) }, + /* 0F E4 */ { GRPSSE(0fe4) }, + /* 0F E5 */ { GRPSSE(0fe5) }, + /* 0F E6 */ { GRPSSE(0fe6) }, + /* 0F E7 */ { GRPSSE(0fe7) }, + /* 0F E8 */ { GRPSSE(0fe8) }, + /* 0F E9 */ { GRPSSE(0fe9) }, + /* 0F EA */ { GRPSSE(0fea) }, + /* 0F EB */ { GRPSSE(0feb) }, + /* 0F EC */ { GRPSSE(0fec) }, + /* 0F ED */ { GRPSSE(0fed) }, + /* 0F EE */ { GRPSSE(0fee) }, + /* 0F EF */ { GRPSSE(0fef) }, + /* 0F F0 */ { GRPSSE(0ff0) }, + /* 0F F1 */ { GRPSSE(0ff1) }, + /* 0F F2 */ { GRPSSE(0ff2) }, + /* 0F F3 */ { GRPSSE(0ff3) }, + /* 0F F4 */ { GRPSSE(0ff4) }, + /* 0F F5 */ { GRPSSE(0ff5) }, + /* 0F F6 */ { GRPSSE(0ff6) }, + /* 0F F7 */ { GRPSSE(0ff7) }, + /* 0F F8 */ { GRPSSE(0ff8) }, + /* 0F F9 */ { GRPSSE(0ff9) }, + /* 0F FA */ { GRPSSE(0ffa) }, + /* 0F FB */ { GRPSSE(0ffb) }, + /* 0F FC */ { GRPSSE(0ffc) }, + /* 0F FD */ { GRPSSE(0ffd) }, + /* 0F FE */ { GRPSSE(0ffe) }, + /* 0F FF */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmOpcodes64d[256*2] = { + // 256 entries for single byte opcodes + /* 00 */ { 0, &Ia_addb_Eb_Gb }, + /* 01 */ { 0, &Ia_addl_Ed_Gd }, + /* 02 */ { 0, &Ia_addb_Gb_Eb }, + /* 03 */ { 0, &Ia_addl_Gd_Ed }, + /* 04 */ { 0, &Ia_addb_AL_Ib, }, + /* 05 */ { 0, &Ia_addl_EAX_Id, }, + /* 06 */ { 0, &Ia_Invalid }, + /* 07 */ { 0, &Ia_Invalid }, + /* 08 */ { 0, &Ia_orb_Eb_Gb }, + /* 09 */ { 0, &Ia_orl_Ed_Gd }, + /* 0A */ { 0, &Ia_orb_Gb_Eb }, + /* 0B */ { 0, &Ia_orl_Gd_Ed }, + /* 0C */ { 0, &Ia_orb_AL_Ib }, + /* 0D */ { 0, &Ia_orl_EAX_Id }, + /* 0E */ { 0, &Ia_Invalid }, + /* 0F */ { 0, &Ia_error }, // 2 byte escape + /* 10 */ { 0, &Ia_adcb_Eb_Gb }, + /* 11 */ { 0, &Ia_adcl_Ed_Gd }, + /* 12 */ { 0, &Ia_adcb_Gb_Eb }, + /* 13 */ { 0, &Ia_adcl_Gd_Ed }, + /* 14 */ { 0, &Ia_adcb_AL_Ib }, + /* 15 */ { 0, &Ia_adcl_EAX_Id }, + /* 16 */ { 0, &Ia_Invalid }, + /* 17 */ { 0, &Ia_Invalid }, + /* 18 */ { 0, &Ia_sbbb_Eb_Gb }, + /* 19 */ { 0, &Ia_sbbl_Ed_Gd }, + /* 1A */ { 0, &Ia_sbbb_Gb_Eb }, + /* 1B */ { 0, &Ia_sbbl_Gd_Ed }, + /* 1C */ { 0, &Ia_sbbb_AL_Ib }, + /* 1D */ { 0, &Ia_sbbl_EAX_Id }, + /* 1E */ { 0, &Ia_Invalid }, + /* 1F */ { 0, &Ia_Invalid }, + /* 20 */ { 0, &Ia_andb_Eb_Gb }, + /* 21 */ { 0, &Ia_andl_Ed_Gd }, + /* 22 */ { 0, &Ia_andb_Gb_Eb }, + /* 23 */ { 0, &Ia_andl_Gd_Ed }, + /* 24 */ { 0, &Ia_andb_AL_Ib }, + /* 25 */ { 0, &Ia_andl_EAX_Id }, + /* 26 */ { 0, &Ia_prefix_es }, // ES: + /* 27 */ { 0, &Ia_Invalid }, + /* 28 */ { 0, &Ia_subb_Eb_Gb }, + /* 29 */ { 0, &Ia_subl_Ed_Gd }, + /* 2A */ { 0, &Ia_subb_Gb_Eb }, + /* 2B */ { 0, &Ia_subl_Gd_Ed }, + /* 2C */ { 0, &Ia_subb_AL_Ib }, + /* 2D */ { 0, &Ia_subl_EAX_Id }, + /* 2E */ { 0, &Ia_prefix_cs }, // CS: + /* 2F */ { 0, &Ia_Invalid }, + /* 30 */ { 0, &Ia_xorb_Eb_Gb }, + /* 31 */ { 0, &Ia_xorl_Ed_Gd }, + /* 32 */ { 0, &Ia_xorb_Gb_Eb }, + /* 33 */ { 0, &Ia_xorl_Gd_Ed }, + /* 34 */ { 0, &Ia_xorb_AL_Ib }, + /* 35 */ { 0, &Ia_xorl_EAX_Id }, + /* 36 */ { 0, &Ia_prefix_ss }, // SS: + /* 37 */ { 0, &Ia_Invalid }, + /* 38 */ { 0, &Ia_cmpb_Eb_Gb }, + /* 39 */ { 0, &Ia_cmpl_Ed_Gd }, + /* 3A */ { 0, &Ia_cmpb_Gb_Eb }, + /* 3B */ { 0, &Ia_cmpl_Gd_Ed }, + /* 3C */ { 0, &Ia_cmpb_AL_Ib }, + /* 3D */ { 0, &Ia_cmpl_EAX_Id }, + /* 3E */ { 0, &Ia_prefix_ds }, // DS: + /* 3F */ { 0, &Ia_Invalid }, + /* 40 */ { 0, &Ia_prefix_rex }, // REX: + /* 41 */ { 0, &Ia_prefix_rex }, // REX: + /* 42 */ { 0, &Ia_prefix_rex }, // REX: + /* 43 */ { 0, &Ia_prefix_rex }, // REX: + /* 44 */ { 0, &Ia_prefix_rex }, // REX: + /* 45 */ { 0, &Ia_prefix_rex }, // REX: + /* 46 */ { 0, &Ia_prefix_rex }, // REX: + /* 47 */ { 0, &Ia_prefix_rex }, // REX: + /* 48 */ { 0, &Ia_prefix_rex }, // REX: + /* 49 */ { 0, &Ia_prefix_rex }, // REX: + /* 4A */ { 0, &Ia_prefix_rex }, // REX: + /* 4B */ { 0, &Ia_prefix_rex }, // REX: + /* 4C */ { 0, &Ia_prefix_rex }, // REX: + /* 4D */ { 0, &Ia_prefix_rex }, // REX: + /* 4E */ { 0, &Ia_prefix_rex }, // REX: + /* 4F */ { 0, &Ia_prefix_rex }, // REX: + /* 50 */ { 0, &Ia_pushq_RRX }, + /* 51 */ { 0, &Ia_pushq_RRX }, + /* 52 */ { 0, &Ia_pushq_RRX }, + /* 53 */ { 0, &Ia_pushq_RRX }, + /* 54 */ { 0, &Ia_pushq_RRX }, + /* 55 */ { 0, &Ia_pushq_RRX }, + /* 56 */ { 0, &Ia_pushq_RRX }, + /* 57 */ { 0, &Ia_pushq_RRX }, + /* 58 */ { 0, &Ia_popq_RRX }, + /* 59 */ { 0, &Ia_popq_RRX }, + /* 5A */ { 0, &Ia_popq_RRX }, + /* 5B */ { 0, &Ia_popq_RRX }, + /* 5C */ { 0, &Ia_popq_RRX }, + /* 5D */ { 0, &Ia_popq_RRX }, + /* 5E */ { 0, &Ia_popq_RRX }, + /* 5F */ { 0, &Ia_popq_RRX }, + /* 60 */ { 0, &Ia_Invalid }, + /* 61 */ { 0, &Ia_Invalid }, + /* 62 */ { 0, &Ia_Invalid }, + /* 63 */ { 0, &Ia_movl_Gd_Ed }, + /* 64 */ { 0, &Ia_prefix_fs }, // FS: + /* 65 */ { 0, &Ia_prefix_gs }, // GS: + /* 66 */ { 0, &Ia_prefix_osize }, // OSIZE: + /* 67 */ { 0, &Ia_prefix_asize }, // ASIZE: + /* 68 */ { 0, &Ia_pushq_sId }, + /* 69 */ { 0, &Ia_imull_Gd_Ed_Id }, + /* 6A */ { 0, &Ia_pushq_sIb }, + /* 6B */ { 0, &Ia_imull_Gd_Ed_sIb }, + /* 6C */ { 0, &Ia_insb_Yb_DX }, + /* 6D */ { 0, &Ia_insl_Yd_DX }, + /* 6E */ { 0, &Ia_outsb_DX_Xb }, + /* 6F */ { 0, &Ia_outsl_DX_Xd }, + /* 70 */ { 0, &Ia_jo_Jb }, + /* 71 */ { 0, &Ia_jno_Jb }, + /* 72 */ { 0, &Ia_jb_Jb }, + /* 73 */ { 0, &Ia_jnb_Jb }, + /* 74 */ { 0, &Ia_jz_Jb }, + /* 75 */ { 0, &Ia_jnz_Jb }, + /* 76 */ { 0, &Ia_jbe_Jb }, + /* 77 */ { 0, &Ia_jnbe_Jb }, + /* 78 */ { 0, &Ia_js_Jb }, + /* 79 */ { 0, &Ia_jns_Jb }, + /* 7A */ { 0, &Ia_jp_Jb }, + /* 7B */ { 0, &Ia_jnp_Jb }, + /* 7C */ { 0, &Ia_jl_Jb }, + /* 7D */ { 0, &Ia_jnl_Jb }, + /* 7E */ { 0, &Ia_jle_Jb }, + /* 7F */ { 0, &Ia_jnle_Jb }, + /* 80 */ { GRPN(G1EbIb) }, + /* 81 */ { GRPN(G1EdId) }, + /* 82 */ { 0, &Ia_Invalid }, + /* 83 */ { GRPN(G1EdIb) }, + /* 84 */ { 0, &Ia_testb_Eb_Gb }, + /* 85 */ { 0, &Ia_testl_Ed_Gd }, + /* 86 */ { 0, &Ia_xchgb_Eb_Gb }, + /* 87 */ { 0, &Ia_xchgl_Ed_Gd }, + /* 88 */ { 0, &Ia_movb_Eb_Gb }, + /* 89 */ { 0, &Ia_movl_Ed_Gd }, + /* 8A */ { 0, &Ia_movb_Gb_Eb }, + /* 8B */ { 0, &Ia_movl_Gd_Ed }, + /* 8C */ { 0, &Ia_movw_Ew_Sw }, + /* 8D */ { 0, &Ia_leal_Gd_Md }, + /* 8E */ { 0, &Ia_movw_Sw_Ew }, + /* 8F */ { 0, &Ia_popq_Eq }, + /* 90 */ { 0, &Ia_nop }, + /* 91 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 92 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 93 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 94 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 95 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 96 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 97 */ { 0, &Ia_xchgl_ERX_EAX }, + /* 98 */ { 0, &Ia_cwde }, + /* 99 */ { 0, &Ia_cdq }, + /* 9A */ { 0, &Ia_Invalid }, + /* 9B */ { 0, &Ia_fwait }, + /* 9C */ { 0, &Ia_pushfq }, + /* 9D */ { 0, &Ia_popfq }, + /* 9E */ { 0, &Ia_sahf }, + /* 9F */ { 0, &Ia_lahf }, + /* A0 */ { 0, &Ia_movb_AL_Ob }, + /* A1 */ { 0, &Ia_movl_EAX_Od }, + /* A0 */ { 0, &Ia_movb_Ob_AL }, + /* A1 */ { 0, &Ia_movl_Od_EAX }, + /* A4 */ { 0, &Ia_movsb_Yb_Xb }, + /* A5 */ { 0, &Ia_movsl_Yd_Xd }, + /* A6 */ { 0, &Ia_cmpsb_Yb_Xb }, + /* A7 */ { 0, &Ia_cmpsl_Yd_Xd }, + /* A8 */ { 0, &Ia_testb_AL_Ib }, + /* A9 */ { 0, &Ia_testl_EAX_Id }, + /* AA */ { 0, &Ia_stosb_Yb_AL }, + /* AB */ { 0, &Ia_stosl_Yd_EAX }, + /* AC */ { 0, &Ia_lodsb_AL_Xb }, + /* AD */ { 0, &Ia_lodsl_EAX_Xd }, + /* AE */ { 0, &Ia_scasb_Yb_AL }, + /* AF */ { 0, &Ia_scasl_Yd_EAX }, + /* B0 */ { 0, &Ia_movb_R8_Ib }, + /* B1 */ { 0, &Ia_movb_R8_Ib }, + /* B2 */ { 0, &Ia_movb_R8_Ib }, + /* B3 */ { 0, &Ia_movb_R8_Ib }, + /* B4 */ { 0, &Ia_movb_R8_Ib }, + /* B5 */ { 0, &Ia_movb_R8_Ib }, + /* B6 */ { 0, &Ia_movb_R8_Ib }, + /* B7 */ { 0, &Ia_movb_R8_Ib }, + /* B8 */ { 0, &Ia_movl_ERX_Id }, + /* B9 */ { 0, &Ia_movl_ERX_Id }, + /* BA */ { 0, &Ia_movl_ERX_Id }, + /* BB */ { 0, &Ia_movl_ERX_Id }, + /* BC */ { 0, &Ia_movl_ERX_Id }, + /* BD */ { 0, &Ia_movl_ERX_Id }, + /* BE */ { 0, &Ia_movl_ERX_Id }, + /* BF */ { 0, &Ia_movl_ERX_Id }, + /* C0 */ { GRPN(G2Eb) }, + /* C1 */ { GRPN(G2Ed) }, + /* C2 */ { 0, &Ia_ret_Iw }, + /* C3 */ { 0, &Ia_ret }, + /* C4 */ { 0, &Ia_Invalid }, + /* C5 */ { 0, &Ia_Invalid }, + /* C6 */ { 0, &Ia_movb_Eb_Ib }, + /* C7 */ { 0, &Ia_movl_Ed_Id }, + /* C8 */ { 0, &Ia_enter }, + /* C9 */ { 0, &Ia_leave }, + /* CA */ { 0, &Ia_lret_Iw }, + /* CB */ { 0, &Ia_lret }, + /* CC */ { 0, &Ia_int3 }, + /* CD */ { 0, &Ia_int_Ib }, + /* CE */ { 0, &Ia_Invalid }, + /* CF */ { 0, &Ia_iretl }, + /* D0 */ { GRPN(G2EbI1) }, + /* D1 */ { GRPN(G2EdI1) }, + /* D2 */ { GRPN(G2EbCL) }, + /* D3 */ { GRPN(G2EdCL) }, + /* D4 */ { 0, &Ia_Invalid }, + /* D5 */ { 0, &Ia_Invalid }, + /* D6 */ { 0, &Ia_Invalid }, + /* D7 */ { 0, &Ia_xlat }, + /* D8 */ { GRPFP(D8) }, + /* D9 */ { GRPFP(D9) }, + /* DA */ { GRPFP(DA) }, + /* DB */ { GRPFP(DB) }, + /* DC */ { GRPFP(DC) }, + /* DD */ { GRPFP(DD) }, + /* DE */ { GRPFP(DE) }, + /* DF */ { GRPFP(DF) }, + /* E0 */ { 0, &Ia_loopne_Jb }, + /* E1 */ { 0, &Ia_loope_Jb }, + /* E2 */ { 0, &Ia_loop_Jb }, + /* E3 */ { 0, &Ia_jrcxz_Jb }, + /* E4 */ { 0, &Ia_inb_AL_Ib }, + /* E5 */ { 0, &Ia_inl_EAX_Ib }, + /* E6 */ { 0, &Ia_outb_Ib_AL }, + /* E7 */ { 0, &Ia_outl_Ib_EAX }, + /* E8 */ { 0, &Ia_call_Jd }, + /* E9 */ { 0, &Ia_jmp_Jd }, + /* EA */ { 0, &Ia_Invalid }, + /* EB */ { 0, &Ia_jmp_Jb }, + /* EC */ { 0, &Ia_inb_AL_Ib }, + /* ED */ { 0, &Ia_inl_EAX_DX }, + /* EE */ { 0, &Ia_outb_DX_AL }, + /* EF */ { 0, &Ia_outl_DX_EAX }, + /* F0 */ { 0, &Ia_prefix_lock }, // LOCK: + /* F1 */ { 0, &Ia_int1 }, + /* F2 */ { 0, &Ia_prefix_repne }, // REPNE: + /* F3 */ { 0, &Ia_prefix_rep }, // REP: + /* F4 */ { 0, &Ia_hlt }, + /* F5 */ { 0, &Ia_cmc }, + /* F6 */ { GRPN(G3Eb) }, + /* F7 */ { GRPN(G3Ed) }, + /* F8 */ { 0, &Ia_clc }, + /* F9 */ { 0, &Ia_stc }, + /* FA */ { 0, &Ia_cli }, + /* FB */ { 0, &Ia_sti }, + /* FC */ { 0, &Ia_cld }, + /* FD */ { 0, &Ia_std }, + /* FE */ { GRPN(G4) }, + /* FF */ { GRPN(64G5d) }, + + // 256 entries for two byte opcodes + /* 0F 00 */ { GRPN(G6) }, + /* 0F 01 */ { GRPN(G7) }, + /* 0F 02 */ { 0, &Ia_larl_Gd_Ew }, + /* 0F 03 */ { 0, &Ia_lsll_Gd_Ew }, + /* 0F 04 */ { 0, &Ia_Invalid }, + /* 0F 05 */ { 0, &Ia_syscall }, + /* 0F 06 */ { 0, &Ia_clts }, + /* 0F 07 */ { 0, &Ia_sysret }, + /* 0F 08 */ { 0, &Ia_invd }, + /* 0F 09 */ { 0, &Ia_wbinvd }, + /* 0F 0A */ { 0, &Ia_Invalid }, + /* 0F 0B */ { 0, &Ia_ud2a }, + /* 0F 0C */ { 0, &Ia_Invalid }, + /* 0F 0D */ { 0, &Ia_prefetch }, // 3DNow! + /* 0F 0E */ { 0, &Ia_femms }, // 3DNow! + /* 0F 0F */ { GRP3DNOW }, + /* 0F 10 */ { GRPSSE(0f10) }, + /* 0F 11 */ { GRPSSE(0f11) }, + /* 0F 12 */ { GRPSSE(0f12) }, + /* 0F 13 */ { GRPSSE(0f13) }, + /* 0F 14 */ { GRPSSE(0f14) }, + /* 0F 15 */ { GRPSSE(0f15) }, + /* 0F 16 */ { GRPSSE(0f16) }, + /* 0F 17 */ { GRPSSE(0f17) }, + /* 0F 18 */ { GRPN(G16) }, + /* 0F 19 */ { 0, &Ia_Invalid }, + /* 0F 1A */ { 0, &Ia_Invalid }, + /* 0F 1B */ { 0, &Ia_Invalid }, + /* 0F 1C */ { 0, &Ia_Invalid }, + /* 0F 1D */ { 0, &Ia_Invalid }, + /* 0F 1E */ { 0, &Ia_Invalid }, + /* 0F 1F */ { 0, &Ia_Invalid }, + /* 0F 20 */ { 0, &Ia_movq_Rq_Cq }, + /* 0F 21 */ { 0, &Ia_movl_Rd_Dd }, + /* 0F 22 */ { 0, &Ia_movq_Cq_Rq }, + /* 0F 23 */ { 0, &Ia_movl_Dd_Rd }, + /* 0F 24 */ { 0, &Ia_Invalid }, + /* 0F 25 */ { 0, &Ia_Invalid }, + /* 0F 26 */ { 0, &Ia_Invalid }, + /* 0F 27 */ { 0, &Ia_Invalid }, + /* 0F 28 */ { GRPSSE(0f28) }, + /* 0F 29 */ { GRPSSE(0f29) }, + /* 0F 2A */ { GRPSSE(0f2a) }, + /* 0F 2B */ { GRPSSE(0f2b) }, + /* 0F 2C */ { GRPSSE(0f2c) }, + /* 0F 2D */ { GRPSSE(0f2d) }, + /* 0F 2E */ { GRPSSE(0f2e) }, + /* 0F 2F */ { GRPSSE(0f2f) }, + /* 0F 30 */ { 0, &Ia_wrmsr }, + /* 0F 31 */ { 0, &Ia_rdtsc }, + /* 0F 32 */ { 0, &Ia_rdmsr }, + /* 0F 33 */ { 0, &Ia_rdpmc }, + /* 0F 34 */ { 0, &Ia_sysenter }, + /* 0F 35 */ { 0, &Ia_sysexit }, + /* 0F 36 */ { 0, &Ia_Invalid }, + /* 0F 37 */ { 0, &Ia_Invalid }, + /* 0F 38 */ { 0, &Ia_Invalid }, + /* 0F 39 */ { 0, &Ia_Invalid }, + /* 0F 3A */ { 0, &Ia_Invalid }, + /* 0F 3B */ { 0, &Ia_Invalid }, + /* 0F 3C */ { 0, &Ia_Invalid }, + /* 0F 3D */ { 0, &Ia_Invalid }, + /* 0F 3E */ { 0, &Ia_Invalid }, + /* 0F 3F */ { 0, &Ia_Invalid }, + /* 0F 40 */ { 0, &Ia_cmovol_Gd_Ed }, + /* 0F 41 */ { 0, &Ia_cmovnol_Gd_Ed }, + /* 0F 42 */ { 0, &Ia_cmovcl_Gd_Ed }, + /* 0F 43 */ { 0, &Ia_cmovncl_Gd_Ed }, + /* 0F 44 */ { 0, &Ia_cmovzl_Gd_Ed }, + /* 0F 45 */ { 0, &Ia_cmovnzl_Gd_Ed }, + /* 0F 46 */ { 0, &Ia_cmovnal_Gd_Ed }, + /* 0F 47 */ { 0, &Ia_cmoval_Gd_Ed }, + /* 0F 48 */ { 0, &Ia_cmovsl_Gd_Ed }, + /* 0F 49 */ { 0, &Ia_cmovnsl_Gd_Ed }, + /* 0F 4A */ { 0, &Ia_cmovpl_Gd_Ed }, + /* 0F 4B */ { 0, &Ia_cmovnpl_Gd_Ed }, + /* 0F 4C */ { 0, &Ia_cmovll_Gd_Ed }, + /* 0F 4D */ { 0, &Ia_cmovnll_Gd_Ed }, + /* 0F 4E */ { 0, &Ia_cmovngl_Gd_Ed }, + /* 0F 4F */ { 0, &Ia_cmovgl_Gd_Ed }, + /* 0F 50 */ { GRPSSE(0f50) }, + /* 0F 51 */ { GRPSSE(0f51) }, + /* 0F 52 */ { GRPSSE(0f52) }, + /* 0F 53 */ { GRPSSE(0f53) }, + /* 0F 54 */ { GRPSSE(0f54) }, + /* 0F 55 */ { GRPSSE(0f55) }, + /* 0F 56 */ { GRPSSE(0f56) }, + /* 0F 57 */ { GRPSSE(0f57) }, + /* 0F 58 */ { GRPSSE(0f58) }, + /* 0F 59 */ { GRPSSE(0f59) }, + /* 0F 5A */ { GRPSSE(0f5a) }, + /* 0F 5B */ { GRPSSE(0f5b) }, + /* 0F 5C */ { GRPSSE(0f5c) }, + /* 0F 5D */ { GRPSSE(0f5d) }, + /* 0F 5E */ { GRPSSE(0f5e) }, + /* 0F 5F */ { GRPSSE(0f5f) }, + /* 0F 60 */ { GRPSSE(0f60) }, + /* 0F 61 */ { GRPSSE(0f61) }, + /* 0F 62 */ { GRPSSE(0f62) }, + /* 0F 63 */ { GRPSSE(0f63) }, + /* 0F 64 */ { GRPSSE(0f64) }, + /* 0F 65 */ { GRPSSE(0f65) }, + /* 0F 66 */ { GRPSSE(0f66) }, + /* 0F 67 */ { GRPSSE(0f67) }, + /* 0F 68 */ { GRPSSE(0f68) }, + /* 0F 69 */ { GRPSSE(0f69) }, + /* 0F 6A */ { GRPSSE(0f6a) }, + /* 0F 6B */ { GRPSSE(0f6b) }, + /* 0F 6C */ { GRPSSE(0f6c) }, + /* 0F 6D */ { GRPSSE(0f6d) }, + /* 0F 6E */ { GRPSSE(0f6e) }, + /* 0F 6F */ { GRPSSE(0f6f) }, + /* 0F 70 */ { GRPSSE(0f70) }, + /* 0F 71 */ { GRPN(G12) }, + /* 0F 72 */ { GRPN(G13) }, + /* 0F 73 */ { GRPN(G14) }, + /* 0F 74 */ { GRPSSE(0f74) }, + /* 0F 75 */ { GRPSSE(0f75) }, + /* 0F 76 */ { GRPSSE(0f76) }, + /* 0F 77 */ { 0, &Ia_emms }, + /* 0F 78 */ { 0, &Ia_Invalid }, + /* 0F 79 */ { 0, &Ia_Invalid }, + /* 0F 7A */ { 0, &Ia_Invalid }, + /* 0F 7B */ { 0, &Ia_Invalid }, + /* 0F 7C */ { GRPSSE(0f7c) }, + /* 0F 7D */ { GRPSSE(0f7d) }, + /* 0F 7E */ { GRPSSE(0f7e) }, + /* 0F 7F */ { GRPSSE(0f7f) }, + /* 0F 80 */ { 0, &Ia_jo_Jd }, + /* 0F 81 */ { 0, &Ia_jno_Jd }, + /* 0F 82 */ { 0, &Ia_jb_Jd }, + /* 0F 83 */ { 0, &Ia_jnb_Jd }, + /* 0F 84 */ { 0, &Ia_jz_Jd }, + /* 0F 85 */ { 0, &Ia_jnz_Jd }, + /* 0F 86 */ { 0, &Ia_jbe_Jd }, + /* 0F 87 */ { 0, &Ia_jnbe_Jd }, + /* 0F 88 */ { 0, &Ia_js_Jd }, + /* 0F 89 */ { 0, &Ia_jns_Jd }, + /* 0F 8A */ { 0, &Ia_jp_Jd }, + /* 0F 8B */ { 0, &Ia_jnp_Jd }, + /* 0F 8C */ { 0, &Ia_jl_Jd }, + /* 0F 8D */ { 0, &Ia_jnl_Jd }, + /* 0F 8E */ { 0, &Ia_jle_Jd }, + /* 0F 8F */ { 0, &Ia_jnle_Jd }, + /* 0F 90 */ { 0, &Ia_seto_Eb }, + /* 0F 91 */ { 0, &Ia_setno_Eb }, + /* 0F 92 */ { 0, &Ia_setb_Eb }, + /* 0F 93 */ { 0, &Ia_setnb_Eb }, + /* 0F 94 */ { 0, &Ia_setz_Eb }, + /* 0F 95 */ { 0, &Ia_setnz_Eb }, + /* 0F 96 */ { 0, &Ia_setbe_Eb }, + /* 0F 97 */ { 0, &Ia_setnbe_Eb }, + /* 0F 98 */ { 0, &Ia_sets_Eb }, + /* 0F 99 */ { 0, &Ia_setns_Eb }, + /* 0F 9A */ { 0, &Ia_setp_Eb }, + /* 0F 9B */ { 0, &Ia_setnp_Eb }, + /* 0F 9C */ { 0, &Ia_setl_Eb }, + /* 0F 9D */ { 0, &Ia_setnl_Eb }, + /* 0F 9E */ { 0, &Ia_setle_Eb }, + /* 0F 9F */ { 0, &Ia_setnle_Eb }, + /* 0F A0 */ { 0, &Ia_pushq_FS }, + /* 0F A1 */ { 0, &Ia_popq_FS }, + /* 0F A2 */ { 0, &Ia_cpuid }, + /* 0F A3 */ { 0, &Ia_btl_Ed_Gd }, + /* 0F A4 */ { 0, &Ia_shldl_Ed_Gd_Ib }, + /* 0F A5 */ { 0, &Ia_shldl_Ed_Gd_CL }, + /* 0F A6 */ { 0, &Ia_Invalid }, + /* 0F A7 */ { 0, &Ia_Invalid }, + /* 0F A8 */ { 0, &Ia_pushq_GS }, + /* 0F A9 */ { 0, &Ia_popq_GS }, + /* 0F AA */ { 0, &Ia_rsm }, + /* 0F AB */ { 0, &Ia_btsl_Ed_Gd }, + /* 0F AC */ { 0, &Ia_shrdl_Ed_Gd_Ib }, + /* 0F AD */ { 0, &Ia_shrdl_Ed_Gd_CL }, + /* 0F AE */ { GRPN(G15) }, + /* 0F AF */ { 0, &Ia_imull_Gd_Ed }, + /* 0F B0 */ { 0, &Ia_cmpxchgb_Eb_Gb }, + /* 0F B1 */ { 0, &Ia_cmpxchgl_Ed_Gd }, + /* 0F B2 */ { 0, &Ia_lssl_Gd_Mp }, + /* 0F B3 */ { 0, &Ia_btrl_Ed_Gd }, + /* 0F B4 */ { 0, &Ia_lfsl_Gd_Mp }, + /* 0F B5 */ { 0, &Ia_lgsl_Gd_Mp }, + /* 0F B6 */ { 0, &Ia_movzbl_Gd_Eb }, + /* 0F B7 */ { 0, &Ia_movzwl_Gd_Ew }, + /* 0F B8 */ { 0, &Ia_Invalid }, + /* 0F B9 */ { 0, &Ia_ud2b }, + /* 0F BA */ { GRPN(G8EdIb) }, + /* 0F BB */ { 0, &Ia_btcl_Ed_Gd }, + /* 0F BC */ { 0, &Ia_bsfl_Gd_Ed }, + /* 0F BD */ { 0, &Ia_bsrl_Gd_Ed }, + /* 0F BE */ { 0, &Ia_movsbl_Gd_Eb }, + /* 0F BF */ { 0, &Ia_movswl_Gd_Ew }, + /* 0F C0 */ { 0, &Ia_xaddb_Eb_Gb }, + /* 0F C0 */ { 0, &Ia_xaddl_Ed_Gd }, + /* 0F C2 */ { GRPSSE(0fc2) }, + /* 0F C3 */ { GRPSSE(0fc3) }, + /* 0F C4 */ { GRPSSE(0fc4) }, + /* 0F C5 */ { GRPSSE(0fc5) }, + /* 0F C6 */ { GRPSSE(0fc6) }, + /* 0F C7 */ { GRPN(G9) }, + /* 0F C8 */ { 0, &Ia_bswapl_ERX }, + /* 0F C9 */ { 0, &Ia_bswapl_ERX }, + /* 0F CA */ { 0, &Ia_bswapl_ERX }, + /* 0F CB */ { 0, &Ia_bswapl_ERX }, + /* 0F CC */ { 0, &Ia_bswapl_ERX }, + /* 0F CD */ { 0, &Ia_bswapl_ERX }, + /* 0F CE */ { 0, &Ia_bswapl_ERX }, + /* 0F CF */ { 0, &Ia_bswapl_ERX }, + /* 0F D0 */ { GRPSSE(0fd0) }, + /* 0F D1 */ { GRPSSE(0fd1) }, + /* 0F D2 */ { GRPSSE(0fd2) }, + /* 0F D3 */ { GRPSSE(0fd3) }, + /* 0F D4 */ { GRPSSE(0fd4) }, + /* 0F D5 */ { GRPSSE(0fd5) }, + /* 0F D6 */ { GRPSSE(0fd6) }, + /* 0F D7 */ { GRPSSE(0fd7) }, + /* 0F D8 */ { GRPSSE(0fd8) }, + /* 0F D9 */ { GRPSSE(0fd9) }, + /* 0F DA */ { GRPSSE(0fda) }, + /* 0F DB */ { GRPSSE(0fdb) }, + /* 0F DC */ { GRPSSE(0fdc) }, + /* 0F DD */ { GRPSSE(0fdd) }, + /* 0F DE */ { GRPSSE(0fde) }, + /* 0F DF */ { GRPSSE(0fdf) }, + /* 0F E0 */ { GRPSSE(0fe0) }, + /* 0F E1 */ { GRPSSE(0fe1) }, + /* 0F E2 */ { GRPSSE(0fe2) }, + /* 0F E3 */ { GRPSSE(0fe3) }, + /* 0F E4 */ { GRPSSE(0fe4) }, + /* 0F E5 */ { GRPSSE(0fe5) }, + /* 0F E6 */ { GRPSSE(0fe6) }, + /* 0F E7 */ { GRPSSE(0fe7) }, + /* 0F E8 */ { GRPSSE(0fe8) }, + /* 0F E9 */ { GRPSSE(0fe9) }, + /* 0F EA */ { GRPSSE(0fea) }, + /* 0F EB */ { GRPSSE(0feb) }, + /* 0F EC */ { GRPSSE(0fec) }, + /* 0F ED */ { GRPSSE(0fed) }, + /* 0F EE */ { GRPSSE(0fee) }, + /* 0F EF */ { GRPSSE(0fef) }, + /* 0F F0 */ { GRPSSE(0ff0) }, + /* 0F F1 */ { GRPSSE(0ff1) }, + /* 0F F2 */ { GRPSSE(0ff2) }, + /* 0F F3 */ { GRPSSE(0ff3) }, + /* 0F F4 */ { GRPSSE(0ff4) }, + /* 0F F5 */ { GRPSSE(0ff5) }, + /* 0F F6 */ { GRPSSE(0ff6) }, + /* 0F F7 */ { GRPSSE(0ff7) }, + /* 0F F8 */ { GRPSSE(0ff8) }, + /* 0F F9 */ { GRPSSE(0ff9) }, + /* 0F FA */ { GRPSSE(0ffa) }, + /* 0F FB */ { GRPSSE(0ffb) }, + /* 0F FC */ { GRPSSE(0ffc) }, + /* 0F FD */ { GRPSSE(0ffd) }, + /* 0F FE */ { GRPSSE(0ffe) }, + /* 0F FF */ { 0, &Ia_Invalid } +}; + +static BxDisasmOpcodeTable_t BxDisasmOpcodes64q[256*2] = { + // 256 entries for single byte opcodes + /* 00 */ { 0, &Ia_addb_Eb_Gb }, + /* 01 */ { 0, &Ia_addq_Eq_Gq }, + /* 02 */ { 0, &Ia_addb_Gb_Eb }, + /* 03 */ { 0, &Ia_addq_Gq_Eq }, + /* 04 */ { 0, &Ia_addb_AL_Ib, }, + /* 05 */ { 0, &Ia_addq_RAX_sId }, + /* 06 */ { 0, &Ia_Invalid }, + /* 07 */ { 0, &Ia_Invalid }, + /* 08 */ { 0, &Ia_orb_Eb_Gb }, + /* 09 */ { 0, &Ia_orq_Eq_Gq }, + /* 0A */ { 0, &Ia_orb_Gb_Eb }, + /* 0B */ { 0, &Ia_orq_Gq_Eq }, + /* 0C */ { 0, &Ia_orb_AL_Ib }, + /* 0D */ { 0, &Ia_orq_RAX_sId }, + /* 0E */ { 0, &Ia_Invalid }, + /* 0F */ { 0, &Ia_error }, // 2 byte escape + /* 10 */ { 0, &Ia_adcb_Eb_Gb }, + /* 11 */ { 0, &Ia_adcq_Eq_Gq }, + /* 12 */ { 0, &Ia_adcb_Gb_Eb }, + /* 13 */ { 0, &Ia_adcq_Gq_Eq }, + /* 14 */ { 0, &Ia_adcb_AL_Ib }, + /* 15 */ { 0, &Ia_adcq_RAX_sId }, + /* 16 */ { 0, &Ia_Invalid }, + /* 17 */ { 0, &Ia_Invalid }, + /* 18 */ { 0, &Ia_sbbb_Eb_Gb }, + /* 19 */ { 0, &Ia_sbbq_Eq_Gq }, + /* 1A */ { 0, &Ia_sbbb_Gb_Eb }, + /* 1B */ { 0, &Ia_sbbq_Gq_Eq }, + /* 1C */ { 0, &Ia_sbbb_AL_Ib }, + /* 1D */ { 0, &Ia_sbbq_RAX_sId }, + /* 1E */ { 0, &Ia_Invalid }, + /* 1F */ { 0, &Ia_Invalid }, + /* 20 */ { 0, &Ia_andb_Eb_Gb }, + /* 21 */ { 0, &Ia_andq_Eq_Gq }, + /* 22 */ { 0, &Ia_andb_Gb_Eb }, + /* 23 */ { 0, &Ia_andq_Gq_Eq }, + /* 24 */ { 0, &Ia_andb_AL_Ib }, + /* 25 */ { 0, &Ia_andq_RAX_sId }, + /* 26 */ { 0, &Ia_prefix_es }, // ES: + /* 27 */ { 0, &Ia_Invalid }, + /* 28 */ { 0, &Ia_subb_Eb_Gb }, + /* 29 */ { 0, &Ia_subq_Eq_Gq }, + /* 2A */ { 0, &Ia_subb_Gb_Eb }, + /* 2B */ { 0, &Ia_subq_Gq_Eq }, + /* 2C */ { 0, &Ia_subb_AL_Ib }, + /* 2D */ { 0, &Ia_subq_RAX_sId }, + /* 2E */ { 0, &Ia_prefix_cs }, // CS: + /* 2F */ { 0, &Ia_Invalid }, + /* 30 */ { 0, &Ia_xorb_Eb_Gb }, + /* 31 */ { 0, &Ia_xorq_Eq_Gq }, + /* 32 */ { 0, &Ia_xorb_Gb_Eb }, + /* 33 */ { 0, &Ia_xorq_Gq_Eq }, + /* 34 */ { 0, &Ia_xorb_AL_Ib }, + /* 35 */ { 0, &Ia_xorq_RAX_sId }, + /* 36 */ { 0, &Ia_prefix_ss }, // SS: + /* 37 */ { 0, &Ia_Invalid }, + /* 38 */ { 0, &Ia_cmpb_Eb_Gb }, + /* 39 */ { 0, &Ia_cmpq_Eq_Gq }, + /* 3A */ { 0, &Ia_cmpb_Gb_Eb }, + /* 3B */ { 0, &Ia_cmpq_Gq_Eq }, + /* 3C */ { 0, &Ia_cmpb_AL_Ib }, + /* 3D */ { 0, &Ia_cmpq_RAX_sId }, + /* 3E */ { 0, &Ia_prefix_ds }, // DS: + /* 3F */ { 0, &Ia_Invalid }, + /* 40 */ { 0, &Ia_prefix_rex }, // REX: + /* 41 */ { 0, &Ia_prefix_rex }, // REX: + /* 42 */ { 0, &Ia_prefix_rex }, // REX: + /* 43 */ { 0, &Ia_prefix_rex }, // REX: + /* 44 */ { 0, &Ia_prefix_rex }, // REX: + /* 45 */ { 0, &Ia_prefix_rex }, // REX: + /* 46 */ { 0, &Ia_prefix_rex }, // REX: + /* 47 */ { 0, &Ia_prefix_rex }, // REX: + /* 48 */ { 0, &Ia_prefix_rex }, // REX: + /* 49 */ { 0, &Ia_prefix_rex }, // REX: + /* 4A */ { 0, &Ia_prefix_rex }, // REX: + /* 4B */ { 0, &Ia_prefix_rex }, // REX: + /* 4C */ { 0, &Ia_prefix_rex }, // REX: + /* 4D */ { 0, &Ia_prefix_rex }, // REX: + /* 4E */ { 0, &Ia_prefix_rex }, // REX: + /* 4F */ { 0, &Ia_prefix_rex }, // REX: + /* 50 */ { 0, &Ia_pushq_RRX }, + /* 51 */ { 0, &Ia_pushq_RRX }, + /* 52 */ { 0, &Ia_pushq_RRX }, + /* 53 */ { 0, &Ia_pushq_RRX }, + /* 54 */ { 0, &Ia_pushq_RRX }, + /* 55 */ { 0, &Ia_pushq_RRX }, + /* 56 */ { 0, &Ia_pushq_RRX }, + /* 57 */ { 0, &Ia_pushq_RRX }, + /* 58 */ { 0, &Ia_popq_RRX }, + /* 59 */ { 0, &Ia_popq_RRX }, + /* 5A */ { 0, &Ia_popq_RRX }, + /* 5B */ { 0, &Ia_popq_RRX }, + /* 5C */ { 0, &Ia_popq_RRX }, + /* 5D */ { 0, &Ia_popq_RRX }, + /* 5E */ { 0, &Ia_popq_RRX }, + /* 5F */ { 0, &Ia_popq_RRX }, + /* 60 */ { 0, &Ia_Invalid }, + /* 61 */ { 0, &Ia_Invalid }, + /* 62 */ { 0, &Ia_Invalid }, + /* 63 */ { 0, &Ia_movslq_Gq_Ed }, + /* 64 */ { 0, &Ia_prefix_fs }, // FS: + /* 65 */ { 0, &Ia_prefix_gs }, // GS: + /* 66 */ { 0, &Ia_prefix_osize }, // OSIZE: + /* 67 */ { 0, &Ia_prefix_asize }, // ASIZE: + /* 68 */ { 0, &Ia_pushq_sId }, + /* 69 */ { 0, &Ia_imulq_Gq_Eq_sId }, + /* 6A */ { 0, &Ia_pushq_sIb }, + /* 6B */ { 0, &Ia_imulq_Gq_Eq_sIb }, + /* 6C */ { 0, &Ia_insb_Yb_DX }, + /* 6D */ { 0, &Ia_insl_Yd_DX }, + /* 6E */ { 0, &Ia_outsb_DX_Xb }, + /* 6F */ { 0, &Ia_outsl_DX_Xd }, + /* 70 */ { 0, &Ia_jo_Jb }, + /* 71 */ { 0, &Ia_jno_Jb }, + /* 72 */ { 0, &Ia_jb_Jb }, + /* 73 */ { 0, &Ia_jnb_Jb }, + /* 74 */ { 0, &Ia_jz_Jb }, + /* 75 */ { 0, &Ia_jnz_Jb }, + /* 76 */ { 0, &Ia_jbe_Jb }, + /* 77 */ { 0, &Ia_jnbe_Jb }, + /* 78 */ { 0, &Ia_js_Jb }, + /* 79 */ { 0, &Ia_jns_Jb }, + /* 7A */ { 0, &Ia_jp_Jb }, + /* 7B */ { 0, &Ia_jnp_Jb }, + /* 7C */ { 0, &Ia_jl_Jb }, + /* 7D */ { 0, &Ia_jnl_Jb }, + /* 7E */ { 0, &Ia_jle_Jb }, + /* 7F */ { 0, &Ia_jnle_Jb }, + /* 80 */ { GRPN(G1EbIb) }, + /* 81 */ { GRPN(G1EqId) }, + /* 82 */ { 0, &Ia_Invalid }, + /* 83 */ { GRPN(G1EqIb) }, + /* 84 */ { 0, &Ia_testb_Eb_Gb }, + /* 85 */ { 0, &Ia_testq_Eq_Gq }, + /* 86 */ { 0, &Ia_xchgb_Eb_Gb }, + /* 87 */ { 0, &Ia_xchgq_Eq_Gq }, + /* 88 */ { 0, &Ia_movb_Eb_Gb }, + /* 89 */ { 0, &Ia_movq_Eq_Gq }, + /* 8A */ { 0, &Ia_movb_Gb_Eb }, + /* 8B */ { 0, &Ia_movq_Gq_Eq }, + /* 8C */ { 0, &Ia_movw_Ew_Sw }, + /* 8D */ { 0, &Ia_leaq_Gq_Mq }, + /* 8E */ { 0, &Ia_movw_Sw_Ew }, + /* 8F */ { 0, &Ia_popq_Eq }, + /* 90 */ { 0, &Ia_nop }, + /* 91 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 92 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 93 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 94 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 95 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 96 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 97 */ { 0, &Ia_xchgq_RRX_RAX }, + /* 98 */ { 0, &Ia_cdqe }, + /* 99 */ { 0, &Ia_cqo }, + /* 9A */ { 0, &Ia_Invalid }, + /* 9B */ { 0, &Ia_fwait }, + /* 9C */ { 0, &Ia_pushfq }, + /* 9D */ { 0, &Ia_popfq }, + /* 9E */ { 0, &Ia_sahf }, + /* 9F */ { 0, &Ia_lahf }, + /* A0 */ { 0, &Ia_movb_AL_Ob }, + /* A1 */ { 0, &Ia_movq_RAX_Oq }, + /* A0 */ { 0, &Ia_movb_Ob_AL }, + /* A1 */ { 0, &Ia_movq_Oq_RAX }, + /* A4 */ { 0, &Ia_movsb_Yb_Xb }, + /* A5 */ { 0, &Ia_movsq_Yq_Xq }, + /* A6 */ { 0, &Ia_cmpsb_Yb_Xb }, + /* A7 */ { 0, &Ia_cmpsq_Yq_Xq }, + /* A8 */ { 0, &Ia_testb_AL_Ib }, + /* A9 */ { 0, &Ia_testq_RAX_sId }, + /* AA */ { 0, &Ia_stosb_Yb_AL }, + /* AB */ { 0, &Ia_stosq_Yq_RAX }, + /* AC */ { 0, &Ia_lodsb_AL_Xb }, + /* AD */ { 0, &Ia_lodsq_RAX_Xq }, + /* AE */ { 0, &Ia_scasb_Yb_AL }, + /* AF */ { 0, &Ia_scasq_Yq_RAX }, + /* B0 */ { 0, &Ia_movb_R8_Ib }, + /* B1 */ { 0, &Ia_movb_R8_Ib }, + /* B2 */ { 0, &Ia_movb_R8_Ib }, + /* B3 */ { 0, &Ia_movb_R8_Ib }, + /* B4 */ { 0, &Ia_movb_R8_Ib }, + /* B5 */ { 0, &Ia_movb_R8_Ib }, + /* B6 */ { 0, &Ia_movb_R8_Ib }, + /* B7 */ { 0, &Ia_movb_R8_Ib }, + /* B8 */ { 0, &Ia_movq_RRX_Iq }, + /* B9 */ { 0, &Ia_movq_RRX_Iq }, + /* BA */ { 0, &Ia_movq_RRX_Iq }, + /* BB */ { 0, &Ia_movq_RRX_Iq }, + /* BC */ { 0, &Ia_movq_RRX_Iq }, + /* BD */ { 0, &Ia_movq_RRX_Iq }, + /* BE */ { 0, &Ia_movq_RRX_Iq }, + /* BF */ { 0, &Ia_movq_RRX_Iq }, + /* C0 */ { GRPN(G2Eb) }, + /* C1 */ { GRPN(G2Eq) }, + /* C2 */ { 0, &Ia_ret_Iw }, + /* C3 */ { 0, &Ia_ret }, + /* C4 */ { 0, &Ia_Invalid }, + /* C5 */ { 0, &Ia_Invalid }, + /* C6 */ { 0, &Ia_movb_Eb_Ib }, + /* C7 */ { 0, &Ia_movq_Eq_sId }, + /* C8 */ { 0, &Ia_enter }, + /* C9 */ { 0, &Ia_leave }, + /* CA */ { 0, &Ia_lret_Iw }, + /* CB */ { 0, &Ia_lret }, + /* CC */ { 0, &Ia_int3 }, + /* CD */ { 0, &Ia_int_Ib }, + /* CE */ { 0, &Ia_Invalid }, + /* CF */ { 0, &Ia_iretq }, + /* D0 */ { GRPN(G2EbI1) }, + /* D1 */ { GRPN(G2EqI1) }, + /* D2 */ { GRPN(G2EbCL) }, + /* D3 */ { GRPN(G2EqCL) }, + /* D4 */ { 0, &Ia_Invalid }, + /* D5 */ { 0, &Ia_Invalid }, + /* D6 */ { 0, &Ia_Invalid }, + /* D7 */ { 0, &Ia_xlat }, + /* D8 */ { GRPFP(D8) }, + /* D9 */ { GRPFP(D9) }, + /* DA */ { GRPFP(DA) }, + /* DB */ { GRPFP(DB) }, + /* DC */ { GRPFP(DC) }, + /* DD */ { GRPFP(DD) }, + /* DE */ { GRPFP(DE) }, + /* DF */ { GRPFP(DF) }, + /* E0 */ { 0, &Ia_loopne_Jb }, + /* E1 */ { 0, &Ia_loope_Jb }, + /* E2 */ { 0, &Ia_loop_Jb }, + /* E3 */ { 0, &Ia_jrcxz_Jb }, + /* E4 */ { 0, &Ia_inb_AL_Ib }, + /* E5 */ { 0, &Ia_inl_EAX_Ib }, + /* E6 */ { 0, &Ia_outb_Ib_AL }, + /* E7 */ { 0, &Ia_outl_Ib_EAX }, + /* E8 */ { 0, &Ia_call_Jd }, + /* E9 */ { 0, &Ia_jmp_Jd }, + /* EA */ { 0, &Ia_Invalid }, + /* EB */ { 0, &Ia_jmp_Jb }, + /* EC */ { 0, &Ia_inb_AL_Ib }, + /* ED */ { 0, &Ia_inl_EAX_DX }, + /* EE */ { 0, &Ia_outb_DX_AL }, + /* EF */ { 0, &Ia_outl_DX_EAX }, + /* F0 */ { 0, &Ia_prefix_lock }, // LOCK: + /* F1 */ { 0, &Ia_int1 }, + /* F2 */ { 0, &Ia_prefix_repne }, // REPNE: + /* F3 */ { 0, &Ia_prefix_rep }, // REP: + /* F4 */ { 0, &Ia_hlt }, + /* F5 */ { 0, &Ia_cmc }, + /* F6 */ { GRPN(G3Eb) }, + /* F7 */ { GRPN(G3Eq) }, + /* F8 */ { 0, &Ia_clc }, + /* F9 */ { 0, &Ia_stc }, + /* FA */ { 0, &Ia_cli }, + /* FB */ { 0, &Ia_sti }, + /* FC */ { 0, &Ia_cld }, + /* FD */ { 0, &Ia_std }, + /* FE */ { GRPN(G4) }, + /* FF */ { GRPN(64G5q) }, + + // 256 entries for two byte opcodes + /* 0F 00 */ { GRPN(G6) }, + /* 0F 01 */ { GRPN(G7) }, + /* 0F 02 */ { 0, &Ia_larq_Gq_Ew }, + /* 0F 03 */ { 0, &Ia_lslq_Gq_Ew }, + /* 0F 04 */ { 0, &Ia_Invalid }, + /* 0F 05 */ { 0, &Ia_syscall }, + /* 0F 06 */ { 0, &Ia_clts }, + /* 0F 07 */ { 0, &Ia_sysret }, + /* 0F 08 */ { 0, &Ia_invd }, + /* 0F 09 */ { 0, &Ia_wbinvd }, + /* 0F 0A */ { 0, &Ia_Invalid }, + /* 0F 0B */ { 0, &Ia_ud2a }, + /* 0F 0C */ { 0, &Ia_Invalid }, + /* 0F 0D */ { 0, &Ia_prefetch }, // 3DNow! + /* 0F 0E */ { 0, &Ia_femms }, // 3DNow! + /* 0F 0F */ { GRP3DNOW }, + /* 0F 10 */ { GRPSSE(0f10) }, + /* 0F 11 */ { GRPSSE(0f11) }, + /* 0F 12 */ { GRPSSE(0f12) }, + /* 0F 13 */ { GRPSSE(0f13) }, + /* 0F 14 */ { GRPSSE(0f14) }, + /* 0F 15 */ { GRPSSE(0f15) }, + /* 0F 16 */ { GRPSSE(0f16) }, + /* 0F 17 */ { GRPSSE(0f17) }, + /* 0F 18 */ { GRPN(G16) }, + /* 0F 19 */ { 0, &Ia_Invalid }, + /* 0F 1A */ { 0, &Ia_Invalid }, + /* 0F 1B */ { 0, &Ia_Invalid }, + /* 0F 1C */ { 0, &Ia_Invalid }, + /* 0F 1D */ { 0, &Ia_Invalid }, + /* 0F 1E */ { 0, &Ia_Invalid }, + /* 0F 1F */ { 0, &Ia_Invalid }, + /* 0F 20 */ { 0, &Ia_movq_Rq_Cq }, + /* 0F 21 */ { 0, &Ia_movq_Rq_Dq }, + /* 0F 22 */ { 0, &Ia_movq_Cq_Rq }, + /* 0F 23 */ { 0, &Ia_movq_Dq_Rq }, + /* 0F 24 */ { 0, &Ia_Invalid }, + /* 0F 25 */ { 0, &Ia_Invalid }, + /* 0F 26 */ { 0, &Ia_Invalid }, + /* 0F 27 */ { 0, &Ia_Invalid }, + /* 0F 28 */ { GRPSSE(0f28) }, + /* 0F 29 */ { GRPSSE(0f29) }, + /* 0F 2A */ { GRPSSE(640f2a) }, + /* 0F 2B */ { GRPSSE(0f2b) }, + /* 0F 2C */ { GRPSSE(0f2c) }, + /* 0F 2D */ { GRPSSE(0f2d) }, + /* 0F 2E */ { GRPSSE(0f2e) }, + /* 0F 2F */ { GRPSSE(0f2f) }, + /* 0F 30 */ { 0, &Ia_wrmsr }, + /* 0F 31 */ { 0, &Ia_rdtsc }, + /* 0F 32 */ { 0, &Ia_rdmsr }, + /* 0F 33 */ { 0, &Ia_rdpmc }, + /* 0F 34 */ { 0, &Ia_sysenter }, + /* 0F 35 */ { 0, &Ia_sysexit }, + /* 0F 36 */ { 0, &Ia_Invalid }, + /* 0F 37 */ { 0, &Ia_Invalid }, + /* 0F 38 */ { 0, &Ia_Invalid }, + /* 0F 39 */ { 0, &Ia_Invalid }, + /* 0F 3A */ { 0, &Ia_Invalid }, + /* 0F 3B */ { 0, &Ia_Invalid }, + /* 0F 3C */ { 0, &Ia_Invalid }, + /* 0F 3D */ { 0, &Ia_Invalid }, + /* 0F 3E */ { 0, &Ia_Invalid }, + /* 0F 3F */ { 0, &Ia_Invalid }, + /* 0F 40 */ { 0, &Ia_cmovoq_Gq_Eq }, + /* 0F 41 */ { 0, &Ia_cmovnoq_Gq_Eq }, + /* 0F 42 */ { 0, &Ia_cmovcq_Gq_Eq }, + /* 0F 43 */ { 0, &Ia_cmovncq_Gq_Eq }, + /* 0F 44 */ { 0, &Ia_cmovzq_Gq_Eq }, + /* 0F 45 */ { 0, &Ia_cmovnzq_Gq_Eq }, + /* 0F 46 */ { 0, &Ia_cmovnaq_Gq_Eq }, + /* 0F 47 */ { 0, &Ia_cmovaq_Gq_Eq }, + /* 0F 48 */ { 0, &Ia_cmovsq_Gq_Eq }, + /* 0F 49 */ { 0, &Ia_cmovnsq_Gq_Eq }, + /* 0F 4A */ { 0, &Ia_cmovpq_Gq_Eq }, + /* 0F 4B */ { 0, &Ia_cmovnpq_Gq_Eq }, + /* 0F 4C */ { 0, &Ia_cmovlq_Gq_Eq }, + /* 0F 4D */ { 0, &Ia_cmovnlq_Gq_Eq }, + /* 0F 4E */ { 0, &Ia_cmovngq_Gq_Eq }, + /* 0F 4F */ { 0, &Ia_cmovgq_Gq_Eq }, + /* 0F 50 */ { GRPSSE(0f50) }, + /* 0F 51 */ { GRPSSE(0f51) }, + /* 0F 52 */ { GRPSSE(0f52) }, + /* 0F 53 */ { GRPSSE(0f53) }, + /* 0F 54 */ { GRPSSE(0f54) }, + /* 0F 55 */ { GRPSSE(0f55) }, + /* 0F 56 */ { GRPSSE(0f56) }, + /* 0F 57 */ { GRPSSE(0f57) }, + /* 0F 58 */ { GRPSSE(0f58) }, + /* 0F 59 */ { GRPSSE(0f59) }, + /* 0F 5A */ { GRPSSE(0f5a) }, + /* 0F 5B */ { GRPSSE(0f5b) }, + /* 0F 5C */ { GRPSSE(0f5c) }, + /* 0F 5D */ { GRPSSE(0f5d) }, + /* 0F 5E */ { GRPSSE(0f5e) }, + /* 0F 5F */ { GRPSSE(0f5f) }, + /* 0F 60 */ { GRPSSE(0f60) }, + /* 0F 61 */ { GRPSSE(0f61) }, + /* 0F 62 */ { GRPSSE(0f62) }, + /* 0F 63 */ { GRPSSE(0f63) }, + /* 0F 64 */ { GRPSSE(0f64) }, + /* 0F 65 */ { GRPSSE(0f65) }, + /* 0F 66 */ { GRPSSE(0f66) }, + /* 0F 67 */ { GRPSSE(0f67) }, + /* 0F 68 */ { GRPSSE(0f68) }, + /* 0F 69 */ { GRPSSE(0f69) }, + /* 0F 6A */ { GRPSSE(0f6a) }, + /* 0F 6B */ { GRPSSE(0f6b) }, + /* 0F 6C */ { GRPSSE(0f6c) }, + /* 0F 6D */ { GRPSSE(0f6d) }, + /* 0F 6E */ { GRPSSE(0f6e) }, + /* 0F 6F */ { GRPSSE(0f6f) }, + /* 0F 70 */ { GRPSSE(0f70) }, + /* 0F 71 */ { GRPN(G12) }, + /* 0F 72 */ { GRPN(G13) }, + /* 0F 73 */ { GRPN(G14) }, + /* 0F 74 */ { GRPSSE(0f74) }, + /* 0F 75 */ { GRPSSE(0f75) }, + /* 0F 76 */ { GRPSSE(0f76) }, + /* 0F 77 */ { 0, &Ia_emms }, + /* 0F 78 */ { 0, &Ia_Invalid }, + /* 0F 79 */ { 0, &Ia_Invalid }, + /* 0F 7A */ { 0, &Ia_Invalid }, + /* 0F 7B */ { 0, &Ia_Invalid }, + /* 0F 7C */ { GRPSSE(0f7c) }, + /* 0F 7D */ { GRPSSE(0f7d) }, + /* 0F 7E */ { GRPSSE(0f7e) }, + /* 0F 7F */ { GRPSSE(0f7f) }, + /* 0F 80 */ { 0, &Ia_jo_Jd }, + /* 0F 81 */ { 0, &Ia_jno_Jd }, + /* 0F 82 */ { 0, &Ia_jb_Jd }, + /* 0F 83 */ { 0, &Ia_jnb_Jd }, + /* 0F 84 */ { 0, &Ia_jz_Jd }, + /* 0F 85 */ { 0, &Ia_jnz_Jd }, + /* 0F 86 */ { 0, &Ia_jbe_Jd }, + /* 0F 87 */ { 0, &Ia_jnbe_Jd }, + /* 0F 88 */ { 0, &Ia_js_Jd }, + /* 0F 89 */ { 0, &Ia_jns_Jd }, + /* 0F 8A */ { 0, &Ia_jp_Jd }, + /* 0F 8B */ { 0, &Ia_jnp_Jd }, + /* 0F 8C */ { 0, &Ia_jl_Jd }, + /* 0F 8D */ { 0, &Ia_jnl_Jd }, + /* 0F 8E */ { 0, &Ia_jle_Jd }, + /* 0F 8F */ { 0, &Ia_jnle_Jd }, + /* 0F 90 */ { 0, &Ia_seto_Eb }, + /* 0F 91 */ { 0, &Ia_setno_Eb }, + /* 0F 92 */ { 0, &Ia_setb_Eb }, + /* 0F 93 */ { 0, &Ia_setnb_Eb }, + /* 0F 94 */ { 0, &Ia_setz_Eb }, + /* 0F 95 */ { 0, &Ia_setnz_Eb }, + /* 0F 96 */ { 0, &Ia_setbe_Eb }, + /* 0F 97 */ { 0, &Ia_setnbe_Eb }, + /* 0F 98 */ { 0, &Ia_sets_Eb }, + /* 0F 99 */ { 0, &Ia_setns_Eb }, + /* 0F 9A */ { 0, &Ia_setp_Eb }, + /* 0F 9B */ { 0, &Ia_setnp_Eb }, + /* 0F 9C */ { 0, &Ia_setl_Eb }, + /* 0F 9D */ { 0, &Ia_setnl_Eb }, + /* 0F 9E */ { 0, &Ia_setle_Eb }, + /* 0F 9F */ { 0, &Ia_setnle_Eb }, + /* 0F A0 */ { 0, &Ia_pushq_FS }, + /* 0F A1 */ { 0, &Ia_popq_FS }, + /* 0F A2 */ { 0, &Ia_cpuid }, + /* 0F A3 */ { 0, &Ia_btq_Eq_Gq }, + /* 0F A4 */ { 0, &Ia_shldq_Eq_Gq_Ib }, + /* 0F A5 */ { 0, &Ia_shldq_Eq_Gq_CL }, + /* 0F A6 */ { 0, &Ia_Invalid }, + /* 0F A7 */ { 0, &Ia_Invalid }, + /* 0F A8 */ { 0, &Ia_pushq_GS }, + /* 0F A9 */ { 0, &Ia_popq_GS }, + /* 0F AA */ { 0, &Ia_rsm }, + /* 0F AB */ { 0, &Ia_btsq_Eq_Gq }, + /* 0F AC */ { 0, &Ia_shrdq_Eq_Gq_Ib }, + /* 0F AD */ { 0, &Ia_shrdq_Eq_Gq_CL }, + /* 0F AE */ { GRPN(G15) }, + /* 0F AF */ { 0, &Ia_imulq_Gq_Eq }, + /* 0F B0 */ { 0, &Ia_cmpxchgb_Eb_Gb }, + /* 0F B1 */ { 0, &Ia_cmpxchgq_Eq_Gq }, + /* 0F B2 */ { 0, &Ia_lssq_Gq_Mp }, + /* 0F B3 */ { 0, &Ia_btrq_Eq_Gq }, + /* 0F B4 */ { 0, &Ia_lfsq_Gq_Mp }, + /* 0F B5 */ { 0, &Ia_lgsq_Gq_Mp }, + /* 0F B6 */ { 0, &Ia_movzbq_Gq_Eb }, + /* 0F B7 */ { 0, &Ia_movzwq_Gq_Ew }, + /* 0F B8 */ { 0, &Ia_Invalid }, + /* 0F B9 */ { 0, &Ia_ud2b }, + /* 0F BA */ { GRPN(G8EqIb) }, + /* 0F BB */ { 0, &Ia_btcq_Eq_Gq }, + /* 0F BC */ { 0, &Ia_bsfq_Gq_Eq }, + /* 0F BD */ { 0, &Ia_bsrq_Gq_Eq }, + /* 0F BE */ { 0, &Ia_movsbq_Gq_Eb }, + /* 0F BF */ { 0, &Ia_movswq_Gq_Ew }, + /* 0F C0 */ { 0, &Ia_xaddb_Eb_Gb }, + /* 0F C0 */ { 0, &Ia_xaddq_Eq_Gq }, + /* 0F C2 */ { GRPSSE(0fc2) }, + /* 0F C3 */ { GRPSSE(640fc3) }, + /* 0F C4 */ { GRPSSE(0fc4) }, + /* 0F C5 */ { GRPSSE(0fc5) }, + /* 0F C6 */ { GRPSSE(0fc6) }, + /* 0F C7 */ { GRPN(G9q) }, + /* 0F C8 */ { 0, &Ia_bswapq_RRX }, + /* 0F C9 */ { 0, &Ia_bswapq_RRX }, + /* 0F CA */ { 0, &Ia_bswapq_RRX }, + /* 0F CB */ { 0, &Ia_bswapq_RRX }, + /* 0F CC */ { 0, &Ia_bswapq_RRX }, + /* 0F CD */ { 0, &Ia_bswapq_RRX }, + /* 0F CE */ { 0, &Ia_bswapq_RRX }, + /* 0F CF */ { 0, &Ia_bswapq_RRX }, + /* 0F D0 */ { GRPSSE(0fd0) }, + /* 0F D1 */ { GRPSSE(0fd1) }, + /* 0F D2 */ { GRPSSE(0fd2) }, + /* 0F D3 */ { GRPSSE(0fd3) }, + /* 0F D4 */ { GRPSSE(0fd4) }, + /* 0F D5 */ { GRPSSE(0fd5) }, + /* 0F D6 */ { GRPSSE(0fd6) }, + /* 0F D7 */ { GRPSSE(0fd7) }, + /* 0F D8 */ { GRPSSE(0fd8) }, + /* 0F D9 */ { GRPSSE(0fd9) }, + /* 0F DA */ { GRPSSE(0fda) }, + /* 0F DB */ { GRPSSE(0fdb) }, + /* 0F DC */ { GRPSSE(0fdc) }, + /* 0F DD */ { GRPSSE(0fdd) }, + /* 0F DE */ { GRPSSE(0fde) }, + /* 0F DF */ { GRPSSE(0fdf) }, + /* 0F E0 */ { GRPSSE(0fe0) }, + /* 0F E1 */ { GRPSSE(0fe1) }, + /* 0F E2 */ { GRPSSE(0fe2) }, + /* 0F E3 */ { GRPSSE(0fe3) }, + /* 0F E4 */ { GRPSSE(0fe4) }, + /* 0F E5 */ { GRPSSE(0fe5) }, + /* 0F E6 */ { GRPSSE(0fe6) }, + /* 0F E7 */ { GRPSSE(0fe7) }, + /* 0F E8 */ { GRPSSE(0fe8) }, + /* 0F E9 */ { GRPSSE(0fe9) }, + /* 0F EA */ { GRPSSE(0fea) }, + /* 0F EB */ { GRPSSE(0feb) }, + /* 0F EC */ { GRPSSE(0fec) }, + /* 0F ED */ { GRPSSE(0fed) }, + /* 0F EE */ { GRPSSE(0fee) }, + /* 0F EF */ { GRPSSE(0fef) }, + /* 0F F0 */ { GRPSSE(0ff0) }, + /* 0F F1 */ { GRPSSE(0ff1) }, + /* 0F F2 */ { GRPSSE(0ff2) }, + /* 0F F3 */ { GRPSSE(0ff3) }, + /* 0F F4 */ { GRPSSE(0ff4) }, + /* 0F F5 */ { GRPSSE(0ff5) }, + /* 0F F6 */ { GRPSSE(0ff6) }, + /* 0F F7 */ { GRPSSE(0ff7) }, + /* 0F F8 */ { GRPSSE(0ff8) }, + /* 0F F9 */ { GRPSSE(0ff9) }, + /* 0F FA */ { GRPSSE(0ffa) }, + /* 0F FB */ { GRPSSE(0ffb) }, + /* 0F FC */ { GRPSSE(0ffc) }, + /* 0F FD */ { GRPSSE(0ffd) }, + /* 0F FE */ { GRPSSE(0ffe) }, + /* 0F FF */ { 0, &Ia_Invalid } +}; diff --git a/bochs/disasm/disasm.h b/bochs/disasm/disasm.h index 52c0a965c..69a74bab2 100644 --- a/bochs/disasm/disasm.h +++ b/bochs/disasm/disasm.h @@ -10,9 +10,9 @@ } #define BX_DECODE_SIB(sib_byte, scale, index, base) { \ - scale = sib >> 6; \ - index = (sib >> 3) & 0x07; \ - base = sib & 0x07; \ + scale = sib_byte >> 6; \ + index = (sib_byte >> 3) & 0x07; \ + base = sib_byte & 0x07; \ } // will be used in future @@ -41,40 +41,7 @@ #define IF_SSE2 0x00000000 /* SSE2 instruction */ #define IF_PNI 0x00000000 /* Prescott new instruction */ -enum { - AL_REG, - CL_REG, - DL_REG, - BL_REG, - AH_REG, - CH_REG, - DH_REG, - BH_REG -}; - -enum { - AX_REG, - CX_REG, - DX_REG, - BX_REG, - SP_REG, - BP_REG, - SI_REG, - DI_REG -}; - -enum { - eAX_REG, - eCX_REG, - eDX_REG, - eBX_REG, - eSP_REG, - eBP_REG, - eSI_REG, - eDI_REG -}; - -#if BX_DISASM_SUPPORT_X86_64 +/* general purpose bit register */ enum { rAX_REG, rCX_REG, @@ -85,33 +52,38 @@ enum { rSI_REG, rDI_REG }; -#endif +/* segment register */ enum { ES_REG, CS_REG, SS_REG, DS_REG, FS_REG, - GS_REG + GS_REG, + INVALID_SEG1, + INVALID_SEG2 }; class disassembler; +class x86_insn; -typedef void (disassembler::*BxDisasmPtr_t) (unsigned attr); -typedef void (disassembler::*BxDisasmResolveModrmPtr_t) (unsigned attr); +typedef void (disassembler::*BxDisasmPtr_t)(const x86_insn *insn); +typedef void (disassembler::*BxDisasmResolveModrmPtr_t)(const x86_insn *insn, unsigned attr); struct BxDisasmOpcodeInfo_t { - const char *Opcode; - unsigned Attr; + const char *IntelOpcode; + const char *AttOpcode; BxDisasmPtr_t Operand1; - unsigned Op1Attr; BxDisasmPtr_t Operand2; - unsigned Op2Attr; BxDisasmPtr_t Operand3; - unsigned Op3Attr; - struct BxDisasmOpcodeInfo_t *AnotherArray; +}; + +struct BxDisasmOpcodeTable_t +{ + Bit32u Attr; + const void *OpcodeInfo; }; // datasize attributes @@ -119,23 +91,73 @@ struct BxDisasmOpcodeInfo_t #define B_SIZE 0x0100 #define W_SIZE 0x0200 #define D_SIZE 0x0300 -#define V_SIZE 0x0400 -#define Q_SIZE 0x0500 -#define Z_SIZE 0x0600 +#define Q_SIZE 0x0400 +#define Z_SIZE 0x0500 +#define V_SIZE 0x0600 #define O_SIZE 0x0700 #define T_SIZE 0x0800 #define P_SIZE 0x0900 -#define S_SIZE 0x0A00 -// branch hint attribute +// branch hint attribute #define BRANCH_HINT 0x1000 +struct x86_insn +{ +public: + x86_insn(bx_bool is32, bx_bool is64); + +public: + bx_bool is_32, is_64; + bx_bool as_32, as_64; + bx_bool os_32, os_64; + + Bit8u extend8b; + Bit8u rex_r, rex_x, rex_b; + Bit8u seg_override; + unsigned b1; + + Bit8u modrm, mod, nnn, rm; + Bit8u sib, scale, index, base; + union { + Bit16u displ16; + Bit32u displ32; + } displacement; +}; + +BX_CPP_INLINE x86_insn::x86_insn(bx_bool is32, bx_bool is64) +{ + is_32 = is32; + is_64 = is64; + + if (is_64) { + os_64 = 0; + as_64 = 1; + os_32 = 1; + as_32 = 1; + } + else { + os_64 = 0; + as_64 = 0; + os_32 = is_32; + as_32 = is_32; + } + + extend8b = 0; + rex_r = rex_b = rex_x = 0; + seg_override = 0; + b1 = 0; + + modrm = mod = nnn = rm = 0; + sib = scale = index = base = 0; + displacement.displ32 = 0; +} + class disassembler { public: disassembler() { set_syntax_intel(); } - unsigned disasm16(bx_address base, bx_address ip, Bit8u *instr, char *disbuf); unsigned disasm32(bx_address base, bx_address ip, Bit8u *instr, char *disbuf); + unsigned disasm64(bx_address base, bx_address ip, Bit8u *instr, char *disbuf); unsigned disasm(bx_bool is_32, bx_bool is_64, bx_address base, bx_address ip, Bit8u *instr, char *disbuf); @@ -148,10 +170,8 @@ private: const char **general_16bit_regname; const char **general_8bit_regname; const char **general_32bit_regname; -#if BX_DISASM_SUPPORT_X86_64 const char **general_8bit_regname_rex; const char **general_64bit_regname; -#endif const char **segment_name; const char **index16; @@ -164,29 +184,10 @@ private: private: - bx_bool os_32; - bx_bool as_32; -#if BX_DISASM_SUPPORT_X86_64 - bx_bool os_64; - bx_bool as_64; -#endif - - Bit8u modrm, mod, nnn, rm; - Bit8u sib, scale, sib_index, sib_base; - - union { - Bit16u displ16; - Bit32u displ32; - } displacement; - bx_address db_eip, db_base; - unsigned n_prefixes; - Bit8u *instruction; // for fetching of next byte of instruction - const char *seg_override; - char *disbufptr; BxDisasmResolveModrmPtr_t resolve_modrm; @@ -218,27 +219,31 @@ private: return(ret32); }; -#if BX_DISASM_SUPPORT_X86_64 BX_CPP_INLINE Bit64u fetch_qword() { Bit64u d0 = fetch_dword(); Bit64u d1 = fetch_dword(); Bit64u ret64 = (d1<<32) | d0; return(ret64); }; -#endif void dis_putc(char symbol); void dis_sprintf(char *fmt, ...); - void decode_modrm(); + void decode_modrm(x86_insn *insn); - void resolve16_mod0 (unsigned mode); - void resolve16_mod1or2 (unsigned mode); + void resolve16_mod0 (const x86_insn *insn, unsigned mode); + void resolve16_mod1or2(const x86_insn *insn, unsigned mode); - void resolve32_mod0 (unsigned mode); - void resolve32_mod1or2 (unsigned mode); + void resolve32_mod0 (const x86_insn *insn, unsigned mode); + void resolve32_mod1or2(const x86_insn *insn, unsigned mode); - void resolve32_mod0_rm4 (unsigned mode); - void resolve32_mod1or2_rm4 (unsigned mode); + void resolve32_mod0_rm4 (const x86_insn *insn, unsigned mode); + void resolve32_mod1or2_rm4(const x86_insn *insn, unsigned mode); + + void resolve64_mod0 (const x86_insn *insn, unsigned mode); + void resolve64_mod1or2(const x86_insn *insn, unsigned mode); + + void resolve64_mod0_rm4 (const x86_insn *insn, unsigned mode); + void resolve64_mod1or2_rm4(const x86_insn *insn, unsigned mode); void initialize_modrm_segregs(); @@ -246,11 +251,11 @@ private: void print_memory_access16(int datasize, const char *seg, const char *index, Bit16u disp); - void print_memory_access32(int datasize, + void print_memory_access (int datasize, const char *seg, const char *base, const char *index, int scale, Bit32u disp); - void print_disassembly_intel(const BxDisasmOpcodeInfo_t *entry); - void print_disassembly_att (const BxDisasmOpcodeInfo_t *entry); + void print_disassembly_intel(const x86_insn *insn, const BxDisasmOpcodeInfo_t *entry); + void print_disassembly_att (const x86_insn *insn, const BxDisasmOpcodeInfo_t *entry); public: @@ -317,78 +322,158 @@ public: * ss - Scalar element of a 128-bit packed single-precision floating data. * sd - Scalar element of a 128-bit packed double-precision floating data. * v - Word, doubleword or quadword, depending on operand-size attribute. - * w - Word, regardless of operand-size attribute. - * z - A word if the effective operand size is 16 bits, or a doubleword - * if the effective operand size is 32 or 64 bits. + * w - Word, regardless of operand-size attr. */ - // fpu - void ST0 (unsigned attribute); - void STj (unsigned attribute); + // far call/jmp + void Apw(const x86_insn *insn); + void Apd(const x86_insn *insn); - // general/segment register - void Rw (unsigned attribute); - void Rd (unsigned attribute); - void Sw (unsigned attribute); + // 8-bit general purpose registers + void AL(const x86_insn *insn); + void CL(const x86_insn *insn); - // control/debug register - void Cd (unsigned attribute); - void Dd (unsigned attribute); - void Td (unsigned attribute); + // 16-bit general purpose registers + void AX(const x86_insn *insn); + void DX(const x86_insn *insn); - // segment register - void OP_SEG (unsigned attribute); + // 32-bit general purpose registers + void EAX(const x86_insn *insn); - // memory only - void OP_MEM (unsigned attribute); + // 64-bit general purpose registers + void RAX(const x86_insn *insn); - // general purpose register - void REG16 (unsigned attribute); - void REG8 (unsigned attribute); - void REG32 (unsigned attribute); + // segment registers + void CS(const x86_insn *insn); + void DS(const x86_insn *insn); + void ES(const x86_insn *insn); + void SS(const x86_insn *insn); + void FS(const x86_insn *insn); + void GS(const x86_insn *insn); - // string instructions - void OP_X (unsigned attribute); - void OP_Y (unsigned attribute); + // segment registers + void Sw(const x86_insn *insn); - // mmx/xmm - void OP_P (unsigned attribute); - void OP_Q (unsigned attribute); - void OP_W (unsigned attribute); - void OP_V (unsigned attribute); + // test registers + void Td(const x86_insn *insn); - // mov - void OP_O (unsigned attribute); + // control register + void Cd(const x86_insn *insn); + void Cq(const x86_insn *insn); - // immediate - void sIb (unsigned attribute); - void I1 (unsigned attribute); - void Ib (unsigned attribute); - void Iw (unsigned attribute); - void Id (unsigned attribute); - void Iv (unsigned attribute); -#if BX_DISASM_SUPPORT_X86_64 - void Iz (unsigned attribute); - void Iq (unsigned attribute); -#endif + // debug register + void Dd(const x86_insn *insn); + void Dq(const x86_insn *insn); - // general purpose register or memory - void Eb (unsigned attribute); - void Ew (unsigned attribute); - void Ed (unsigned attribute); - void Ev (unsigned attribute); + // 8-bit general purpose register + void R8(const x86_insn *insn); - // general purpose register - void Gb (unsigned attribute); - void Gv (unsigned attribute); - void Gd (unsigned attribute); + // 16-bit general purpose register + void RX(const x86_insn *insn); - // call/jump - void Jb (unsigned attribute); - void Jv (unsigned attribute); + // 32-bit general purpose register + void ERX(const x86_insn *insn); - // call/jmp far - void Ap (unsigned attribute); + // 64-bit general purpose register + void RRX(const x86_insn *insn); + + // general purpose register or memory operand + void Eb(const x86_insn *insn); + void Ew(const x86_insn *insn); + void Ed(const x86_insn *insn); + void Eq(const x86_insn *insn); + + // general purpose register + void Gb(const x86_insn *insn); + void Gw(const x86_insn *insn); + void Gd(const x86_insn *insn); + void Gq(const x86_insn *insn); + + // immediate + void I1(const x86_insn *insn); + void Ib(const x86_insn *insn); + void Iw(const x86_insn *insn); + void Id(const x86_insn *insn); + void Iq(const x86_insn *insn); + + // sign extended immediate + void sIbw(const x86_insn *insn); + void sIbd(const x86_insn *insn); + void sIbq(const x86_insn *insn); + void sIdq(const x86_insn *insn); + + // floating point + void ST0(const x86_insn *insn); + void STi(const x86_insn *insn); + + // general purpose register + void Rw(const x86_insn *insn); + void Rd(const x86_insn *insn); + void Rq(const x86_insn *insn); + + // mmx register + void Pq(const x86_insn *insn); + + // mmx register or memory operand + void Qd(const x86_insn *insn); + void Qq(const x86_insn *insn); + void Vq(const x86_insn *insn); + + // xmm register + void Vdq(const x86_insn *insn); + void Vss(const x86_insn *insn); + void Vsd(const x86_insn *insn); + void Vps(const x86_insn *insn); + void Vpd(const x86_insn *insn); + + // xmm register or memory operand + void Wq(const x86_insn *insn); + void Wdq(const x86_insn *insn); + void Wss(const x86_insn *insn); + void Wsd(const x86_insn *insn); + void Wps(const x86_insn *insn); + void Wpd(const x86_insn *insn); + + // direct memory access + void OP_O(const x86_insn *insn, unsigned size); + void Ob(const x86_insn *insn); + void Ow(const x86_insn *insn); + void Od(const x86_insn *insn); + void Oq(const x86_insn *insn); + + // memory operand + void OP_M(const x86_insn *insn, unsigned size); + void Ma(const x86_insn *insn); + void Mp(const x86_insn *insn); + void Ms(const x86_insn *insn); + void Mx(const x86_insn *insn); + void Mb(const x86_insn *insn); + void Mw(const x86_insn *insn); + void Md(const x86_insn *insn); + void Mq(const x86_insn *insn); + void Mt(const x86_insn *insn); + void Mdq(const x86_insn *insn); + void Mps(const x86_insn *insn); + void Mpd(const x86_insn *insn); + + // string instructions + void OP_X(const x86_insn *insn, unsigned size); + void Xb(const x86_insn *insn); + void Xw(const x86_insn *insn); + void Xd(const x86_insn *insn); + void Xq(const x86_insn *insn); + + // string instructions + void OP_Y(const x86_insn *insn, unsigned size); + void Yb(const x86_insn *insn); + void Yw(const x86_insn *insn); + void Yd(const x86_insn *insn); + void Yq(const x86_insn *insn); + + // jump offset + void Jb(const x86_insn *insn); + void Jw(const x86_insn *insn); + void Jd(const x86_insn *insn); }; #endif diff --git a/bochs/disasm/opcodes.inc b/bochs/disasm/opcodes.inc new file mode 100755 index 000000000..9bec40e9d --- /dev/null +++ b/bochs/disasm/opcodes.inc @@ -0,0 +1,1189 @@ +Ia_aaa = { "aaa", "aaa", XX, XX, XX }, +Ia_aad = { "aad", "aad", Ib, XX, XX }, +Ia_aam = { "aam", "aam", Ib, XX, XX }, +Ia_aas = { "aas", "aas", XX, XX, XX }, +Ia_adcb_AL_Ib = { "adc", "adcb", AL, Ib, XX }, +Ia_adcb_Eb_Gb = { "adc", "adcb", Eb, Gb, XX }, +Ia_adcb_Eb_Ib = { "adc", "adcb", Eb, Ib, XX }, +Ia_adcb_Gb_Eb = { "adc", "adcb", Gb, Eb, XX }, +Ia_adcl_EAX_Id = { "adc", "adcl", EAX, Id, XX }, +Ia_adcl_Ed_Gd = { "adc", "adcl", Ed, Gd, XX }, +Ia_adcl_Ed_Id = { "adc", "adcl", Ed, Id, XX }, +Ia_adcl_Ed_sIb = { "adc", "adcl", Ed, sIbd, XX }, +Ia_adcl_Gd_Ed = { "adc", "adcl", Gd, Ed, XX }, +Ia_adcq_Eq_Gq = { "adc", "adcq", Eq, Gq, XX }, +Ia_adcq_Eq_sIb = { "adc", "adcq", Eq, sIbq, XX }, +Ia_adcq_Eq_sId = { "adc", "adcq", Eq, Iq, XX }, +Ia_adcq_Gq_Eq = { "adc", "adcq", Gq, Eq, XX }, +Ia_adcq_RAX_sId = { "adc", "adcq", RAX, sIdq, XX }, +Ia_adcw_AX_Iw = { "adc", "adcw", AX, Iw, XX }, +Ia_adcw_Ew_Gw = { "adc", "adcw", Ew, Gw, XX }, +Ia_adcw_Ew_Iw = { "adc", "adcw", Ew, Iw, XX }, +Ia_adcw_Ew_sIb = { "adc", "adcw", Ew, sIbw, XX }, +Ia_adcw_Gw_Ew = { "adc", "adcw", Gw, Ew, XX }, +Ia_addb_AL_Ib = { "add", "addb", AL, Ib, XX }, +Ia_addb_Eb_Gb = { "add", "addb", Eb, Gb, XX }, +Ia_addb_Eb_Ib = { "add", "addb", Eb, Ib, XX }, +Ia_addb_Gb_Eb = { "add", "addb", Gb, Eb, XX }, +Ia_addl_EAX_Id = { "add", "addl", EAX, Id, XX }, +Ia_addl_Ed_Gd = { "add", "addl", Ed, Gd, XX }, +Ia_addl_Ed_Id = { "add", "addl", Ed, Id, XX }, +Ia_addl_Ed_sIb = { "add", "addl", Ed, sIbd, XX }, +Ia_addl_Gd_Ed = { "add", "addl", Gd, Ed, XX }, +Ia_addpd_Vpd_Wpd = { "addpd", "addpd", Vpd, Wpd, XX }, +Ia_addps_Vps_Wps = { "addps", "addps", Vps, Wps, XX }, +Ia_addq_Eq_Gq = { "add", "addq", Eq, Gq, XX }, +Ia_addq_Eq_sIb = { "add", "addq", Eq, sIbq, XX }, +Ia_addq_Eq_sId = { "add", "addq", Eq, sIdq, XX }, +Ia_addq_Gq_Eq = { "add", "addq", Gq, Eq, XX }, +Ia_addq_RAX_sId = { "add", "addq", RAX, sIdq, XX }, +Ia_addsd_Vsd_Wsd = { "addsd", "addsd", Vsd, Wsd, XX }, +Ia_addss_Vss_Wss = { "addss", "addss", Vss, Wss, XX }, +Ia_addsubpd_Vpd_Wpd = { "addsubpd", "addsubpd", Vpd, Wpd, XX }, +Ia_addsubps_Vps_Wps = { "addsubps", "addsubps", Vps, Wps, XX }, +Ia_addw_AX_Iw = { "add", "addw", AX, Iw, XX }, +Ia_addw_Ew_Gw = { "add", "addw", Ew, Gw, XX }, +Ia_addw_Ew_Iw = { "add", "addw", Ew, Iw, XX }, +Ia_addw_Ew_sIb = { "add", "addw", Ew, sIbw, XX }, +Ia_addw_Gw_Ew = { "add", "addw", Gw, Ew, XX }, +Ia_andb_AL_Ib = { "and", "andb", AL, Ib, XX }, +Ia_andb_Eb_Gb = { "and", "andb", Eb, Gb, XX }, +Ia_andb_Eb_Ib = { "and", "andb", Eb, Ib, XX }, +Ia_andb_Gb_Eb = { "and", "andb", Gb, Eb, XX }, +Ia_andl_EAX_Id = { "and", "andl", EAX, Id, XX }, +Ia_andl_Ed_Gd = { "and", "andl", Ed, Gd, XX }, +Ia_andl_Ed_Id = { "and", "andl", Ed, Id, XX }, +Ia_andl_Ed_sIb = { "and", "andl", Ed, sIbd, XX }, +Ia_andl_Gd_Ed = { "and", "andl", Gd, Ed, XX }, +Ia_andnpd_Vpd_Wpd = { "andnpd", "andnpd", Vpd, Wpd, XX }, +Ia_andnps_Vps_Wps = { "andnps", "andnps", Vps, Wps, XX }, +Ia_andpd_Vpd_Wpd = { "andpd", "andpd", Vpd, Wpd, XX }, +Ia_andps_Vps_Wps = { "andps", "andps", Vps, Wps, XX }, +Ia_andq_Eq_Gq = { "and", "andq", Eq, Gq, XX }, +Ia_andq_Eq_sIb = { "and", "andq", Eq, sIbq, XX }, +Ia_andq_Eq_sId = { "and", "andq", Eq, sIdq, XX }, +Ia_andq_Gq_Eq = { "and", "andq", Gq, Eq, XX }, +Ia_andq_RAX_sId = { "and", "andq", RAX, sIdq, XX }, +Ia_andw_AX_Iw = { "and", "andw", AX, Iw, XX }, +Ia_andw_Ew_Gw = { "and", "andw", Ew, Gw, XX }, +Ia_andw_Ew_Iw = { "and", "andw", Ew, Iw, XX }, +Ia_andw_Ew_sIb = { "and", "andw", Ew, sIbw, XX }, +Ia_andw_Gw_Ew = { "and", "andw", Gw, Ew, XX }, +Ia_arpl_Ew_Rw = { "arpl", "arpl", Ew, Rw, XX }, +Ia_boundl_Gd_Ma = { "bound", "boundl", Gd, Ma, XX }, +Ia_boundw_Gw_Ma = { "bound", "boundw", Gw, Ma, XX }, +Ia_bsfl_Gd_Ed = { "bsf", "bsfl", Gd, Ed, XX }, +Ia_bsfq_Gq_Eq = { "bsf", "bsfq", Gq, Eq, XX }, +Ia_bsfw_Gw_Ew = { "bsf", "bsfw", Gw, Ew, XX }, +Ia_bsrl_Gd_Ed = { "bsr", "bsrl", Gd, Ed, XX }, +Ia_bsrq_Gq_Eq = { "bsr", "bsrq", Gq, Eq, XX }, +Ia_bsrw_Gw_Ew = { "bsr", "bsrw", Gw, Ew, XX }, +Ia_bswapl_ERX = { "bswap", "bswapl", ERX, XX, XX }, +Ia_bswapq_RRX = { "bswap", "bswapq", RRX, XX, XX }, +Ia_bswapw_RX = { "bswap", "bswapw", RX, XX, XX }, +Ia_btcl_Ed_Gd = { "btc", "btcl", Ed, Gd, XX }, +Ia_btcl_Ed_Ib = { "btc", "btcl", Ed, Ib, XX }, +Ia_btcq_Eq_Gq = { "btc", "btcq", Eq, Gq, XX }, +Ia_btcq_Eq_Ib = { "btc", "btcq", Eq, Ib, XX }, +Ia_btcw_Ew_Gw = { "btc", "btcw", Ew, Gw, XX }, +Ia_btcw_Ew_Ib = { "btc", "btcw", Ew, Ib, XX }, +Ia_btl_Ed_Gd = { "bt", "btl", Ed, Gd, XX }, +Ia_btl_Ed_Ib = { "bt", "btl", Ed, Ib, XX }, +Ia_btq_Eq_Gq = { "bt", "btq", Eq, Gq, XX }, +Ia_btq_Eq_Ib = { "bt", "btq", Eq, Ib, XX }, +Ia_btrl_Ed_Gd = { "btr", "btrl", Ed, Gd, XX }, +Ia_btrl_Ed_Ib = { "btr", "btrl", Ed, Ib, XX }, +Ia_btrq_Eq_Gq = { "btr", "btrq", Eq, Gq, XX }, +Ia_btrq_Eq_Ib = { "btr", "btrq", Eq, Ib, XX }, +Ia_btrw_Ew_Gw = { "btr", "btrw", Ew, Gw, XX }, +Ia_btrw_Ew_Ib = { "btr", "btrw", Ew, Ib, XX }, +Ia_btsl_Ed_Gd = { "bts", "btsl", Ed, Gd, XX }, +Ia_btsl_Ed_Ib = { "bts", "btsl", Ed, Ib, XX }, +Ia_btsq_Eq_Gq = { "bts", "btsq", Eq, Gq, XX }, +Ia_btsq_Eq_Ib = { "bts", "btsq", Eq, Ib, XX }, +Ia_btsw_Ew_Gw = { "bts", "btsw", Ew, Gw, XX }, +Ia_btsw_Ew_Ib = { "bts", "btsw", Ew, Ib, XX }, +Ia_btw_Ew_Gw = { "bt", "btw", Ew, Gw, XX }, +Ia_btw_Ew_Ib = { "bt", "btw", Ew, Ib, XX }, +Ia_call_Ed = { "call", "call", Ed, XX, XX }, +Ia_call_Eq = { "call", "call", Eq, XX, XX }, +Ia_call_Ew = { "call", "call", Ew, XX, XX }, +Ia_call_Jd = { "call", "call", Jd, XX, XX }, +Ia_call_Jw = { "call", "call", Jw, XX, XX }, +Ia_cbw = { "cbw", "cbtw", XX, XX, XX }, +Ia_cdq = { "cdq", "cltd", XX, XX, XX }, +Ia_cdqe = { "cdqe", "cltq", XX, XX, XX }, +Ia_cflush = { "cflush", "cflush", Mb, XX, XX }, +Ia_clc = { "clc", "clc", XX, XX, XX }, +Ia_cld = { "cld", "cld", XX, XX, XX }, +Ia_cli = { "cli", "cli", XX, XX, XX }, +Ia_clts = { "clts", "clts", XX, XX, XX }, +Ia_cmc = { "cmc", "cmc", XX, XX, XX }, +Ia_cmoval_Gd_Ed = { "cmova", "cmoval", Gd, Ed, XX }, +Ia_cmovaq_Gq_Eq = { "cmova", "cmovaq", Gq, Eq, XX }, +Ia_cmovaw_Gw_Ew = { "cmova", "cmovaw", Gw, Ew, XX }, +Ia_cmovcl_Gd_Ed = { "cmovc", "cmovcl", Gd, Ed, XX }, +Ia_cmovcq_Gq_Eq = { "cmovc", "cmovcq", Gq, Eq, XX }, +Ia_cmovcw_Gw_Ew = { "cmovc", "cmovcw", Gw, Ew, XX }, +Ia_cmovgl_Gd_Ed = { "cmovg", "cmovgl", Gd, Ed, XX }, +Ia_cmovgq_Gq_Eq = { "cmovg", "cmovgq", Gq, Eq, XX }, +Ia_cmovgw_Gw_Ew = { "cmovg", "cmovgw", Gw, Ew, XX }, +Ia_cmovll_Gd_Ed = { "cmovl", "cmovll", Gd, Ed, XX }, +Ia_cmovlq_Gq_Eq = { "cmovl", "cmovlq", Gq, Eq, XX }, +Ia_cmovlw_Gw_Ew = { "cmovl", "cmovlw", Gw, Ew, XX }, +Ia_cmovnal_Gd_Ed = { "cmovna", "cmovnal", Gd, Ed, XX }, +Ia_cmovnaq_Gq_Eq = { "cmovna", "cmovnaq", Gq, Eq, XX }, +Ia_cmovnaw_Gw_Ew = { "cmovna", "cmovnaw", Gw, Ew, XX }, +Ia_cmovncl_Gd_Ed = { "cmovnc", "cmovncl", Gd, Ed, XX }, +Ia_cmovncq_Gq_Eq = { "cmovnc", "cmovncq", Gq, Eq, XX }, +Ia_cmovncw_Gw_Ew = { "cmovnc", "cmovncw", Gw, Ew, XX }, +Ia_cmovngl_Gd_Ed = { "cmovng", "cmovngl", Gd, Ed, XX }, +Ia_cmovngq_Gq_Eq = { "cmovng", "cmovngq", Gq, Eq, XX }, +Ia_cmovngw_Gw_Ew = { "cmovng", "cmovngw", Gw, Ew, XX }, +Ia_cmovnll_Gd_Ed = { "cmovnl", "cmovnll", Gd, Ed, XX }, +Ia_cmovnlq_Gq_Eq = { "cmovnl", "cmovnlq", Gq, Eq, XX }, +Ia_cmovnlw_Gw_Ew = { "cmovnl", "cmovnlw", Gw, Ew, XX }, +Ia_cmovnol_Gd_Ed = { "cmovno", "cmovnol", Gd, Ed, XX }, +Ia_cmovnoq_Gq_Eq = { "cmovno", "cmovnoq", Gq, Eq, XX }, +Ia_cmovnow_Gw_Ew = { "cmovno", "cmovnow", Gw, Ew, XX }, +Ia_cmovnpl_Gd_Ed = { "cmovnp", "cmovnpl", Gd, Ed, XX }, +Ia_cmovnpq_Gq_Eq = { "cmovnp", "cmovnpq", Gq, Eq, XX }, +Ia_cmovnpw_Gw_Ew = { "cmovnp", "cmovnpw", Gw, Ew, XX }, +Ia_cmovnsl_Gd_Ed = { "cmovns", "cmovnsl", Gd, Ed, XX }, +Ia_cmovnsq_Gq_Eq = { "cmovns", "cmovnsq", Gq, Eq, XX }, +Ia_cmovnsw_Gw_Ew = { "cmovns", "cmovnsw", Gw, Ew, XX }, +Ia_cmovnzl_Gd_Ed = { "cmovnz", "cmovnzl", Gd, Ed, XX }, +Ia_cmovnzq_Gq_Eq = { "cmovnz", "cmovnzq", Gq, Eq, XX }, +Ia_cmovnzw_Gw_Ew = { "cmovnz", "cmovnzw", Gw, Ew, XX }, +Ia_cmovol_Gd_Ed = { "cmovo", "cmovol", Gd, Ed, XX }, +Ia_cmovoq_Gq_Eq = { "cmovo", "cmovoq", Gq, Eq, XX }, +Ia_cmovow_Gw_Ew = { "cmovo", "cmovow", Gw, Ew, XX }, +Ia_cmovpl_Gd_Ed = { "cmovp", "cmovpl", Gd, Ed, XX }, +Ia_cmovpq_Gq_Eq = { "cmovp", "cmovpq", Gq, Eq, XX }, +Ia_cmovpw_Gw_Ew = { "cmovp", "cmovpw", Gw, Ew, XX }, +Ia_cmovsl_Gd_Ed = { "cmovs", "cmovsl", Gd, Ed, XX }, +Ia_cmovsq_Gq_Eq = { "cmovs", "cmovsq", Gq, Eq, XX }, +Ia_cmovsw_Gw_Ew = { "cmovs", "cmovsw", Gw, Ew, XX }, +Ia_cmovzl_Gd_Ed = { "cmovz", "cmovzl", Gd, Ed, XX }, +Ia_cmovzq_Gq_Eq = { "cmovz", "cmovzq", Gq, Eq, XX }, +Ia_cmovzw_Gw_Ew = { "cmovz", "cmovzw", Gw, Ew, XX }, +Ia_cmpb_AL_Ib = { "cmp", "cmpb", AL, Ib, XX }, +Ia_cmpb_Eb_Gb = { "cmp", "cmpb", Eb, Gb, XX }, +Ia_cmpb_Eb_Ib = { "cmp", "cmpb", Eb, Ib, XX }, +Ia_cmpb_Gb_Eb = { "cmp", "cmpb", Gb, Eb, XX }, +Ia_cmpl_EAX_Id = { "cmp", "cmpl", EAX, Id, XX }, +Ia_cmpl_Ed_Gd = { "cmp", "cmpl", Ed, Gd, XX }, +Ia_cmpl_Ed_Id = { "cmp", "cmpl", Ed, Id, XX }, +Ia_cmpl_Ed_sIb = { "cmp", "cmpl", Ed, sIbd, XX }, +Ia_cmpl_Gd_Ed = { "cmp", "cmpl", Gd, Ed, XX }, +Ia_cmppd_Vpd_Wpd_Ib = { "cmppd", "cmppd", Vpd, Wpd, Ib }, +Ia_cmpps_Vps_Wps_Ib = { "cmpps", "cmpps", Vps, Wps, Ib }, +Ia_cmpq_Eq_Gq = { "cmp", "cmpq", Eq, Gq, XX }, +Ia_cmpq_Eq_sIb = { "cmp", "cmpq", Eq, sIbq, XX }, +Ia_cmpq_Eq_sId = { "cmp", "cmpq", Eq, sIdq, XX }, +Ia_cmpq_Gq_Eq = { "cmp", "cmpq", Gq, Eq, XX }, +Ia_cmpq_RAX_sId = { "cmp", "cmpq", RAX, sIdq, XX }, +Ia_cmpsb_Yb_Xb = { "cmpsb", "cmpsb", Yb, Xb, XX }, +Ia_cmpsd_Vsd_Wsd_Ib = { "cmpsd", "cmpsd", Vsd, Wsd, Ib }, +Ia_cmpsl_Yd_Xd = { "cmpsd", "cmpsl", Yd, Xd, XX }, +Ia_cmpsq_Yq_Xq = { "cmpsq", "cmpsq", Yq, Xq, XX }, +Ia_cmpss_Vss_Wss_Ib = { "cmpss", "cmpss", Vss, Wss, Ib }, +Ia_cmpsw_Yw_Xw = { "cmpsw", "cmpsw", Yw, Xw, XX }, +Ia_cmpw_AX_Iw = { "cmp", "cmpw", AX, Iw, XX }, +Ia_cmpw_Ew_Gw = { "cmp", "cmpw", Ew, Gw, XX }, +Ia_cmpw_Ew_Iw = { "cmp", "cmpw", Ew, Iw, XX }, +Ia_cmpw_Ew_sIb = { "cmp", "cmpw", Ew, sIbw, XX }, +Ia_cmpw_Gw_Ew = { "cmp", "cmpw", Gw, Ew, XX }, +Ia_cmpxchg16b = { "cmpxchg16b", "cmpxchg16b", Mdq, XX, XX }, +Ia_cmpxchg8b = { "cmpxchg8b", "cmpxchg8b", Mq, XX, XX }, +Ia_cmpxchgb_Eb_Gb = { "cmpxchg", "cmpxchgb", Eb, Gb, XX }, +Ia_cmpxchgl_Ed_Gd = { "cmpxchg", "cmpxchgl", Ed, Gd, XX }, +Ia_cmpxchgq_Eq_Gq = { "cmpxchg", "cmpxchgq", Eq, Gq, XX }, +Ia_cmpxchgw_Ew_Gw = { "cmpxchg", "cmpxchgw", Ew, Gw, XX }, +Ia_comisd_Vsd_Wsd = { "comisd", "comisd", Vsd, Wsd, XX }, +Ia_comiss_Vss_Wss = { "comiss", "comiss", Vss, Wss, XX }, +Ia_cpuid = { "cpuid", "cpuid", XX, XX, XX }, +Ia_cqo = { "cqo", "cqto", XX, XX, XX }, +Ia_cvtdq2pd_Vpd_Wq = { "cvtdq2pd", "cvtdq2pd", Vpd, Wq, XX }, +Ia_cvtdq2ps_Vps_Wdq = { "cvtdq2ps", "cvtdq2ps", Vps, Wdq, XX }, +Ia_cvtpd2dq_Vq_Wpd = { "cvtpd2dq", "cvtpd2dq", Vq, Wpd, XX }, +Ia_cvtpd2pi_Pq_Wpd = { "cvtpd2pi", "cvtpd2pi", Pq, Wpd, XX }, +Ia_cvtpd2ps_Vps_Wpd = { "cvtpd2ps", "cvtpd2ps", Vps, Wpd, XX }, +Ia_cvtpi2pd_Vpd_Qq = { "cvtpi2pd", "cvtpi2pd", Vpd, Qq, XX }, +Ia_cvtpi2ps_Vps_Qq = { "cvtpi2ps", "cvtpi2ps", Vps, Qq, XX }, +Ia_cvtps2dq_Vdq_Wps = { "cvtps2dq", "cvtps2dq", Vdq, Wps, XX }, +Ia_cvtps2pd_Vpd_Wps = { "cvtps2pd", "cvtps2pd", Vpd, Wps, XX }, +Ia_cvtps2pi_Pq_Wps = { "cvtps2pi", "cvtps2pi", Pq, Wps, XX }, +Ia_cvtsd2si_Gd_Wsd = { "cvtsd2si", "cvtsd2si", Gd, Wsd, XX }, +Ia_cvtsd2si_Gq_Wsd = { "cvtsd2si", "cvtsd2si", Gq, Wsd, XX }, +Ia_cvtsd2ss_Vss_Wsd = { "cvtsd2ss", "cvtsd2ss", Vss, Wsd, XX }, +Ia_cvtsi2sd_Vsd_Ed = { "cvtsi2sd", "cvtsi2sd", Vsd, Ed, XX }, +Ia_cvtsi2sd_Vsd_Eq = { "cvtsi2sd", "cvtsi2sd", Vsd, Eq, XX }, +Ia_cvtsi2ss_Vss_Ed = { "cvtsi2ss", "cvtsi2ss", Vss, Ed, XX }, +Ia_cvtsi2ss_Vss_Eq = { "cvtsi2ss", "cvtsi2ss", Vss, Eq, XX }, +Ia_cvtss2sd_Vsd_Wss = { "cvtss2sd", "cvtss2sd", Vsd, Wss, XX }, +Ia_cvtss2si_Gd_Wss = { "cvtss2si", "cvtss2si", Gd, Wss, XX }, +Ia_cvtss2si_Gq_Wss = { "cvtss2si", "cvtss2si", Gq, Wss, XX }, +Ia_cvtss2ss_Gd_Wss = { "cvtss2ss", "cvtss2ss", Gd, Wss, XX }, +Ia_cvtss2ss_Gq_Wss = { "cvtss2ss", "cvtss2ss", Gq, Wss, XX }, +Ia_cvttpd2dq_Vq_Wpd = { "cvttpd2dq", "cvttpd2dq", Vq, Wpd, XX }, +Ia_cvttps2dq_Vdq_Wps = { "cvttps2dq", "cvttps2dq", Vdq, Wps, XX }, +Ia_cwd = { "cwd", "cwtd", XX, XX, XX }, +Ia_cwde = { "cwde", "cwtl", XX, XX, XX }, +Ia_daa = { "daa", "daa", XX, XX, XX }, +Ia_das = { "das", "das", XX, XX, XX }, +Ia_decb_Eb = { "dec", "decb", Eb, XX, XX }, +Ia_decl_Ed = { "dec", "decl", Ed, XX, XX }, +Ia_decl_ERX = { "dec", "decl", ERX, XX, XX }, +Ia_decq_Eq = { "dec", "decq", Eq, XX, XX }, +Ia_decw_Ew = { "dec", "decw", Ew, XX, XX }, +Ia_decw_RX = { "dec", "decw", RX, XX, XX }, +Ia_divb_AL_Eb = { "div", "divb", AL, Eb, XX }, +Ia_divl_EAX_Ed = { "div", "divl", EAX, Ed, XX }, +Ia_divpd_Vpd_Wpd = { "divpd", "divpd", Vpd, Wpd, XX }, +Ia_divps_Vps_Wps = { "divps", "divps", Vps, Wps, XX }, +Ia_divq_RAX_Eq = { "div", "divq", RAX, Eq, XX }, +Ia_divsd_Vsd_Wsd = { "divsd", "divsd", Vsd, Wsd, XX }, +Ia_divss_Vss_Wss = { "divss", "divss", Vss, Wss, XX }, +Ia_divw_AX_Ew = { "div", "divw", AX, Ew, XX }, +Ia_emms = { "emms", "emms", XX, XX, XX }, +Ia_enter = { "enter", "enter", Iw, Ib, XX }, +Ia_error = { "(error)", "(error)", XX, XX, XX }, +Ia_f2xm1 = { "f2xm1", "f2xm1", XX, XX, XX }, +Ia_fabs = { "fabs", "fabs", XX, XX, XX }, +Ia_fadd_ST0_STi = { "fadd", "fadd", ST0, STi, XX }, +Ia_fadd_STi_ST0 = { "fadd", "fadd", STi, ST0, XX }, +Ia_faddl_Mq = { "fadd", "faddl", Mq, XX, XX }, +Ia_faddp_STi_ST0 = { "faddp", "faddp", STi, ST0, XX }, +Ia_fadds_Md = { "fadd", "fadds", Md, XX, XX }, +Ia_fbldt_Mt = { "fbld", "fbldt", Mt, XX, XX }, +Ia_fbstpt_Mt = { "fbstp", "fbstpt", Mt, XX, XX }, +Ia_fchs = { "fchs", "fchs", XX, XX, XX }, +Ia_fcmovb_ST0_STi = { "fcmovb", "fcmovb", ST0, STi, XX }, +Ia_fcmovbe_ST0_STi = { "fcmovbe", "fcmovbe", ST0, STi, XX }, +Ia_fcmove_ST0_STi = { "fcmove", "fcmove", ST0, STi, XX }, +Ia_fcmovnb_ST0_STi = { "fcmovnb", "fcmovnb", ST0, STi, XX }, +Ia_fcmovnbe_ST0_STi = { "fcmovnbe", "fcmovnbe", ST0, STi, XX }, +Ia_fcmovne_ST0_STi = { "fcmovne", "fcmovne", ST0, STi, XX }, +Ia_fcmovnu_ST0_STi = { "fcmovnu", "fcmovnu", ST0, STi, XX }, +Ia_fcmovu_ST0_STi = { "fcmovu", "fcmovu", ST0, STi, XX }, +Ia_fcom_STi = { "fcom", "fcom", STi, XX, XX }, +Ia_fcomi_ST0_STi = { "fcomi", "fcomi", ST0, STi, XX }, +Ia_fcomip_ST0_STi = { "fcomip", "fcomip", ST0, STi, XX }, +Ia_fcoml_Mq = { "fcom", "fcoml", Mq, XX, XX }, +Ia_fcomp_STi = { "fcomp", "fcomp", STi, XX, XX }, +Ia_fcompl_Mq = { "fcomp", "fcompl", Mq, XX, XX }, +Ia_fcompp = { "fcompp", "fcompp", XX, XX, XX }, +Ia_fcomps_Md = { "fcomp", "fcomps", Md, XX, XX }, +Ia_fcoms_Md = { "fcom", "fcoms", Md, XX, XX }, +Ia_fcos = { "fcos", "fcos", XX, XX, XX }, +Ia_fdecstp = { "fdecstp", "fdecstp", XX, XX, XX }, +Ia_fdisi = { "fdisi (287 legacy)", "fdisi (287 legacy)", XX, XX, XX }, +Ia_fdiv_ST0_STi = { "fdiv", "fdiv", ST0, STi, XX }, +Ia_fdiv_STi_ST0 = { "fdiv", "fdiv", STi, ST0, XX }, +Ia_fdivl_Mq = { "fdiv", "fdivl", Mq, XX, XX }, +Ia_fdivp_STi_ST0 = { "fdivp", "fdivp", STi, ST0, XX }, +Ia_fdivprs_Md = { "fdivpr", "fdivprs", Md, XX, XX }, +Ia_fdivr_STi_ST0 = { "fdivr", "fdivr", STi, ST0, XX }, +Ia_fdivrl_Mq = { "fdivr", "fdivrl", Mq, XX, XX }, +Ia_fdivrp_STi_ST0 = { "fdivrp", "fdivrp", STi, ST0, XX }, +Ia_fdivs_Md = { "fdiv", "fdivs", Md, XX, XX }, +Ia_femms = { "femms", "femms", XX, XX, XX }, +Ia_feni = { "feni (287 legacy)", "feni(287 legacy)", XX, XX, XX }, +Ia_ffree_STi = { "ffree", "ffree", STi, XX, XX }, +Ia_ffreep_STi = { "ffreep", "ffreep", STi, XX, XX }, +Ia_fiaddl_Md = { "fiadd", "fiaddl", Md, XX, XX }, +Ia_fiadds_Mw = { "fiadd", "fiadds", Mw, XX, XX }, +Ia_ficoml_Md = { "ficom", "ficoml", Md, XX, XX }, +Ia_ficompl_Md = { "ficomp", "ficompl", Md, XX, XX }, +Ia_ficomps_Mw = { "ficomp", "ficomps", Mw, XX, XX }, +Ia_ficoms_Mw = { "ficom", "ficoms", Mw, XX, XX }, +Ia_fidivl_Md = { "fidiv", "fidivl", Md, XX, XX }, +Ia_fidivrl_Md = { "fidivr", "fidivrl", Md, XX, XX }, +Ia_fidivrs_Mw = { "fidivr", "fidivrs", Mw, XX, XX }, +Ia_fidivs_Mw = { "fidiv", "fidivs", Mw, XX, XX }, +Ia_fildl_Md = { "fild", "fildl", Md, XX, XX }, +Ia_fildq_Mq = { "fild", "fildq", Mq, XX, XX }, +Ia_filds_Mw = { "fild", "filds", Mw, XX, XX }, +Ia_fimull_Md = { "fimul", "fimull", Md, XX, XX }, +Ia_fimuls_Mw = { "fimul", "fimuls", Mw, XX, XX }, +Ia_fincstp = { "fincstp", "fincstp", XX, XX, XX }, +Ia_fistl_Md = { "fist", "fistl", Md, XX, XX }, +Ia_fistpl_Md = { "fistp", "fistpl", Md, XX, XX }, +Ia_fistpq_Mq = { "fistp", "fistpq", Mq, XX, XX }, +Ia_fistps_Mw = { "fistp", "fistps", Mw, XX, XX }, +Ia_fists_Mw = { "fist", "fists", Mw, XX, XX }, +Ia_fisttpl_Md = { "fisttp", "fisttpl", Md, XX, XX }, +Ia_fisttpq_Mq = { "fisttp", "fisttpq", Mq, XX, XX }, +Ia_fisttps_Mw = { "fisttp", "fisttps", Mw, XX, XX }, +Ia_fisubl_Md = { "fisub", "fisubl", Md, XX, XX }, +Ia_fisubrl_Md = { "fisubr", "fisubrl", Md, XX, XX }, +Ia_fisubrs_Mw = { "fisubr", "fisubrs", Mw, XX, XX }, +Ia_fisubs_Mw = { "fisub", "fisubs", Mw, XX, XX }, +Ia_fld_STi = { "fld", "fld", STi, XX, XX }, +Ia_fld1 = { "fld1", "fld1", XX, XX, XX }, +Ia_fldcw = { "fldcw", "fldcw", Ew, XX, XX }, +Ia_fldenv = { "fldenv", "fldenv", Mx, XX, XX }, +Ia_fldl_Mq = { "fld", "fldl", Mq, XX, XX }, +Ia_fldl2e = { "fldl2e", "fldl2e", XX, XX, XX }, +Ia_fldl2t = { "fldl2t", "fldl2t", XX, XX, XX }, +Ia_fldlg2 = { "fldlg2", "fldlg2", XX, XX, XX }, +Ia_fldln2 = { "fldln2", "fldln2", XX, XX, XX }, +Ia_fldpi = { "fldpi", "fldpi", XX, XX, XX }, +Ia_flds_Md = { "fld", "flds", Md, XX, XX }, +Ia_fldt_Mt = { "fld", "fldt", Mt, XX, XX }, +Ia_fldz = { "fldz", "fldz", XX, XX, XX }, +Ia_fmul_ST0_STi = { "fmul", "fmul", ST0, STi, XX }, +Ia_fmul_STi_ST0 = { "fmul", "fmul", STi, ST0, XX }, +Ia_fmull_Mq = { "fmul", "fmull", Mq, XX, XX }, +Ia_fmulp_STi_ST0 = { "fmulp", "fmulp", STi, ST0, XX }, +Ia_fmuls_Md = { "fmul", "fmuls", Md, XX, XX }, +Ia_fnclex = { "fnclex", "fnclex", XX, XX, XX }, +Ia_fninit = { "fninit", "fninit", XX, XX, XX }, +Ia_fnop = { "fnop", "fnop", XX, XX, XX }, +Ia_fnsave = { "fnsave", "fnsave", Mx, XX, XX }, +Ia_fnstcw = { "fnstcw", "fnstcw", Mw, XX, XX }, +Ia_fnstenv = { "fnstenv", "fnstenv", Mx, XX, XX }, +Ia_fnstsw = { "fnstsw", "fnstsw", Mw, XX, XX }, +Ia_fnstsw_AX = { "fnstsw", "fnstsw", AX, XX, XX }, +Ia_fpatan = { "fpatan", "fpatan", XX, XX, XX }, +Ia_fprem = { "fprem", "fprem", XX, XX, XX }, +Ia_fprem1 = { "fprem1", "fprem1", XX, XX, XX }, +Ia_fptan = { "fptan", "fptan", XX, XX, XX }, +Ia_frndint = { "frndint", "frndint", XX, XX, XX }, +Ia_frstor = { "frstor", "frstor", Mx, XX, XX }, +Ia_fscale = { "fscale", "fscale", XX, XX, XX }, +Ia_fsetpm = { "fsetpm (287 legacy)", "fsetpm (287 legacy)", XX, XX, XX }, +Ia_fsin = { "fsin", "fsin", XX, XX, XX }, +Ia_fsincos = { "fsincos", "fsincos", XX, XX, XX }, +Ia_fsqrt = { "fsqrt", "fsqrt", XX, XX, XX }, +Ia_fst_STi = { "fst", "fst", STi, XX, XX }, +Ia_fstl_Mq = { "fst", "fstl", Mq, XX, XX }, +Ia_fstp_STi = { "fstp", "fstp", STi, XX, XX }, +Ia_fstpl_Mq = { "fstp", "fstpl", Mq, XX, XX }, +Ia_fstps_Md = { "fstp", "fstps", Md, XX, XX }, +Ia_fstpt_Mt = { "fstp", "fstpt", Mt, XX, XX }, +Ia_fsts_Md = { "fst", "fsts", Md, XX, XX }, +Ia_fsub_ST0_STi = { "fsub", "fsub", ST0, STi, XX }, +Ia_fsub_STi_ST0 = { "fsub", "fsub", STi, ST0, XX }, +Ia_fsubl_Mq = { "fsub", "fsubl", Mq, XX, XX }, +Ia_fsubp_STi_ST0 = { "fsubp", "fsubp", STi, ST0, XX }, +Ia_fsubr_ST0_STi = { "fsubr", "fsubr", ST0, STi, XX }, +Ia_fsubr_STi_ST0 = { "fsubr", "fsubr", STi, ST0, XX }, +Ia_fsubrl_Mq = { "fsubr", "fsubrl", Mq, XX, XX }, +Ia_fsubrp_STi_ST0 = { "fsubrp", "fsubrp", STi, ST0, XX }, +Ia_fsubrs_Md = { "fsubr", "fsubrs", Md, XX, XX }, +Ia_fsubs_Md = { "fsub", "fsubs", Md, XX, XX }, +Ia_ftst = { "ftst", "ftst", XX, XX, XX }, +Ia_fucom_STi = { "fucom", "fucom", STi, XX, XX }, +Ia_fucomi_ST0_STi = { "fucomi", "fucomi", ST0, STi, XX }, +Ia_fucomip_ST0_STi = { "fucomip", "fucomip", ST0, STi, XX }, +Ia_fucomp_STi = { "fucomp", "fucomp", STi, XX, XX }, +Ia_fucompp = { "fucompp", "fucompp", XX, XX, XX }, +Ia_fwait = { "fwait", "fwait", XX, XX, XX }, +Ia_fxam = { "fxam", "fxam", XX, XX, XX }, +Ia_fxch = { "fxch", "fxch", STi, XX, XX }, +Ia_fxrstor = { "fxrstor", "fxrstor", Mx, XX, XX }, +Ia_fxsave = { "fxsave", "fxsave", Mx, XX, XX }, +Ia_fxtract = { "fxtract", "fxtract", XX, XX, XX }, +Ia_fyl2x = { "fyl2x", "fyl2x", XX, XX, XX }, +Ia_fyl2xp1 = { "fyl2xp1", "fyl2xp1", XX, XX, XX }, +Ia_haddpd_Vpd_Wpd = { "haddpd", "haddpd", Vpd, Wpd, XX }, +Ia_haddps_Vps_Wps = { "haddps", "haddps", Vps, Wps, XX }, +Ia_hlt = { "hlt", "hlt", XX, XX, XX }, +Ia_hsubpd_Vpd_Wpd = { "hsubpd", "hsubpd", Vpd, Wpd, XX }, +Ia_hsubps_Vps_Wps = { "hsubps", "hsubps", Vps, Wps, XX }, +Ia_idivb_AL_Eb = { "idiv", "idivb", AL, Eb, XX }, +Ia_idivl_EAX_Ed = { "idiv", "idivl", EAX, Ed, XX }, +Ia_idivq_RAX_Eq = { "idiv", "idivq", RAX, Eq, XX }, +Ia_idivw_AX_Ew = { "idiv", "idivw", AX, Ew, XX }, +Ia_imulb_AL_Eb = { "imul", "imulb", AL, Eb, XX }, +Ia_imull_EAX_Ed = { "imul", "imull", EAX, Ed, XX }, +Ia_imull_Gd_Ed = { "imul", "imull", Gd, Ed, XX }, +Ia_imull_Gd_Ed_Id = { "imul", "imull", Gd, Ed, Id }, +Ia_imull_Gd_Ed_sIb = { "imul", "imull", Gd, Ed, sIbd }, +Ia_imulq_Gq_Eq = { "imul", "imulq", Gq, Eq, XX }, +Ia_imulq_Gq_Eq_sIb = { "imul", "imulq", Gq, Eq, sIbq }, +Ia_imulq_Gq_Eq_sId = { "imul", "imulq", Gq, Eq, sIdq }, +Ia_imulq_RAX_Eq = { "imul", "imulq", RAX, Eq, XX }, +Ia_imulw_AX_Ew = { "imul", "imulw", AX, Ew, XX }, +Ia_imulw_Gw_Ew = { "imul", "imulw", Gw, Ew, XX }, +Ia_imulw_Gw_Ew_Iw = { "imulS", "imulw", Gw, Ew, Iw }, +Ia_imulw_Gw_Ew_sIb = { "imul", "imulw", Gw, Ew, sIbw }, +Ia_inb_AL_DX = { "in", "inb", AL, DX, XX }, +Ia_inb_AL_Ib = { "in", "inb", AL, Ib, XX }, +Ia_incb_Eb = { "inc", "incb", Eb, XX, XX }, +Ia_incl_Ed = { "inc", "incl", Ed, XX, XX }, +Ia_incl_ERX = { "inc", "incl", ERX, XX, XX }, +Ia_incq_Eq = { "inc", "incq", Eq, XX, XX }, +Ia_incw_Ew = { "inc", "incw", Ew, XX, XX }, +Ia_incw_RX = { "inc", "incw", RX, XX, XX }, +Ia_inl_EAX_DX = { "in", "inl", EAX, DX, XX }, +Ia_inl_EAX_Ib = { "in", "inl", EAX, Ib, XX }, +Ia_insb_Yb_DX = { "insb", "insb", Yb, DX, XX }, +Ia_insl_Yd_DX = { "insd", "insl", Yd, DX, XX }, +Ia_insw_Yw_DX = { "insw", "insw", Yw, DX, XX }, +Ia_int_Ib = { "int", "int", Ib, XX, XX }, +Ia_int1 = { "int1", "int1", XX, XX, XX }, +Ia_int3 = { "int3", "int3", XX, XX, XX }, +Ia_into = { "into", "into", XX, XX, XX }, +Ia_Invalid = { "(invalid)", "(invalid)", XX, XX, XX }, +Ia_invd = { "invd", "invd", XX, XX, XX }, +Ia_invlpg = { "invlpg", "invlpg", Mx, XX, XX }, +Ia_inw_AX_DX = { "in", "inw", AX, DX, XX }, +Ia_inw_AX_Ib = { "in", "inw", AX, Ib, XX }, +Ia_iretl = { "iretd", "iretd", XX, XX, XX }, +Ia_iretq = { "iretq", "iretq", XX, XX, XX }, +Ia_iretw = { "iret", "iretw", XX, XX, XX }, +Ia_jb_Jb = { "jb", "jb", Jb, XX, XX }, +Ia_jb_Jd = { "jb", "jb", Jd, XX, XX }, +Ia_jb_Jw = { "jb", "jb", Jw, XX, XX }, +Ia_jbe_Jb = { "jbe", "jbe", Jb, XX, XX }, +Ia_jbe_Jd = { "jbe", "jbe", Jd, XX, XX }, +Ia_jbe_Jw = { "jbe", "jbe", Jw, XX, XX }, +Ia_jcxz_Jb = { "jcxz", "jcxz", Jb, XX, XX }, +Ia_jecxz_Jb = { "jecxz", "jecxz", Jb, XX, XX }, +Ia_jl_Jb = { "jl", "jl", Jb, XX, XX }, +Ia_jl_Jd = { "jl", "jl", Jd, XX, XX }, +Ia_jl_Jw = { "jl", "jl", Jw, XX, XX }, +Ia_jle_Jb = { "jle", "jle", Jb, XX, XX }, +Ia_jle_Jd = { "jle", "jle", Jd, XX, XX }, +Ia_jle_Jw = { "jle", "jle", Jw, XX, XX }, +Ia_jmp_Ed = { "jmp", "jmp", Ed, XX, XX }, +Ia_jmp_Eq = { "jmp", "jmp", Eq, XX, XX }, +Ia_jmp_Ew = { "jmp", "jmp", Ew, XX, XX }, +Ia_jmp_Jb = { "jmp", "jmp", Jb, XX, XX }, +Ia_jmp_Jd = { "jmp", "jmp", Jd, XX, XX }, +Ia_jmp_Jw = { "jmp", "jmp", Jw, XX, XX }, +Ia_jnb_Jb = { "jnb", "jnb", Jb, XX, XX }, +Ia_jnb_Jd = { "jnb", "jnb", Jd, XX, XX }, +Ia_jnb_Jw = { "jnb", "jnb", Jw, XX, XX }, +Ia_jnbe_Jb = { "jnbe", "jnbe", Jb, XX, XX }, +Ia_jnbe_Jd = { "jnbe", "jnbe", Jd, XX, XX }, +Ia_jnbe_Jw = { "jnbe", "jnbe", Jw, XX, XX }, +Ia_jnl_Jb = { "jnl", "jnl", Jb, XX, XX }, +Ia_jnl_Jd = { "jnl", "jnl", Jd, XX, XX }, +Ia_jnl_Jw = { "jnl", "jnl", Jw, XX, XX }, +Ia_jnle_Jb = { "jnle", "jnle", Jb, XX, XX }, +Ia_jnle_Jd = { "jnle", "jnle", Jd, XX, XX }, +Ia_jnle_Jw = { "jnle", "jnle", Jw, XX, XX }, +Ia_jno_Jb = { "jno", "jno", Jb, XX, XX }, +Ia_jno_Jd = { "jno", "jno", Jd, XX, XX }, +Ia_jno_Jw = { "jno", "jno", Jw, XX, XX }, +Ia_jnp_Jb = { "jnp", "jnp", Jb, XX, XX }, +Ia_jnp_Jd = { "jnp", "jnp", Jd, XX, XX }, +Ia_jnp_Jw = { "jnp", "jnp", Jw, XX, XX }, +Ia_jns_Jb = { "jns", "jns", Jb, XX, XX }, +Ia_jns_Jd = { "jns", "jns", Jd, XX, XX }, +Ia_jns_Jw = { "jns", "jns", Jw, XX, XX }, +Ia_jnz_Jb = { "jnz", "jnz", Jb, XX, XX }, +Ia_jnz_Jd = { "jnz", "jnz", Jd, XX, XX }, +Ia_jnz_Jw = { "jnz", "jnz", Jw, XX, XX }, +Ia_jo_Jb = { "jo", "jo", Jb, XX, XX }, +Ia_jo_Jd = { "jo", "jo", Jd, XX, XX }, +Ia_jo_Jw = { "jo", "jo", Jw, XX, XX }, +Ia_jp_Jb = { "jp", "jp", Jb, XX, XX }, +Ia_jp_Jd = { "jp", "jp", Jd, XX, XX }, +Ia_jp_Jw = { "jp", "jp", Jw, XX, XX }, +Ia_jrcxz_Jb = { "jrcxz", "jrcxz", Jb, XX, XX }, +Ia_js_Jb = { "js", "js", Jb, XX, XX }, +Ia_js_Jd = { "js", "js", Jd, XX, XX }, +Ia_js_Jw = { "js", "js", Jw, XX, XX }, +Ia_jz_Jb = { "jz", "jz", Jb, XX, XX }, +Ia_jz_Jd = { "jz", "jz", Jd, XX, XX }, +Ia_jz_Jw = { "jz", "jz", Jw, XX, XX }, +Ia_lahf = { "lahf", "lahf", XX, XX, XX }, +Ia_larl_Gd_Ew = { "lar", "larl", Gd, Ew, XX }, +Ia_larq_Gq_Ew = { "lar", "larq", Gq, Ew, XX }, +Ia_larw_Gw_Ew = { "lar", "larw", Gw, Ew, XX }, +Ia_lcall_Apd = { "call far", "lcall", Apd, XX, XX }, +Ia_lcall_Apw = { "call far", "lcall", Apw, XX, XX }, +Ia_lcall_Mp = { "call far", "lcall", Mp, XX, XX }, +Ia_lddqu_Vdq_Mdq = { "lddqu", "lddqu", Vdq, Mdq, XX }, +Ia_ldmxcsr = { "ldmxcsr", "ldmxcsr", Md, XX, XX }, +Ia_ldsl_Gd_Mp = { "lds", "ldsl", Gd, Mp, XX }, +Ia_ldsw_Gw_Mp = { "lds", "ldsw", Gw, Mp, XX }, +Ia_leal_Gd_Md = { "lea", "leal", Gd, Md, XX }, +Ia_leaq_Gq_Mq = { "lea", "leaq", Gq, Mq, XX }, +Ia_leave = { "leave", "leave", XX, XX, XX }, +Ia_leaw_Gw_Mw = { "lea", "leaw", Gw, Mw, XX }, +Ia_lesl_Gd_Mp = { "les", "lesl", Gd, Mp, XX }, +Ia_lesw_Gw_Mp = { "les", "lesw", Gw, Mp, XX }, +Ia_lfence = { "lfence", "lfence", XX, XX, XX }, +Ia_lfsl_Gd_Mp = { "lfs", "lfsl", Gd, Mp, XX }, +Ia_lfsq_Gq_Mp = { "lfs", "lfsq", Gq, Mp, XX }, +Ia_lfsw_Gw_Mp = { "lfs", "lfsw", Gw, Mp, XX }, +Ia_lgdt = { "lgdt", "lgdt", Ms, XX, XX }, +Ia_lgsl_Gd_Mp = { "lgs", "lgsl", Gd, Mp, XX }, +Ia_lgsq_Gq_Mp = { "lgs", "lgsq", Gq, Mp, XX }, +Ia_lgsw_Gw_Mp = { "lgs", "lgsw", Gw, Mp, XX }, +Ia_lidt = { "lidt", "lidt", Ms, XX, XX }, +Ia_ljmp_Mp = { "jmp far", "ljmp", Mp, XX, XX }, +Ia_ljmp_Apd = { "jmp far", "ljmp", Apd, XX, XX }, +Ia_ljmp_Apw = { "jmp far", "ljmp", Apw, XX, XX }, +Ia_lldt = { "lldt", "lldt", Ew, XX, XX }, +Ia_lmsw_Ew = { "lmsw", "lmsw", Ew, XX, XX }, +Ia_lodsb_AL_Xb = { "lodsb", "lodsb", AL, Xb, XX }, +Ia_lodsl_EAX_Xd = { "lodsd", "lodsl", EAX, Xd, XX }, +Ia_lodsq_RAX_Xq = { "lodsq", "lodsq", RAX, Xq, XX }, +Ia_lodsw_AX_Xw = { "lodsw", "lodsw", AX, Xw, XX }, +Ia_loop_Jb = { "loop", "loop", Jb, XX, XX }, +Ia_loope_Jb = { "loope", "loope", Jb, XX, XX }, +Ia_loopne_Jb = { "loopne", "loopne", Jb, XX, XX }, +Ia_lret = { "retf", "lret", XX, XX, XX }, +Ia_lret_Iw = { "retf", "lret", Iw, XX, XX }, +Ia_lsll_Gd_Ew = { "lsl", "lsll", Gd, Ew, XX }, +Ia_lslq_Gq_Ew = { "lsl", "lslq", Gq, Ew, XX }, +Ia_lslw_Gw_Ew = { "lsl", "lslw", Gw, Ew, XX }, +Ia_lssl_Gd_Mp = { "lss", "lssl", Gd, Mp, XX }, +Ia_lssq_Gq_Mp = { "lss", "lssq", Gq, Mp, XX }, +Ia_lssw_Gw_Mp = { "lss", "lssw", Gw, Mp, XX }, +Ia_ltr = { "ltr", "ltr", Ew, XX, XX }, +Ia_maskmovdqu_Vdq_Wdq = { "maskmovdqu", "maskmovdqu", Vdq, Wdq, XX }, +Ia_maskmovq_Pq_Qq = { "maskmovq", "maskmovq", Pq, Qq, XX }, +Ia_maxpd_Vpd_Wpd = { "maxpd", "maxpd", Vpd, Wpd, XX }, +Ia_maxps_Vps_Wps = { "maxps", "maxps", Vps, Wps, XX }, +Ia_maxsd_Vsd_Wsd = { "maxsd", "maxsd", Vsd, Wsd, XX }, +Ia_maxss_Vss_Wss = { "maxss", "maxss", Vss, Wss, XX }, +Ia_mfence = { "mfence", "mfence", XX, XX, XX }, +Ia_minpd_Vpd_Wpd = { "minpd", "minpd", Vpd, Wpd, XX }, +Ia_minps_Vps_Wps = { "minps", "minps", Vps, Wps, XX }, +Ia_minsd_Vsd_Wsd = { "minsd", "minsd", Vsd, Wsd, XX }, +Ia_minss_Vss_Wss = { "minss", "minss", Vss, Wss, XX }, +Ia_monitor = { "monitor", "monitor", XX, XX, XX }, +Ia_movapd_Vpd_Wpd = { "movapd", "movapd", Vpd, Wpd, XX }, +Ia_movapd_Wpd_Vpd = { "movapd", "movapd", Wpd, Vpd, XX }, +Ia_movaps_Vps_Wps = { "movaps", "movaps", Vps, Wps, XX }, +Ia_movaps_Wps_Vps = { "movaps", "movaps", Wps, Vps, XX }, +Ia_movb_AL_Ob = { "mov", "movb", AL, Ob, XX }, +Ia_movb_Eb_Gb = { "mov", "movb", Eb, Gb, XX }, +Ia_movb_Eb_Ib = { "mov", "movb", Eb, Ib, XX }, +Ia_movb_Gb_Eb = { "mov", "movb", Gb, Eb, XX }, +Ia_movb_Ob_AL = { "mov", "movb", Ob, AL, XX }, +Ia_movb_R8_Ib = { "mov", "movb", R8, Ib, XX }, +Ia_movd_Ed_Pq = { "movd", "movd", Ed, Pq, XX }, +Ia_movd_Ed_Vd = { "movd", "movd", Ed, Vdq, XX }, +Ia_movd_Pq_Ed = { "movd", "movd", Pq, Ed, XX }, +Ia_movd_Vdq_Ed = { "movd", "movd", Vdq, Ed, XX }, +Ia_movddup_Vdq_Wq = { "movddup", "movddup", Vdq, Wq, XX }, +Ia_movdq2q_Pq_Vq = { "movdq2q", "movdq2q", Pq, Vq, XX }, +Ia_movdqa_Vdq_Wdq = { "movdqa", "movdqa", Vdq, Wdq, XX }, +Ia_movdqa_Wdq_Vdq = { "movdqa", "movdqa", Wdq, Vdq, XX }, +Ia_movdqu_Vdq_Wdq = { "movdqu", "movdqu", Vdq, Wdq, XX }, +Ia_movdqu_Wdq_Vdq = { "movdqu", "movdqu", Wdq, Vdq, XX }, +Ia_movhpd_Mq_Vpd = { "movhpd", "movhpd", Mq, Vpd, XX }, +Ia_movhpd_Vpd_Mq = { "movhpd", "movhpd", Vpd, Mq, XX }, +Ia_movhps_Mq_Vps = { "movhps", "movhps", Mq, Vps, XX }, +Ia_movhps_Vps_Mq = { "movhps", "movhps", Vps, Mq, XX }, +Ia_movl_Cd_Rd = { "mov", "movl", Cd, Rd, XX }, +Ia_movl_Dd_Rd = { "mov", "movl", Dd, Rd, XX }, +Ia_movl_EAX_Od = { "mov", "movl", EAX, Od, XX }, +Ia_movl_Ed_Gd = { "mov", "movl", Ed, Gd, XX }, +Ia_movl_Ed_Id = { "mov", "movl", Ed, Id, XX }, +Ia_movl_ERX_Id = { "mov", "movl", ERX, Id, XX }, +Ia_movl_Gd_Ed = { "mov", "movl", Gd, Ed, XX }, +Ia_movl_Od_EAX = { "mov", "movl", Od, EAX, XX }, +Ia_movl_Rd_Cd = { "mov", "movl", Rd, Cd, XX }, +Ia_movl_Rd_Dd = { "mov", "movl", Rd, Dd, XX }, +Ia_movl_Rd_Td = { "mov", "movl", Rd, Td, XX }, +Ia_movl_Td_Rd = { "mov", "movl", Td, Rd, XX }, +Ia_movlpd_Mq_Vpd = { "movlpd", "movlpd", Mq, Vpd, XX }, +Ia_movlpd_Vpd_Mq = { "movlpd", "movlpd", Vpd, Mq, XX }, +Ia_movlps_Mq_Vps = { "movlps", "movlps", Mq, Vps, XX }, +Ia_movlps_Vps_Mq = { "movlps", "movlps", Vps, Mq, XX }, +Ia_movmskpd_Gd_Vpd = { "movmskpd", "movmskpd", Gd, Vpd, XX }, +Ia_movmskps_Gd_Vps = { "movmskps", "movmskps", Gd, Vps, XX }, +Ia_movntdq_Mdq_Vdq = { "movntdq", "movntdq", Mdq, Vdq, XX }, +Ia_movnti_Md_Gd = { "movnti", "movnti", Md, Gd, XX }, +Ia_movntiq_Mq_Gq = { "movntiq", "movntiq", Mq, Gq, XX }, +Ia_movntpd_Mpd_Vpd = { "movntpd", "movntpd", Mpd, Vpd, XX }, +Ia_movntps_Mps_Vps = { "movntps", "movntps", Mps, Vps, XX }, +Ia_movntq_Mq_Pq = { "movntq", "movntq", Mq, Pq, XX }, +Ia_movq_Cq_Rq = { "mov", "movq", Cq, Rq, XX }, +Ia_movq_Dq_Rq = { "mov", "movq", Dq, Rq, XX }, +Ia_movq_Eq_Gq = { "mov", "movq", Eq, Gq, XX }, +Ia_movq_Eq_Pq = { "movq", "movq", Eq, Pq, XX }, +Ia_movq_Eq_sId = { "mov", "movq", Eq, sIdq, XX }, +Ia_movq_Eq_Vq = { "movq", "movq", Eq, Vq, XX }, +Ia_movq_Gq_Eq = { "mov", "movq", Gq, Eq, XX }, +Ia_movq_Oq_RAX = { "mov", "movq", Oq, RAX, XX }, +Ia_movq_Pq_Eq = { "movq", "movq", Pq, Eq, XX }, +Ia_movq_Pq_Qq = { "movq", "movq", Pq, Qq, XX }, +Ia_movq_Qq_Pq = { "movq", "movq", Qq, Pq, XX }, +Ia_movq_RAX_Oq = { "mov", "movq", RAX, Oq, XX }, +Ia_movq_Rq_Cq = { "mov", "movq", Rq, Cq, XX }, +Ia_movq_Rq_Dq = { "mov", "movq", Rq, Dq, XX }, +Ia_movq_RRX_Iq = { "mov", "movq", RRX, Iq, XX }, +Ia_movq_Vdq_Eq = { "movq", "movq", Vdq, Eq, XX }, +Ia_movq_Vq_Wq = { "movq", "movq", Vq, Wq, XX }, +Ia_movq_Wq_Vq = { "movq", "movq", Wq, Vq, XX }, +Ia_movq2dq_Vdq_Qq = { "movq2dq", "movq2dq", Vdq, Qq, XX }, +Ia_movsb_Yb_Xb = { "movsb", "movsb", Yb, Xb, XX }, +Ia_movsbl_Gd_Eb = { "movsx", "movsbl", Gd, Eb, XX }, +Ia_movsbq_Gq_Eb = { "movsx", "movsbq", Gq, Eb, XX }, +Ia_movsbw_Gw_Eb = { "movsx", "movsbw", Gw, Eb, XX }, +Ia_movsd_Vsd_Wsd = { "movsd", "movsd", Vsd, Wsd, XX }, +Ia_movsd_Wsd_Vsd = { "movsd", "movsd", Wsd, Vsd, XX }, +Ia_movshdup_Vdq_Wdq = { "movshdup", "movshdup", Vdq, Wdq, XX }, +Ia_movsl_Yd_Xd = { "movsd", "movsl", Yd, Xd, XX }, +Ia_movsldup_Vdq_Wdq = { "movsldup", "movsldup", Vdq, Wdq, XX }, +Ia_movslq_Gq_Ed = { "movsxd", "movslq", Gq, Ed, XX }, +Ia_movsq_Yq_Xq = { "movsq", "movsq", Yq, Xq, XX }, +Ia_movss_Vss_Wss = { "movss", "movss", Vss, Wss, XX }, +Ia_movss_Wss_Vss = { "movss", "movss", Wss, Vss, XX }, +Ia_movsw_Yw_Xw = { "movsw", "movsw", Yw, Xw, XX }, +Ia_movswl_Gd_Ew = { "movsx", "movswl", Gd, Ew, XX }, +Ia_movswq_Gq_Ew = { "movsx", "movswq", Gq, Ew, XX }, +Ia_movupd_Vpd_Wpd = { "movupd", "movupd", Vpd, Wpd, XX }, +Ia_movupd_Wpd_Vpd = { "movupd", "movupd", Wpd, Vpd, XX }, +Ia_movups_Vps_Wps = { "movups", "movups", Vps, Wps, XX }, +Ia_movups_Wps_Vps = { "movups", "movups", Wps, Vps, XX }, +Ia_movw_AX_Ow = { "mov", "movw", AX, Ow, XX }, +Ia_movw_Ew_Gw = { "mov", "movw", Ew, Gw, XX }, +Ia_movw_Ew_Iw = { "mov", "movw", Ew, Iw, XX }, +Ia_movw_Ew_Sw = { "mov", "movw", Ew, Sw, XX }, +Ia_movw_Gw_Ew = { "mov", "movw", Gw, Ew, XX }, +Ia_movw_Ow_AX = { "mov", "movw", Ow, AX, XX }, +Ia_movw_RX_Iw = { "mov", "movw", RX, Iw, XX }, +Ia_movw_Sw_Ew = { "mov", "movw", Sw, Ew, XX }, +Ia_movzbl_Gd_Eb = { "movzx", "movzbl", Gd, Eb, XX }, +Ia_movzbq_Gq_Eb = { "movzx", "movzbq", Gq, Eb, XX }, +Ia_movzbw_Gw_Eb = { "movzx", "movzbw", Gw, Eb, XX }, +Ia_movzwl_Gd_Ew = { "movzx", "movzwl", Gd, Ew, XX }, +Ia_movzwq_Gq_Ew = { "movzx", "movzwq", Gq, Ew, XX }, +Ia_mulb_AL_Eb = { "mul", "mulb", AL, Eb, XX }, +Ia_mull_EAX_Ed = { "mul", "mull", EAX, Ed, XX }, +Ia_mulpd_Vpd_Wpd = { "mulpd", "mulpd", Vpd, Wpd, XX }, +Ia_mulps_Vps_Wps = { "mulps", "mulps", Vps, Wps, XX }, +Ia_mulq_RAX_Eq = { "mul", "mulq", RAX, Eq, XX }, +Ia_mulsd_Vsd_Wsd = { "mulsd", "mulsd", Vsd, Wsd, XX }, +Ia_mulss_Vss_Wss = { "mulss", "mulss", Vss, Wss, XX }, +Ia_mulw_AX_Ew = { "mul", "mulw", AX, Ew, XX }, +Ia_mwait = { "mwait", "mwait", XX, XX, XX }, +Ia_negb_Eb = { "neg", "negb", Eb, XX, XX }, +Ia_negl_Ed = { "neg", "negl", Ed, XX, XX }, +Ia_negq_Eq = { "neg", "negq", Eq, XX, XX }, +Ia_negw_Ew = { "neg", "negw", Ew, XX, XX }, +Ia_nop = { "nop", "nop", XX, XX, XX }, +Ia_notb_Eb = { "not", "notb", Eb, XX, XX }, +Ia_notl_Ed = { "not", "notl", Ed, XX, XX }, +Ia_notq_Eq = { "not", "notq", Eq, XX, XX }, +Ia_notw_Ew = { "not", "notw", Ew, XX, XX }, +Ia_orb_AL_Ib = { "or", "orb", AL, Ib, XX }, +Ia_orb_Eb_Gb = { "or", "orb", Eb, Gb, XX }, +Ia_orb_Eb_Ib = { "or", "orb", Eb, Ib, XX }, +Ia_orb_Gb_Eb = { "or", "orb", Gb, Eb, XX }, +Ia_orl_EAX_Id = { "or", "orl", EAX, Id, XX }, +Ia_orl_Ed_Gd = { "or", "orl", Ed, Gd, XX }, +Ia_orl_Ed_Id = { "or", "orl", Ed, Id, XX }, +Ia_orl_Ed_sIb = { "or", "orl", Ed, sIbd, XX }, +Ia_orl_Gd_Ed = { "or", "orl", Gd, Ed, XX }, +Ia_orpd_Vpd_Wpd = { "orpd", "orpd", Vpd, Wpd, XX }, +Ia_orps_Vps_Wps = { "orps", "orps", Vps, Wps, XX }, +Ia_orq_Eq_Gq = { "or", "orq", Eq, Gq, XX }, +Ia_orq_Eq_sIb = { "or", "orq", Eq, sIbq, XX }, +Ia_orq_Eq_sId = { "or", "orq", Eq, sIdq, XX }, +Ia_orq_Gq_Eq = { "or", "orq", Gq, Eq, XX }, +Ia_orq_RAX_sId = { "or", "orq", RAX, sIdq, XX }, +Ia_orw_AX_Iw = { "or", "orw", AX, Iw, XX }, +Ia_orw_Ew_Gw = { "or", "orw", Ew, Gw, XX }, +Ia_orw_Ew_Iw = { "or", "orw", Ew, Iw, XX }, +Ia_orw_Ew_sIb = { "or", "orw", Ew, sIbw, XX }, +Ia_orw_Gw_Ew = { "or", "orw", Gw, Ew, XX }, +Ia_outb_DX_AL = { "out", "outb", DX, AL, XX }, +Ia_outb_Ib_AL = { "out", "outb", Ib, AL, XX }, +Ia_outl_DX_EAX = { "out", "outl", DX, EAX, XX }, +Ia_outl_Ib_EAX = { "out", "outl", Ib, EAX, XX }, +Ia_outsb_DX_Xb = { "outsb", "outsb", DX, Xb, XX }, +Ia_outsl_DX_Xd = { "outsd", "outsl", DX, Xd, XX }, +Ia_outsw_DX_Xw = { "outsw", "outsw", DX, Xw, XX }, +Ia_outw_DX_AX = { "out", "outw", DX, AX, XX }, +Ia_outw_Ib_AX = { "out", "outw", Ib, AX, XX }, +Ia_packssdw_Pq_Qq = { "packssdw", "packssdw", Pq, Qq, XX }, +Ia_packssdw_Vdq_Wdq = { "packssdw", "packssdw", Vdq, Wdq, XX }, +Ia_packsswb_Pq_Qq = { "packsswb", "packsswb", Pq, Qq, XX }, +Ia_packsswb_Vdq_Wq = { "packsswb", "packsswb", Vdq, Wq, XX }, +Ia_packuswb_Pq_Qq = { "packuswb", "packuswb", Pq, Qq, XX }, +Ia_packuswb_Vdq_Wdq = { "packuswb", "packuswb", Vdq, Wdq, XX }, +Ia_paddb_Pq_Qq = { "paddb", "paddb", Pq, Qq, XX }, +Ia_paddb_Vdq_Wdq = { "paddb", "paddb", Vdq, Wdq, XX }, +Ia_paddd_Pq_Qq = { "paddd", "paddd", Pq, Qq, XX }, +Ia_paddd_Vdq_Wdq = { "paddd", "paddd", Vdq, Wdq, XX }, +Ia_paddq_Pq_Qq = { "paddq", "paddq", Pq, Qq, XX }, +Ia_paddq_Vdq_Wdq = { "paddq", "paddq", Vdq, Wdq, XX }, +Ia_paddsb_Pq_Qq = { "paddsb", "paddsb", Pq, Qq, XX }, +Ia_paddsb_Vdq_Wdq = { "paddsb", "paddsb", Vdq, Wdq, XX }, +Ia_paddsw_Pq_Qq = { "paddsw", "paddsw", Pq, Qq, XX }, +Ia_paddsw_Vdq_Wdq = { "paddsw", "paddsw", Vdq, Wdq, XX }, +Ia_paddusb_Pq_Qq = { "paddusb", "paddusb", Pq, Qq, XX }, +Ia_paddusb_Vdq_Wdq = { "paddusb", "paddusb", Vdq, Wdq, XX }, +Ia_paddusw_Pq_Qq = { "paddusw", "paddusw", Pq, Qq, XX }, +Ia_paddusw_Vdq_Wdq = { "paddusw", "paddusw", Vdq, Wdq, XX }, +Ia_paddw_Pq_Qq = { "paddw", "paddw", Pq, Qq, XX }, +Ia_paddw_Vdq_Wdq = { "paddw", "paddw", Vdq, Wdq, XX }, +Ia_pand_Pq_Qq = { "pand", "pand", Pq, Qq, XX }, +Ia_pand_Vdq_Wdq = { "pand", "pand", Vdq, Wdq, XX }, +Ia_pandn_Pq_Qq = { "pandn", "pandn", Pq, Qq, XX }, +Ia_pandn_Vdq_Wdq = { "pandn", "pandn", Vdq, Wdq, XX }, +Ia_pause = { "pause", "pause", XX, XX, XX }, +Ia_pavgb_Pq_Qq = { "pavgb", "pavgb", Pq, Qq, XX }, +Ia_pavgb_Vdq_Wdq = { "pavgb", "pavgb", Vdq, Wdq, XX }, +Ia_pavgw_Pq_Qq = { "pavgw", "pavgw", Pq, Qq, XX }, +Ia_pavgw_Vdq_Wdq = { "pavgw", "pavgw", Vdq, Wdq, XX }, +Ia_pcmpeqb_Pq_Qq = { "pcmpeqb", "pcmpeqb", Pq, Qq, XX }, +Ia_pcmpeqb_Vdq_Wdq = { "pcmpeqb", "pcmpeqb", Vdq, Wdq, XX }, +Ia_pcmpeqd_Pq_Qq = { "pcmpeqd", "pcmpeqd", Pq, Qq, XX }, +Ia_pcmpeqd_Vdq_Wdq = { "pcmpeqd", "pcmpeqd", Vdq, Wdq, XX }, +Ia_pcmpeqw_Pq_Qq = { "pcmpeqw", "pcmpeqw", Pq, Qq, XX }, +Ia_pcmpeqw_Vdq_Wdq = { "pcmpeqw", "pcmpeqw", Vdq, Wdq, XX }, +Ia_pcmpgtb_Pq_Qq = { "pcmpgtb", "pcmpgtb", Pq, Qq, XX }, +Ia_pcmpgtb_Vdq_Wq = { "pcmpgtb", "pcmpgtb", Vdq, Wq, XX }, +Ia_pcmpgtd_Pq_Qq = { "pcmpgtd", "pcmpgtd", Pq, Qq, XX }, +Ia_pcmpgtd_Vdq_Wdq = { "pcmpgtd", "pcmpgtd", Vdq, Wdq, XX }, +Ia_pcmpgtw_Pq_Qq = { "pcmpgtw", "pcmpgtw", Pq, Qq, XX }, +Ia_pcmpgtw_Vdq_Wq = { "pcmpgtw", "pcmpgtw", Vdq, Wq, XX }, +Ia_pextrw_Gd_Pq_Ib = { "pextrw", "pextrw", Gd, Pq, Ib }, +Ia_pextrw_Gd_Vdq_Ib = { "pextrw", "pextrw", Gd, Vdq, Ib }, +Ia_pf2id_Pq_Qq = { "pf2id", "pf2id", Pq, Qq, XX }, +Ia_pf2iw_Pq_Qq = { "pf2iw", "pf2iw", Pq, Qq, XX }, +Ia_pfacc_Pq_Qq = { "pfacc", "pfacc", Pq, Qq, XX }, +Ia_pfadd_Pq_Qq = { "pfadd", "pfadd", Pq, Qq, XX }, +Ia_pfcmpeq_Pq_Qq = { "pfcmpeq", "pfcmpeq", Pq, Qq, XX }, +Ia_pfcmpge_Pq_Qq = { "pfcmpge", "pfcmpge", Pq, Qq, XX }, +Ia_pfcmpgt_Pq_Qq = { "pfcmpgt", "pfcmpgt", Pq, Qq, XX }, +Ia_pfmax_Pq_Qq = { "pfmax", "pfmax", Pq, Qq, XX }, +Ia_pfmin_Pq_Qq = { "pfmin", "pfmin", Pq, Qq, XX }, +Ia_pfmul_Pq_Qq = { "pfmul", "pfmul", Pq, Qq, XX }, +Ia_pfnacc_Pq_Qq = { "pfnacc", "pfnacc", Pq, Qq, XX }, +Ia_pfpnacc_Pq_Qq = { "pfpnacc", "pfpnacc", Pq, Qq, XX }, +Ia_pfrcp_Pq_Qq = { "pfrcp", "pfrcp", Pq, Qq, XX }, +Ia_pfrcpit1_Pq_Qq = { "pfrcpit1", "pfrcpit1", Pq, Qq, XX }, +Ia_pfrcpit2_Pq_Qq = { "pfrcpit2", "pfrcpit2", Pq, Qq, XX }, +Ia_pfrsqit1_Pq_Qq = { "pfrsqit1", "pfrsqit1", Pq, Qq, XX }, +Ia_pfrsqrt_Pq_Qq = { "pfrsqrt", "pfrsqrt", Pq, Qq, XX }, +Ia_pfsub_Pq_Qq = { "pfsub", "pfsub", Pq, Qq, XX }, +Ia_pfsubr_Pq_Qq = { "pfsubr", "pfsubr", Pq, Qq, XX }, +Ia_pi2fd_Pq_Qq = { "pi2fd", "pi2fd", Pq, Qq, XX }, +Ia_pi2fw_Pq_Qq = { "pi2fw", "pi2fw", Pq, Qq, XX }, +Ia_pinsrw_Pq_Ed_Ib = { "pinsrw", "pinsrw", Pq, Ed, Ib }, +Ia_pinsrw_Vdq_Ed_Ib = { "pinsrw", "pinsrw", Vdq, Ed, Ib }, +Ia_pmaddwd_Pq_Qq = { "pmaddwd", "pmaddwd", Pq, Qq, XX }, +Ia_pmaddwd_Vdq_Wdq = { "pmaddwd", "pmaddwd", Vdq, Wdq, XX }, +Ia_pmaxub_Pq_Qq = { "pmaxub", "pmaxub", Pq, Qq, XX }, +Ia_pmaxub_Vdq_Wdq = { "pmaxub", "pmaxub", Vdq, Wdq, XX }, +Ia_pmaxuw_Pq_Qq = { "pmaxuw", "pmaxuw", Pq, Qq, XX }, +Ia_pmaxuw_Vdq_Wdq = { "pmaxuw", "pmaxuw", Vdq, Wdq, XX }, +Ia_pminsw_Pq_Qq = { "pminsw", "pminsw", Pq, Qq, XX }, +Ia_pminsw_Vdq_Wdq = { "pminsw", "pminsw", Vdq, Wdq, XX }, +Ia_pminub_Pq_Qq = { "pminub", "pminub", Pq, Qq, XX }, +Ia_pminub_Vdq_Wdq = { "pminub", "pminub", Vdq, Wdq, XX }, +Ia_pmovmskb_Gd_Pq = { "pmovmskb", "pmovmskb", Gd, Pq, XX }, +Ia_pmovmskb_Gd_Vdq = { "pmovmskb", "pmovmskb", Gd, Vdq, XX }, +Ia_pmulhrw_Pq_Qq = { "pmulhrw", "pmulhrw", Pq, Qq, XX }, +Ia_pmulhuw_Pq_Qq = { "pmulhuw", "pmulhuw", Pq, Qq, XX }, +Ia_pmulhuw_Vdq_Wdq = { "pmulhuw", "pmulhuw", Vdq, Wdq, XX }, +Ia_pmulhw_Pq_Qq = { "pmulhw", "pmulhw", Pq, Qq, XX }, +Ia_pmulhw_Vdq_Wdq = { "pmulhw", "pmulhw", Vdq, Wdq, XX }, +Ia_pmullw_Pq_Qq = { "pmullw", "pmullw", Pq, Qq, XX }, +Ia_pmullw_Vdq_Wdq = { "pmullw", "pmullw", Vdq, Wdq, XX }, +Ia_pmuludq_Pq_Qq = { "pmuludq", "pmuludq", Pq, Qq, XX }, +Ia_pmuludq_Vdq_Wdq = { "pmuludq", "pmuludq", Vdq, Wdq, XX }, +Ia_popal = { "popad", "popal", XX, XX, XX }, +Ia_popaw = { "popa", "popa", XX, XX, XX }, +Ia_popfl = { "popfd", "popfl", XX, XX, XX }, +Ia_popfq = { "popfq", "popfq", XX, XX, XX }, +Ia_popfw = { "popf", "popf", XX, XX, XX }, +Ia_popl_DS = { "pop", "popl", DS, XX, XX }, +Ia_popl_Ed = { "pop", "popl", Ed, XX, XX }, +Ia_popl_ERX = { "pop", "popl", ERX, XX, XX }, +Ia_popl_ES = { "pop", "popl", ES, XX, XX }, +Ia_popl_FS = { "pop", "popl", FS, XX, XX }, +Ia_popl_GS = { "pop", "popl", GS, XX, XX }, +Ia_popl_SS = { "pop", "popl", SS, XX, XX }, +Ia_popq_Eq = { "pop", "popq", Eq, XX, XX }, +Ia_popq_FS = { "pop", "popq", FS, XX, XX }, +Ia_popq_GS = { "pop", "popq", GS, XX, XX }, +Ia_popq_RRX = { "pop", "popq", RRX, XX, XX }, +Ia_popw_DS = { "pop", "popw", DS, XX, XX }, +Ia_popw_ES = { "pop", "popw", ES, XX, XX }, +Ia_popw_Ew = { "pop", "popw", Ew, XX, XX }, +Ia_popw_FS = { "pop", "popw", FS, XX, XX }, +Ia_popw_GS = { "pop", "popw", GS, XX, XX }, +Ia_popw_RX = { "pop", "popw", RX, XX, XX }, +Ia_popw_SS = { "pop", "popw", SS, XX, XX }, +Ia_por_Pq_Qq = { "por", "por", Pq, Qq, XX }, +Ia_por_Vdq_Wdq = { "por", "por", Vdq, Wdq, XX }, +Ia_prefetch = { "prefetch (3dnow!)", "prefetch (3dnow!)", Mb, XX, XX }, +Ia_prefetchnta = { "prefetchnta", "prefetchnta", Mb, XX, XX }, +Ia_prefetcht0 = { "prefetcht0", "prefetcht0", Mb, XX, XX }, +Ia_prefetcht1 = { "prefetcht1", "prefetcht1", Mb, XX, XX }, +Ia_prefetcht2 = { "prefetcht2", "prefetcht2", Mb, XX, XX }, +Ia_prefix_asize = { "asize", "asize", XX, XX, XX }, +Ia_prefix_cs = { "cs", "cs", XX, XX, XX }, +Ia_prefix_ds = { "ds", "ds", XX, XX, XX }, +Ia_prefix_es = { "es", "es", XX, XX, XX }, +Ia_prefix_fs = { "fs", "fs", XX, XX, XX }, +Ia_prefix_gs = { "gs", "gs", XX, XX, XX }, +Ia_prefix_lock = { "lock", "lock", XX, XX, XX }, +Ia_prefix_osize = { "osize", "osize", XX, XX, XX }, +Ia_prefix_rep = { "rep", "rep", XX, XX, XX }, +Ia_prefix_repne = { "repne", "repne", XX, XX, XX }, +Ia_prefix_rex = { "rex", "rex", XX, XX, XX }, +Ia_prefix_ss = { "ss", "ss", XX, XX, XX }, +Ia_psadbw_Pq_Qq = { "psadbw", "psadbw", Pq, Qq, XX }, +Ia_psadbw_Vdq_Wdq = { "psadbw", "psadbw", Vdq, Wdq, XX }, +Ia_pshufd_Vdq_Wdq_Ib = { "pshufd", "pshufd", Vdq, Wdq, Ib }, +Ia_pshufhw_Vq_Wq_Ib = { "pshufhw", "pshufhw", Vq, Wq, Ib }, +Ia_pshuflw_Vq_Wq_Ib = { "pshuflw", "pshuflw", Vq, Wq, Ib }, +Ia_pshufw_Pq_Qq_Ib = { "pshufw", "pshufw", Pq, Qq, Ib }, +Ia_pslld_Pq_Ib = { "pslld", "pslld", Pq, Ib, XX }, +Ia_pslld_Pq_Qq = { "pslld", "pslld", Pq, Qq, XX }, +Ia_pslld_Vdq_Ib = { "pslld", "pslld", Vdq, Ib, XX }, +Ia_pslld_Vdq_Wdq = { "pslld", "pslld", Vdq, Wdq, XX }, +Ia_pslldq_Vdq_Ib = { "pslldq", "pslldq", Vdq, Ib, XX }, +Ia_psllq_Pq_Ib = { "psllq", "psllq", Pq, Ib, XX }, +Ia_psllq_Pq_Qq = { "psllq", "psllq", Pq, Qq, XX }, +Ia_psllq_Vdq_Ib = { "psllq", "psllq", Vdq, Ib, XX }, +Ia_psllq_Vdq_Wdq = { "psllq", "psllq", Vdq, Wdq, XX }, +Ia_psllw_Pq_Ib = { "psllw", "psllw", Pq, Ib, XX }, +Ia_psllw_Pq_Qq = { "psllw", "psllw", Pq, Qq, XX }, +Ia_psllw_Vdq_Ib = { "psllw", "psllw", Vdq, Ib, XX }, +Ia_psllw_Vdq_Wdq = { "psllw", "psllw", Vdq, Wdq, XX }, +Ia_psrad_Pq_Ib = { "psrad", "psrad", Pq, Ib, XX }, +Ia_psrad_Pq_Qq = { "psrad", "psrad", Pq, Qq, XX }, +Ia_psrad_Vdq_Ib = { "psrad", "psrad", Vdq, Ib, XX }, +Ia_psrad_Vdq_Wdq = { "psrad", "psrad", Vdq, Wdq, XX }, +Ia_psraw_Pq_Ib = { "psraw", "psraw", Pq, Ib, XX }, +Ia_psraw_Pq_Qq = { "psraw", "psraw", Pq, Qq, XX }, +Ia_psraw_Vdq_Ib = { "psraw", "psraw", Vdq, Ib, XX }, +Ia_psraw_Vdq_Wdq = { "psraw", "psraw", Vdq, Wdq, XX }, +Ia_psrld_Pq_Ib = { "psrld", "psrld", Pq, Ib, XX }, +Ia_psrld_Pq_Qq = { "psrld", "psrld", Pq, Qq, XX }, +Ia_psrld_Vdq_Ib = { "psrld", "psrld", Vdq, Ib, XX }, +Ia_psrld_Vdq_Wdq = { "psrld", "psrld", Vdq, Wdq, XX }, +Ia_psrldq_Wdq_Ib = { "psrldq", "psrldq", Wdq, Ib, XX }, +Ia_psrlq_Pq_Ib = { "psrlq", "psrlq", Pq, Ib, XX }, +Ia_psrlq_Pq_Qq = { "psrlq", "psrlq", Pq, Qq, XX }, +Ia_psrlq_Vdq_Ib = { "psrlq", "psrlq", Vdq, Ib, XX }, +Ia_psrlq_Vdq_Wdq = { "psrlq", "psrlq", Vdq, Wdq, XX }, +Ia_psrlw_Pq_Ib = { "psrlw", "psrlw", Pq, Ib, XX }, +Ia_psrlw_Pq_Qq = { "psrlw", "psrlw", Pq, Qq, XX }, +Ia_psrlw_Vdq_Ib = { "psrlw", "psrlw", Vdq, Ib, XX }, +Ia_psrlw_Vdq_Wdq = { "psrlw", "psrlw", Vdq, Wdq, XX }, +Ia_psubb_Pq_Qq = { "psubb", "psubb", Pq, Qq, XX }, +Ia_psubb_Vdq_Wdq = { "psubb", "psubb", Vdq, Wdq, XX }, +Ia_psubd_Pq_Qq = { "psubd", "psubd", Pq, Qq, XX }, +Ia_psubd_Vdq_Wdq = { "psubd", "psubd", Vdq, Wdq, XX }, +Ia_psubq_Pq_Qq = { "psubq", "psubq", Pq, Qq, XX }, +Ia_psubq_Vdq_Wdq = { "psubq", "psubq", Vdq, Wdq, XX }, +Ia_psubsb_Pq_Qq = { "psubsb", "psubsb", Pq, Qq, XX }, +Ia_psubsb_Vdq_Wdq = { "psubsb", "psubsb", Vdq, Wdq, XX }, +Ia_psubsw_Pq_Qq = { "psubsw", "psubsw", Pq, Qq, XX }, +Ia_psubsw_Vdq_Wdq = { "psubsw", "psubsw", Vdq, Wdq, XX }, +Ia_psubusb_Pq_Qq = { "psubusb", "psubusb", Pq, Qq, XX }, +Ia_psubusb_Vdq_Wdq = { "psubusb", "psubusb", Vdq, Wdq, XX }, +Ia_psubusw_Pq_Qq = { "psubusw", "psubusw", Pq, Qq, XX }, +Ia_psubusw_Vdq_Wdq = { "psubusw", "psubusw", Vdq, Wdq, XX }, +Ia_psubw_Pq_Qq = { "psubw", "psubw", Pq, Qq, XX }, +Ia_psubw_Vdq_Wdq = { "psubw", "psubw", Vdq, Wdq, XX }, +Ia_pswapd_Pq_Qq = { "pswapd", "pswapd", Pq, Qq, XX }, +Ia_punpckhbw_Pq_Qq = { "punpckhbw", "punpckhbw", Pq, Qq, XX }, +Ia_punpckhbw_Vdq_Wq = { "punpckhbw", "punpckhbw", Vdq, Wq, XX }, +Ia_punpckhdq_Pq_Qq = { "punpckhdq", "punpckhdq", Pq, Qq, XX }, +Ia_punpckhdq_Vdq_Wq = { "punpckhdq", "punpckhdq", Vdq, Wq, XX }, +Ia_punpckhqdq_Vdq_Wq = { "punpckhqdq", "punpckhqdq", Vdq, Wq, XX }, +Ia_punpckhwd_Pq_Qq = { "punpckhwd", "punpckhwd", Pq, Qq, XX }, +Ia_punpckhwd_Vdq_Wq = { "punpckhwd", "punpckhwd", Vdq, Wq, XX }, +Ia_punpcklbw_Pq_Qd = { "punpcklbw", "punpcklbw", Pq, Qd, XX }, +Ia_punpcklbw_Vdq_Wq = { "punpcklbw", "punpcklbw", Vdq, Wq, XX }, +Ia_punpckldq_Pq_Qd = { "punpckldq", "punpckldq", Pq, Qd, XX }, +Ia_punpckldq_Vdq_Wq = { "punpckldq", "punpckldq", Vdq, Wq, XX }, +Ia_punpcklqdq_Vdq_Wq = { "punpcklqdq", "punpcklqdq", Vdq, Wq, XX }, +Ia_punpcklwd_Pq_Qd = { "punpcklwd", "punpcklwd", Pq, Qd, XX }, +Ia_punpcklwd_Vdq_Wq = { "punpcklwd", "punpcklwd", Vdq, Wq, XX }, +Ia_pushal = { "pushad", "pushal", XX, XX, XX }, +Ia_pushaw = { "pusha", "pusha", XX, XX, XX }, +Ia_pushfl = { "pushfd", "pushfl", XX, XX, XX }, +Ia_pushfq = { "pushfq", "pushfq", XX, XX, XX }, +Ia_pushfw = { "pushf", "pushf", XX, XX, XX }, +Ia_pushl_CS = { "push", "pushl", CS, XX, XX }, +Ia_pushl_DS = { "push", "pushl", DS, XX, XX }, +Ia_pushl_Ed = { "push", "pushl", Ed, XX, XX }, +Ia_pushl_ERX = { "push", "pushl", ERX, XX, XX }, +Ia_pushl_ES = { "push", "pushl", ES, XX, XX }, +Ia_pushl_FS = { "push", "pushl", FS, XX, XX }, +Ia_pushl_GS = { "push", "pushl", GS, XX, XX }, +Ia_pushl_Id = { "push", "pushl", Id, XX, XX }, +Ia_pushl_sIb = { "push", "pushl", sIbd, XX, XX }, +Ia_pushl_SS = { "push", "pushl", SS, XX, XX }, +Ia_pushq_Eq = { "push", "pushq", Eq, XX, XX }, +Ia_pushq_FS = { "push", "pushq", FS, XX, XX }, +Ia_pushq_GS = { "push", "pushq", GS, XX, XX }, +Ia_pushq_RRX = { "push", "pushq", RRX, XX, XX }, +Ia_pushq_sIb = { "push", "pushq", sIbq, XX, XX }, +Ia_pushq_sId = { "push", "pushq", sIdq, XX, XX }, +Ia_pushw_CS = { "push", "pushw", CS, XX, XX }, +Ia_pushw_DS = { "push", "pushw", DS, XX, XX }, +Ia_pushw_ES = { "push", "pushw", ES, XX, XX }, +Ia_pushw_Ew = { "push", "pushw", Ew, XX, XX }, +Ia_pushw_FS = { "push", "pushw", FS, XX, XX }, +Ia_pushw_GS = { "push", "pushw", GS, XX, XX }, +Ia_pushw_Iw = { "push", "pushw", Iw, XX, XX }, +Ia_pushw_RX = { "push", "pushw", RX, XX, XX }, +Ia_pushw_sIb = { "push", "pushw", sIbw, XX, XX }, +Ia_pushw_SS = { "push", "pushw", SS, XX, XX }, +Ia_pxor_Pq_Qq = { "pxor", "pxor", Pq, Qq, XX }, +Ia_pxor_Vdq_Wdq = { "pxor", "pxor", Vdq, Wdq, XX }, +Ia_rclb_Eb_CL = { "rcl", "rclb", Eb, CL, XX }, +Ia_rclb_Eb_I1 = { "rcl", "rclb", Eb, I1, XX }, +Ia_rclb_Eb_Ib = { "rcl", "rclb", Eb, Ib, XX }, +Ia_rcll_Ed_CL = { "rcl", "rcll", Ed, CL, XX }, +Ia_rcll_Ed_I1 = { "rcl", "rcll", Ed, I1, XX }, +Ia_rcll_Ed_Ib = { "rcl", "rcll", Ed, Ib, XX }, +Ia_rclq_Eq_CL = { "rcl", "rclq", Eq, CL, XX }, +Ia_rclq_Eq_I1 = { "rcl", "rclq", Eq, I1, XX }, +Ia_rclq_Eq_Ib = { "rcl", "rclq", Eq, Ib, XX }, +Ia_rclw_Ew_CL = { "rcl", "rclw", Ew, CL, XX }, +Ia_rclw_Ew_I1 = { "rcl", "rclw", Ew, I1, XX }, +Ia_rclw_Ew_Ib = { "rcl", "rclw", Ew, Ib, XX }, +Ia_rcpps_Vps_Wps = { "rcpps", "rcpps", Vps, Wps, XX }, +Ia_rcpss_Vss_Wss = { "rcpss", "rcpss", Vss, Wss, XX }, +Ia_rcrb_Eb_CL = { "rcr", "rcrb", Eb, CL, XX }, +Ia_rcrb_Eb_I1 = { "rcr", "rcrb", Eb, I1, XX }, +Ia_rcrb_Eb_Ib = { "rcr", "rcrb", Eb, Ib, XX }, +Ia_rcrl_Ed_CL = { "rcr", "rcrl", Ed, CL, XX }, +Ia_rcrl_Ed_I1 = { "rcr", "rcrl", Ed, I1, XX }, +Ia_rcrl_Ed_Ib = { "rcr", "rcrl", Ed, Ib, XX }, +Ia_rcrq_Eq_CL = { "rcr", "rcrq", Eq, CL, XX }, +Ia_rcrq_Eq_I1 = { "rcr", "rcrq", Eq, I1, XX }, +Ia_rcrq_Eq_Ib = { "rcr", "rcrq", Eq, Ib, XX }, +Ia_rcrw_Ew_CL = { "rcr", "rcrw", Ew, CL, XX }, +Ia_rcrw_Ew_I1 = { "rcr", "rcrw", Ew, I1, XX }, +Ia_rcrw_Ew_Ib = { "rcr", "rcrw", Ew, Ib, XX }, +Ia_rdmsr = { "rdmsr", "rdmsr", XX, XX, XX }, +Ia_rdpmc = { "rdpmc", "rdpmc", XX, XX, XX }, +Ia_rdtsc = { "rdtsc", "rdtsc", XX, XX, XX }, +Ia_rdtscp = { "rdtscp", "rdtscp", XX, XX, XX }, +Ia_ret = { "ret", "ret", XX, XX, XX }, +Ia_ret_Iw = { "ret", "ret", Iw, XX, XX }, +Ia_rolb_Eb_CL = { "rol", "rolb", Eb, CL, XX }, +Ia_rolb_Eb_I1 = { "rol", "rolb", Eb, I1, XX }, +Ia_rolb_Eb_Ib = { "rol", "rolb", Eb, Ib, XX }, +Ia_roll_Ed_CL = { "rol", "roll", Ed, CL, XX }, +Ia_roll_Ed_I1 = { "rol", "roll", Ed, I1, XX }, +Ia_roll_Ed_Ib = { "rol", "roll", Ed, Ib, XX }, +Ia_rolq_Eq_CL = { "rol", "rolq", Eq, CL, XX }, +Ia_rolq_Eq_I1 = { "rol", "rolq", Eq, I1, XX }, +Ia_rolq_Eq_Ib = { "rol", "rolq", Eq, Ib, XX }, +Ia_rolw_Ew_CL = { "rol", "rolw", Ew, CL, XX }, +Ia_rolw_Ew_I1 = { "rol", "rolw", Ew, I1, XX }, +Ia_rolw_Ew_Ib = { "rol", "rolw", Ew, Ib, XX }, +Ia_rorb_Eb_CL = { "ror", "rorb", Eb, CL, XX }, +Ia_rorb_Eb_I1 = { "ror", "rorb", Eb, I1, XX }, +Ia_rorb_Eb_Ib = { "ror", "rorb", Eb, Ib, XX }, +Ia_rorl_Ed_CL = { "ror", "rorl", Ed, CL, XX }, +Ia_rorl_Ed_I1 = { "ror", "rorl", Ed, I1, XX }, +Ia_rorl_Ed_Ib = { "ror", "rorl", Ed, Ib, XX }, +Ia_rorq_Eq_CL = { "ror", "rorq", Eq, CL, XX }, +Ia_rorq_Eq_I1 = { "ror", "rorq", Eq, I1, XX }, +Ia_rorq_Eq_Ib = { "ror", "rorq", Eq, Ib, XX }, +Ia_rorw_Ew_CL = { "ror", "rorw", Ew, CL, XX }, +Ia_rorw_Ew_I1 = { "ror", "rorw", Ew, I1, XX }, +Ia_rorw_Ew_Ib = { "ror", "rorw", Ew, Ib, XX }, +Ia_rsm = { "rsm", "rsm", XX, XX, XX }, +Ia_rsqrtps_Vps_Wps = { "rsqrtps", "rsqrtps", Vps, Wps, XX }, +Ia_rsqrtss_Vss_Wss = { "rsqrtss", "rsqrtss", Vss, Wss, XX }, +Ia_sahf = { "sahf", "sahf", XX, XX, XX }, +Ia_salc = { "salc", "salc", XX, XX, XX }, +Ia_sarb_Eb_CL = { "sar", "sarb", Eb, CL, XX }, +Ia_sarb_Eb_I1 = { "sar", "sarb", Eb, I1, XX }, +Ia_sarb_Eb_Ib = { "sar", "sarb", Eb, Ib, XX }, +Ia_sarl_Ed_CL = { "sar", "sarl", Ed, CL, XX }, +Ia_sarl_Ed_I1 = { "sar", "sarl", Ed, I1, XX }, +Ia_sarl_Ed_Ib = { "sar", "sarl", Ed, Ib, XX }, +Ia_sarq_Eq_CL = { "sar", "sarq", Eq, CL, XX }, +Ia_sarq_Eq_I1 = { "sar", "sarq", Eq, I1, XX }, +Ia_sarq_Eq_Ib = { "sar", "sarq", Eq, Ib, XX }, +Ia_sarw_Ew_CL = { "sar", "sarw", Ew, CL, XX }, +Ia_sarw_Ew_I1 = { "sar", "sarw", Ew, I1, XX }, +Ia_sarw_Ew_Ib = { "sar", "sarw", Ew, Ib, XX }, +Ia_sbbb_AL_Ib = { "sbb", "sbbb", AL, Ib, XX }, +Ia_sbbb_Eb_Gb = { "sbb", "sbbb", Eb, Gb, XX }, +Ia_sbbb_Eb_Ib = { "sbb", "sbbb", Eb, Ib, XX }, +Ia_sbbb_Gb_Eb = { "sbb", "sbbb", Gb, Eb, XX }, +Ia_sbbl_EAX_Id = { "sbb", "sbbl", EAX, Id, XX }, +Ia_sbbl_Ed_Gd = { "sbb", "sbbl", Ed, Gd, XX }, +Ia_sbbl_Ed_Id = { "sbb", "sbbl", Ed, Id, XX }, +Ia_sbbl_Ed_sIb = { "sbb", "sbbl", Ed, sIbd, XX }, +Ia_sbbl_Gd_Ed = { "sbb", "sbbl", Gd, Ed, XX }, +Ia_sbbq_Eq_Gq = { "sbb", "sbbq", Eq, Gq, XX }, +Ia_sbbq_Eq_sIb = { "sbb", "sbbq", Eq, sIbq, XX }, +Ia_sbbq_Eq_sId = { "sbb", "sbbq", Eq, sIdq, XX }, +Ia_sbbq_Gq_Eq = { "sbb", "sbbq", Gq, Eq, XX }, +Ia_sbbq_RAX_sId = { "sbb", "sbbq", RAX, sIdq, XX }, +Ia_sbbw_AX_Iw = { "sbb", "sbbw", AX, Iw, XX }, +Ia_sbbw_Ew_Gw = { "sbb", "sbbw", Ew, Gw, XX }, +Ia_sbbw_Ew_Iw = { "sbb", "sbbw", Ew, Iw, XX }, +Ia_sbbw_Ew_sIb = { "sbb", "sbbw", Ew, sIbw, XX }, +Ia_sbbw_Gw_Ew = { "sbb", "sbbw", Gw, Ew, XX }, +Ia_scasb_Yb_AL = { "scasb", "scasb", Yb, AL, XX }, +Ia_scasl_Yd_EAX = { "scasd", "scasl", Yd, EAX, XX }, +Ia_scasq_Yq_RAX = { "scasq", "scasq", Yq, RAX, XX }, +Ia_scasw_Yw_AX = { "scasw", "scasw", Yw, AX, XX }, +Ia_setb_Eb = { "setb", "setb", Eb, XX, XX }, +Ia_setbe_Eb = { "setbe", "setbe", Eb, XX, XX }, +Ia_setl_Eb = { "setl", "setl", Eb, XX, XX }, +Ia_setle_Eb = { "setle", "setle", Eb, XX, XX }, +Ia_setnb_Eb = { "setnb", "setnb", Eb, XX, XX }, +Ia_setnbe_Eb = { "setnbe", "setnbe", Eb, XX, XX }, +Ia_setnl_Eb = { "setnl", "setnl", Eb, XX, XX }, +Ia_setnle_Eb = { "setnle", "setnle", Eb, XX, XX }, +Ia_setno_Eb = { "setno", "setno", Eb, XX, XX }, +Ia_setnp_Eb = { "setnp", "setnp", Eb, XX, XX }, +Ia_setns_Eb = { "setns", "setns", Eb, XX, XX }, +Ia_setnz_Eb = { "setnz", "setnz", Eb, XX, XX }, +Ia_seto_Eb = { "seto", "seto", Eb, XX, XX }, +Ia_setp_Eb = { "setp", "setp", Eb, XX, XX }, +Ia_sets_Eb = { "sets", "sets", Eb, XX, XX }, +Ia_setz_Eb = { "setz", "setz", Eb, XX, XX }, +Ia_sfence = { "sfence", "sfence", XX, XX, XX }, +Ia_sgdt = { "sgdt", "sgdt", Ms, XX, XX }, +Ia_shlb_Eb_CL = { "shl", "shlb", Eb, CL, XX }, +Ia_shlb_Eb_I1 = { "shl", "shlb", Eb, I1, XX }, +Ia_shlb_Eb_Ib = { "shl", "shlb", Eb, Ib, XX }, +Ia_shldl_Ed_Gd_CL = { "shld", "shldl", Ed, Gd, CL }, +Ia_shldl_Ed_Gd_Ib = { "shld", "shldl", Ed, Gd, Ib }, +Ia_shldq_Eq_Gq_CL = { "shld", "shldq", Eq, Gq, CL }, +Ia_shldq_Eq_Gq_Ib = { "shld", "shldq", Eq, Gq, Ib }, +Ia_shldw_Ew_Gw_CL = { "shld", "shldw", Ew, Gw, CL }, +Ia_shldw_Ew_Gw_Ib = { "shld", "shldw", Ew, Gw, Ib }, +Ia_shll_Ed_CL = { "shl", "shll", Ed, CL, XX }, +Ia_shll_Ed_I1 = { "shl", "shll", Ed, I1, XX }, +Ia_shll_Ed_Ib = { "shl", "shll", Ed, Ib, XX }, +Ia_shlq_Eq_CL = { "shl", "shlq", Eq, CL, XX }, +Ia_shlq_Eq_I1 = { "shl", "shlq", Eq, I1, XX }, +Ia_shlq_Eq_Ib = { "shl", "shlq", Eq, Ib, XX }, +Ia_shlw_Ew_CL = { "shl", "shlw", Ew, CL, XX }, +Ia_shlw_Ew_I1 = { "shl", "shlw", Ew, I1, XX }, +Ia_shlw_Ew_Ib = { "shl", "shlw", Ew, Ib, XX }, +Ia_shrb_Eb_CL = { "shr", "shrb", Eb, CL, XX }, +Ia_shrb_Eb_I1 = { "shr", "shrb", Eb, I1, XX }, +Ia_shrb_Eb_Ib = { "shr", "shrb", Eb, Ib, XX }, +Ia_shrdl_Ed_Gd_CL = { "shrd", "shrdl", Ed, Gd, CL }, +Ia_shrdl_Ed_Gd_Ib = { "shrd", "shrdl", Ed, Gd, Ib }, +Ia_shrdq_Eq_Gq_CL = { "shrd", "shrdq", Eq, Gq, CL }, +Ia_shrdq_Eq_Gq_Ib = { "shrd", "shrdq", Eq, Gq, Ib }, +Ia_shrdw_Ew_Gw_CL = { "shrd", "shrdw", Ew, Gw, CL }, +Ia_shrdw_Ew_Gw_Ib = { "shrd", "shrdw", Ew, Gw, Ib }, +Ia_shrl_Ed_CL = { "shr", "shrl", Ed, CL, XX }, +Ia_shrl_Ed_I1 = { "shr", "shrl", Ed, I1, XX }, +Ia_shrl_Ed_Ib = { "shr", "shrl", Ed, Ib, XX }, +Ia_shrq_Eq_CL = { "shr", "shrq", Eq, CL, XX }, +Ia_shrq_Eq_I1 = { "shr", "shrq", Eq, I1, XX }, +Ia_shrq_Eq_Ib = { "shr", "shrq", Eq, Ib, XX }, +Ia_shrw_Ew_CL = { "shr", "shrw", Ew, CL, XX }, +Ia_shrw_Ew_I1 = { "shr", "shrw", Ew, I1, XX }, +Ia_shrw_Ew_Ib = { "shr", "shrw", Ew, Ib, XX }, +Ia_shufpd_Vpd_Wpd_Ib = { "shufpd", "shufpd", Vpd, Wpd, Ib }, +Ia_shufps_Vps_Wps_Ib = { "shufps", "shufps", Vps, Wps, Ib }, +Ia_sidt = { "sidt", "sidt", Ms, XX, XX }, +Ia_sldt = { "sldt", "sldt", Ew, XX, XX }, +Ia_smsw_Ew = { "smsw", "smsw", Ew, XX, XX }, +Ia_sqrtpd_Vpd_Wpd = { "sqrtpd", "sqrtpd", Vpd, Wpd, XX }, +Ia_sqrtps_Vps_Wps = { "sqrtps", "sqrtps", Vps, Wps, XX }, +Ia_sqrtsd_Vsd_Wsd = { "sqrtsd", "sqrtsd", Vsd, Wsd, XX }, +Ia_sqrtss_Vss_Wss = { "sqrtss", "sqrtss", Vss, Wss, XX }, +Ia_stc = { "stc", "stc", XX, XX, XX }, +Ia_std = { "std", "std", XX, XX, XX }, +Ia_sti = { "sti", "sti", XX, XX, XX }, +Ia_stmxcsr = { "stmxcsr", "stmxcsr", Md, XX, XX }, +Ia_stosb_Yb_AL = { "stosb", "stosb", Yb, AL, XX }, +Ia_stosl_Yd_EAX = { "stosd", "stosl", Yd, EAX, XX }, +Ia_stosq_Yq_RAX = { "stosq", "stosq", Yq, RAX, XX }, +Ia_stosw_Yw_AX = { "stosw", "stosw", Yw, AX, XX }, +Ia_str = { "str", "str", Ew, XX, XX }, +Ia_subb_AL_Ib = { "sub", "subb", AL, Ib, XX }, +Ia_subb_Eb_Gb = { "sub", "subb", Eb, Gb, XX }, +Ia_subb_Eb_Ib = { "sub", "subb", Eb, Ib, XX }, +Ia_subb_Gb_Eb = { "sub", "subb", Gb, Eb, XX }, +Ia_subl_EAX_Id = { "sub", "subl", EAX, Id, XX }, +Ia_subl_Ed_Gd = { "sub", "subl", Ed, Gd, XX }, +Ia_subl_Ed_Id = { "sub", "subl", Ed, Id, XX }, +Ia_subl_Ed_sIb = { "sub", "subl", Ed, sIbd, XX }, +Ia_subl_Gd_Ed = { "sub", "subl", Gd, Ed, XX }, +Ia_subpd_Vpd_Wpd = { "subpd", "subpd", Vpd, Wpd, XX }, +Ia_subps_Vps_Wps = { "subps", "subps", Vps, Wps, XX }, +Ia_subq_Eq_Gq = { "sub", "subq", Eq, Gq, XX }, +Ia_subq_Eq_sIb = { "sub", "subq", Eq, sIbq, XX }, +Ia_subq_Eq_sId = { "sub", "subq", Eq, sIdq, XX }, +Ia_subq_Gq_Eq = { "sub", "subq", Gq, Eq, XX }, +Ia_subq_RAX_sId = { "sub", "subq", RAX, sIdq, XX }, +Ia_subsd_Vsd_Wsd = { "subsd", "subsd", Vsd, Wsd, XX }, +Ia_subss_Vss_Wss = { "subss", "subss", Vss, Wss, XX }, +Ia_subw_AX_Iw = { "sub", "subw", AX, Iw, XX }, +Ia_subw_Ew_Gw = { "sub", "subw", Ew, Gw, XX }, +Ia_subw_Ew_Iw = { "sub", "subw", Ew, Iw, XX }, +Ia_subw_Ew_sIb = { "sub", "subw", Ew, sIbw, XX }, +Ia_subw_Gw_Ew = { "sub", "subw", Gw, Ew, XX }, +Ia_swapgs = { "swapgs", "swapgs", XX, XX, XX }, +Ia_syscall = { "syscall", "syscall", XX, XX, XX }, +Ia_sysenter = { "sysenter", "sysenter", XX, XX, XX }, +Ia_sysexit = { "sysexit", "sysexit", XX, XX, XX }, +Ia_sysret = { "sysret", "sysret", XX, XX, XX }, +Ia_testb_AL_Ib = { "testS", "testb", AL, Ib, XX }, +Ia_testb_Eb_Gb = { "test", "testb", Eb, Gb, XX }, +Ia_testb_Eb_Ib = { "test", "testb", Eb, Ib, XX }, +Ia_testl_EAX_Id = { "test", "testl", EAX, Id, XX }, +Ia_testl_Ed_Gd = { "test", "testl", Ed, Gd, XX }, +Ia_testl_Ed_Id = { "test", "testl", Ed, Id, XX }, +Ia_testq_Eq_Gq = { "test", "testq", Eq, Gq, XX }, +Ia_testq_Eq_sId = { "test", "testq", Eq, sIdq, XX }, +Ia_testq_RAX_sId = { "test", "testq", RAX, sIdq, XX }, +Ia_testw_AX_Iw = { "testS", "testw", AX, Iw, XX }, +Ia_testw_Ew_Gw = { "test", "testw", Ew, Gw, XX }, +Ia_testw_Ew_Iw = { "test", "testw", Ew, Iw, XX }, +Ia_ucomisd_Vsd_Wss = { "ucomisd", "ucomisd", Vsd, Wsd, XX }, +Ia_ucomiss_Vss_Wss = { "ucomiss", "ucomiss", Vss, Wss, XX }, +Ia_ud2a = { "ud2a", "ud2a", XX, XX, XX }, +Ia_ud2b = { "ud2b", "ud2b", XX, XX, XX }, +Ia_unpckhpd_Vpd_Wq = { "unpckhpd", "unpckhpd", Vpd, Wq, XX }, +Ia_unpckhps_Vps_Wq = { "unpckhps", "unpckhps", Vps, Wq, XX }, +Ia_unpcklpd_Vpd_Wq = { "unpcklpd", "unpcklpd", Vpd, Wq, XX }, +Ia_unpcklps_Vps_Wq = { "unpcklps", "unpcklps", Vps, Wq, XX }, +Ia_verr = { "verr", "verr", Ew, XX, XX }, +Ia_verw = { "verw", "verw", Ew, XX, XX }, +Ia_wbinvd = { "wbinvd", "wbinvd", XX, XX, XX }, +Ia_wrmsr = { "wrmsr", "wrmsr", XX, XX, XX }, +Ia_xaddb_Eb_Gb = { "xadd", "xaddb", Eb, Gb, XX }, +Ia_xaddl_Ed_Gd = { "xadd", "xaddl", Ed, Gd, XX }, +Ia_xaddq_Eq_Gq = { "xadd", "xaddq", Eq, Gq, XX }, +Ia_xaddw_Ew_Gw = { "xadd", "xaddw", Ew, Gw, XX }, +Ia_xchgb_Eb_Gb = { "xchg", "xchgb", Eb, Gb, XX }, +Ia_xchgl_Ed_Gd = { "xchg", "xchgl", Ed, Gd, XX }, +Ia_xchgl_ERX_EAX = { "xchg", "xchgl", ERX, EAX, XX }, +Ia_xchgq_Eq_Gq = { "xchg", "xchgq", Eq, Gq, XX }, +Ia_xchgq_RRX_RAX = { "xchg", "xchgq", RRX, RAX, XX }, +Ia_xchgw_Ew_Gw = { "xchg", "xchgw", Ew, Gw, XX }, +Ia_xchgw_RX_AX = { "xchg", "xchgw", RX, AX, XX }, +Ia_xlat = { "xlat", "xlat", XX, XX, XX }, +Ia_xorb_AL_Ib = { "xor", "xorb", AL, Ib, XX }, +Ia_xorb_Eb_Gb = { "xor", "xorb", Eb, Gb, XX }, +Ia_xorb_Eb_Ib = { "xor", "xorb", Eb, Ib, XX }, +Ia_xorb_Gb_Eb = { "xor", "xorb", Gb, Eb, XX }, +Ia_xorl_EAX_Id = { "xor", "xorl", EAX, Id, XX }, +Ia_xorl_Ed_Gd = { "xor", "xorl", Ed, Gd, XX }, +Ia_xorl_Ed_Id = { "xor", "xorl", Ed, Id, XX }, +Ia_xorl_Ed_sIb = { "xor", "xorl", Ed, sIbd, XX }, +Ia_xorl_Gd_Ed = { "xor", "xorl", Gd, Ed, XX }, +Ia_xorpd_Vpd_Wpd = { "xorpd", "xorpd", Vpd, Wpd, XX }, +Ia_xorps_Vps_Wps = { "xorps", "xorps", Vps, Wps, XX }, +Ia_xorq_Eq_Gq = { "xor", "xorq", Eq, Gq, XX }, +Ia_xorq_Eq_sIb = { "xor", "xorq", Eq, sIbq, XX }, +Ia_xorq_Eq_sId = { "xor", "xorq", Eq, sIdq, XX }, +Ia_xorq_Gq_Eq = { "xor", "xorq", Gq, Eq, XX }, +Ia_xorq_RAX_sId = { "xor", "xorq", RAX, sIdq, XX }, +Ia_xorw_AX_Iw = { "xor", "xorw", AX, Iw, XX }, +Ia_xorw_Ew_Gw = { "xor", "xorw", Ew, Gw, XX }, +Ia_xorw_Ew_Iw = { "xor", "xorw", Ew, Iw, XX }, +Ia_xorw_Ew_sIb = { "xor", "xorw", Ew, sIbw, XX }, +Ia_xorw_Gw_Ew = { "xor", "xorw", Gw, Ew, XX }; diff --git a/bochs/disasm/resolve.cc b/bochs/disasm/resolve.cc index e04e6d01e..114b830b3 100755 --- a/bochs/disasm/resolve.cc +++ b/bochs/disasm/resolve.cc @@ -1,188 +1,305 @@ #include #include "disasm.h" -void disassembler::decode_modrm() +void disassembler::decode_modrm(x86_insn *insn) { - modrm = fetch_byte(); - BX_DECODE_MODRM(modrm, mod, nnn, rm); + insn->modrm = fetch_byte(); + BX_DECODE_MODRM(insn->modrm, insn->mod, insn->nnn, insn->rm); + insn->nnn |= insn->rex_r; - if (as_32) + if (insn->mod == 3) { + /* mod, reg, reg */ + insn->rm |= insn->rex_b; + return; + } + + if (insn->as_64) { - /* use 32bit addressing modes. orthogonal base & index registers, - scaling available, etc. */ - if (mod == 3) { - /* mod, reg, reg */ - return; - } - else { /* mod != 3 */ - if (rm != 4) { /* rm != 100b, no s-i-b byte */ + if (insn->rm != 4) { /* rm != 100b, no s-i-b byte */ + insn->rm |= insn->rex_b; // one byte modrm - switch (mod) { + switch (insn->mod) { case 0: - resolve_modrm = &disassembler::resolve32_mod0; - if (rm == 5) /* no reg, 32-bit displacement */ - displacement.displ32 = fetch_dword(); + resolve_modrm = &disassembler::resolve64_mod0; + if (insn->rm == 5) /* no reg, 32-bit displacement */ + insn->displacement.displ32 = fetch_dword(); break; case 1: /* reg, 8-bit displacement, sign extend */ - resolve_modrm = &disassembler::resolve32_mod1or2; - displacement.displ32 = (Bit8s) fetch_byte(); + resolve_modrm = &disassembler::resolve64_mod1or2; + insn->displacement.displ32 = (Bit8s) fetch_byte(); break; case 2: /* reg, 32-bit displacement */ - resolve_modrm = &disassembler::resolve32_mod1or2; - displacement.displ32 = fetch_dword(); + resolve_modrm = &disassembler::resolve64_mod1or2; + insn->displacement.displ32 = fetch_dword(); break; } /* switch (mod) */ } /* if (rm != 4) */ else { /* rm == 4, s-i-b byte follows */ - sib = fetch_byte(); - BX_DECODE_SIB(sib, scale, sib_index, sib_base); + insn->sib = fetch_byte(); + BX_DECODE_SIB(insn->sib, insn->scale, insn->index, insn->base); - switch (mod) { + switch (insn->mod) { case 0: - resolve_modrm = &disassembler::resolve32_mod0_rm4; - if (sib_base == 5) - displacement.displ32 = fetch_dword(); + resolve_modrm = &disassembler::resolve64_mod0_rm4; + if (insn->base == 5) + insn->displacement.displ32 = fetch_dword(); break; case 1: - resolve_modrm = &disassembler::resolve32_mod1or2_rm4; - displacement.displ32 = (Bit8s) fetch_byte(); + resolve_modrm = &disassembler::resolve64_mod1or2_rm4; + insn->displacement.displ32 = (Bit8s) fetch_byte(); break; case 2: - resolve_modrm = &disassembler::resolve32_mod1or2_rm4; - displacement.displ32 = fetch_dword(); + resolve_modrm = &disassembler::resolve64_mod1or2_rm4; + insn->displacement.displ32 = fetch_dword(); break; } } /* s-i-b byte follows */ - } /* if (mod != 3) */ } - else { - /* 16 bit addressing modes. */ - switch (mod) { - case 0: - resolve_modrm = &disassembler::resolve16_mod0; - if(rm == 6) - displacement.displ16 = fetch_word(); - break; - case 1: - /* reg, 8-bit displacement, sign extend */ - resolve_modrm = &disassembler::resolve16_mod1or2; - displacement.displ16 = (Bit8s) fetch_byte(); - break; - case 2: - resolve_modrm = &disassembler::resolve16_mod1or2; - displacement.displ16 = fetch_word(); - break; - case 3: - /* mod, reg, reg */ - return; + else + { + if (insn->as_32) + { + if (insn->rm != 4) { /* rm != 100b, no s-i-b byte */ + insn->rm |= insn->rex_b; + // one byte modrm + switch (insn->mod) { + case 0: + resolve_modrm = &disassembler::resolve32_mod0; + if (insn->rm == 5) /* no reg, 32-bit displacement */ + insn->displacement.displ32 = fetch_dword(); + break; + case 1: + /* reg, 8-bit displacement, sign extend */ + resolve_modrm = &disassembler::resolve32_mod1or2; + insn->displacement.displ32 = (Bit8s) fetch_byte(); + break; + case 2: + /* reg, 32-bit displacement */ + resolve_modrm = &disassembler::resolve32_mod1or2; + insn->displacement.displ32 = fetch_dword(); + break; + } /* switch (mod) */ + } /* if (rm != 4) */ + else { /* rm == 4, s-i-b byte follows */ + insn->sib = fetch_byte(); + BX_DECODE_SIB(insn->sib, insn->scale, insn->index, insn->base); + insn->base |= insn->rex_b; + insn->index |= insn->rex_x; - } /* switch (mod) ... */ + switch (insn->mod) { + case 0: + resolve_modrm = &disassembler::resolve32_mod0_rm4; + if (insn->base == 5) + insn->displacement.displ32 = fetch_dword(); + break; + case 1: + resolve_modrm = &disassembler::resolve32_mod1or2_rm4; + insn->displacement.displ32 = (Bit8s) fetch_byte(); + break; + case 2: + resolve_modrm = &disassembler::resolve32_mod1or2_rm4; + insn->displacement.displ32 = fetch_dword(); + break; + } + } /* s-i-b byte follows */ + } + else { + /* 16 bit addressing modes. */ + switch (insn->mod) { + case 0: + resolve_modrm = &disassembler::resolve16_mod0; + if(insn->rm == 6) + insn->displacement.displ16 = fetch_word(); + break; + case 1: + /* reg, 8-bit displacement, sign extend */ + resolve_modrm = &disassembler::resolve16_mod1or2; + insn->displacement.displ16 = (Bit8s) fetch_byte(); + break; + case 2: + resolve_modrm = &disassembler::resolve16_mod1or2; + insn->displacement.displ16 = fetch_word(); + break; + } /* switch (mod) ... */ + } } } -void disassembler::resolve16_mod0(unsigned mode) +void disassembler::resolve16_mod0(const x86_insn *insn, unsigned mode) { const char *seg; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else - seg = sreg_mod00_rm16[rm]; + seg = sreg_mod00_rm16[insn->rm]; - if(rm == 6) - print_memory_access16(mode, seg, NULL, displacement.displ16); + if(insn->rm == 6) + print_memory_access16(mode, seg, NULL, insn->displacement.displ16); else - print_memory_access16(mode, seg, index16[rm], 0); + print_memory_access16(mode, seg, index16[insn->rm], 0); } -void disassembler::resolve16_mod1or2(unsigned mode) +void disassembler::resolve16_mod1or2(const x86_insn *insn, unsigned mode) { const char *seg; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else - seg = sreg_mod01or10_rm16[rm]; + seg = sreg_mod01or10_rm16[insn->rm]; - print_memory_access16(mode, seg, index16[rm], displacement.displ16); + print_memory_access16(mode, seg, index16[insn->rm], insn->displacement.displ16); } -void disassembler::resolve32_mod0(unsigned mode) +void disassembler::resolve32_mod0(const x86_insn *insn, unsigned mode) { const char *seg; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else seg = segment_name[DS_REG]; - if (rm == 5) /* no reg, 32-bit displacement */ - print_memory_access32(mode, seg, NULL, NULL, 0, displacement.displ32); + if (insn->rm == 5) /* no reg, 32-bit displacement */ + print_memory_access(mode, seg, NULL, NULL, 0, insn->displacement.displ32); else - print_memory_access32(mode, seg, general_32bit_regname[rm], NULL, 0, 0); + print_memory_access(mode, seg, general_32bit_regname[insn->rm], NULL, 0, 0); } -void disassembler::resolve32_mod1or2(unsigned mode) +void disassembler::resolve32_mod1or2(const x86_insn *insn, unsigned mode) { const char *seg; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else - seg = sreg_mod01or10_rm32[rm]; + seg = sreg_mod01or10_rm32[insn->rm]; - print_memory_access32(mode, seg, - general_32bit_regname[rm], NULL, 0, displacement.displ32); + print_memory_access(mode, seg, + general_32bit_regname[insn->rm], NULL, 0, insn->displacement.displ32); } -void disassembler::resolve32_mod0_rm4(unsigned mode) +void disassembler::resolve32_mod0_rm4(const x86_insn *insn, unsigned mode) { const char *seg, *base = NULL, *index = NULL; Bit32u disp32 = 0; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else - seg = sreg_mod00_base32[sib_base]; + seg = sreg_mod00_base32[insn->base]; - if (sib_base != 5) - base = general_32bit_regname[sib_base]; + if (insn->base != 5) + base = general_32bit_regname[insn->base]; else - disp32 = displacement.displ32; + disp32 = insn->displacement.displ32; - if (sib_index != 4) + if (insn->index != 4) { - index = general_32bit_regname[sib_index]; + index = general_32bit_regname[insn->index]; } - print_memory_access32(mode, seg, base, index, scale, disp32); + print_memory_access(mode, seg, base, index, insn->scale, disp32); } -void disassembler::resolve32_mod1or2_rm4(unsigned mode) +void disassembler::resolve32_mod1or2_rm4(const x86_insn *insn, unsigned mode) { const char *seg, *index = NULL; - if (seg_override) - seg = seg_override; + if (insn->seg_override) + seg = segment_name[insn->seg_override]; else - seg = sreg_mod01or10_base32[sib_base]; + seg = sreg_mod01or10_base32[insn->base]; - if (sib_index != 4) + if (insn->index != 4) { - index = general_32bit_regname[sib_index]; + index = general_32bit_regname[insn->index]; } - print_memory_access32(mode, seg, - general_32bit_regname[sib_base], index, scale, displacement.displ32); + print_memory_access(mode, seg, + general_32bit_regname[insn->base], index, insn->scale, insn->displacement.displ32); } -void disassembler::print_datasize(unsigned mode) +void disassembler::resolve64_mod0(const x86_insn *insn, unsigned mode) +{ + const char *seg, *rip_regname; + + if (insn->seg_override) + seg = segment_name[insn->seg_override]; + else + seg = segment_name[DS_REG]; + + if (intel_mode) rip_regname = "rip"; + else rip_regname = "%rip"; + + if (insn->rm == 5) /* no reg, 32-bit displacement */ + print_memory_access(mode, seg, rip_regname, NULL, 0, insn->displacement.displ32); + else + print_memory_access(mode, seg, general_64bit_regname[insn->rm], NULL, 0, 0); +} + +void disassembler::resolve64_mod1or2(const x86_insn *insn, unsigned mode) +{ + const char *seg; + + if (insn->seg_override) + seg = segment_name[insn->seg_override]; + else + seg = sreg_mod01or10_rm32[insn->rm]; + + print_memory_access(mode, seg, + general_64bit_regname[insn->rm], NULL, 0, insn->displacement.displ32); +} + +void disassembler::resolve64_mod0_rm4(const x86_insn *insn, unsigned mode) +{ + const char *seg, *base = NULL, *index = NULL; + Bit32u disp32 = 0; + + if (insn->seg_override) + seg = segment_name[insn->seg_override]; + else + seg = sreg_mod00_base32[insn->base]; + + if (insn->base != 5) + base = general_64bit_regname[insn->base]; + else + disp32 = insn->displacement.displ32; + + if (insn->index != 4) + { + index = general_64bit_regname[insn->index]; + } + + print_memory_access(mode, seg, base, index, insn->scale, disp32); +} + +void disassembler::resolve64_mod1or2_rm4(const x86_insn *insn, unsigned mode) +{ + const char *seg, *index = NULL; + + if (insn->seg_override) + seg = segment_name[insn->seg_override]; + else + seg = sreg_mod01or10_base32[insn->base]; + + if (insn->index != 4) + { + index = general_64bit_regname[insn->index]; + } + + print_memory_access(mode, seg, + general_64bit_regname[insn->base], index, insn->scale, insn->displacement.displ32); +} + +void disassembler::print_datasize(unsigned size) { if (!intel_mode) return; - switch(mode) + switch(size) { case B_SIZE: dis_sprintf("byte ptr "); @@ -193,12 +310,6 @@ void disassembler::print_datasize(unsigned mode) case D_SIZE: dis_sprintf("dword ptr "); break; - case V_SIZE: - if (os_32) - dis_sprintf("dword ptr "); - else - dis_sprintf("word ptr "); - break; case Q_SIZE: dis_sprintf("qword ptr "); break; @@ -210,8 +321,6 @@ void disassembler::print_datasize(unsigned mode) break; case P_SIZE: break; - case S_SIZE: - break; case X_SIZE: break; }; @@ -252,7 +361,7 @@ void disassembler::print_memory_access16(int datasize, } } -void disassembler::print_memory_access32(int datasize, +void disassembler::print_memory_access(int datasize, const char *seg, const char *base, const char *index, int scale, Bit32u disp) { print_datasize(datasize); diff --git a/bochs/disasm/syntax.cc b/bochs/disasm/syntax.cc index 8887cf009..39e652896 100755 --- a/bochs/disasm/syntax.cc +++ b/bochs/disasm/syntax.cc @@ -5,7 +5,9 @@ // Intel STYLE ////////////////// -#if BX_DISASM_SUPPORT_X86_64 +#define BX_DISASM_SUPPORT_X86_64 + +#ifdef BX_DISASM_SUPPORT_X86_64 static const char *intel_general_16bit_regname[16] = { "ax", "cx", "dx", "bx", "sp", "bp", "si", "di", @@ -63,7 +65,7 @@ static const char *intel_index16[8] = { // AT&T STYLE ////////////////// -#if BX_DISASM_SUPPORT_X86_64 +#ifdef BX_DISASM_SUPPORT_X86_64 static const char *att_general_16bit_regname[16] = { "%ax", "%cx", "%dx", "%bx", "%sp", "%bp", "%si", "%di", @@ -177,10 +179,8 @@ void disassembler::set_syntax_intel() general_16bit_regname = intel_general_16bit_regname; general_8bit_regname = intel_general_8bit_regname; general_32bit_regname = intel_general_32bit_regname; -#if BX_DISASM_SUPPORT_X86_64 general_8bit_regname_rex = intel_general_8bit_regname_rex; general_64bit_regname = intel_general_64bit_regname; -#endif segment_name = intel_segment_name; index16 = intel_index16; @@ -188,56 +188,21 @@ void disassembler::set_syntax_intel() initialize_modrm_segregs(); } -void disassembler::print_disassembly_intel(const BxDisasmOpcodeInfo_t *entry) +void disassembler::print_disassembly_intel(const x86_insn *insn, const BxDisasmOpcodeInfo_t *entry) { // print opcode - dis_sprintf("%s", entry->Opcode); - - // patch opcode - disbufptr --; - - switch(*disbufptr) { - case 'B': - case 'W': - case 'V': - case 'L': - case 'Q': - case 'T': - break; - - case 'X': // movsx or movzx - dis_putc('x'); - break; - - case 'S': // string - if (os_32) - dis_putc('d'); - else - dis_putc('w'); - break; - - case 'D': - if (os_32) - dis_putc('d'); - break; - - default: - disbufptr ++; - break; - } - - dis_putc(' '); + dis_sprintf("%s ", entry->IntelOpcode); if (entry->Operand1) { - (this->*entry->Operand1)(entry->Op1Attr); + (this->*entry->Operand1)(insn); } if (entry->Operand2) { dis_sprintf(", "); - (this->*entry->Operand2)(entry->Op2Attr); + (this->*entry->Operand2)(insn); } if (entry->Operand3) { dis_sprintf(", "); - (this->*entry->Operand3)(entry->Op3Attr); + (this->*entry->Operand3)(insn); } } @@ -252,10 +217,8 @@ void disassembler::set_syntax_att() general_16bit_regname = att_general_16bit_regname; general_8bit_regname = att_general_8bit_regname; general_32bit_regname = att_general_32bit_regname; -#if BX_DISASM_SUPPORT_X86_64 general_8bit_regname_rex = att_general_8bit_regname_rex; general_64bit_regname = att_general_64bit_regname; -#endif segment_name = att_segment_name; index16 = att_index16; @@ -263,91 +226,20 @@ void disassembler::set_syntax_att() initialize_modrm_segregs(); } -void disassembler::print_disassembly_att(const BxDisasmOpcodeInfo_t *entry) +void disassembler::print_disassembly_att(const x86_insn *insn, const BxDisasmOpcodeInfo_t *entry) { // print opcode - dis_sprintf("%s", entry->Opcode); - - // patch opcode - disbufptr --; - - switch(*disbufptr) { - case 'B': - dis_putc('b'); - break; - - case 'W': - dis_putc('w'); - break; - - case 'S': - case 'V': - if (os_32) - dis_putc('l'); - else - dis_putc('w'); - break; - - case 'L': - dis_putc('l'); - break; - - case 'Q': - dis_putc('q'); - break; - - case 'T': - dis_putc('t'); - break; - - case 'X': - if (entry->Op2Attr == B_SIZE) - dis_putc('b'); - else if (entry->Op2Attr == W_SIZE) - dis_putc('w'); - else if (entry->Op2Attr == D_SIZE) - dis_putc('l'); - else - printf("Internal disassembler error !\n"); - - if (entry->Op1Attr == W_SIZE) - dis_putc('w'); - else if (entry->Op1Attr == D_SIZE) - dis_putc('l'); - else if (entry->Op1Attr == Q_SIZE) - dis_putc('q'); - else if (entry->Op1Attr == V_SIZE) - { - if (os_32) - dis_putc('l'); - else - dis_putc('w'); - } - else - printf("Internal disassembler error !\n"); - break; - - case 'D': - if (os_32) - dis_putc('l'); - break; - - default: - disbufptr ++; - break; - } - - dis_putc(' '); + dis_sprintf("%s ", entry->AttOpcode); if (entry->Operand3) { - (this->*entry->Operand3)(entry->Op3Attr); + (this->*entry->Operand3)(insn); dis_sprintf(", "); } if (entry->Operand2) { - (this->*entry->Operand2)(entry->Op2Attr); + (this->*entry->Operand2)(insn); dis_sprintf(", "); } if (entry->Operand1) { - (this->*entry->Operand1)(entry->Op1Attr); + (this->*entry->Operand1)(insn); } }