5 .type _strncmp,@function
9 ;; R3: max number of bytes to compare
10 #ifdef __RX_DISALLOW_STRING_INSNS__
11 cmp #0, r3 ; For a length of zero, return zero
25 3: and #0xff, r4 ; We need to perform an unsigned comparison of the bytes.
33 scmpu ; Perform the string comparison
34 bnc 1f ; If Carry is not set skip over
35 scne.L r1 ; Set result based on Z flag
38 mov #-1,r1 ; Carry not set, result should be negative
41 .size _strncmp, . - _strncmp