Data Movement Instructions 

These instructions move data within the computer and to or from input/output devices

Possible data movements are:
  1. Memory-to-Memory
  2. Memory-to-CPU (i.e. to CPU registers)
  3. Constant-to-CPU (the constant would be specified in the instruction itself)
  4. Input-to-CPU
  5. CPU-to-Memory
  6. CPU-to-Output
The more the allowable data movements the more complex the CPU design become. A decision can be made to simplify the CPU by restricting data movement to or from the CPU registers (i.e. either the source or the destination has to be a register).

The moved data size might range from a single byte to hundreds of bytes

The longer the length of the moved data in a single instruction, the more complex the resulting CPU design. Requiring more than one instruction to move longer words of data would simplify the CPU design. Depending on the intended applications, the maximum size of data word that can be moved in one instruction is selected to minimize the overall execution time.

Separate instructions might deal with different data types. Possible data types are integers, floating point, characters, and address data type. This would complicate the CPU design further.

The table below shows examples of data movement instructions from different machines illustrating the different options discussed above.

Examples of data movement instructions from several machines

MOV A, BMove 16-bit data from memory location A to memory location BVAX11
LDA A, AddrLoad the accumulator A with the byte at memory location AddrM6800
lwz R3, AMove 32-bit data from memory location A to register R3PPC601
li $3, 455Load the 32-bit integer constant 455 into register $3MIPS R3000
mov R4, doutMove 16-bit data from register R4 to output port doutDEC PDP11
IN AL, KBDLoad a byte from input port KBD to the lower 8-bits of the accumulator registerIntel Pentium
LEA.L (A0), A2Load the address pointed to by A0 into A2MC68000