The sparcv9 uses the generic sparc64 sysdeps/sparc/sparc64/memmove.S implementation and the initial size test is done with a signed comparison: ENTRY(memmove) mov %o0, %g2 /* Save pointer to destination */ cmp %o1, %o0 /* if from address is >= to use forward copy */ bgeu,a %XCC, 2f /* else use backward if ... */ cmp %o2, 17 /* delay slot, for small counts copy bytes */ sub %o0, %o1, %o4 /* get difference of two addresses */ cmp %o2, %o4 /* compare size and difference of addresses */ bgu %XCC, .Lovbc /* if size is bigger, have to do overlapped copy */ cmp %o2, 17 /* delay slot, for small counts copy bytes */ /* * normal, copy forwards */ 2: ble %XCC, .Ldbytecp andcc %o1, 3, %o5 /* is src word aligned */ Where it should be a 'bleu' due the buffer length being a size_t.
Fixed on 2.39.