ch3-addrModes

ch3-addrModes - Addressing modes EE 3750 Variables MYDATA...

Info iconThis preview shows pages 1–5. Sign up to view the full content.

View Full Document Right Arrow Icon
Addressing modes EE 3750 2 Variables MYDATA SEGMENT VAR1 DW 10101101B VAR2 DD 19AF376H VAR3 DW 762D ; 762D = 1011111010B VAR4 DB 9 MYDATA ENDS
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
3 Sample instructions MOV Instruction: MOV AX, BX Action: AX ! BX ADD Instruction: ADD AX, BX Action: AX ! AX + BX 4 Register and Immediate modes Register - operand is in register specified by instruction Example: MOV BL, AH Immediate - operand (8 or 16 bits long) is part of the instruction Example: ADD AX, 5
Background image of page 2
5 Machine code example: register and immediate Example instruction using register and immediate modes: add 123 hex to register AX Assembly language ADD AX, 123H Machine code format: 100000sw mod 000 r/m low data high data details: 10000001 11000000 00100011 00000001 6 Direct (or Displacement) mode Direct (or Displacement) - 16-bit EA is part of instruction Used for variables. Example: MOV BL, GREEN where GREEN is a byte variable
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
7 Machine code example: direct and immediate Example instruction using direct and immediate modes:
Background image of page 4
Image of page 5
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/25/2012 for the course EE 3750 taught by Professor Desouza during the Fall '08 term at LSU.

Page1 / 10

ch3-addrModes - Addressing modes EE 3750 Variables MYDATA...

This preview shows document pages 1 - 5. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online