]> git.ipfire.org Git - thirdparty/glibc.git/blame - sysdeps/x86_64/memmove.S
Update copyright dates with scripts/update-copyrights
[thirdparty/glibc.git] / sysdeps / x86_64 / memmove.S
CommitLineData
c867597b 1/* Optimized memmove for x86-64.
6d7e8eda 2 Copyright (C) 2016-2023 Free Software Foundation, Inc.
c867597b
L
3 This file is part of the GNU C Library.
4
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.
9
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.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
5a82c748 17 <https://www.gnu.org/licenses/>. */
c867597b 18
c867597b
L
19
20#ifdef USE_MULTIARCH
fc11ff8d 21# if !IS_IN (libc)
c867597b
L
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
fc11ff8d 31#if !defined USE_MULTIARCH || !IS_IN (libc)
c867597b
L
32# define MEMPCPY_SYMBOL(p,s) __mempcpy
33#endif
c867597b 34
b6a02c36
NG
35#define MEMMOVE_CHK_SYMBOL(p,s) p
36#define MEMMOVE_SYMBOL(p,s) memmove
37
38
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"
42
43#include "isa-default-impl.h"
44
45weak_alias (__mempcpy, mempcpy)
c867597b
L
46
47#ifndef USE_MULTIARCH
48libc_hidden_builtin_def (memmove)
49# if defined SHARED && IS_IN (libc)
50strong_alias (memmove, __memcpy)
51libc_hidden_ver (memmove, memcpy)
52# endif
53libc_hidden_def (__mempcpy)
54weak_alias (__mempcpy, mempcpy)
55libc_hidden_builtin_def (mempcpy)
56
b6a02c36 57
c867597b
L
58# if defined SHARED && IS_IN (libc)
59# undef memcpy
60# include <shlib-compat.h>
61versioned_symbol (libc, __memcpy, memcpy, GLIBC_2_14);
c867597b
L
62# endif
63#endif