You are on page 1of 16

MOVS:

Data fetch from one location and save on another location.


MOVS instruction used for fetch data from one memory location and over written
on another memory location.
Two Versions:
 MOVSB
 MOVSW
 MOVSB stands for MOVSByte
It is used for fetch one byte from one memory location and saves on another.

 MOVSW stands for MOVSWord


It is used for fetch one word from one memory location and saves on another.

 CLD Clear the direction flag


Example:
Output:
Scroll up 5 times:
CMPS:
Compare one memory location to another memory location.
Two Versions:
 CMPSB
 CMPSW

 CMPSB stands for CMPSByte


It is used for compare byte in two different memory location
 CMPSW stands for CMPSWord
It is used for compare word in two different memory location.
Example:
.
Output: (in case of different)
Output:( in case of same)

You might also like