Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing Module M18.2 Section 12.3
Introduction to Computer Engineering by Richard E. Haskell
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
Introduction to Computer Engineering by Richard E. Haskell Postbyte modregr/m mov al,[si] 8A mov b reg, r/m reg = AL = mod = 00 r/m = si = = 04 mov al,[si] 8A 04 Move byte pointed to by si into AL AL
Introduction to Computer Engineering by Richard E. Haskell Register Indirect Addressing
Introduction to Computer Engineering by Richard E. Haskell Segment Override Prefix MOV AL,[SI] MOV [DI],AL Default segment is data segment, DS MOV ES:[DI],AL
Introduction to Computer Engineering by Richard E. Haskell
The Status Register ODITSZAPC 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
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.
Introduction to Computer Engineering by Richard E. Haskell
JE can be used following a REPNE instruction to jump if a match is found. REPNE and REPE
Introduction to Computer Engineering by Richard E. Haskell