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 rsa/2.17_backports_v3 updated. glibc-2.17-35-g7dfe8a3


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, rsa/2.17_backports_v3 has been updated
       via  7dfe8a35215a019f552f117d907eca294225c121 (commit)
       via  e0c595c971d958da58533a2b9b59f46a71a1e4cf (commit)
       via  2d718ff7745d89dcc2a630fe72783acf109cadc0 (commit)
       via  a6d45052042c1fc962523633c0489634864e1a02 (commit)
       via  42b373ad467ba426610a358d90034bcf68abb15f (commit)
       via  e934fb28368b5a36546c7faafab141fcd71172db (commit)
       via  979bcc3f2854d938c6e3facf8d0308f4721029a0 (commit)
       via  ed81f668f7c9eff0692c3c81691a7380b55063ff (commit)
      from  01c3d9bb14a1e90159d6999cf3469e62c0c5d4b2 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

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

commit 7dfe8a35215a019f552f117d907eca294225c121
Author: Adhemerval Zanella <azanella@linux.vnet.ibm.com>
Date:   Wed Jun 12 10:21:22 2013 -0500

    Fix unsafe compiler optimization
    
    GCC 4.8 enables -ftree-loop-distribute-patterns at -O3 by default and
    this optimization may transform loops into memset/memmove calls. Without
    proper handling this may generate unexpected PLT calls on GLIBC.
    This patch fixes by create memset/memmove alias to internal GLIBC
    __GI_memset/__GI_memmove symbols.
    (cherry picked from commit 6a97b62a5b4f18aea849d6f4d8de58d1469d2521)

diff --git a/ChangeLog b/ChangeLog
index d622405..9737691 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2013-06-11  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
+
+	[BZ #15605]
+	* sysdeps/generic/symbol-hacks.h: Add workaround for memset/memmove calls
+	generated by the compiler on loop optimizations.
+	* sysdeps/wordsize-32/symbol-hacks.h: Include next symbol-hacks.h for
+	general definitions.
+
 2013-06-11  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
 
 	* sysdeps/powerpc/dl-procinfo.c (_dl_powerpc_platforms): Add ppc405,
diff --git a/sysdeps/generic/symbol-hacks.h b/sysdeps/generic/symbol-hacks.h
index bc7b4c4..9eaf014 100644
--- a/sysdeps/generic/symbol-hacks.h
+++ b/sysdeps/generic/symbol-hacks.h
@@ -1 +1,6 @@
-/* Fortunately nothing to do.  */
+/* Some compiler optimizations may transform loops into memset/memmove
+   calls and without proper declaration it may generate PLT calls.  */
+#if !defined __ASSEMBLER__ && !defined NOT_IN_libc && defined SHARED
+asm ("memmove = __GI_memmove");
+asm ("memset = __GI_memset");
+#endif
diff --git a/sysdeps/wordsize-32/symbol-hacks.h b/sysdeps/wordsize-32/symbol-hacks.h
index 52a14fc..ad5b231 100644
--- a/sysdeps/wordsize-32/symbol-hacks.h
+++ b/sysdeps/wordsize-32/symbol-hacks.h
@@ -16,6 +16,8 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#include_next "symbol-hacks.h"
+
 /* A very dirty trick: gcc emits references to __divdi3, __udivdi3,
    __moddi3, and __umoddi3.  These functions are exported and
    therefore we get PLTs.  Unnecessarily so.  Changing gcc is a big

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=e0c595c971d958da58533a2b9b59f46a71a1e4cf

commit e0c595c971d958da58533a2b9b59f46a71a1e4cf
Author: Ryan S. Arnold <rsa@linux.vnet.ibm.com>
Date:   Tue Jun 11 09:33:33 2013 -0500

    PowerPC: Remove redundant ports/sysdeps/powerpc/dl-procinfo.[ch].
    (cherry picked from commit d04310f210734448a5b950988d49dcea145df9c1)

diff --git a/ports/ChangeLog.powerpc b/ports/ChangeLog.powerpc
index ae61953..c558414 100644
--- a/ports/ChangeLog.powerpc
+++ b/ports/ChangeLog.powerpc
@@ -1,5 +1,12 @@
 2013-06-11  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
 
+	* sysdeps/powerpc/dl-procinfo.c: Remove as this is now redundant with
+	glibc/sysdeps/powerpc/dl-procinfo.c.
+	* sysdeps/powerpc/dl-procinfo.h: Remove as this is now redundant with
+	glibc/sysdeps/powerpc/dl-procinfo.h
+
+2013-06-11  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
+
 	 * sysdeps/powerpc/dl-procinfo.h: Fix whitespace by correcting
 	 spaces with tabs where appropriate.
 
diff --git a/ports/sysdeps/powerpc/dl-procinfo.c b/ports/sysdeps/powerpc/dl-procinfo.c
deleted file mode 100644
index 00cd497..0000000
--- a/ports/sysdeps/powerpc/dl-procinfo.c
+++ /dev/null
@@ -1,96 +0,0 @@
-/* Data for processor capability information.  PowerPC version.
-   Copyright (C) 2005-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
-   <http://www.gnu.org/licenses/>.  */
-
-/* This information must be kept in sync with the _DL_HWCAP_COUNT and
-   _DL_PLATFORM_COUNT definitions in procinfo.h.
-
-   If anything should be added here check whether the size of each string
-   is still ok with the given array size.
-
-   All the #ifdefs in the definitions are quite irritating but
-   necessary if we want to avoid duplicating the information.  There
-   are three different modes:
-
-   - PROCINFO_DECL is defined.  This means we are only interested in
-     declarations.
-
-   - PROCINFO_DECL is not defined:
-
-     + if SHARED is defined the file is included in an array
-       initializer.  The .element = { ... } syntax is needed.
-
-     + if SHARED is not defined a normal array initialization is
-       needed.
-  */
-
-#ifndef PROCINFO_CLASS
-# define PROCINFO_CLASS
-#endif
-
-#if !defined PROCINFO_DECL && defined SHARED
-  ._dl_powerpc_cap_flags
-#else
-PROCINFO_CLASS const char _dl_powerpc_cap_flags[25][10]
-#endif
-#ifndef PROCINFO_DECL
-= {
-    "vsx",
-    "arch_2_06", "power6x", "dfp", "pa6t",
-    "arch_2_05", "ic_snoop", "smt", "booke",
-    "cellbe", "power5+", "power5", "power4",
-    "notb", "efpdouble", "efpsingle", "spe",
-    "ucache", "4xxmac", "mmu", "fpu",
-    "altivec", "ppc601", "ppc64", "ppc32",
-  }
-#endif
-#if !defined SHARED || defined PROCINFO_DECL
-;
-#else
-,
-#endif
-
-#if !defined PROCINFO_DECL && defined SHARED
-  ._dl_powerpc_platforms
-#else
-PROCINFO_CLASS const char _dl_powerpc_platforms[13][12]
-#endif
-#ifndef PROCINFO_DECL
-= {
-    [PPC_PLATFORM_POWER4] = "power4",
-    [PPC_PLATFORM_PPC970] = "ppc970",
-    [PPC_PLATFORM_POWER5] = "power5",
-    [PPC_PLATFORM_POWER5_PLUS] = "power5+",
-    [PPC_PLATFORM_POWER6] = "power6",
-    [PPC_PLATFORM_CELL_BE] = "ppc-cell-be",
-    [PPC_PLATFORM_POWER6X] = "power6x",
-    [PPC_PLATFORM_POWER7] = "power7",
-    [PPC_PLATFORM_PPCA2] = "ppca2",
-    [PPC_PLATFORM_PPC405] = "ppc405",
-    [PPC_PLATFORM_PPC440] = "ppc440",
-    [PPC_PLATFORM_PPC464] = "ppc464",
-    [PPC_PLATFORM_PPC476] = "ppc476"
-  }
-#endif
-#if !defined SHARED || defined PROCINFO_DECL
-;
-#else
-,
-#endif
-
-#undef PROCINFO_DECL
-#undef PROCINFO_CLASS
diff --git a/ports/sysdeps/powerpc/dl-procinfo.h b/ports/sysdeps/powerpc/dl-procinfo.h
deleted file mode 100644
index 861d6b6..0000000
--- a/ports/sysdeps/powerpc/dl-procinfo.h
+++ /dev/null
@@ -1,172 +0,0 @@
-/* Processor capability information handling macros.  PowerPC version.
-   Copyright (C) 2005-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
-   <http://www.gnu.org/licenses/>.  */
-
-#ifndef _DL_PROCINFO_H
-#define _DL_PROCINFO_H 1
-
-#include <ldsodefs.h>
-#include <sysdep.h>	/* This defines the PPC_FEATURE_* macros.  */
-
-/* There are 25 bits used, but they are bits 7..31.  */
-#define _DL_HWCAP_FIRST		7
-#define _DL_HWCAP_COUNT		32
-
-/* These bits influence library search.  */
-#define HWCAP_IMPORTANT		(PPC_FEATURE_HAS_ALTIVEC \
-				+ PPC_FEATURE_HAS_DFP)
-
-#define _DL_PLATFORMS_COUNT	13
-
-#define _DL_FIRST_PLATFORM	32
-/* Mask to filter out platforms.  */
-#define _DL_HWCAP_PLATFORM	(((1ULL << _DL_PLATFORMS_COUNT) - 1) \
-				<< _DL_FIRST_PLATFORM)
-
-/* Platform bits (relative to _DL_FIRST_PLATFORM).  */
-#define PPC_PLATFORM_POWER4		0
-#define PPC_PLATFORM_PPC970		1
-#define PPC_PLATFORM_POWER5		2
-#define PPC_PLATFORM_POWER5_PLUS	3
-#define PPC_PLATFORM_POWER6		4
-#define PPC_PLATFORM_CELL_BE		5
-#define PPC_PLATFORM_POWER6X		6
-#define PPC_PLATFORM_POWER7		7
-#define PPC_PLATFORM_PPCA2		8
-#define PPC_PLATFORM_PPC405		9
-#define PPC_PLATFORM_PPC440		10
-#define PPC_PLATFORM_PPC464		11
-#define PPC_PLATFORM_PPC476		12
-
-static inline const char *
-__attribute__ ((unused))
-_dl_hwcap_string (int idx)
-{
-  return GLRO(dl_powerpc_cap_flags)[idx - _DL_HWCAP_FIRST];
-}
-
-static inline const char *
-__attribute__ ((unused))
-_dl_platform_string (int idx)
-{
-  return GLRO(dl_powerpc_platforms)[idx - _DL_FIRST_PLATFORM];
-}
-
-static inline int
-__attribute__ ((unused))
-_dl_string_hwcap (const char *str)
-{
-  for (int i = _DL_HWCAP_FIRST; i < _DL_HWCAP_COUNT; ++i)
-    if (strcmp (str, _dl_hwcap_string (i)) == 0)
-      return i;
-  return -1;
-}
-
-static inline int
-__attribute__ ((unused, always_inline))
-_dl_string_platform (const char *str)
-{
-  if (str == NULL)
-    return -1;
-
-  if (strncmp (str, GLRO(dl_powerpc_platforms)[PPC_PLATFORM_POWER4], 5) == 0)
-    {
-      int ret;
-      str += 5;
-      switch (*str)
-	{
-	case '4':
-	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER4;
-	  break;
-	case '5':
-	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER5;
-	  if (str[1] == '+')
-	    {
-	      ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER5_PLUS;
-	      ++str;
-	    }
-	  break;
-	case '6':
-	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER6;
-	  if (str[1] == 'x')
-	    {
-	      ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER6X;
-	      ++str;
-	    }
-	  break;
-	case '7':
-	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER7;
-	  break;
-	default:
-	  return -1;
-	}
-      if (str[1] == '\0')
-       return ret;
-    }
-  else if (strncmp (str, GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC970],
-		    3) == 0)
-    {
-      if (strcmp (str + 3, GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC970]
-			   + 3) == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC970;
-      else if (strcmp (str + 3,
-		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_CELL_BE] + 3)
-	       == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_CELL_BE;
-      else if (strcmp (str + 3,
-		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPCA2] + 3)
-	       == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPCA2;
-      else if (strcmp (str + 3,
-		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC405] + 3)
-	       == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC405;
-      else if (strcmp (str + 3,
-		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC440] + 3)
-	       == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC440;
-      else if (strcmp (str + 3,
-		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC464] + 3)
-	       == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC464;
-      else if (strcmp (str + 3,
-		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC476] + 3)
-	       == 0)
-	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC476;
-    }
-
-  return -1;
-}
-
-#ifdef IS_IN_rtld
-static inline int
-__attribute__ ((unused))
-_dl_procinfo (int word)
-{
-  _dl_printf ("AT_HWCAP:       ");
-
-  for (int i = _DL_HWCAP_FIRST; i < _DL_HWCAP_COUNT; ++i)
-    if (word & (1 << i))
-      _dl_printf (" %s", _dl_hwcap_string (i));
-
-  _dl_printf ("\n");
-
-  return 0;
-}
-#endif
-
-#endif /* dl-procinfo.h */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=2d718ff7745d89dcc2a630fe72783acf109cadc0

commit 2d718ff7745d89dcc2a630fe72783acf109cadc0
Author: Ryan S. Arnold <rsa@linux.vnet.ibm.com>
Date:   Tue Jun 11 09:32:41 2013 -0500

    PowerPC: Merge ports/ dl-procinfo.[ch] with base.
    (cherry picked from commit fac0c5f2b1dc0e1806cd95f2d6a4619929119f01)

diff --git a/ChangeLog b/ChangeLog
index a65548c..d622405 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2013-06-11  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
+
+	* sysdeps/powerpc/dl-procinfo.c (_dl_powerpc_platforms): Add ppc405,
+	ppc440, ppc464, and ppc476, merging from ports/ dl-procinfo.c.
+	* sysdeps/powerpc/dl-procinfo.h: Fix whitespace by correcting spaces
+	with tabs where appropriate.
+	[PPC_PLATFORM_PPC405]: Define new platform merging from ports/
+	dl-procinfo.h.
+	[PPC_PLATFORM_PPC440]: Likewise.
+	[PPC_PLATFORM_PPC464]: Likewise.
+	[PPC_PLATFORM_PPC476]: Likewise.
+	(_dl_string_platform): Add support for detecting ppc405, ppc440,
+	ppc464, and ppc476 platform strings merging from ports/
+	dl-procinfo.h.
+
 2013-05-24  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
 
 	* manual/platform.texi: Add PowerPC PPR function set documentation.
diff --git a/ports/ChangeLog.powerpc b/ports/ChangeLog.powerpc
index 3233b2c..ae61953 100644
--- a/ports/ChangeLog.powerpc
+++ b/ports/ChangeLog.powerpc
@@ -1,3 +1,8 @@
+2013-06-11  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
+
+	 * sysdeps/powerpc/dl-procinfo.h: Fix whitespace by correcting
+	 spaces with tabs where appropriate.
+
 2012-12-05  Joseph Myers  <joseph@codesourcery.com>
 
 	* sysdeps/powerpc/nofpu/fgetexcptflg.c (__fegetexceptflag):
diff --git a/ports/sysdeps/powerpc/dl-procinfo.h b/ports/sysdeps/powerpc/dl-procinfo.h
index 98c3775..861d6b6 100644
--- a/ports/sysdeps/powerpc/dl-procinfo.h
+++ b/ports/sysdeps/powerpc/dl-procinfo.h
@@ -20,37 +20,37 @@
 #define _DL_PROCINFO_H 1
 
 #include <ldsodefs.h>
-#include <sysdep.h>            /* This defines the PPC_FEATURE_* macros.  */
+#include <sysdep.h>	/* This defines the PPC_FEATURE_* macros.  */
 
 /* There are 25 bits used, but they are bits 7..31.  */
-#define _DL_HWCAP_FIRST                7
-#define _DL_HWCAP_COUNT                32
+#define _DL_HWCAP_FIRST		7
+#define _DL_HWCAP_COUNT		32
 
 /* These bits influence library search.  */
-#define HWCAP_IMPORTANT                (PPC_FEATURE_HAS_ALTIVEC \
-                               + PPC_FEATURE_HAS_DFP)
+#define HWCAP_IMPORTANT		(PPC_FEATURE_HAS_ALTIVEC \
+				+ PPC_FEATURE_HAS_DFP)
 
-#define _DL_PLATFORMS_COUNT    13
+#define _DL_PLATFORMS_COUNT	13
 
-#define _DL_FIRST_PLATFORM     32
+#define _DL_FIRST_PLATFORM	32
 /* Mask to filter out platforms.  */
-#define _DL_HWCAP_PLATFORM      (((1ULL << _DL_PLATFORMS_COUNT) - 1) \
-                               << _DL_FIRST_PLATFORM)
+#define _DL_HWCAP_PLATFORM	(((1ULL << _DL_PLATFORMS_COUNT) - 1) \
+				<< _DL_FIRST_PLATFORM)
 
 /* Platform bits (relative to _DL_FIRST_PLATFORM).  */
-#define PPC_PLATFORM_POWER4          0
-#define PPC_PLATFORM_PPC970          1
-#define PPC_PLATFORM_POWER5          2
-#define PPC_PLATFORM_POWER5_PLUS      3
-#define PPC_PLATFORM_POWER6          4
-#define PPC_PLATFORM_CELL_BE         5
-#define PPC_PLATFORM_POWER6X         6
-#define PPC_PLATFORM_POWER7          7
-#define PPC_PLATFORM_PPCA2           8
-#define PPC_PLATFORM_PPC405          9
-#define PPC_PLATFORM_PPC440          10
-#define PPC_PLATFORM_PPC464          11
-#define PPC_PLATFORM_PPC476          12
+#define PPC_PLATFORM_POWER4		0
+#define PPC_PLATFORM_PPC970		1
+#define PPC_PLATFORM_POWER5		2
+#define PPC_PLATFORM_POWER5_PLUS	3
+#define PPC_PLATFORM_POWER6		4
+#define PPC_PLATFORM_CELL_BE		5
+#define PPC_PLATFORM_POWER6X		6
+#define PPC_PLATFORM_POWER7		7
+#define PPC_PLATFORM_PPCA2		8
+#define PPC_PLATFORM_PPC405		9
+#define PPC_PLATFORM_PPC440		10
+#define PPC_PLATFORM_PPC464		11
+#define PPC_PLATFORM_PPC476		12
 
 static inline const char *
 __attribute__ ((unused))
@@ -88,65 +88,65 @@ _dl_string_platform (const char *str)
       int ret;
       str += 5;
       switch (*str)
-       {
-       case '4':
-         ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER4;
-         break;
-       case '5':
-         ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER5;
-         if (str[1] == '+')
-           {
-             ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER5_PLUS;
-             ++str;
-           }
-         break;
-       case '6':
-         ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER6;
-         if (str[1] == 'x')
-           {
-             ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER6X;
-             ++str;
-           }
-         break;
-       case '7':
-         ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER7;
-         break;
-       default:
-         return -1;
-       }
+	{
+	case '4':
+	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER4;
+	  break;
+	case '5':
+	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER5;
+	  if (str[1] == '+')
+	    {
+	      ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER5_PLUS;
+	      ++str;
+	    }
+	  break;
+	case '6':
+	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER6;
+	  if (str[1] == 'x')
+	    {
+	      ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER6X;
+	      ++str;
+	    }
+	  break;
+	case '7':
+	  ret = _DL_FIRST_PLATFORM + PPC_PLATFORM_POWER7;
+	  break;
+	default:
+	  return -1;
+	}
       if (str[1] == '\0')
        return ret;
     }
   else if (strncmp (str, GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC970],
-                   3) == 0)
+		    3) == 0)
     {
       if (strcmp (str + 3, GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC970]
-                          + 3) == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC970;
+			   + 3) == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC970;
       else if (strcmp (str + 3,
-                      GLRO(dl_powerpc_platforms)[PPC_PLATFORM_CELL_BE] + 3)
-              == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_CELL_BE;
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_CELL_BE] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_CELL_BE;
       else if (strcmp (str + 3,
-                      GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPCA2] + 3)
-              == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPCA2;
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPCA2] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPCA2;
       else if (strcmp (str + 3,
-                      GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC405] + 3)
-              == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC405;
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC405] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC405;
       else if (strcmp (str + 3,
-                      GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC440] + 3)
-              == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC440;
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC440] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC440;
       else if (strcmp (str + 3,
-                      GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC464] + 3)
-              == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC464;
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC464] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC464;
       else if (strcmp (str + 3,
-                      GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC476] + 3)
-              == 0)
-       return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC476;
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC476] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC476;
     }
 
   return -1;
diff --git a/sysdeps/powerpc/dl-procinfo.c b/sysdeps/powerpc/dl-procinfo.c
index bb2aea8..8488799 100644
--- a/sysdeps/powerpc/dl-procinfo.c
+++ b/sysdeps/powerpc/dl-procinfo.c
@@ -13,7 +13,7 @@
    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
+   License along with the GNU C Library.  If not, see
    <http://www.gnu.org/licenses/>.  */
 
 /* This information must be kept in sync with the _DL_HWCAP_COUNT and
@@ -67,7 +67,7 @@ PROCINFO_CLASS const char _dl_powerpc_cap_flags[25][10]
 #if !defined PROCINFO_DECL && defined SHARED
   ._dl_powerpc_platforms
 #else
-PROCINFO_CLASS const char _dl_powerpc_platforms[9][12]
+PROCINFO_CLASS const char _dl_powerpc_platforms[13][12]
 #endif
 #ifndef PROCINFO_DECL
 = {
@@ -79,7 +79,11 @@ PROCINFO_CLASS const char _dl_powerpc_platforms[9][12]
     [PPC_PLATFORM_CELL_BE] = "ppc-cell-be",
     [PPC_PLATFORM_POWER6X] = "power6x",
     [PPC_PLATFORM_POWER7] = "power7",
-    [PPC_PLATFORM_PPCA2] = "ppca2"
+    [PPC_PLATFORM_PPCA2] = "ppca2",
+    [PPC_PLATFORM_PPC405] = "ppc405",
+    [PPC_PLATFORM_PPC440] = "ppc440",
+    [PPC_PLATFORM_PPC464] = "ppc464",
+    [PPC_PLATFORM_PPC476] = "ppc476"
   }
 #endif
 #if !defined SHARED || defined PROCINFO_DECL
diff --git a/sysdeps/powerpc/dl-procinfo.h b/sysdeps/powerpc/dl-procinfo.h
index bf96e40..6d904ad 100644
--- a/sysdeps/powerpc/dl-procinfo.h
+++ b/sysdeps/powerpc/dl-procinfo.h
@@ -13,14 +13,14 @@
    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
+   License along with the GNU C Library.  If not, see
    <http://www.gnu.org/licenses/>.  */
 
 #ifndef _DL_PROCINFO_H
-#define _DL_PROCINFO_H	1
+#define _DL_PROCINFO_H 1
 
 #include <ldsodefs.h>
-#include <sysdep.h>		/* This defines the PPC_FEATURE_* macros.  */
+#include <sysdep.h>	/* This defines the PPC_FEATURE_* macros.  */
 
 /* There are 25 bits used, but they are bits 7..31.  */
 #define _DL_HWCAP_FIRST		7
@@ -30,12 +30,12 @@
 #define HWCAP_IMPORTANT		(PPC_FEATURE_HAS_ALTIVEC \
 				+ PPC_FEATURE_HAS_DFP)
 
-#define _DL_PLATFORMS_COUNT	9
+#define _DL_PLATFORMS_COUNT	13
 
-#define _DL_FIRST_PLATFORM      32
+#define _DL_FIRST_PLATFORM	32
 /* Mask to filter out platforms.  */
-#define _DL_HWCAP_PLATFORM      (((1ULL << _DL_PLATFORMS_COUNT) - 1) \
-                                 << _DL_FIRST_PLATFORM)
+#define _DL_HWCAP_PLATFORM	(((1ULL << _DL_PLATFORMS_COUNT) - 1) \
+				<< _DL_FIRST_PLATFORM)
 
 /* Platform bits (relative to _DL_FIRST_PLATFORM).  */
 #define PPC_PLATFORM_POWER4		0
@@ -47,6 +47,10 @@
 #define PPC_PLATFORM_POWER6X		6
 #define PPC_PLATFORM_POWER7		7
 #define PPC_PLATFORM_PPCA2		8
+#define PPC_PLATFORM_PPC405		9
+#define PPC_PLATFORM_PPC440		10
+#define PPC_PLATFORM_PPC464		11
+#define PPC_PLATFORM_PPC476		12
 
 static inline const char *
 __attribute__ ((unused))
@@ -111,7 +115,7 @@ _dl_string_platform (const char *str)
 	  return -1;
 	}
       if (str[1] == '\0')
-	return ret;
+       return ret;
     }
   else if (strncmp (str, GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC970],
 		    3) == 0)
@@ -127,6 +131,22 @@ _dl_string_platform (const char *str)
 		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPCA2] + 3)
 	       == 0)
 	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPCA2;
+      else if (strcmp (str + 3,
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC405] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC405;
+      else if (strcmp (str + 3,
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC440] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC440;
+      else if (strcmp (str + 3,
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC464] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC464;
+      else if (strcmp (str + 3,
+		       GLRO(dl_powerpc_platforms)[PPC_PLATFORM_PPC476] + 3)
+	       == 0)
+	return _DL_FIRST_PLATFORM + PPC_PLATFORM_PPC476;
     }
 
   return -1;

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a6d45052042c1fc962523633c0489634864e1a02

commit a6d45052042c1fc962523633c0489634864e1a02
Author: Adhemerval Zanella <azanella@linux.vnet.ibm.com>
Date:   Fri May 24 13:29:30 2013 -0500

    PowerPC: Program Priority Register support
    
    This patch add inline functions to change the Program Priority Register
    from ISA 2.05.
    (cherry picked from commit d116b7c414c8239b677e341ac517745db689ac2d)

diff --git a/ChangeLog b/ChangeLog
index 422a02d..a65548c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2013-05-24  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
+
+	* manual/platform.texi: Add PowerPC PPR function set documentation.
+	* sysdeps/powerpc/sys/platform/ppc.h: Add PowerPC PPR set function
+	implementation.
+
 2013-05-23  Edjunior Machado  <emachado@linux.vnet.ibm.com>
 
 	* sysdeps/powerpc/sys/platform/ppc.h: Add __ppc_yield,
diff --git a/manual/platform.texi b/manual/platform.texi
index 316b1f1..f1a40d6 100644
--- a/manual/platform.texi
+++ b/manual/platform.texi
@@ -57,4 +57,24 @@ Provide a hint that performance will probably be improved if shared resources
 dedicated to the executing processor are released until all outstanding storage
 accesses to cacheable storage for which the data is not in the cache have been
 completed.
+
+@deftypefun {void} __ppc_set_ppr_med (void)
+Set the Program Priority Register to medium value (default).
+
+The @dfn{Program Priority Register} (PPR) is a 64-bit register that controls
+the program's priority.  By adjusting the PPR value the programmer may
+improve system throughput by causing the system resources to be used
+more efficiently, especially in contention situations.
+The three unprivileged states available are covered by the functions
+@code{__ppc_set_ppr_med} (medium -- default), @code{__ppc_set_ppc_low} (low)
+and @code{__ppc_set_ppc_med_low} (medium low).  More information
+available in @cite{Power ISA 2.06b - Book II - Section 3.1}.
+@end deftypefun
+
+@deftypefun {void} __ppc_set_ppr_low (void)
+Set the Program Priority Register to low value.
+@end deftypefun
+
+@deftypefun {void} __ppc_set_ppr_med_low (void)
+Set the Program Priority Register to medium low value.
 @end deftypefun
diff --git a/sysdeps/powerpc/sys/platform/ppc.h b/sysdeps/powerpc/sys/platform/ppc.h
index d3ed6b9..8c8d6af 100644
--- a/sysdeps/powerpc/sys/platform/ppc.h
+++ b/sysdeps/powerpc/sys/platform/ppc.h
@@ -82,4 +82,34 @@ __ppc_mdoom (void)
   __asm__ volatile ("or 30,30,30");
 }
 
+
+/* ISA 2.05 and beyond support the Program Priority Register (PPR) to adjust
+   thread priorities based on lock acquisition, wait and release. The ISA
+   defines the use of form 'or Rx,Rx,Rx' as the way to modify the PRI field.
+   The unprivileged priorities are:
+     Rx = 1 (low)
+     Rx = 2 (medium)
+     Rx = 6 (medium-low/normal)
+   The 'or' instruction form is a nop in previous hardware, so it is safe to
+   use unguarded. The default value is 'medium'.
+ */
+
+static inline void
+__ppc_set_ppr_med (void)
+{
+  __asm__ volatile ("or 2,2,2");
+}
+
+static inline void
+__ppc_set_ppr_med_low (void)
+{
+  __asm__ volatile ("or 6,6,6");
+}
+
+static inline void
+__ppc_set_ppr_low (void)
+{
+  __asm__ volatile ("or 1,1,1");
+}
+
 #endif  /* sys/platform/ppc.h */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=42b373ad467ba426610a358d90034bcf68abb15f

commit 42b373ad467ba426610a358d90034bcf68abb15f
Author: Edjunior Machado <emachado@linux.vnet.ibm.com>
Date:   Thu May 23 10:06:24 2013 -0500

    PowerPC: Add functions for shared resources hints.
    (cherry picked from commit 9323d39baea2fb0cca3735136abe263eff405133)

diff --git a/ChangeLog b/ChangeLog
index a5e0b23..422a02d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2013-05-23  Edjunior Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/powerpc/sys/platform/ppc.h: Add __ppc_yield,
+	__ppc_mdoio and __ppc_mdoom.
+	* manual/platform.texi: Document new functions __ppc_yield,
+	__ppc_mdoio and __ppc_mdoom.
+
 2013-05-22  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
 
 	* sysdeps/unix/sysv/linux/bits/siginfo.h (siginfo_t): Add si_addr_lsb
diff --git a/manual/platform.texi b/manual/platform.texi
index e387ff4..316b1f1 100644
--- a/manual/platform.texi
+++ b/manual/platform.texi
@@ -34,3 +34,27 @@ This frequency is not related to the processor clock or the bus clock.
 It is also possible that this frequency is not constant.  More information is
 available in @cite{Power ISA 2.06b - Book II - Section 5.2}.
 @end deftypefun
+
+The following functions provide hints about the usage of resources that are
+shared with other processors.  They can be used, for example, if a program
+waiting on a lock intends to divert the shared resources to be used by other
+processors.  More information is available in @cite{Power ISA 2.06b - Book II -
+Section 3.2}.
+
+@deftypefun {void} __ppc_yield (void)
+Provide a hint that performance will probably be improved if shared resources
+dedicated to the executing processor are released for use by other processors.
+@end deftypefun
+
+@deftypefun {void} __ppc_mdoio (void)
+Provide a hint that performance will probably be improved if shared resources
+dedicated to the executing processor are released until all outstanding storage
+accesses to caching-inhibited storage have been completed.
+@end deftypefun
+
+@deftypefun {void} __ppc_mdoom (void)
+Provide a hint that performance will probably be improved if shared resources
+dedicated to the executing processor are released until all outstanding storage
+accesses to cacheable storage for which the data is not in the cache have been
+completed.
+@end deftypefun
diff --git a/sysdeps/powerpc/sys/platform/ppc.h b/sysdeps/powerpc/sys/platform/ppc.h
index 58948e8..d3ed6b9 100644
--- a/sysdeps/powerpc/sys/platform/ppc.h
+++ b/sysdeps/powerpc/sys/platform/ppc.h
@@ -50,4 +50,36 @@ __ppc_get_timebase (void)
 #endif
 }
 
+/* The following functions provide hints about the usage of shared processor
+   resources, as defined in ISA 2.06 and newer. */
+
+/* Provides a hint that performance will probably be improved if shared
+   resources dedicated to the executing processor are released for use by other
+   processors.  */
+static inline void
+__ppc_yield (void)
+{
+  __asm__ volatile ("or 27,27,27");
+}
+
+/* Provides a hint that performance will probably be improved if shared
+   resources dedicated to the executing processor are released until
+   all outstanding storage accesses to caching-inhibited storage have been
+   completed.  */
+static inline void
+__ppc_mdoio (void)
+{
+  __asm__ volatile ("or 29,29,29");
+}
+
+/* Provides a hint that performance will probably be improved if shared
+   resources dedicated to the executing processor are released until all
+   outstanding storage accesses to cacheable storage for which the data is not
+   in the cache have been completed.  */
+static inline void
+__ppc_mdoom (void)
+{
+  __asm__ volatile ("or 30,30,30");
+}
+
 #endif  /* sys/platform/ppc.h */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=e934fb28368b5a36546c7faafab141fcd71172db

commit e934fb28368b5a36546c7faafab141fcd71172db
Author: Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
Date:   Wed May 22 14:19:49 2013 -0500

    Update bits/siginfo.h with Linux hwpoison SIGBUS changes
    
    Adds new SIGBUS error codes for hardware poison signals, syncing with
    the current kernel headers (v3.9). It also adds si_trapno field for
    alpha.
    (cherry picked from commit 85118d4de37e76a1596a75bae75f75f69c33225c)

diff --git a/ChangeLog b/ChangeLog
index 2c1867c..a5e0b23 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2013-05-22  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/unix/sysv/linux/bits/siginfo.h (siginfo_t): Add si_addr_lsb
+	to _sifields.sigfault.
+	(si_addr_lsb): Define new macro.
+	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
+	* sysdeps/unix/sysv/linux/sparc/bits/siginfo.h: Likewise.
+	* sysdeps/unix/sysv/linux/x86/bits/siginfo.h: Likewise.
+
 2013-05-15  Edjunior Machado  <emachado@linux.vnet.ibm.com>
 
 	* sysdeps/unix/sysv/linux/s390/bits/siginfo.h (siginfo_t): Remove
diff --git a/ports/ChangeLog.alpha b/ports/ChangeLog.alpha
index 9be0600..39fd14d 100644
--- a/ports/ChangeLog.alpha
+++ b/ports/ChangeLog.alpha
@@ -1,3 +1,10 @@
+2013-05-22  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/unix/sysv/linux/alpha/bits/siginfo.h (siginfo_t): Add
+	si_trapno and si_addr_lsb to _sifields.sigfault.
+	(si_trapno, si_addr_lsb): Define new macros.
+	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
+
 2012-12-07  Richard Henderson  <rth@redhat.com>
 
 	* sysdeps/alpha/Makefile [$(subdir) = math]
diff --git a/ports/ChangeLog.ia64 b/ports/ChangeLog.ia64
index d886cf4..e08d022 100644
--- a/ports/ChangeLog.ia64
+++ b/ports/ChangeLog.ia64
@@ -1,3 +1,10 @@
+2013-05-22  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/unix/sysv/linux/ia64/bits/siginfo.h (siginfo_t): Add
+	si_addr_lsb to _sifields.sigfault.
+	(si_addr_lsb): Define new macro.
+	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
+
 2012-11-29  Mike Frysinger  <vapier@gentoo.org>
 
 	* sysdeps/unix/sysv/linux/ia64/clock_getcpuclockid.c: Delete.
diff --git a/ports/ChangeLog.mips b/ports/ChangeLog.mips
index 75076b0..5eca3b9 100644
--- a/ports/ChangeLog.mips
+++ b/ports/ChangeLog.mips
@@ -1,3 +1,10 @@
+2013-05-22  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/unix/sysv/linux/mips/bits/siginfo.h (siginfo_t): Add
+	si_addr_lsb to _sifields.sifault.
+	(si_addr_lsb): Define new macro.
+	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
+
 2012-12-04  Joseph Myers  <joseph@codesourcery.com>
 
 	* sysdeps/mips/fpu_control.h [__mips_soft_float] (_FPU_GETCW):
diff --git a/ports/ChangeLog.tile b/ports/ChangeLog.tile
index f0cd08d..91b38be 100644
--- a/ports/ChangeLog.tile
+++ b/ports/ChangeLog.tile
@@ -1,3 +1,10 @@
+2013-05-22  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/unix/sysv/linux/tile/bits/siginfo.h (siginfo_t): Fix comment
+	formatting. Add	si_addr_lsb to _sifields.sigfault.
+	(si_addr_lsb): Define new macro.
+	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
+
 2013-07-22  Chris Metcalf  <cmetcalf@tilera.com>
 
 	[BZ #15759]
diff --git a/ports/sysdeps/unix/sysv/linux/alpha/bits/siginfo.h b/ports/sysdeps/unix/sysv/linux/alpha/bits/siginfo.h
index 4a8c8d5..1a157b8 100644
--- a/ports/sysdeps/unix/sysv/linux/alpha/bits/siginfo.h
+++ b/ports/sysdeps/unix/sysv/linux/alpha/bits/siginfo.h
@@ -89,6 +89,8 @@ typedef struct
 	struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
+	    int si_trapno;	/* TRAP # which caused the signal.  */
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -121,6 +123,8 @@ typedef struct
 # define si_int		_sifields._rt.si_sigval.sival_int
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
+# define si_trapno	_sifields._sigfault.si_trapno
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 # define si_call_addr 	_sifields._sigsys._call_addr
@@ -211,8 +215,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */
diff --git a/ports/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h b/ports/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h
index fbb07b5..1e4becd 100644
--- a/ports/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h
+++ b/ports/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h
@@ -94,6 +94,7 @@ typedef struct siginfo
 	    int _si_imm;
 	    unsigned int _si_flags;
 	    unsigned long int _si_isr;
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -118,6 +119,7 @@ typedef struct siginfo
 # define si_int		_sifields._rt.si_sigval.sival_int
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 
@@ -233,8 +235,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */
diff --git a/ports/sysdeps/unix/sysv/linux/mips/bits/siginfo.h b/ports/sysdeps/unix/sysv/linux/mips/bits/siginfo.h
index 3337396..b2111e6 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/bits/siginfo.h
+++ b/ports/sysdeps/unix/sysv/linux/mips/bits/siginfo.h
@@ -98,6 +98,7 @@ typedef struct
 	struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -122,6 +123,7 @@ typedef struct
 # define si_int		_sifields._rt.si_sigval.sival_int
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 
@@ -209,8 +211,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */
diff --git a/ports/sysdeps/unix/sysv/linux/tile/bits/siginfo.h b/ports/sysdeps/unix/sysv/linux/tile/bits/siginfo.h
index 6fa354a..957d001 100644
--- a/ports/sysdeps/unix/sysv/linux/tile/bits/siginfo.h
+++ b/ports/sysdeps/unix/sysv/linux/tile/bits/siginfo.h
@@ -95,7 +95,8 @@ typedef struct
 	struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
-	    int si_trapno;	/* TRAP # which caused the signal */
+	    int si_trapno;	/* TRAP # which caused the signal.  */
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -129,6 +130,7 @@ typedef struct
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
 # define si_trapno	_sifields._sigfault.si_trapno
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 # define si_call_addr 	_sifields._sigsys._call_addr
@@ -223,8 +225,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */
diff --git a/sysdeps/unix/sysv/linux/bits/siginfo.h b/sysdeps/unix/sysv/linux/bits/siginfo.h
index 1304d5c..8540adc 100644
--- a/sysdeps/unix/sysv/linux/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/bits/siginfo.h
@@ -95,6 +95,7 @@ typedef struct
 	struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -127,6 +128,7 @@ typedef struct
 # define si_int		_sifields._rt.si_sigval.sival_int
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 # define si_call_addr 	_sifields._sigsys._call_addr
@@ -217,8 +219,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */
diff --git a/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h b/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
index babd70c..80757cd 100644
--- a/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
@@ -96,6 +96,7 @@ typedef struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
 	    int si_trapno;
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -129,6 +130,7 @@ typedef struct
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
 # define si_trapno	_sifields._sigfault.si_trapno
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 # define si_call_addr 	_sifields._sigsys._call_addr
@@ -219,8 +221,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */
diff --git a/sysdeps/unix/sysv/linux/x86/bits/siginfo.h b/sysdeps/unix/sysv/linux/x86/bits/siginfo.h
index b0f4a65..a10e3fd 100644
--- a/sysdeps/unix/sysv/linux/x86/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/x86/bits/siginfo.h
@@ -107,6 +107,7 @@ typedef struct
 	struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
+	    short int si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -139,6 +140,7 @@ typedef struct
 # define si_int		_sifields._rt.si_sigval.sival_int
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 # define si_call_addr 	_sifields._sigsys._call_addr
@@ -229,8 +231,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.  */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=979bcc3f2854d938c6e3facf8d0308f4721029a0

commit 979bcc3f2854d938c6e3facf8d0308f4721029a0
Author: Edjunior Machado <emachado@linux.vnet.ibm.com>
Date:   Wed May 15 20:15:19 2013 +0200

    Update s390/bits/siginfo.h
    
    2013-05-15  Edjunior Machado  <emachado@linux.vnet.ibm.com>
    
    	* sysdeps/unix/sysv/linux/s390/bits/siginfo.h (siginfo_t):
    	Remove si_trapno and add si_addr_lsb to _sifields.sigfault.
    	(si_trapno): Remove macro.
    	(si_addr_lsb): Define new macro.
    	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
    (cherry picked from commit 12fba011bde4332687819ada867992192e5105f7)

diff --git a/ChangeLog b/ChangeLog
index 153515d..2c1867c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2013-05-15  Edjunior Machado  <emachado@linux.vnet.ibm.com>
+
+	* sysdeps/unix/sysv/linux/s390/bits/siginfo.h (siginfo_t): Remove
+	si_trapno and add si_addr_lsb to _sifields.sigfault.
+	(si_trapno): Remove macro.
+	(si_addr_lsb): Define new macro.
+	(BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
+
 2013-05-17  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
 
 	[BZ # 15497]
diff --git a/sysdeps/unix/sysv/linux/s390/bits/siginfo.h b/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
index 159bafb..345d610 100644
--- a/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
+++ b/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
@@ -95,7 +95,7 @@ typedef struct
 	struct
 	  {
 	    void *si_addr;	/* Faulting insn/memory ref.  */
-	    int si_trapno;
+	    short si_addr_lsb;	/* Valid LSB of the reported address.  */
 	  } _sigfault;
 
 	/* SIGPOLL.  */
@@ -128,7 +128,7 @@ typedef struct
 # define si_int		_sifields._rt.si_sigval.sival_int
 # define si_ptr		_sifields._rt.si_sigval.sival_ptr
 # define si_addr	_sifields._sigfault.si_addr
-# define si_trapno	_sifields._sigfault.si_trapno
+# define si_addr_lsb	_sifields._sigfault.si_addr_lsb
 # define si_band	_sifields._sigpoll.si_band
 # define si_fd		_sifields._sigpoll.si_fd
 # define si_call_addr 	_sifields._sigsys._call_addr
@@ -219,8 +219,12 @@ enum
 # define BUS_ADRALN	BUS_ADRALN
   BUS_ADRERR,			/* Non-existant physical address.  */
 # define BUS_ADRERR	BUS_ADRERR
-  BUS_OBJERR			/* Object specific hardware error.  */
+  BUS_OBJERR,			/* Object specific hardware error.  */
 # define BUS_OBJERR	BUS_OBJERR
+  BUS_MCEERR_AR,		/* Hardware memory error: action required.  */
+# define BUS_MCEERR_AR	BUS_MCEERR_AR
+  BUS_MCEERR_AO			/* Hardware memory error: action optional.  */
+# define BUS_MCEERR_AO	BUS_MCEERR_AO
 };
 
 /* `si_code' values for SIGTRAP signal.	 */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=ed81f668f7c9eff0692c3c81691a7380b55063ff

commit ed81f668f7c9eff0692c3c81691a7380b55063ff
Author: Adhemerval Zanella <azanella@linux.vnet.ibm.com>
Date:   Fri May 17 08:12:16 2013 -0500

    PowerPC: fix hypot/hypotf check for -INF
    (cherry picked from commit 13d3b41a36c4f28d171a144f8a9baad3a8835981)
    (backported missing CL/NEWS from commit 68191c1d59d40b3d9f5babef4f37f265920ff565)

diff --git a/ChangeLog b/ChangeLog
index 5e72136..153515d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2013-05-17  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
+
+	[BZ # 15497]
+	* sysdeps/powerpc/fpu/e_hypot.c (GET_TWO_FLOAT_WORD): Fix test for
+	negative infinity on POWER6 or lower.
+	* sysdeps/powerpc/fpu/e_hypotf.c (GET_TWO_FLOAT_WORD): Likewise.
+
 2013-04-30  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
 
 	* sysdeps/unix/sysv/linux/powerpc/Versions: Add __vdso_time symbol.
diff --git a/NEWS b/NEWS
index c6380a7..e418a46 100644
--- a/NEWS
+++ b/NEWS
@@ -8,7 +8,7 @@ using `glibc' in the "product" field.
 Version 2.17.1
 
 * The following bugs are resolved with this release:
-  15003, 15006, 15055, 15122, 15759.
+  15003, 15006, 15055, 15122, 15497, 15759.
 
 
 Version 2.17
diff --git a/sysdeps/powerpc/fpu/e_hypot.c b/sysdeps/powerpc/fpu/e_hypot.c
index cfadd5c..fc17bea 100644
--- a/sysdeps/powerpc/fpu/e_hypot.c
+++ b/sysdeps/powerpc/fpu/e_hypot.c
@@ -52,13 +52,13 @@ static const double pdnum   = 2.225073858507201e-308;
    ieee_double_shape_type gh_u2;                                  \
    gh_u1.value = (d1);                                            \
    gh_u2.value = (d2);                                            \
-   (i1) = gh_u1.parts.msw;                                        \
-   (i2) = gh_u2.parts.msw;                                        \
+   (i1) = gh_u1.parts.msw & 0x7fffffff;                           \
+   (i2) = gh_u2.parts.msw & 0x7fffffff;                           \
  } while (0)
 
 # define TEST_INF_NAN(x, y)                                      \
  do {                                                            \
-   int32_t hx, hy;                                               \
+   uint32_t hx, hy;                                              \
    GET_TW0_HIGH_WORD(x, y, hx, hy);                              \
    if (hy > hx) {                                                \
      uint32_t ht = hx; hx = hy; hy = ht;                         \
diff --git a/sysdeps/powerpc/fpu/e_hypotf.c b/sysdeps/powerpc/fpu/e_hypotf.c
index 92e824d..77c1b17 100644
--- a/sysdeps/powerpc/fpu/e_hypotf.c
+++ b/sysdeps/powerpc/fpu/e_hypotf.c
@@ -46,13 +46,13 @@ static const float two30  = 1.0737418e09;
    ieee_float_shape_type gf_u2;                                  \
    gf_u1.value = (f1);                                           \
    gf_u2.value = (f2);                                           \
-   (i1) = gf_u1.word;                                            \
-   (i2) = gf_u2.word;                                            \
+   (i1) = gf_u1.word & 0x7fffffff;                               \
+   (i2) = gf_u2.word & 0x7fffffff;                               \
  } while (0)
 
 # define TEST_INF_NAN(x, y)                                      \
  do {                                                            \
-   int32_t hx, hy;                                               \
+   uint32_t hx, hy;                                              \
    GET_TWO_FLOAT_WORD(x, y, hx, hy);                             \
    if (hy > hx) {                                                \
      uint32_t ht = hx; hx = hy; hy = ht;                         \

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

Summary of changes:
 ChangeLog                                          |   60 +++++++
 NEWS                                               |    2 +-
 manual/platform.texi                               |   44 +++++
 ports/ChangeLog.alpha                              |    7 +
 ports/ChangeLog.ia64                               |    7 +
 ports/ChangeLog.mips                               |    7 +
 ports/ChangeLog.powerpc                            |   12 ++
 ports/ChangeLog.tile                               |    7 +
 ports/sysdeps/powerpc/dl-procinfo.c                |   96 -----------
 ports/sysdeps/powerpc/dl-procinfo.h                |  172 --------------------
 ports/sysdeps/unix/sysv/linux/alpha/bits/siginfo.h |   10 +-
 ports/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h  |    8 +-
 ports/sysdeps/unix/sysv/linux/mips/bits/siginfo.h  |    8 +-
 ports/sysdeps/unix/sysv/linux/tile/bits/siginfo.h  |   10 +-
 sysdeps/generic/symbol-hacks.h                     |    7 +-
 sysdeps/powerpc/dl-procinfo.c                      |   10 +-
 sysdeps/powerpc/dl-procinfo.h                      |   36 ++++-
 sysdeps/powerpc/fpu/e_hypot.c                      |    6 +-
 sysdeps/powerpc/fpu/e_hypotf.c                     |    6 +-
 sysdeps/powerpc/sys/platform/ppc.h                 |   62 +++++++
 sysdeps/unix/sysv/linux/bits/siginfo.h             |    8 +-
 sysdeps/unix/sysv/linux/s390/bits/siginfo.h        |   10 +-
 sysdeps/unix/sysv/linux/sparc/bits/siginfo.h       |    8 +-
 sysdeps/unix/sysv/linux/x86/bits/siginfo.h         |    8 +-
 sysdeps/wordsize-32/symbol-hacks.h                 |    2 +
 25 files changed, 315 insertions(+), 298 deletions(-)
 delete mode 100644 ports/sysdeps/powerpc/dl-procinfo.c
 delete mode 100644 ports/sysdeps/powerpc/dl-procinfo.h


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]