1 <!DOCTYPE HTML PUBLIC
"-//IETF//DTD HTML 2.0//EN">
4 <TITLE>80386 Programmer's Reference Manual -- Chapter
17</TITLE>
7 <B>up:
</B> <A HREF=
"toc.htm">
8 Table of Contents
</A><BR>
11 16.4 Transferring Control Among Mixed Code Segments
></A><BR>
13 <A HREF=
"s17_01.htm">17.1 Operand-Size and Address-Size Attributes
</A>
17 <H1>Chapter
17 80386 Instruction Set
</H1>
19 This chapter presents instructions for the
80386 in alphabetical order. For
20 each instruction, the forms are given for each operand combination,
21 including object code produced, operands required, execution time, and a
22 description. For each instruction, there is an operational description and a
23 summary of exceptions generated.
25 <A HREF=
"s17_01.htm">17.1 Operand-Size and Address-Size Attributes
</A>
26 <BR><A HREF=
"s17_02.htm">17.2 Instruction Format
</A>
28 <H2>Instruction Set
</H2>
30 <A HREF=
"AAA.htm"> AAA ASCII Adjust after Addition
</A>
31 <BR><A HREF=
"AAD.htm"> AAD ASCII Adjust AX before Division
</A>
32 <BR><A HREF=
"AAM.htm"> AAM ASCII Adjust AX after Multiply
</A>
33 <BR><A HREF=
"AAS.htm"> AAS ASCII Adjust AL after Subtraction
</A>
34 <BR><A HREF=
"ADC.htm"> ADC Add with Carry
</A>
35 <BR><A HREF=
"ADD.htm"> ADD Add
</A>
36 <BR><A HREF=
"AND.htm"> AND Logical AND
</A>
37 <BR><A HREF=
"ARPL.htm"> ARPL Adjust RPL Field of Selector
</A>
38 <BR><A HREF=
"BOUND.htm"> BOUND Check Array Index Against Bounds
</A>
39 <BR><A HREF=
"BSF.htm"> BSF Bit Scan Forward
</A>
40 <BR><A HREF=
"BSR.htm"> BSR Bit Scan Reverse
</A>
41 <BR><A HREF=
"BT.htm"> BT Bit Test
</A>
42 <BR><A HREF=
"BTC.htm"> BTC Bit Test and Complement
</A>
43 <BR><A HREF=
"BTR.htm"> BTR Bit Test and Reset
</A>
44 <BR><A HREF=
"BTS.htm"> BTS Bit Test and Set
</A>
45 <BR><A HREF=
"CALL.htm"> CALL Call Procedure
</A>
46 <BR><A HREF=
"CBW.htm"> CBW/CWDE Convert Byte to Word/Convert Word to Doubleword
</A>
47 <BR><A HREF=
"CLC.htm"> CLC Clear Carry Flag
</A>
48 <BR><A HREF=
"CLD.htm"> CLD Clear Direction Flag
</A>
49 <BR><A HREF=
"CLI.htm"> CLI Clear Interrupt Flag
</A>
50 <BR><A HREF=
"CLTS.htm"> CLTS Clear Task-Switched Flag in CR0
</A>
51 <BR><A HREF=
"CMC.htm"> CMC Complement Carry Flag
</A>
52 <BR><A HREF=
"CMP.htm"> CMP Compare Two Operands
</A>
53 <BR><A HREF=
"CMPS.htm"> CMPS/CMPSB/CMPSW/CMPSD Compare String Operands
</A>
54 <BR><A HREF=
"CWD.htm"> CWD/CDQ Convert Word to Doubleword/Convert Doubleword to Quadword
</A>
55 <BR><A HREF=
"DAA.htm"> DAA Decimal Adjust AL after Addition
</A>
56 <BR><A HREF=
"DAS.htm"> DAS Decimal Adjust AL after Subtraction
</A>
57 <BR><A HREF=
"DEC.htm"> DEC Decrement by
1</A>
58 <BR><A HREF=
"DIV.htm"> DIV Unsigned Divide
</A>
59 <BR><A HREF=
"ENTER.htm"> ENTER Make Stack Frame for Procedure Parameters
</A>
60 <BR><A HREF=
"HLT.htm"> HLT Halt
</A>
61 <BR><A HREF=
"IDIV.htm"> IDIV Signed Divide
</A>
62 <BR><A HREF=
"IMUL.htm"> IMUL Signed Multiply
</A>
63 <BR><A HREF=
"IN.htm"> IN Input from Port
</A>
64 <BR><A HREF=
"INC.htm"> INC Increment by
1</A>
65 <BR><A HREF=
"INS.htm"> INS/INSB/INSW/INSD Input from Port to String
</A>
66 <BR><A HREF=
"INT.htm"> INT/INTO Call to Interrupt Procedure
</A>
67 <BR><A HREF=
"IRET.htm"> IRET/IRETD Interrupt Return
</A>
68 <BR><A HREF=
"Jcc.htm"> Jcc Jump if Condition is Met
</A>
69 <BR><A HREF=
"JMP.htm"> JMP Jump
</A>
70 <BR><A HREF=
"LAHF.htm"> LAHF Load Flags into AH Register
</A>
71 <BR><A HREF=
"LAR.htm"> LAR Load Access Rights Byte
</A>
72 <BR><A HREF=
"LEA.htm"> LEA Load Effective Address
</A>
73 <BR><A HREF=
"LEAVE.htm"> LEAVE High Level Procedure Exit
</A>
74 <BR><A HREF=
"LGDT.htm"> LGDT/LIDT Load Global/Interrupt Descriptor Table Register
</A>
75 <BR><A HREF=
"LGS.htm"> LGS/LSS/LDS/LES/LFS Load Full Pointer
</A>
76 <BR><A HREF=
"LLDT.htm"> LLDT Load Local Descriptor Table Register
</A>
77 <BR><A HREF=
"LMSW.htm"> LMSW Load Machine Status Word
</A>
78 <BR><A HREF=
"LOCK.htm"> LOCK Assert LOCK# Signal Prefix
</A>
79 <BR><A HREF=
"LODS.htm"> LODS/LODSB/LODSW/LODSD Load String Operand
</A>
80 <BR><A HREF=
"LOOP.htm"> LOOP/LOOPcond Loop Control with CX Counter
</A>
81 <BR><A HREF=
"LSL.htm"> LSL Load Segment Limit
</A>
82 <BR><A HREF=
"LTR.htm"> LTR Load Task Register
</A>
83 <BR><A HREF=
"MOV.htm"> MOV Move Data
</A>
84 <BR><A HREF=
"MOVRS.htm"> MOV Move to/from Special Registers
</A>
85 <BR><A HREF=
"MOVS.htm"> MOVS/MOVSB/MOVSW/MOVSD Move Data from String to String
</A>
86 <BR><A HREF=
"MOVSX.htm"> MOVSX Move with Sign-Extend
</A>
87 <BR><A HREF=
"MOVZX.htm"> MOVZX Move with Zero-Extend
</A>
88 <BR><A HREF=
"MUL.htm"> MUL Unsigned Multiplication of AL or AX
</A>
89 <BR><A HREF=
"NEG.htm"> NEG Two's Complement Negation
</A>
90 <BR><A HREF=
"NOP.htm"> NOP No Operation
</A>
91 <BR><A HREF=
"NOT.htm"> NOT One's Complement Negation
</A>
92 <BR><A HREF=
"OR.htm"> OR Logical Inclusive OR
</A>
93 <BR><A HREF=
"OUT.htm"> OUT Output to Port
</A>
94 <BR><A HREF=
"OUTS.htm"> OUTS/OUTSB/OUTSW/OUTSD Output String to Port
</A>
95 <BR><A HREF=
"POP.htm"> POP Pop a Word from the Stack
</A>
96 <BR><A HREF=
"POPA.htm"> POPA/POPAD Pop all General Registers
</A>
97 <BR><A HREF=
"POPF.htm"> POPF/POPFD Pop Stack into FLAGS or EFLAGS Register
</A>
98 <BR><A HREF=
"PUSH.htm"> PUSH Push Operand onto the Stack
</A>
99 <BR><A HREF=
"PUSHA.htm"> PUSHA/PUSHAD Push all General Registers
</A>
100 <BR><A HREF=
"PUSHF.htm"> PUSHF/PUSHFD Push Flags Register onto the Stack
</A>
101 <BR><A HREF=
"RCL.htm"> RCL/RCR/ROL/ROR Rotate
</A>
102 <BR><A HREF=
"REP.htm"> REP/REPE/REPZ/REPNE/REPNZ Repeat Following String Operation
</A>
103 <BR><A HREF=
"RET.htm"> RET Return from Procedure
</A>
104 <BR><A HREF=
"SAHF.htm"> SAHF Store AH into Flags
</A>
105 <BR><A HREF=
"SAL.htm"> SAL/SAR/SHL/SHR Shift Instructions
</A>
106 <BR><A HREF=
"SBB.htm"> SBB Integer Subtraction with Borrow
</A>
107 <BR><A HREF=
"SCAS.htm"> SCAS/SCASB/SCASW/SCASD Compare String Data
</A>
108 <BR><A HREF=
"SETcc.htm"> SETcc Byte Set on Condition
</A>
109 <BR><A HREF=
"SGDT.htm"> SGDT/SIDT Store Global/Interrupt Descriptor Table Register
</A>
110 <BR><A HREF=
"SHLD.htm"> SHLD Double Precision Shift Left
</A>
111 <BR><A HREF=
"SHRD.htm"> SHRD Double Precision Shift Right
</A>
112 <BR><A HREF=
"SLDT.htm"> SLDT Store Local Descriptor Table Register
</A>
113 <BR><A HREF=
"SMSW.htm"> SMSW Store Machine Status Word
</A>
114 <BR><A HREF=
"STC.htm"> STC Set Carry Flag
</A>
115 <BR><A HREF=
"STD.htm"> STD Set Direction Flag
</A>
116 <BR><A HREF=
"STI.htm"> STI Set Interrupt Flag
</A>
117 <BR><A HREF=
"STOS.htm"> STOS/STOSB/STOSW/STOSD Store String Data
</A>
118 <BR><A HREF=
"STR.htm"> STR Store Task Register
</A>
119 <BR><A HREF=
"SUB.htm"> SUB Integer Subtraction
</A>
120 <BR><A HREF=
"TEST.htm"> TEST Logical Compare
</A>
121 <BR><A HREF=
"VERR.htm">VERR, VERW Verify a Segment for Reading or Writing
</A>
122 <BR><A HREF=
"WAIT.htm"> WAIT Wait until BUSY# Pin is Inactive (HIGH)
</A>
123 <BR><A HREF=
"XCHG.htm"> XCHG Exchange Register/Memory with Register
</A>
124 <BR><A HREF=
"XLAT.htm"> XLAT/XLATB Table Look-up Translation
</A>
125 <BR><A HREF=
"XOR.htm"> XOR Logical Exclusive OR
</A>
129 <B>up:
</B> <A HREF=
"toc.htm">
130 Table of Contents
</A><BR>
132 <A HREF=
"s16_04.htm">
133 16.4 Transferring Control Among Mixed Code Segments
></A><BR>
135 <A HREF=
"s17_01.htm">17.1 Operand-Size and Address-Size Attributes
</A>