From: Joseph Myers Date: Mon, 21 May 2012 10:45:52 +0000 (+0000) Subject: Update ARM hwcap code. X-Git-Tag: glibc-2.16-ports-before-merge~90 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c0ddea5a1ff43f59d10a754ba89d1007e0c03bb1;p=thirdparty%2Fglibc.git Update ARM hwcap code. --- diff --git a/ChangeLog.arm b/ChangeLog.arm index c87595225e3..bb1bab7ee25 100644 --- a/ChangeLog.arm +++ b/ChangeLog.arm @@ -1,5 +1,32 @@ 2012-05-21 Joseph Myers + * sysdeps/unix/sysv/linux/arm/bits/hwcap.h: New file. Macros + taken from sysdeps/unix/sysv/linux/arm/sysdep.h. + (HWCAP_ARM_TLS): New macro. + (HWCAP_ARM_VFPv4): Likewise. + (HWCAP_ARM_IDIVA): Likewise. + (HWCAP_ARM_IDIVT): Likewise. + * sysdeps/unix/sysv/linux/arm/sysdep.h: Include . + (HWCAP_ARM_SWP): Remove macro. Moved to . + (HWCAP_ARM_HALF): Likewise. + (HWCAP_ARM_THUMB): Likewise. + (HWCAP_ARM_26BIT): Likewise. + (HWCAP_ARM_FAST_MULT): Likewise. + (HWCAP_ARM_FPA): Likewise. + (HWCAP_ARM_VFP): Likewise. + (HWCAP_ARM_EDSP): Likewise. + (HWCAP_ARM_JAVA): Likewise. + (HWCAP_ARM_IWMMXT): Likewise. + (HWCAP_ARM_CRUNCH): Likewise. + (HWCAP_ARM_THUMBEE): Likewise. + (HWCAP_ARM_NEON): Likewise. + (HWCAP_ARM_VFPv3): Likewise. + (HWCAP_ARM_VFPv3D16): Likewise. + * sysdeps/unix/sysv/linux/arm/dl-procinfo.c (_dl_arm_cap_flags): + Add "tls", "vfpv4", "idiva" and "idivt". + * sysdeps/unix/sysv/linux/arm/dl-procinfo.h (_DL_HWCAP_COUNT): + Increase to 19. + * sysdeps/unix/sysv/linux/arm/nptl/libc.abilist: Update. 2012-05-19 Joseph Myers diff --git a/sysdeps/unix/sysv/linux/arm/bits/hwcap.h b/sysdeps/unix/sysv/linux/arm/bits/hwcap.h new file mode 100644 index 00000000000..ddfed85053f --- /dev/null +++ b/sysdeps/unix/sysv/linux/arm/bits/hwcap.h @@ -0,0 +1,42 @@ +/* Defines for bits in AT_HWCAP. ARM Linux version. + Copyright (C) 2012 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 + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + . */ + +#ifndef _SYS_AUXV_H +# error "Never include directly; use instead." +#endif + +/* The following must match the kernel's . */ +#define HWCAP_ARM_SWP 1 +#define HWCAP_ARM_HALF 2 +#define HWCAP_ARM_THUMB 4 +#define HWCAP_ARM_26BIT 8 +#define HWCAP_ARM_FAST_MULT 16 +#define HWCAP_ARM_FPA 32 +#define HWCAP_ARM_VFP 64 +#define HWCAP_ARM_EDSP 128 +#define HWCAP_ARM_JAVA 256 +#define HWCAP_ARM_IWMMXT 512 +#define HWCAP_ARM_CRUNCH 1024 +#define HWCAP_ARM_THUMBEE 2048 +#define HWCAP_ARM_NEON 4096 +#define HWCAP_ARM_VFPv3 8192 +#define HWCAP_ARM_VFPv3D16 16384 +#define HWCAP_ARM_TLS 32768 +#define HWCAP_ARM_VFPv4 65536 +#define HWCAP_ARM_IDIVA 131072 +#define HWCAP_ARM_IDIVT 262144 diff --git a/sysdeps/unix/sysv/linux/arm/dl-procinfo.c b/sysdeps/unix/sysv/linux/arm/dl-procinfo.c index 64a444482a4..227492ef90f 100644 --- a/sysdeps/unix/sysv/linux/arm/dl-procinfo.c +++ b/sysdeps/unix/sysv/linux/arm/dl-procinfo.c @@ -1,5 +1,5 @@ /* Data for Linux/ARM version of processor capability information. - Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc. + Copyright (C) 2001-2012 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Philip Blundell , 2001. @@ -46,12 +46,13 @@ #if !defined PROCINFO_DECL && defined SHARED ._dl_arm_cap_flags #else -PROCINFO_CLASS const char _dl_arm_cap_flags[15][10] +PROCINFO_CLASS const char _dl_arm_cap_flags[19][10] #endif #ifndef PROCINFO_DECL = { "swp", "half", "thumb", "26bit", "fastmult", "fpa", "vfp", "edsp", "java", "iwmmxt", "crunch", "thumbee", "neon", "vfpv3", "vfpv3d16", + "tls", "vfpv4", "idiva", "idivt", } #endif #if !defined SHARED || defined PROCINFO_DECL diff --git a/sysdeps/unix/sysv/linux/arm/dl-procinfo.h b/sysdeps/unix/sysv/linux/arm/dl-procinfo.h index 7fe6674d490..bea7100e13f 100644 --- a/sysdeps/unix/sysv/linux/arm/dl-procinfo.h +++ b/sysdeps/unix/sysv/linux/arm/dl-procinfo.h @@ -1,5 +1,5 @@ /* Linux/ARM version of processor capability information handling macros. - Copyright (C) 2001, 2002, 2004, 2006 Free Software Foundation, Inc. + Copyright (C) 2001-2012 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Philip Blundell , 2001. @@ -23,7 +23,7 @@ #include #include -#define _DL_HWCAP_COUNT 15 +#define _DL_HWCAP_COUNT 19 /* The kernel provides platform data but it is not interesting. */ #define _DL_HWCAP_PLATFORM 0 diff --git a/sysdeps/unix/sysv/linux/arm/sysdep.h b/sysdeps/unix/sysv/linux/arm/sysdep.h index ef83ec24882..30fa599e056 100644 --- a/sysdeps/unix/sysv/linux/arm/sysdep.h +++ b/sysdeps/unix/sysv/linux/arm/sysdep.h @@ -40,23 +40,8 @@ #undef SYS_ify #define SYS_ify(syscall_name) (__NR_##syscall_name) - -/* The following must match the kernel's . */ -#define HWCAP_ARM_SWP 1 -#define HWCAP_ARM_HALF 2 -#define HWCAP_ARM_THUMB 4 -#define HWCAP_ARM_26BIT 8 -#define HWCAP_ARM_FAST_MULT 16 -#define HWCAP_ARM_FPA 32 -#define HWCAP_ARM_VFP 64 -#define HWCAP_ARM_EDSP 128 -#define HWCAP_ARM_JAVA 256 -#define HWCAP_ARM_IWMMXT 512 -#define HWCAP_ARM_CRUNCH 1024 -#define HWCAP_ARM_THUMBEE 2048 -#define HWCAP_ARM_NEON 4096 -#define HWCAP_ARM_VFPv3 8192 -#define HWCAP_ARM_VFPv3D16 16384 +#define _SYS_AUXV_H 1 +#include #ifdef __ASSEMBLER__