Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing Module M18.2 Section 12.3.

Similar presentations


Presentation on theme: "Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing Module M18.2 Section 12.3."— Presentation transcript:

1 Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing Module M18.2 Section 12.3

2 Introduction to Computer Engineering by Richard E. Haskell

3 Register Indirect Addressing mov al,[si] Move into AL the byte in the data segment whose offset address is in SI mov [di],al Move AL into the byte in the data segment whose offset address is in DI

4 Introduction to Computer Engineering by Richard E. Haskell Postbyte modregr/m mov al,[si] 8A mov b reg, r/m reg = AL = 000 0 0 0 mod = 00 r/m = si = 100 0 1 0 0 = 04 mov al,[si] 8A 04 Move byte pointed to by si into AL AL

5 Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing

6 Introduction to Computer Engineering by Richard E. Haskell Segment Override Prefix MOV AL,[SI] MOV [DI],AL Default segment is data segment, DS 26 88 05 MOV ES:[DI],AL

7 Introduction to Computer Engineering by Richard E. Haskell

8 The Status Register ­­­­­­­ODITSZAPC 1514131211109876543210 Overflow Direction Interrupt enable Trap Sign Zero Auxiliary Carry Parity Carry String Primitive Instructions D = 0: SI and DI are incremented -- CLD D = 1: SI and DI are decremented -- STD

9 Introduction to Computer Engineering by Richard E. Haskell REP Prefix Used before a string primitive. Repeats the string primitive CX times. SIDI DS ES CLD REP MOVSB Will move CS bytes from [SI] in the data segment to [DI] in the extra segment.

10 Introduction to Computer Engineering by Richard E. Haskell

11 JE can be used following a REPNE instruction to jump if a match is found. REPNE and REPE

12 Introduction to Computer Engineering by Richard E. Haskell


Download ppt "Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing Module M18.2 Section 12.3."

Similar presentations


Ads by Google