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

Addressing Modes

This document discusses various addressing modes for 80x86 microprocessors including register, immediate, memory, direct, indirect register, based, indexed, and based-indexed addressing with or without displacement. It also covers addressing on strings of bytes and addressing of ports. The document outlines the 80x86 instruction set including instructions for data transfer, arithmetic, logic, shifts/rotates, strings of bytes, and port input/output. Examples are provided of addressing strings and ports as well as how to switch on an LED.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views

Addressing Modes

This document discusses various addressing modes for 80x86 microprocessors including register, immediate, memory, direct, indirect register, based, indexed, and based-indexed addressing with or without displacement. It also covers addressing on strings of bytes and addressing of ports. The document outlines the 80x86 instruction set including instructions for data transfer, arithmetic, logic, shifts/rotates, strings of bytes, and port input/output. Examples are provided of addressing strings and ports as well as how to switch on an LED.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 33

(C3)

Addressing Modes for


80x86 microprocessors

Addressing modes- Classification


Register addressing
Immediate addressing
Memory addressing

Direct addressing
Indirect register addressing
Based addressing (with/without displacement)
Indexed addressing (with/without displacement)
Based-indexed adressing (with/without
displacement)
Addrssing on strings of bytes
Addressing of ports

Exceptions:
-Segm segm
-Segm immediate value

Memory addressing

Addressing on strings of bytes


Strings of bytes
Source string (SI), in DS (default)
Destination string (DI), in ES (default)

Examples of strings
Examples how the address is calculated:
MOVSB, LODSB.

Addressing the ports


What is a port?
Input/output on ports
Which is the address of the port?
Difference on memory address

Registers used in addressing


Examples
How to switch on a LED? Example.

Instruction encoding (e.g. MOV)

The instruction set


http://burks.brighton.ac.uk/burks/language/asm/asmtut/asm1.htm#toc
http://webster.cs.ucr.edu/AoA/DOS/AoADosIndex.html

1) Instructions for data transfer

2) Arithmetic instructions
3) Logic instructions

4) Shifts/rotate instructions + LOOPS


5) Instructions on strings of bytes

6) Instructions for port input/outpus

Instructions for data transfer

MOV
XCHG
XLAT
PUSH/POP
LEA
LDS, LES

Arithmetic Instructions ( to be continued)

ADD, ADC
INC
AAA, DAA
SUB, SBB
DEC
AAS, DAS

You might also like