memcpy(3) no longer deals with overlap case; it's now forward-only.
This commit is contained in:
parent
4fcc3e8569
commit
333f362341
|
@ -36,7 +36,7 @@
|
|||
#include <machine/asm.h>
|
||||
|
||||
#if defined(LIBC_SCCS)
|
||||
RCSID("$NetBSD: bcopy.S,v 1.9 2002/10/29 06:35:17 junyoung Exp $")
|
||||
RCSID("$NetBSD: bcopy.S,v 1.10 2002/10/29 06:53:18 junyoung Exp $")
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
@ -64,9 +64,11 @@ ENTRY(bcopy)
|
|||
movl 16(%esp),%edi
|
||||
#endif
|
||||
movl 20(%esp),%ecx
|
||||
#if !defined(MEMCOPY)
|
||||
movl %edi,%edx
|
||||
subl %esi,%edx
|
||||
cmpl %ecx,%edx /* overlapping? */
|
||||
#endif
|
||||
movl %ecx,%edx
|
||||
jb 1f
|
||||
cld /* nope, copy forwards. */
|
||||
|
|
Loading…
Reference in New Issue