Difference Between Call and Jump Instructions in 8 - 231126 - 132313
Difference Between Call and Jump Instructions in 8 - 231126 - 132313
In 8085 Instruction set, there are a set of jump instructions, which can transfer
program control to a certain memory location. So after these branching
mnemonics we shall have to mention 16-bit target address of the location.
These jump instructions can be divided into two categories:
Under unconditional jump instructions there is only one mnemonic i.e. JUMP.
But under conditional Jump instructions we are having 8 different mnemonics.
We know that there are 5 flag bits in 8085 Flag register. They are S, Z, P, Cy,
AC. Out of them only on AC flag bit, there is no jump instruction. But for rest
4 flag bits, we are having 8 conditional jump instructions depending upon their
1 or 0 i.e. TRUE and FALSE values respectively. Here is the list of all
branching instructions in the following table ;
Mnemonics, Operand Opcode (in HEX) Bytes
JC Label DA 3
JM Label FA 3
JMP Label C3 3
JNC Label D2 3
JNZ Label C2 3
JP Label F2 3
JPE Label EA 3
JPO Label E2 3
JZ Label CA 3
The following table shows the list of Branching instructions with their
meanings.
Flag
Opcode Description
Status
CALL Label CD 3
RET C9 1
Let us consider the following sample code for better explanation:
Hex
Address Mnemonic Comment
Codes
200B CD CALL 2013H Calling the sub routine at address 2013H. So now
the control of the program will be transferred to
the location 2013H. And the return address
200EH i.e. address of the next instruction will be
pushed on the top of the stack. As a result 4FFFH
(SP – 1) will contain 20H and 4FFEH (SP – 2)
will contain 0EH respectively .