diff options
Diffstat (limited to 'sysdeps/powerpc/powerpc32/power4/multiarch/memcpy.c')
-rw-r--r-- | sysdeps/powerpc/powerpc32/power4/multiarch/memcpy.c | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/sysdeps/powerpc/powerpc32/power4/multiarch/memcpy.c b/sysdeps/powerpc/powerpc32/power4/multiarch/memcpy.c index f379e479a2..7db588fb76 100644 --- a/sysdeps/powerpc/powerpc32/power4/multiarch/memcpy.c +++ b/sysdeps/powerpc/powerpc32/power4/multiarch/memcpy.c @@ -1,5 +1,5 @@ /* Multiple versions of memcpy. - Copyright (C) 2013-2016 Free Software Foundation, Inc. + Copyright (C) 2013-2018 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -20,6 +20,8 @@ DSO. In static binaries we need memcpy before the initialization happened. */ #if defined SHARED && IS_IN (libc) +# undef memcpy +# define memcpy __redirect_memcpy # include <string.h> # include <shlib-compat.h> # include "init-arch.h" @@ -29,17 +31,18 @@ extern __typeof (memcpy) __memcpy_cell attribute_hidden; extern __typeof (memcpy) __memcpy_power6 attribute_hidden; extern __typeof (memcpy) __memcpy_a2 attribute_hidden; extern __typeof (memcpy) __memcpy_power7 attribute_hidden; +# undef memcpy /* Avoid DWARF definition DIE on ifunc symbol so that GDB can handle ifunc symbol properly. */ -libc_ifunc (memcpy, - (hwcap & PPC_FEATURE_HAS_VSX) - ? __memcpy_power7 : - (hwcap & PPC_FEATURE_ARCH_2_06) - ? __memcpy_a2 : - (hwcap & PPC_FEATURE_ARCH_2_05) - ? __memcpy_power6 : - (hwcap & PPC_FEATURE_CELL_BE) - ? __memcpy_cell - : __memcpy_ppc); +libc_ifunc_redirected (__redirect_memcpy, memcpy, + (hwcap & PPC_FEATURE_HAS_VSX) + ? __memcpy_power7 + : (hwcap & PPC_FEATURE_ARCH_2_06) + ? __memcpy_a2 + : (hwcap & PPC_FEATURE_ARCH_2_05) + ? __memcpy_power6 + : (hwcap & PPC_FEATURE_CELL_BE) + ? __memcpy_cell + : __memcpy_ppc); #endif |