0% found this document useful (0 votes)
18 views13 pages

3rd Lecture - Addressing Modes of 8086

The document outlines various addressing modes used in the 8086 microprocessor, categorized into two groups: addressing modes for register and immediate data, and addressing modes for memory data. It explains each mode, including Register Addressing, Immediate Addressing, Direct Addressing, and others, providing examples for clarity. Additionally, it describes how physical addresses are calculated using segment registers and offsets to access memory effectively.

Uploaded by

nnooobmasterr69
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views13 pages

3rd Lecture - Addressing Modes of 8086

The document outlines various addressing modes used in the 8086 microprocessor, categorized into two groups: addressing modes for register and immediate data, and addressing modes for memory data. It explains each mode, including Register Addressing, Immediate Addressing, Direct Addressing, and others, providing examples for clarity. Additionally, it describes how physical addresses are calculated using segment registers and offsets to access memory effectively.

Uploaded by

nnooobmasterr69
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 13

ADDRESSING MODES

Dr. Manju Khurana


Assistant Professor,
CSED
TIET, Patiala
[email protected]
du
8086
Microprocessor Addressing Modes

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. Register Addressing
Group I : Addressing modes for
2. Immediate Addressing register and immediate data

3. Direct Addressing

4. Register Indirect Addressing

5. Based Addressing
Group II : Addressing modes for
6. Indexed Addressing memory data
7. Based Indexed Addressing

8. Based Indexed with Displacement


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

1. Register Addressing The instruction will specify the name of the


register which holds the data to be operated by
2. Immediate Addressing the instruction.
3. Direct Addressing Example:
4. Register Indirect Addressing
MOV CL, DH
5. Based Addressing
The content of 8-bit register DH is moved to
6. Indexed Addressing another 8-bit register CL

7. Based Indexed Addressing (CL)  (DH)

8. Based Indexed with Displacement


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

1. Register Addressing
In immediate addressing mode, an 8-bit or 16-bit
2. Immediate Addressing data is specified as part of the instruction
3. Direct Addressing
Example:
4. Register Indirect Addressing
MOV DL, 08H
5. Based Addressing
The 8-bit data (08H) given in the instruction is
6. Indexed Addressing moved to DL

7. Based Indexed Addressing (DL)  08H

8. Based Indexed with Displacement


MOV AX, 0A9FH

The 16-bit data (0A9FH) given in the instruction is


moved to AX register

(AX)  0A9FH
8086
Microprocessor Addressing Modes : Memory Access

Offset Value (16 bits)

Segment Register (16 bits) 0000

Adder

Physical Address (20 Bits)


8086
Microprocessor Addressing Modes : Memory Access

20 Address lines  8086 can address up to


220 = 1M bytes of memory

However, the largest register is only 16 bits

Physical Address will have to be calculated


Physical Address : Actual address of a byte in
memory. i.e. the value which goes out onto the
address bus.

Memory Address represented in the form –


Seg : Offset (Eg - 89AB:F012)

Each time the processor wants to access


memory, it takes the contents of a segment
register, shifts it one hexadecimal place to the
16 bytes of
left (same as multiplying by 16 10), then add the contiguous memory
required offset to form the 20- bit address

89AB : F012  89AB  89AB0 (Paragraph to byte  89AB x 10 = 89AB0)


F012  0F012 (Offset is already in byte unit)
+ -------
98AC2 (The absolute address)
8086 Group II : Addressing modes
Microprocessor Addressing Modes for memory data

1. Register Addressing

2. Immediate Addressing
In direct addressing mode the operand’s offset
3. Direct Addressing
is given in the instruction as an 8-bit or 16-bit
4. Register Indirect Addressing displacement element.

5. Based Addressing Examples are:

6. Indexed Addressing MOV BX, [1354H]


MOV BL, [0400H]
7. Based Indexed Addressing
The square brackets around the 1354H
8. Based Indexed with Displacement
denotes the contents of the memory location.
When executed, this instruction will copy the
contents of the memory location into BX
register.

This addressing mode is called direct because


the displacement of the operand from the
segment base is specified directly in the
instruction.
8086 Group II : Addressing modes
Microprocessor Addressing Modes for memory data

1. Register Addressing In Register indirect addressing, operand’s offset


is placed in any one of the registers BX, BP, SI
2. Immediate Addressing or DI as specified in the instruction.

3. Direct Addressing Example:


MOV CX, [BX]
4. Register Indirect Addressing
ADD AL, [SI]
5. Based Addressing

6. Indexed Addressing

7. Based Indexed Addressing

8. Based Indexed with Displacement


8086 Group II : Addressing modes
Microprocessor Addressing Modes for memory data

1. Register Addressing In Based Addressing, operand’s offset is the


sum of an 8-bit or 16-bit displacement and the
2. Immediate Addressing contents of the base register BX or BP. BX is
used as a base register for data segment, and
3. Direct Addressing BP is used as a base register for stack segment.

4. Register Indirect Addressing Offset (Effective address)= [BX + 8-bit or 16-bit


displacement]
5. Based Addressing
Examples are:
6. Indexed Addressing
MOV AL, [BX + 05H]
7. Based Indexed Addressing

8. Based Indexed with Displacement MOV AL, [BX + 1346H]


8086 Group II : Addressing modes
Microprocessor Addressing Modes for memory data

1. Register Addressing The operand’s offset is the sum of the content


of an index register SI or DI and an 8-bit or 16-
2. Immediate Addressing bit displacement.

3. Direct Addressing Offset (Effective address)= [SI or DI + 8-bit or


16-bit displacement]
4. Register Indirect Addressing

5. Based Addressing MOV AX, [SI + 05]


MOV AX, [SI + 1528H]
6. Indexed Addressing

7. Based Indexed Addressing

8. Based Indexed with Displacement


8086 Group II : Addressing modes
Microprocessor Addressing Modes for memory data

1. Register Addressing In Based Index Addressing, the operand’s


offset is the sum of the content of a base
2. Immediate Addressing register BX or BP and an index register SI or DI.

3. Direct Addressing Offset (Effective address)= [BX or BP]+ [SI or


DI]
4. Register Indirect Addressing
Examples are:
5. Based Addressing
ADD AX, [BX + SI]
6. Indexed Addressing
MOV CX, [BX + SI]
7. Based Indexed Addressing

8. Based Indexed with Displacement


8086 Group II : Addressing modes
Microprocessor Addressing Modes for memory data

1. Register Addressing In this mode of addressing the operand’s offset


is given by
2. Immediate Addressing
Offset (Effective address)= [BX or BP]+ [SI or
3. Direct Addressing DI] + 8-bit or 16-bit displacement

4. Register Indirect Addressing Examples are:

5. Based Addressing MOV AX, [BX + SI + 05]


6. Indexed Addressing
MOV AX, [BX + SI + 1235H]
7. Based Indexed Addressing

8. Based Indexed with Displacement

You might also like