]> git.ipfire.org Git - thirdparty/glibc.git/blob - sysdeps/sparc/sparc-ifunc.h
61ccc0117997b78c46a1139c9ced3d6fd5f0c4d1
[thirdparty/glibc.git] / sysdeps / sparc / sparc-ifunc.h
1 /* This file is part of the GNU C Library.
2 Copyright (C) 2012-2020 Free Software Foundation, Inc.
3
4 The GNU C Library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Lesser General Public
6 License as published by the Free Software Foundation; either
7 version 2.1 of the License, or (at your option) any later version.
8
9 The GNU C Library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Lesser General Public License for more details.
13
14 You should have received a copy of the GNU Lesser General Public
15 License along with the GNU C Library; if not, see
16 <https://www.gnu.org/licenses/>. */
17
18 #include <sysdep.h>
19
20 #define INIT_ARCH()
21
22 #define sparc_libc_ifunc_redirected(redirected_name, name, expr) \
23 __ifunc (redirected_name, name, expr(hwcap), int hwcap, INIT_ARCH)
24
25 #define sparc_libm_ifunc(name, expr) \
26 __ifunc (name, name, expr, int hwcap, libm_ifunc_init)
27
28 #define sparc_libc_ifunc(name, expr) sparc_libm_ifunc (name, expr)
29
30 #define sparc_libm_ifunc_redirected(redirected_name, name, expr) \
31 __ifunc (redirected_name, name, expr, int hwcap, libm_ifunc_init)
32
33 /* It essentially does libc_hidden_builtin_def (name) and redirect
34 the internal redirected symbol to ifunc implementation. */
35 #if defined SHARED
36 # define sparc_ifunc_redirected_hidden_def(redirect_name, name) \
37 __hidden_ver1 (name, __GI_##name, redirect_name) \
38 __attribute__ ((visibility ("hidden"))) \
39 __attribute_copy__ (name);
40 #else
41 # define sparc_ifunc_redirected_hidden_def(redirect_name, name)
42 #endif