Added the "div" instruction (with differentiation where required)

This commit is contained in:
Pierre Pronchery 2011-04-17 13:40:58 +00:00
parent 1bfda5e60b
commit 86dc27e426
2 changed files with 19 additions and 0 deletions

View File

@ -297,5 +297,15 @@
/* CDQ 0x99 1 */ /* CDQ 0x99 1 */
{ "cdq", 0x99, OP1F, AOT_NONE, AOT_NONE, AOT_NONE }, { "cdq", 0x99, OP1F, AOT_NONE, AOT_NONE, AOT_NONE },
#endif #endif
/* DIV 0xf6 /6 1 r/m8 */
{ "divb", 0xf6, OP1F, OP_RM8_D0+6,AOT_NONE, AOT_NONE },
{ "divb", 0xf6, OP1F, OP_RM8_D8+6,AOT_NONE, AOT_NONE },
{ "divb", 0xf6, OP1F, OP_RM8_DW+6,AOT_NONE, AOT_NONE },
{ "div", 0xf6, OP1F, OP_RM8_R8+6,AOT_NONE, AOT_NONE },
/* DIV 0xf7 /6 1 r/mW */
{ "div", 0xf7, OP1F, OP_RMW_D0+6,AOT_NONE, AOT_NONE },
{ "div", 0xf7, OP1F, OP_RMW_D8+6,AOT_NONE, AOT_NONE },
{ "div", 0xf7, OP1F, OP_RMW_DW+6,AOT_NONE, AOT_NONE },
{ "div", 0xf7, OP1F, OP_RMW_RW+6,AOT_NONE, AOT_NONE },
/* NOP */ /* NOP */
{ "nop", 0x90, OP1F, AOT_NONE, AOT_NONE, AOT_NONE }, { "nop", 0x90, OP1F, AOT_NONE, AOT_NONE, AOT_NONE },

View File

@ -82,4 +82,13 @@
cmc /* f5 */ cmc /* f5 */
cpuid /* 0f a2 */ cpuid /* 0f a2 */
cdq /* 0x99 */ cdq /* 0x99 */
/* DIV */
divb [%ecx] /* f6 31 */
divb [%eax + $0x02] /* f6 70 02 */
divb [%ebx + $0x4012] /* f6 b3 12 40 00 00 */
div %dl /* f6 f2 */
div [%ecx] /* f7 31 */
div [%eax + $0x02] /* f7 70 02 */
div [%ebx + $0x4012] /* f7 b3 12 40 00 00 */
div %edx /* f7 f2 */
nop /* 0x90 */ nop /* 0x90 */