xref: /aosp_15_r20/external/musl/src/string/x86_64/memmove.s (revision c9945492fdd68bbe62686c5b452b4dc1be3f8453)
1.global memmove
2.type memmove,@function
3memmove:
4	mov %rdi,%rax
5	sub %rsi,%rax
6	cmp %rdx,%rax
7.hidden __memcpy_fwd
8	jae __memcpy_fwd
9	mov %rdx,%rcx
10	lea -1(%rdi,%rdx),%rdi
11	lea -1(%rsi,%rdx),%rsi
12	std
13	rep movsb
14	cld
15	lea 1(%rdi),%rax
16	ret
17