This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch roland/arm-ifunc-test created. glibc-2.17-823-g34aec16


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, roland/arm-ifunc-test has been created
        at  34aec1678ea363937599c0bd39b1850161b0900b (commit)

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=34aec1678ea363937599c0bd39b1850161b0900b

commit 34aec1678ea363937599c0bd39b1850161b0900b
Author: Roland McGrath <roland@hack.frob.com>
Date:   Mon Jun 17 13:50:36 2013 -0700

    ARM: Clean up __libc_ifunc_impl_list

diff --git a/ports/ChangeLog.arm b/ports/ChangeLog.arm
index 00f3789..f6243d4 100644
--- a/ports/ChangeLog.arm
+++ b/ports/ChangeLog.arm
@@ -1,3 +1,9 @@
+2013-06-17  Roland McGrath  <roland@hack.frob.com>
+
+	* sysdeps/arm/armv7/multiarch/ifunc-impl-list.c (__libc_ifunc_impl_list)
+	[__ARM_NEON__]: Do not refer to HWCAP_ARM_NEON.
+	[!__SOFTFP__]: Do not refer to HWCAP_ARM_VFP.
+
 2013-06-17  Joseph Myers  <joseph@codesourcery.com>
 
 	[BZ #14907]
diff --git a/ports/sysdeps/arm/armv7/multiarch/ifunc-impl-list.c b/ports/sysdeps/arm/armv7/multiarch/ifunc-impl-list.c
index 9c2487f..3ef713c 100644
--- a/ports/sysdeps/arm/armv7/multiarch/ifunc-impl-list.c
+++ b/ports/sysdeps/arm/armv7/multiarch/ifunc-impl-list.c
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#include <stdbool.h>
 #include <string.h>
 #include <ldsodefs.h>
 #include <sysdep.h>
@@ -29,21 +30,22 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
 			size_t max)
 {
   size_t i = 0;
-  int hwcap;
 
-  hwcap = GLRO(dl_hwcap);
+  bool use_neon = true;
+#ifndef __ARM_NEON__
+  use_neon = (GLRO(dl_hwcap) & HWCAP_ARM_NEON) != 0;
+# define __memcpy_neon	memcpy
+#endif
 
-  IFUNC_IMPL (i, name, memcpy,
-	      IFUNC_IMPL_ADD (array, i, memcpy, hwcap & HWCAP_ARM_NEON,
-#ifdef __ARM_NEON__
-                              memcpy
-#else
-			      __memcpy_neon
+  bool use_vfp = true;
+#ifdef __SOFTFP__
+  use_neon = (GLRO(dl_hwcap) & HWCAP_ARM_VFP) != 0;
 #endif
-                              )
+
+  IFUNC_IMPL (i, name, memcpy,
+	      IFUNC_IMPL_ADD (array, i, memcpy, use_neon, __memcpy_neon)
 #ifndef __ARM_NEON__
-	      IFUNC_IMPL_ADD (array, i, memcpy, hwcap & HWCAP_ARM_VFP,
-			      __memcpy_vfp)
+	      IFUNC_IMPL_ADD (array, i, memcpy, use_vfp, __memcpy_vfp)
 #endif
 	      IFUNC_IMPL_ADD (array, i, memcpy, 1, __memcpy_arm));
 

-----------------------------------------------------------------------


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]