bcmp

bcmp

Function

bcmp

Compares byte strings

Syntax

#include <ultra64.h>        /* os.h */
int bcmp(const void *s1, const void *s2, int length);

Arguments

s1
Byte string 1
s2
Byte string 2
length
Data length

Return

Comparison Result

0 Equal
1 Byte string 1 > Byte string 2
-1 Byte string 1 < Byte string 2

Description

This function compares two specified byte strings. It is assumed that at least length bytes are secured for each byte string.

Note

This function is designed for optimization at the assembler level, so the process can execute quickly.

See Also

bcopy, bzero

Revision History

02/01/99 Entirely revised