Blame sysdeps/s390/memmove.c

Packit Service e721db
/* Multiple versions of memmove.
Packit Service e721db
   Copyright (C) 2016-2018 Free Software Foundation, Inc.
Packit Service e721db
   This file is part of the GNU C Library.
Packit Service e721db
Packit Service e721db
   The GNU C Library is free software; you can redistribute it and/or
Packit Service e721db
   modify it under the terms of the GNU Lesser General Public
Packit Service e721db
   License as published by the Free Software Foundation; either
Packit Service e721db
   version 2.1 of the License, or (at your option) any later version.
Packit Service e721db
Packit Service e721db
   The GNU C Library is distributed in the hope that it will be useful,
Packit Service e721db
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service e721db
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit Service e721db
   Lesser General Public License for more details.
Packit Service e721db
Packit Service e721db
   You should have received a copy of the GNU Lesser General Public
Packit Service e721db
   License along with the GNU C Library; if not, see
Packit Service e721db
   <http://www.gnu.org/licenses/>.  */
Packit Service e721db
Packit Service e721db
#include <ifunc-memcpy.h>
Packit Service e721db
Packit Service e721db
#if HAVE_MEMMOVE_IFUNC
Packit Service e721db
/* If we don't use ifunc, an alias is defined for memmove
Packit Service e721db
   in sysdeps/s390/memmove-c.c or sysdeps/s390/memcpy.S
Packit Service e721db
   depending on the used default implementation.  */
Packit Service e721db
# undef memmove
Packit Service e721db
# define memmove __redirect_memmove
Packit Service e721db
# include <string.h>
Packit Service e721db
# include <ifunc-resolve.h>
Packit Service e721db
# undef memmove
Packit Service e721db
Packit Service e721db
# if HAVE_MEMMOVE_C
Packit Service e721db
extern __typeof (__redirect_memmove) MEMMOVE_C attribute_hidden;
Packit Service e721db
# endif
Packit Service e721db
Packit Service e721db
# if HAVE_MEMMOVE_Z13
Packit Service e721db
extern __typeof (__redirect_memmove) MEMMOVE_Z13 attribute_hidden;
Packit Service e721db
# endif
Packit Service e721db
Packit Service e721db
s390_libc_ifunc_expr (__redirect_memmove, memmove,
Packit Service e721db
		      (HAVE_MEMMOVE_Z13 && (hwcap & HWCAP_S390_VX))
Packit Service e721db
		      ? MEMMOVE_Z13
Packit Service e721db
		      : MEMMOVE_DEFAULT
Packit Service e721db
		      )
Packit Service e721db
#endif