From d336f06a0618f7d4290adae5d5ba69610fe8435e Mon Sep 17 00:00:00 2001 From: Jonathan Campbell Date: Mon, 24 Aug 2020 12:19:11 -0700 Subject: [PATCH] more --- doc-collection/opcodes/x86/8086.dop | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/doc-collection/opcodes/x86/8086.dop b/doc-collection/opcodes/x86/8086.dop index b917ee4d8..48835844b 100644 --- a/doc-collection/opcodes/x86/8086.dop +++ b/doc-collection/opcodes/x86/8086.dop @@ -749,3 +749,22 @@ opcode sequence(0xD1 mrm) where reg == 7 name "SAR" { common opcode "SAR" param( opcode sequence(0xD2 mrm) where reg == 7 name "SAR" { common opcode "SAR" param(rmb,cl); } opcode sequence(0xD3 mrm) where reg == 7 name "SAR" { common opcode "SAR" param(rmw,cl); } +opcode sequence(0xD4 immb) name "AAM" { + modifies flags(SF,ZF,PF,OF,AF,CF); + + /* tmp = al */ + /* ah = tmp / immb */ + /* al = tmp % immb */ + output ah, al; + input al; +} + +opcode sequence(0xD5 immb) name "AAD" { + modifies flags(SF,ZF,PF,OF,AF,CF); + + /* al = (al + (ah * immb)) & 0xFF */ + /* ah = 0 */ + output ah, al; + input ah, al; +} +