Skip to main content

Classification of 8085 instructions

Short answer

8085 instructions are classified by function into data transfer, arithmetic, logical, branching, and machine control, and by size into one, two, or three bytes. Branching instructions change the PC to implement loops, decisions, subroutines, and interrupt service routines.

In how many ways 8085 instructions can be classified? Explain with examples. What is the purpose of the branching instructions?

The 8085 instructions are classified in two ways.

(a) By function (five groups)

  1. Data transfer: copy data between registers, memory and I/O without changing the source. MOV A,B, MVI C,05H, LDA 2050H, STA 3000H, LXI H,2000H, XCHG, PUSH B, IN 80H, OUT 81H.
  2. Arithmetic: add, subtract, increment, decrement. ADD B, ADI 05H, SUB C, INR A, DCR M, INX H, DAD B, DAA.
  3. Logical: AND, OR, XOR, compare, rotate, complement. ANA B, ORI 0FH, XRA A, CMP B, CPI 05H, RLC, RAR, CMA.
  4. Branching: change the normal sequence of execution. JMP 3000H, JZ, JNC, CALL 4000H, RET, RST 3, PCHL.
  5. Machine control: control the processor operation. NOP, HLT, EI, DI, RIM, SIM.

(b) By instruction size

TypeBytesExample
One-byte1MOV A,B, ADD C, RET
Two-byte2MVI A,32H, ADI 05H, OUT 80H
Three-byte3LDA 2050H, JMP 3000H, LXI H,1234H

Purpose of branching instructions

Branching (jump, call, return, restart) instructions change the content of the program counter, so the next instruction is fetched from a different address instead of the next sequential address. They are used to:

  • Implement loops and repeat a block (e.g., JNZ LOOP).
  • Take decisions using flags (conditional jumps like JZ, JC).
  • Call subroutines and return (CALL, RET) so code can be reused.
  • Jump to interrupt service routines (RST n).

Types: unconditional (JMP, CALL, RET) and conditional (JZ, JNZ, JC, JNC, JP, JM, JPE, JPO, CZ, RNC ...), which act only if the flag condition is true.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Microprocessor chapter 2 questions →