6 #include "rose_config.h"
10 #include "AsmUnparser_compat.h"
22 #define BYTET (SgAsmTypeByte::createType())
23 #define WORDT (SgAsmTypeWord::createType())
24 #define DWORDT (SgAsmTypeDoubleWord::createType())
25 #define QWORDT (SgAsmTypeQuadWord::createType())
26 #define DQWORDT (SgAsmTypeDoubleQuadWord::createType())
27 #define FLOATT (SgAsmTypeSingleFloat::createType())
28 #define DOUBLET (SgAsmTypeDoubleFloat::createType())
29 #define LDOUBLET (SgAsmType80bitFloat::createType())
30 #define V8BYTET (SgAsmTypeVector::createType(8, BYTET))
31 #define V16BYTET (SgAsmTypeVector::createType(16, BYTET))
32 #define V4WORDT (SgAsmTypeVector::createType(4, WORDT))
33 #define V8WORDT (SgAsmTypeVector::createType(8, WORDT))
34 #define V2DWORDT (SgAsmTypeVector::createType(2, DWORDT))
35 #define V4DWORDT (SgAsmTypeVector::createType(4, DWORDT))
36 #define V2FLOATT (SgAsmTypeVector::createType(2, FLOATT))
37 #define V4FLOATT (SgAsmTypeVector::createType(4, FLOATT))
38 #define V2QWORDT (SgAsmTypeVector::createType(2, QWORDT))
39 #define V2DOUBLET (SgAsmTypeVector::createType(2, DOUBLET))
67 default: ROSE_ASSERT(!
"unknown x86 instruction size");
91 unsigned char temp[16];
103 successors->insert(suc2.begin(), suc2.end());
127 throw ExceptionX86(
"instruction longer than 15 bytes",
this);
146 return (hi<<16) | lo;
154 return (hi<<32) | lo;
179 default: { ROSE_ASSERT(
false);
return insnSize; }
204 default: { ROSE_ASSERT(
false);
return insnSize; }
228 throw ExceptionX86(
"bad combination of repeat prefix and operand size override",
this);
235 throw ExceptionX86(
"bad combination of repeat prefix and operand size override",
this);
240 default: { ROSE_ASSERT(
false);
return mmNone; }
248 rexW = (opcode & 8) != 0;
249 rexR = (opcode & 4) != 0;
250 rexX = (opcode & 2) != 0;
251 rexB = (opcode & 1) != 0;
261 default: { ROSE_ASSERT(
false);
return rmWord; }
273 default: { abort();
return NULL; }
328 ROSE_ASSERT((!op1 && !op2 && !op3 && !op4) ||
329 ( op1 && !op2 && !op3 && !op4) ||
330 ( op1 && op2 && !op3 && !op4) ||
331 ( op1 && op2 && op3 && !op4) ||
332 ( op1 && op2 && op3 && op4));
349 const char *
name = NULL;
358 ROSE_ASSERT(rdesc!=NULL);
367 return makeRegister((rexExtension ? 8 : 0) + registerNumber,
374 return makeRegister((rexExtension ? 8 : 0) + registerNumber,
398 static const char* regnames8l[16] = {
399 "al",
"cl",
"dl",
"bl",
"spl",
"bpl",
"sil",
"dil",
"r8b",
"r9b",
"r10b",
"r11b",
"r12b",
"r13b",
"r14b",
"r15b"
401 static const char* regnames8h[4] = {
402 "ah",
"ch",
"dh",
"bh"
404 static const char* regnames16[16] = {
405 "ax",
"cx",
"dx",
"bx",
"sp",
"bp",
"si",
"di",
"r8w",
"r9w",
"r10w",
"r11w",
"r12w",
"r13w",
"r14w",
"r15w"
407 static const char* regnames32[16] = {
408 "eax",
"ecx",
"edx",
"ebx",
"esp",
"ebp",
"esi",
"edi",
"r8d",
"r9d",
"r10d",
"r11d",
"r12d",
"r13d",
"r14d",
"r15d"
410 static const char* regnames64[16] = {
411 "rax",
"rcx",
"rdx",
"rbx",
"rsp",
"rbp",
"rsi",
"rdi",
"r8",
"r9",
"r10",
"r11",
"r12",
"r13",
"r14",
"r15"
413 static const char* regnamesSeg[6] = {
414 "es",
"cs",
"ss",
"ds",
"fs",
"gs"
421 if (fullRegisterNumber >= 8)
422 throw Exception(
"register number out of bounds");
423 if (fullRegisterNumber & 4) {
424 name = regnames8h[fullRegisterNumber % 4];
426 name = regnames8l[fullRegisterNumber % 4];
428 registerType =
BYTET;
431 if (fullRegisterNumber >= 16)
432 throw Exception(
"register number out of bounds");
433 name = regnames8l[fullRegisterNumber];
434 registerType =
BYTET;
437 if (fullRegisterNumber >= 16)
438 throw Exception(
"register number out of bounds");
439 name = regnames16[fullRegisterNumber];
440 registerType =
WORDT;
443 if (fullRegisterNumber >= 16)
444 throw Exception(
"register number out of bounds");
445 name = regnames32[fullRegisterNumber];
449 if (fullRegisterNumber >= 16)
450 throw Exception(
"register number out of bounds");
451 name = regnames64[fullRegisterNumber];
455 if (fullRegisterNumber >= 6)
456 throw Exception(
"register number out of bounds");
457 name = regnamesSeg[fullRegisterNumber];
458 registerType =
WORDT;
479 ROSE_ASSERT(!name.empty());
485 throw Exception(
"register \"" + name +
"\" is not available for " +
get_registers()->get_architecture_name());
498 case x86_segreg_none: ROSE_ASSERT(!
"makeSegmentRegister does not support x86_segreg_none");
505 default: ROSE_ASSERT(!
"Bad segment register in makeSegmentRegister");
582 default: ROSE_ASSERT(
false);
615 addressExpr =
makeAddrSizeValue(IntegerOps::signExtend<32, 64>((uint64_t)offset), bit_offset, 32);
622 uint8_t sibScaleField = sib >> 6;
623 uint8_t sibIndexField = (sib & 0070) >> 3;
624 uint8_t sibBaseField = sib & 7;
625 uint8_t actualScale = (1 << sibScaleField);
627 if (sibBaseField == 5) {
632 sibBase =
makeAddrSizeValue(IntegerOps::signExtend<32, 64>((uint64_t)offset), bit_offset, 32);
650 if (sibBaseField == 4)
653 if (sibIndexField == 4 && !
rexX) {
654 addressExpr = sibBase;
655 }
else if (actualScale == 1) {
693 ROSE_ASSERT(addressExpr);
795 default: { ROSE_ASSERT(
false);
return NULL; }
806 default: { ROSE_ASSERT(
false);
return NULL; }
814 size_t bit_offset=8*
insnbufat, bit_size=0;
818 val = IntegerOps::signExtend<16, 64>((uint64_t)val2);
822 val = IntegerOps::signExtend<32, 64>((uint64_t)val2);
866 { ROSE_ASSERT(
false);
return NULL; }
875 uint64_t target =
ip +
insnbufat + IntegerOps::signExtend<8, 64>((uint64_t)val);
1559 throw ExceptionX86(
"bad repeat prefix for insb",
this);
1573 throw ExceptionX86(
"bad repeat prefix for insw",
this);
1585 throw ExceptionX86(
"bad repeat prefix for insd",
this);
1587 default: ROSE_ASSERT(
false);
1599 throw ExceptionX86(
"bad repeat prefix for outsb",
this);
1613 throw ExceptionX86(
"bad repeat prefix for outsw",
this);
1625 throw ExceptionX86(
"bad repeat prefix for outsd",
this);
1627 default: ROSE_ASSERT(
false);
1971 throw ExceptionX86(
"bad repeat prefix for movsb",
this);
1985 throw ExceptionX86(
"bad repeat prefix for movsw",
this);
1996 throw ExceptionX86(
"bad repeat prefix for movsd",
this);
2007 throw ExceptionX86(
"bad repeat prefix for movsq",
this);
2009 default: ROSE_ASSERT(
false);
2024 throw ExceptionX86(
"bad repeat prefix for cmpsb",
this);
2041 throw ExceptionX86(
"bad repeat prefix for cmpsw",
this);
2055 throw ExceptionX86(
"bad repeat prefix for cmpsd",
this);
2069 throw ExceptionX86(
"bad repeat prefix for cmpsq",
this);
2071 default: ROSE_ASSERT(
false);
2093 throw ExceptionX86(
"bad repeat prefix for stosb",
this);
2107 throw ExceptionX86(
"bad repeat prefix for stosw",
this);
2118 throw ExceptionX86(
"bad repeat prefix for stosd",
this);
2128 default:
throw ExceptionX86(
"bad repeat prefix for stosq",
this);
2143 throw ExceptionX86(
"bad repeat prefix for lodsb",
this);
2157 throw ExceptionX86(
"bad repeat prefix for lodsw",
this);
2168 throw ExceptionX86(
"bad repeat prefix for lodsd",
this);
2179 throw ExceptionX86(
"bad repeat prefix for lodsq",
this);
2181 default: ROSE_ASSERT(
false);
2196 throw ExceptionX86(
"bad repeat prefix for scasb",
this);
2213 throw ExceptionX86(
"bad repeat prefix for scasw",
this);
2227 throw ExceptionX86(
"bad repeat prefix for scasd",
this);
2241 throw ExceptionX86(
"bad repeat prefix for scasq",
this);
2243 default: ROSE_ASSERT(
false);
2667 default: ROSE_ASSERT(!
"Should not get here");
2718 uint8_t thirdOpcodeByte =
getByte();
2720 sprintf(opcodestr,
"0x0f0f%02x", thirdOpcodeByte);
2721 if (thirdOpcodeByte < 0x80) {
2723 switch (thirdOpcodeByte) {
2745 throw ExceptionX86(std::string(
"bad opcode ")+opcodestr,
this);
2747 }
else if (thirdOpcodeByte < 0xB7) {
2751 switch (thirdOpcodeByte) {
2770 throw ExceptionX86(std::string(
"bad opcode ")+opcodestr,
this);
2775 switch (thirdOpcodeByte) {
2786 throw ExceptionX86(std::string(
"bad opcode ")+opcodestr,
this);
2850 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f13",
this);
2856 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f13",
this);
2865 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f14",
this);
2870 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f14",
this);
2879 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f15",
this);
2884 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f15",
this);
2904 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f16",
this);
2914 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f17",
this);
2920 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f17",
this);
2948 throw ExceptionX86(
"bad ModR/M value for 0x0f20",
this);
2955 throw ExceptionX86(
"bad ModR/M value for 0x0f21",
this);
2962 throw ExceptionX86(
"bad ModR/M value for 0x0f22",
this);
2969 throw ExceptionX86(
"bad ModR/M value for 0x0f23",
this);
2987 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f28",
this);
2992 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f18",
this);
3001 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f29",
this);
3006 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f19",
this);
3080 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f2e",
this);
3085 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f2e",
this);
3094 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f2f",
this);
3099 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f2f",
this);
3126 uint8_t thirdOpcodeByte =
getByte();
3127 switch (thirdOpcodeByte) {
3138 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f3a0f",
this);
3144 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f3a0f",
this);
3149 sprintf(opcodestr,
"0x0f3a%02x", thirdOpcodeByte);
3150 throw ExceptionX86(std::string(
"bad or unimplemented opcode ")+opcodestr,
this);
3219 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f50",
this);
3222 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f50",
this);
3228 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f50",
this);
3231 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f50",
this);
3259 throw ExceptionX86(
"bad mm prefix 66 for opcode 0x0f52",
this);
3261 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f52",
this);
3273 throw ExceptionX86(
"bad mm prefix 66 for opcode 0x0f53",
this);
3275 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f53",
this);
3284 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f54",
this);
3289 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f54",
this);
3298 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f55",
this);
3303 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f55",
this);
3312 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f56",
this);
3317 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f56",
this);
3326 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f57",
this);
3331 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f57",
this);
3394 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f5b",
this);
3467 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f60",
this);
3472 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f60",
this);
3481 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f61",
this);
3486 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f61",
this);
3495 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f62",
this);
3500 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f62",
this);
3509 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f63",
this);
3514 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f63",
this);
3523 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f64",
this);
3528 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f64",
this);
3537 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f65",
this);
3542 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f65",
this);
3551 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f66",
this);
3556 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f66",
this);
3565 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f67",
this);
3570 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f67",
this);
3579 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f68",
this);
3584 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f68",
this);
3593 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f69",
this);
3598 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f69",
this);
3607 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f6a",
this);
3612 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f6a",
this);
3621 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f6b",
this);
3626 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f6b",
this);
3632 throw ExceptionX86(
"bad mm prefix None for opcode 0x0f6c",
this);
3634 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f6c",
this);
3639 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f6c",
this);
3645 throw ExceptionX86(
"bad mm prefix None for opcode 0x0f6d",
this);
3647 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f6d",
this);
3652 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f6d",
this);
3666 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f6e",
this);
3679 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f6e",
this);
3694 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f6f",
this);
3727 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3730 case 0:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3731 case 1:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3733 case 3:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3735 case 5:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3737 case 7:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3738 default: ROSE_ASSERT(
false);
3742 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f71",
this);
3746 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3749 case 0:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3750 case 1:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3752 case 3:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3754 case 5:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3756 case 7:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f71",
this);
3757 default: ROSE_ASSERT(
false);
3761 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f71",
this);
3770 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3773 case 0:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3774 case 1:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3776 case 3:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3778 case 5:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3780 case 7:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3781 default: ROSE_ASSERT(
false);
3785 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f72",
this);
3789 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3792 case 0:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3793 case 1:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3795 case 3:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3797 case 5:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3799 case 7:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f72",
this);
3800 default: ROSE_ASSERT(
false);
3804 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f72",
this);
3813 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3816 case 0:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3817 case 1:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3819 case 3:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3821 case 5:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3823 case 7:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3824 default: ROSE_ASSERT(
false);
3828 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f73",
this);
3832 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3836 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3838 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3845 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3847 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f73",
this);
3858 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f73",
this);
3867 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f74",
this);
3872 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f74",
this);
3881 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f75",
this);
3886 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f75",
this);
3895 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f76",
this);
3900 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f76",
this);
3908 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f77",
this);
3910 throw ExceptionX86(
"bad mm prefix 66 for opcode 0x0f77",
this);
3912 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f77",
this);
3920 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f78",
this);
3931 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f78",
this);
3934 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f78",
this);
3944 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f78",
this);
3954 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f79",
this);
3960 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f79",
this);
3967 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0f79",
this);
3978 throw ExceptionX86(
"bad mm prefix None for opcode 0x0f7c",
this);
3980 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f7c",
this);
3992 throw ExceptionX86(
"bad mm prefix None for opcode 0x0f7d",
this);
3994 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f7d",
this);
4029 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f7e",
this);
4044 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f7f",
this);
4251 throw ExceptionX86(
"bad mm prefix for opcode 0x0fb8",
this);
4304 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fc3",
this);
4306 throw ExceptionX86(
"bad mm prefix 66 for opcode 0x0fc3",
this);
4308 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fc3",
this);
4319 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fc4",
this);
4326 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fc4",
this);
4337 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fc5",
this);
4341 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fc5",
this);
4348 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fc5",
this);
4352 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fc5",
this);
4363 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fc6",
this);
4370 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fc6",
this);
4393 default:
throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fc7",
this);
4401 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fc7",
this);
4423 throw ExceptionX86(
"bad mm prefix None for opcode 0x0fd0",
this);
4425 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd0",
this);
4440 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd1",
this);
4445 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd1",
this);
4454 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd2",
this);
4459 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd2",
this);
4468 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd3",
this);
4473 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd3",
this);
4482 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd4",
this);
4487 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd4",
this);
4496 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd5",
this);
4501 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd5",
this);
4507 throw ExceptionX86(
"bad mm prefix None for opcode 0x0fd6",
this);
4513 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fd6",
this);
4523 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fd6",
this);
4534 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fd7",
this);
4537 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd7",
this);
4543 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0fd7",
this);
4546 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd7",
this);
4555 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd8",
this);
4560 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd8",
this);
4569 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fd9",
this);
4574 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fd9",
this);
4583 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fda",
this);
4588 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fda",
this);
4597 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fdb",
this);
4602 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fdb",
this);
4611 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fdc",
this);
4616 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fdc",
this);
4625 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fdd",
this);
4630 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fdd",
this);
4639 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fde",
this);
4644 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fde",
this);
4653 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fdf",
this);
4658 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fdf",
this);
4667 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe0",
this);
4672 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe0",
this);
4681 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe1",
this);
4686 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe1",
this);
4695 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe2",
this);
4700 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe2",
this);
4709 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe3",
this);
4714 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe3",
this);
4723 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe4",
this);
4728 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe4",
this);
4737 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe5",
this);
4742 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe5",
this);
4748 throw ExceptionX86(
"bad mm prefix None for opcode 0x0fe6",
this);
4767 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe7",
this);
4773 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe7",
this);
4782 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe8",
this);
4787 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe8",
this);
4796 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fe9",
this);
4801 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fe9",
this);
4810 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fea",
this);
4815 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fea",
this);
4824 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0feb",
this);
4829 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0feb",
this);
4838 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fec",
this);
4843 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fec",
this);
4852 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fed",
this);
4857 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fed",
this);
4866 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fee",
this);
4871 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fee",
this);
4880 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0fef",
this);
4885 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0fef",
this);
4891 throw ExceptionX86(
"bad mm prefix None for opcode 0x0ff0",
this);
4893 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff0",
this);
4895 throw ExceptionX86(
"bad mm prefix 66 for opcode 0x0ff0",
this);
4908 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff1",
this);
4913 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff1",
this);
4922 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff2",
this);
4927 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff2",
this);
4936 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff3",
this);
4941 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff3",
this);
4950 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff4",
this);
4955 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff4",
this);
4964 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff5",
this);
4969 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff5",
this);
4978 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff6",
this);
4983 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff6",
this);
4995 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0ff7",
this);
4998 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff7",
this);
5004 throw ExceptionX86(
"bad combination of mm prefix and ModR/M for opcode 0x0ff7",
this);
5007 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff7",
this);
5016 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff8",
this);
5021 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff8",
this);
5030 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ff9",
this);
5035 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ff9",
this);
5044 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ffa",
this);
5049 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ffa",
this);
5058 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ffb",
this);
5063 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ffb",
this);
5072 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ffc",
this);
5077 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ffc",
this);
5086 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ffd",
this);
5091 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ffd",
this);
5100 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0ffe",
this);
5105 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0ffe",
this);
5133 throw ExceptionX86(
"bad mm prefix F3 for opcode 0x0f3800",
this);
5138 throw ExceptionX86(
"bad mm prefix F2 for opcode 0x0f3800",
this);
5163 default: { ROSE_ASSERT(
false);
return NULL; }
5175 default: { ROSE_ASSERT(
false);
return NULL; }
5192 throw ExceptionX86(
"bad ModR/M for x87 opcode 0xd9",
this);
5219 default: ROSE_ASSERT(
false);
5251 default:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xd9",
this);
5272 default: ROSE_ASSERT(
false);
5281 default: ROSE_ASSERT(
false);
5286 default:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xda",
this);
5310 case 4:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdb",
this);
5312 case 6:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdb",
this);
5314 default: ROSE_ASSERT(
false);
5325 default: ROSE_ASSERT(
false);
5331 default:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdb",
this);
5352 default: ROSE_ASSERT(
false);
5358 case 2:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdc",
this);
5359 case 3:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdc",
this);
5364 default: ROSE_ASSERT(
false);
5395 throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdd",
this);
5408 case 1:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdd",
this);
5413 case 6:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdd",
this);
5414 case 7:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdd",
this);
5415 default: ROSE_ASSERT(
false);
5436 default: ROSE_ASSERT(
false);
5442 case 2:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xde",
this);
5446 default:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xde",
this);
5453 default: ROSE_ASSERT(
false);
5476 default: ROSE_ASSERT(
false);
5481 case 0:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdf",
this);
5482 case 1:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdf",
this);
5483 case 2:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdf",
this);
5484 case 3:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdf",
this);
5489 throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdf",
this);
5494 case 7:
throw ExceptionX86(
"bad ModR/M value for x87 opcode 0xdf",
this);
5495 default: ROSE_ASSERT(
false);
5514 default: ROSE_ASSERT(
false);
5524 throw ExceptionX86(
"bad ModR/M value for Group 1a opcode",
this);
5540 default: ROSE_ASSERT(
false);
5552 ROSE_ASSERT(immMaybe);
5579 default:
throw ExceptionX86(
"bad ModR/M value for Group 4 opcode",
this);
5606 throw ExceptionX86(
"bad ModR/M value for Group 5 opcode",
this);
5624 case 6:
throw ExceptionX86(
"bad ModR/M value for Group 6 opcode",
this);
5625 case 7:
throw ExceptionX86(
"bad ModR/M value for Group 6 opcode",
this);
5626 default: ROSE_ASSERT(
false);
5644 default:
throw ExceptionX86(
"bad ModR/M value for Group 7 opcode",
this);
5656 default:
throw ExceptionX86(
"bad ModR/M value for Group 7 opcode",
this);
5668 default:
throw ExceptionX86(
"bad ModR/M value for Group 7 opcode",
this);
5686 default: ROSE_ASSERT(
false);
5698 throw ExceptionX86(
"bad ModR/M value for Group 7 opcode",
this);
5708 default:
throw ExceptionX86(
"bad ModR/M value for Group 7 opcode",
this);
5726 case 0:
throw ExceptionX86(
"bad ModR/M value for Group 8 opcode",
this);
5727 case 1:
throw ExceptionX86(
"bad ModR/M value for Group 8 opcode",
this);
5728 case 2:
throw ExceptionX86(
"bad ModR/M value for Group 8 opcode",
this);
5729 case 3:
throw ExceptionX86(
"bad ModR/M value for Group 8 opcode",
this);
5734 default: ROSE_ASSERT(
false);
5745 default:
throw ExceptionX86(
"bad ModR/M value for Group 11 opcode",
this);
5786 throw ExceptionX86(
"bad ModR/M value for Group 15 opcode",
this);