# MI_CpuMove*

## Syntax

  `#include <nitro/mi.h>`
  `void MI_CpuMove16( const void* src, void* dest, u32 size );`
  `void MI_CpuMove32( const void* src, void* dest, u32 size );`
  `void MI_CpuMoveFast( const void* src, void* dest, u32 size );`
  `void MI_CpuMove( const void* src, void* dest, u32 size );`

## Arguments

src | The transfer source address.
dest | The transfer destination address.
size | Transfer size.

## Return Values

None.

## Description

Moves data in the CPU. Data can be moved properly, even if the source and destination transfer regions overlap each other.

`MI_CpuMove16()` moves data in 16-bit units. Both the transfer source address and the transfer destination address must be 2-byte aligned.

`MI_CpuMove32()` moves data in 32-bit units. Both the transfer source address and the transfer destination address must be 4-byte aligned.

`MI_CpuMoveFast()` moves data at high speed in 32-bit units. Both the transfer source address and the transfer destination address must be 4-byte aligned. The transfer size is an integral multiple of 4 bytes. It does not have to be an integral multiple of 32 bytes. After transferring in 32-byte units, the fractional part is handled by performing the same process as `MI_CpuMove32()`.

`MI_CpuMove()` selects the most efficient method possible based on the transfer destination address, and also moves data in 32-byte units in addition to moving data in 8-bit, 16-bit and 32-bit units as appropriate. There are no limitations on either the alignment or transfer size of the source or destination addresses.

## Internal Operation

Processing is done by the CPU only and does not use the DMA controller. It does not use a system call. `MI_CpuMove()` may sometimes move data in 8-bit units depending on the target address, so do not use it if you are accessing VRAM directly, if in NITRO mode (or even in TWL mode if the "byte write" extensions for VRAM have not been enabled).

## See Also

`MI_CpuCopy*, MI_CpuFill*, MI_CpuClear*, MI_CpuSend*, MI_DmaCopy*
`

## Revision History

2007/12/10 Initial version.

CONFIDENTIAL