MI_CpuComp*

Syntax

#include <nitro/mi.h>

int MI_CpuComp8( const void* mem1, const void* mem2, u32 size );
int MI_CpuComp16( const void* mem1, const void* mem2, u32 size );
int MI_CpuComp32( const void* mem1, const void* mem2, u32 size );

Arguments

mem1 First address to compare.
mem2 Second address to compare.
size Comparison size.

Return Values

Returns 0 if the addresses being compared are equal, a negative value if mem1 is smaller, or a positive value if mem1 is larger.

Description

Uses CPU to perform a memory comparison.

MI_CpuComp8() compares using 8-bit units. The alignment of the addresses to compare does not matter.

MI_CpuComp16() compares using 16-bit units. The second address to compare must be 2-byte aligned.

MI_CpuComp32() compares using 32-bit units. The second address to compare must be 4-byte aligned.

Internal Operation

Processing is done by the CPU only and does not use the DMA controller. It does not use a system call.

See Also

Revision History

2007/12/10 Initial version.


CONFIDENTIAL