Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
MOVS/MOVSB/MOVSW
◄Summary► ◄Detail► ◄Example► ◄Key to Flags►
──────────────────────────────────────────────────────────────────────────────
Move String Data Flags: O D I T S Z A P C
═════════════════
Syntax: MOVS dest,src
MOVSB
MOVSW
Moves a string from one area of memory to another. The source string
must be pointed to by DS:SI and the destination address must be
pointed to by ES:DI (even if operands are given). For each ele-
ment moved, DI and SI are adjusted according to the size of the
operands and the status of the direction flag. They are increased if
the direction flag has been cleared with CLD, or decreased if the
direction flag has been set with STD.
If the MOVS form of the instruction is used, operands must be provided
to indicate the size of the data elements to be processed. A segment
override can be given for the source operand (but not for the
destination). If MOVSB (bytes) or MOVSW (words) is used, the
instruction determines the size of the data elements to be processed.
Operands are not allowed in MOVSB or MOVSW.
MOVS and its variations are usually used with the REP prefix.
Before a move using a repeat prefix, CX should contain the number
of elements to move.
-♦-