The University of Texas at Austin
Department of Electrical and Computer Engineering

List of Instructions for the Project

EE 382N – Spring 2016
Yale N. Patt, Instructor
Ben Lin, Stephen Pruett, TAs

The following table contains all instruction variations you will implement in the project. It includes the instruction variations due to the operand size override and REP prefix; in addition, many instructions may be preceded by a segment override prefix (consult the manuals for details).

OpcodeMnemonicDescription
04 ibADD AL,imm8Add imm8 to AL
05 iwADD AX,imm16Add imm16 to AX
05 idADD EAX,imm32Add imm32 to EAX
80 /0 ibADD r/m8,imm8Add imm8 to r/m8
81 /0 iwADD r/m16,imm16Add imm16 to r/m16
81 /0 idADD r/m32,imm32Add imm32 to r/m32
83 /0 ibADD r/m16,imm8Add sign-extended imm8 to r/m16
83 /0 ibADD r/m32,imm8Add sign-extended imm8 to r/m32
00 /rADD r/m8,r8Add r8 to r/m8
01 /rADD r/m16,r16Add r16 to r/m16
01 /rADD r/m32,r32Add r32 to r/m32
02 /rADD r8,r/m8Add r/m8 to r8
03 /rADD r16,r/m16Add r/m16 to r16
03 /rADD r32,r/m32Add r/m32 to r32
0F BB BTC r/m16,r16 Compliments the selected bit. Stores original value in CF
0F BB BTC r/m32,r32 Compliments the selected bit. Stores original value in CF
0F BA /7 ibBTC r/m16,imm8Compliments the selected bit. Stores original value in CF
0F BA /7 ibBTC r/m32,imm8Compliments the selected bit. Stores original value in CF
E8 cwCALL rel16Call near, relative, displacement relative to next instruction
E8 cdCALL rel32Call near, relative, displacement relative to next instruction
FF /2CALL r/m16Call near, absolute indirect, address given in r/m16
FF /2CALL r/m32Call near, absolute indirect, address given in r/m32
9A cpCALL ptr16:32Call far, absolute, address given in operand
FCCLDClear DF flag
0F 42 /rCMOVC r16, r/m16Move if carry (CF=1)
0F 42 /rCMOVC r32, r/m32Move if carry (CF=1)
0F B0 /rCMPXCHG r/m8,r8 Compare AL with r/m8. If equal, r/m8 = r8 and ZF=1. Else, ZF=0, AL=r/m8.
0F B1 /rCMPXCHG r/m16,r16 Compare AX with r/m16. If equal, r/m16 = r16 and ZF=1. Else, ZF=0, AX=r/m16.
0F B1 /rCMPXCHG r/m32,r32 Compare EAX with r/m32. If equal, r/m32 = r32 and ZF=1. Else, ZF=0, EAX=r/m32.
27DAADecimal adjust AL after addition
F4HLTHalt
CFIRETDInterrupt return (32-bit operand size)
77 cbJNBE rel8Jump short if not below or equal (CF=0 and ZF=0)
75 cbJNE rel8Jump short if not equal (ZF=0)
0F 87 cwJNBE rel16Jump near if not below or equal (CF=0 and ZF=0)
0F 87 cdJNBE rel32Jump near if not below or equal (CF=0 and ZF=0)
0F 85 cwJNE rel16Jump near if not equal (ZF=0)
0F 85 cdJNE rel32Jump near if not equal (ZF=0)
EB cbJMP rel8Jump short, relative, displacement relative to next instruction
E9 cwJMP rel16Jump near, relative, displacement relative to next instruction
E9 cdJMP rel32Jump near, relative, displacement relative to next instruction
FF /4JMP r/m16Jump near, absolute indirect, address given in r/m16
FF /4JMP r/m32Jump near, absolute indirect, address given in r/m32
EA cdJMP ptr16:16Jump far, absolute, address given in operand
EA cpJMP ptr16:32Jump far, absolute, address given in operand
88 /rMOV r/m8,r8Move r8 to r/m8
89 /rMOV r/m16,r16Move r16 to r/m16
89 /rMOV r/m32,r32Move r32 to r/m32
8A /rMOV r8,r/m8Move r/m8 to r8
8B /rMOV r16,r/m16Move r/m16 to r16
8B /rMOV r32,r/m32Move r/m32 to r32
8C /rMOV r/m16,SregMove segment register to r/m16
8E /rMOV Sreg,r/m16Move r/m16 to segment register
B0+ rbMOV r8,imm8Move imm8 to r8
B8+ rwMOV r16,imm16Move imm16 to r16
B8+ rdMOV r32,imm32Move imm32 to r32
C6 /0MOV r/m8,imm8Move imm8 to r/m8
C7 /0MOV r/m16,imm16Move imm16 to r/m16
C7 /0MOV r/m32,imm32Move imm32 to r/m32
0F 6F /rMOVQ mm, mm/m64Move quadword from mm/m64 to mm.
0F 7F /rMOVQ mm/m64, mmMove quadword from mm to mm/m64.
F6 /2NOT r/m8Reverse each bit of r/m8
F7 /2NOT r/m16Reverse each bit of r/m16
F7 /2NOT r/m32Reverse each bit of r/m32
0C ibOR AL, imm8 AL OR imm8
0D iwOR AX, imm16 AX OR imm16
0D idOR EAX, imm32 EAX OR imm32
80 /1 ibOR r/m8 ,imm8 r/m8 OR imm8
81 /1 iwOR r/m16,imm16r/m16 OR imm16
81 /1 idOR r/m32,imm32r/m32 OR imm32
83 /1 ibOR r/m16,imm8 r/m16 OR imm8 (sign-extended)
83 /1 ibOR r/m32,imm8 r/m32 OR imm8 (sign-extended)
08 /r OR r/m8 ,r8 r/m8 OR r8
09 /r OR r/m16,r16 r/m16 OR r16
09 /r OR r/m32,r32 r/m32 OR r32
0A /r OR r8 ,r/m8 r8 OR r/m8
0B /r OR r16 ,r/m16r16 OR r/m16
0B /r OR r32 ,r/m32r32 OR r/m32
0F FE /rPADDD mm, mm/m64Add packed doubleword integers from mm/m64 and mm.
0F C4 /r ib PINSRW mm, r32/m16/imm8Copies the word from r32/m16 and inserts it into mm at the index specified by imm8.
8F /0POP r/m16Pop top of stack into m16; increment stack pointer
8F /0POP r/m32Pop top of stack into m32; increment stack pointer
58+ rwPOP r16Pop top of stack into r16; increment stack pointer
58+ rdPOP r32Pop top of stack into r32; increment stack pointer
1FPOP DSPop top of stack into DS; increment stack pointer
07POP ESPop top of stack into ES; increment stack pointer
17POP SSPop top of stack into SS; increment stack pointer
0F A1POP FSPop top of stack into FS; increment stack pointer
0F A9POP GSPop top of stack into GS; increment stack pointer
FF /6PUSH r/m16Push r/m16
FF /6PUSH r/m32Push r/m32
50+rwPUSH r16Push r16
50+rdPUSH r32Push r32
6APUSH imm8Push imm8
68PUSH imm16Push imm16
68PUSH imm32Push imm32
0EPUSH CSPush CS
16PUSH SSPush SS
1EPUSH DSPush DS
06PUSH ESPush ES
0F A0PUSH FSPush FS
0F A8PUSH GSPush GS
F2 AEREPNE SCAS m8 Finds matching word in AL in string specified by ES:EDI
F2 AFREPNE SCAS m16 Finds matching word in AX in string specified by ES:EDI
F2 AFREPNE SCAS m32 Finds matchine word in EAX in string specified by ES:EDI
C3RETNear return to calling procedure
CBRETFar return to calling procedure
C2 iwRET imm16Near return to calling procedure and pop imm16 bytes from stack
CA iwRET imm16Far return to calling procedure and pop imm16 bytes from stack
D0 /4SAL r/m8,1Multiply r/m8 by 2, once
D2 /4SAL r/m8,CLMultiply r/m8 by 2, CL times
C0 /4 ibSAL r/m8,imm8Multiply r/m8 by 2, imm8 times
D1 /4SAL r/m16,1Multiply r/m16 by 2, once
D3 /4SAL r/m16,CLMultiply r/m16 by 2, CL times
C1 /4 ibSAL r/m16,imm8Multiply r/m16 by 2, imm8 times
D1 /4SAL r/m32,1Multiply r/m32 by 2, once
D3 /4SAL r/m32,CLMultiply r/m32 by 2, CL times
C1 /4 ibSAL r/m32,imm8Multiply r/m32 by 2, imm8 times
D0 /7SAR r/m8,1Signed divide r/m8 by 2, once
D2 /7SAR r/m8,CLSigned divide r/m8 by 2, CL times
C0 /7 ibSAR r/m8,imm8Signed divide r/m8 by 2, imm8 times
D1 /7SAR r/m16,1Signed divide r/m16 by 2, once
D3 /7SAR r/m16,CLSigned divide r/m16 by 2, CL times
C1 /7 ibSAR r/m16,imm8Signed divide r/m16 by 2, imm8 times
D1 /7SAR r/m32,1Signed divide r/m32 by 2, once
D3 /7SAR r/m32,CLSigned divide r/m32 by 2, CL times
C1 /7 ibSAR r/m32,imm8Signed divide r/m32 by 2, imm8 times
AESCAS m8 Compare byte in AL with byte specified by memory address
AFSCAS m16 Compare word in AX with word specified by memory address
AFSCAS m32 Compare doubleword in EAX with doubleword specified by memory address
FDSTDSet DF flag
90+rwXCHG AX,r16 Exchange r16 with AX
90+rdXCHG EAX,r32 Exchange r32 with EAX
86 /rXCHG r/m8,r8 Exchange r8 with r/m8
87 /rXCHG r/m16,r16 Exchange r16 with r/m16
87 /rXCHG r/m32,r32Exchange r32 with r/m32