Instruction Set of Intel 8086 Microprocessor


Instruction set of 8086 microprocessor can be divided into data copy/transfer instructions, arithmetic and logical instructions, branch/loop instructions, machine control instructions, flag manipulation instructions, string manipulation instructions. In this article, the instruction set of 8086 microprocessor is discussed in detail.

Instruction Set

Instruction set refers to the instructions which can be used to program a microprocessor etc,. Instruction set can be divided into data copy/transfer instructions, arithmetic and logical instructions, branch/loop instructions, machine control instructions, flag manipulation instructions, string manipulation instructions. The instruction set of 8086 microprocessor is:

Data Copy/Transfer Instructions


These are the type of instructions used to copy, move etc., data from source to destination. Some of the data copy/transfer instructions are:


MOV : Move data from register to register, memory to register, register to memory,
memory to accumulator, accumulator to memory etc,.
PUSH : Push data into register, memory etc,.
POP : Pop data from register, memory etc,.
XCHG : Exchange data between register, memory etc,.
IN : Input from fixed port or variable port
OUT : Output to fixed port or variable port
LDS : Load pointer to DS
LES : Load pointer to ES
LAHF : Load AH with flags
SAHF : Store AH into flags
PUSHF : Push flags
POPF : Pop flags

Arithmetic and Logical Instructions

These are the type of instructions used to perform arithmetic operations like addition, subtraction etc., and logical operations like and, or etc,. Some of the arithmetic and logical instructions are:

Arithmetic Instructions


ADD : Addition
ADC : Addition with Carry
INC : Increment by 1
AAA : ASCII Adjust for Addition
DAA : Decimal Adjust for Addition
SUB : Subtraction
SBB : Subtraction with Borrow
DEC : Decrement by 1
AAS : ASCII Adjust for Subtraction
DAS : Decimal Adjust for Subtraction
MUL : Unsigned Multiplication
IMUL : Signed Multiplication
AAM : ASCII Adjust for Multiplication
DIV : Unsigned Division
IDIV : Signed Division
AAD : ASCII Adjust for Division
NEG : Change Sign
CMP : Compare
CBW : Convert Byte to Word
CWD : Convert Word to Double Word

Logical Instructions


AND : Logical AND
OR : Logical OR
NOT : Logical NOT
XOR : Logical XOR
SHL : Shift Logical Left
SHR : Shift Logical Right
ROL : Rotate Left
ROR : Rotate Right
RCL : Rotate Left through Carry Flag
RCR : Rotate Right through Carry Flag

Branch/Loop Instructions


These are the type of instructions used to control the transfer to a specified address. Some of the branch/loop instructions are:

Unconditional Branch/Loop Instructions


CALL : Call a subroutine Unconditionally
RET : Return from a procedure
INTN : Interrupt of Type N
INTO : Interrupt on Over flow
LOOP : Loop instructions Unconditionally

Conditional Branch/Loop Instructions


JZ : Jump if zero
JE : Jump if equal
JNZ : Jump if not zero
JNE : Jump if not equal
JL : Jump if lesser
JLE : Jump if lesser or equal
JG : Jump if greater
JGE : Jump if greater or equal
JO : Jump on Over flow
JNO : Jump on not Over flow
JS : Jump on Sign
JNS : Jump on not Sign
LOOPZ : Loop if zero
LOOPE : Loop if equal
LOOPNZ : Loop if not zero
LOOPNE : Loop if not equal

Machine Control Instructions


These are type of instructions used to control machine status. Some of the machine control instructions are:


WAIT : Wait for the test input to go low
HLT : Halt the processor
NOP : No operation
ESC : Escape to external device
LOCK : Lock instruction prefix

Flag manipulation Instructions


These are the type of instructions used to manipulate different flags present in the flag register of 8086 microprocessor. Some of the flag manipulation instructions are:


CLC : Clear Carry Flag
STC : Set Carry Flag
CLD : Clear Direction Flag
STD : Set Direction Flag
CLI : Clear Interrupt Flag
STI : Set Interrupt Flag

String Manipulation Instructions


These are the type of instructions used to manipulate strings. Some of the string manipulation operations are:


REP : Repeat Instruction Prefix
REPE : Repeat if equal
REPZ : Repeat if zero
REPNE : Repeat if not equal
REPNZ : Repeat if not zero
MOVS : Move String Byte/Word
CMPS : Compare String Byte/Word
SCAS : Scan String Byte/Word
LODS : Load String Byte/Word
STOS : Store String Byte/Word


Comments

No responses found. Be the first to comment...


  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:
    Email: