configure: Move nm, objdump, and readelf to LIBC_PROG_BINUTILS
[glibc.git] / sysdeps / x86_64 / memmove.S
blobf0b84e3b520466ba435cd45222c10cf0915dc013
1 /* Optimized memmove for x86-64.
2    Copyright (C) 2016-2023 Free Software Foundation, Inc.
3    This file is part of the GNU C Library.
5    The GNU C Library is free software; you can redistribute it and/or
6    modify it under the terms of the GNU Lesser General Public
7    License as published by the Free Software Foundation; either
8    version 2.1 of the License, or (at your option) any later version.
10    The GNU C Library is distributed in the hope that it will be useful,
11    but WITHOUT ANY WARRANTY; without even the implied warranty of
12    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13    Lesser General Public License for more details.
15    You should have received a copy of the GNU Lesser General Public
16    License along with the GNU C Library; if not, see
17    <https://www.gnu.org/licenses/>.  */
20 #ifdef USE_MULTIARCH
21 # if !IS_IN (libc)
22 #  define MEMCPY_SYMBOL(p,s)            memcpy
23 # endif
24 #else
25 # if defined SHARED && IS_IN (libc)
26 #  define MEMCPY_SYMBOL(p,s)            __memcpy
27 # else
28 #  define MEMCPY_SYMBOL(p,s)            memcpy
29 # endif
30 #endif
31 #if !defined USE_MULTIARCH || !IS_IN (libc)
32 # define MEMPCPY_SYMBOL(p,s)            __mempcpy
33 #endif
35 #define MEMMOVE_CHK_SYMBOL(p,s) p
36 #define MEMMOVE_SYMBOL(p,s)     memmove
39 #define DEFAULT_IMPL_V1 "multiarch/memmove-sse2-unaligned-erms.S"
40 #define DEFAULT_IMPL_V3 "multiarch/memmove-avx-unaligned-erms.S"
41 #define DEFAULT_IMPL_V4 "multiarch/memmove-evex-unaligned-erms.S"
43 #include "isa-default-impl.h"
45 weak_alias (__mempcpy, mempcpy)
47 #ifndef USE_MULTIARCH
48 libc_hidden_builtin_def (memmove)
49 # if defined SHARED && IS_IN (libc)
50 strong_alias (memmove, __memcpy)
51 libc_hidden_ver (memmove, memcpy)
52 # endif
53 libc_hidden_def (__mempcpy)
54 weak_alias (__mempcpy, mempcpy)
55 libc_hidden_builtin_def (mempcpy)
58 # if defined SHARED && IS_IN (libc)
59 #  undef memcpy
60 #  include <shlib-compat.h>
61 versioned_symbol (libc, __memcpy, memcpy, GLIBC_2_14);
62 # endif
63 #endif