|
Packit Service |
72e31c |
/* Multiple versions of memmem.
|
|
Packit Service |
72e31c |
Copyright (C) 2018 Free Software Foundation, Inc.
|
|
Packit Service |
72e31c |
This file is part of the GNU C Library.
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
The GNU C Library is free software; you can redistribute it and/or
|
|
Packit Service |
72e31c |
modify it under the terms of the GNU Lesser General Public
|
|
Packit Service |
72e31c |
License as published by the Free Software Foundation; either
|
|
Packit Service |
72e31c |
version 2.1 of the License, or (at your option) any later version.
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
The GNU C Library is distributed in the hope that it will be useful,
|
|
Packit Service |
72e31c |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Packit Service |
72e31c |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Packit Service |
72e31c |
Lesser General Public License for more details.
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
You should have received a copy of the GNU Lesser General Public
|
|
Packit Service |
72e31c |
License along with the GNU C Library; if not, see
|
|
Packit Service |
72e31c |
<http://www.gnu.org/licenses/>. */
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
#include <ifunc-memmem.h>
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
#if HAVE_MEMMEM_IFUNC
|
|
Packit Service |
72e31c |
# define memmem __redirect_memmem
|
|
Packit Service |
72e31c |
# define __memmem __redirect___memmem
|
|
Packit Service |
72e31c |
# include <string.h>
|
|
Packit Service |
72e31c |
# include <ifunc-resolve.h>
|
|
Packit Service |
72e31c |
# undef memmem
|
|
Packit Service |
72e31c |
# undef __memmem
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
# if HAVE_MEMMEM_C
|
|
Packit Service |
72e31c |
extern __typeof (__redirect_memmem) MEMMEM_C attribute_hidden;
|
|
Packit Service |
72e31c |
# endif
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
# if HAVE_MEMMEM_Z13
|
|
Packit Service |
72e31c |
extern __typeof (__redirect_memmem) MEMMEM_Z13 attribute_hidden;
|
|
Packit Service |
72e31c |
# endif
|
|
Packit Service |
72e31c |
|
|
Packit Service |
72e31c |
s390_libc_ifunc_expr (__redirect_memmem, __memmem,
|
|
Packit Service |
72e31c |
(HAVE_MEMMEM_Z13 && (hwcap & HWCAP_S390_VX))
|
|
Packit Service |
72e31c |
? MEMMEM_Z13
|
|
Packit Service |
72e31c |
: MEMMEM_DEFAULT
|
|
Packit Service |
72e31c |
)
|
|
Packit Service |
72e31c |
weak_alias (__memmem, memmem)
|
|
Packit Service |
72e31c |
#endif
|