0% found this document useful (0 votes)
14 views

Addressing Modes

Directives_Macros
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views

Addressing Modes

Directives_Macros
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 6

8086

Microprocess Addressing
or Modes
 A way locating data locating data or operands
 Every instruction of a program has to operate on a data.
 The different ways in which a source operand is denoted in an instruction are known as addressing modes.

1. Immediate Addressing
2. Direct Addressing
3. Indirect Addressing
4. Register Addressing
5. Register Indirect Addressing
6. Indexed Addressing
7. Based Addressing
8. Based Index Addressing
9. Based Index with displacement Addressing

August 31, 2024 1


8086 Group I : Addressing modes for
Microprocess Addressing register and immediate
or Modes data

1. Register Addressing
The data is stored in a register and it is referred using the
particular register (except IP)

Example: MOV CL, DH The content of 8-bit register another 8-bit DH is


MOV AX, BX moved to register CL. (CL) <-- (DH)

MOV DL, 08H


2. Immediate Addressing MOV AX, 0A9FH
 Immediate data is a part of instruction, and appears in the form of successive byte or bytes.
 MOV AX,0005H
 In the above example, 0005H is the immediate data. The immediate data may be 8 bit or 16 bit size.

MOV BX, [1354H]


3. Direct Addressing MOV BL, [0400H]

 A 16 bit memory address (offset) is directly specified in instruction as apart of it


 MOV AX, [5000H]
 Data resides in a memory location in the data segment, whole effective address computed using 5000H as
the offset address and content of DS as a segment address
 Here the address is 10H*DS+5000H.

August 31, 2024 2


4. Register Indirect Addressing
 Data to be addressed at any memory location through an offset address (logical address) held.in any of the following BX or
SI or DI.
 MOV AX,[BX]
 Here data present in a memory location in DS whose offset address is in BX. The effective address of the data is given as
10H*DS+[BX]

5. Indexed Addressing
 OFFSET of the operand is stored in one of the index registers.
 DS is the default segment for index registers SI or DI
 In case of string instructions DS or ES are default.
 MOV AX,[SI]
 Here data AVAILABLE ON offset address stored in SI in DS. The effective address is 10H*DS+[SI]

6. Based indexed Addressing


 The effective address of a data is formed, by adding content of a base register (any of BX, or BP) to the content of an index
register (any of SI, or DI)
 The default segment register is ES or DS.
 MOV AX, [BX] [SI]
 Here BX is the base register and SI is the index register. The effective address computed as 10H*DS+[BX]+[SI]

7. Based Addressing : MOV DX, [BX+04]


August 31, 2024 3
8. Based Index with displacement Addressing

 The operand offset is computed by adding the base register contents of Index register and 8 or 16 bit
displacement
 MOV AX, [BX+DI+08]
 ADD CX, [BX+SI+16]
 In the above example, 0005H is the immediate data. The immediate data may be 8 bit or 16 bit size.

August 31, 2024 4


8086 Group IV : Relative
Microprocessor Addressing Addressing
Modes mode

1. Register
Addressing

2. Immediate
Addressing In this addressing mode, the effective address
a
of program instruction is specified relative to
3.
4. Direct Addressing
Register Indirect Addressing Instruction Pointer (IP) by an 8-bit
displacement. signed
5. Based Addressing
Example: JZ 0AH
6. Indexed Addressing

7. Based Index Addressing


Operations:

8. String Addressing 000AH (sign extend)


0AH
9. Direct I/O port Addressing
If ZF = 1, then
10. Indirect I/O port Addressing EA = (IP) + 000AH
BA = (CS) x 1610
11. Relative Addressing MA = BA + EA
12. Implied Addressing If ZF = 1, then the program control jumps to
new address calculated above.

If ZF = 0, then next instruction of


the program is executed.
August 31, 2024 5
8086 Group IV : Implied
Microprocessor Addressing Addressing mode
Modes
1. Register
Addressing

2. Immediate
Addressing

3.
4. Direct Addressing
Register Indirect Addressing

5. Based Addressing

6. Indexed Addressing
Instructions using this mode have no operands.
7. Based Index Addressing
The instruction itself will specify the data to be
operated by the instruction.
8. String Addressing
Example: CLC
9. Direct I/O port Addressing
This clears the carry flag to
10. Indirect I/O port Addressing zero.

11. Relative Addressing

12. Implied Addressing

August 31, 2024 6

You might also like