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, master, updated. glibc-2.15-672-ga462cb6


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, master has been updated
       via  a462cb63326595eb018e26ea415f8ddc1ed50730 (commit)
      from  6ad3493e2247e6cb3c9e086e8cb1f8b51a5f27d6 (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://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a462cb63326595eb018e26ea415f8ddc1ed50730

commit a462cb63326595eb018e26ea415f8ddc1ed50730
Author: Ryan S. Arnold <rsa@linux.vnet.ibm.com>
Date:   Fri Apr 27 10:47:39 2012 -0500

    New test to expose erroneous negative sign on logb(1) (bug 887).

diff --git a/ChangeLog b/ChangeLog
index 2035e58..e6eb858 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2012-04-27  Ryan S. Arnold  <rsa@linux.vnet.ibm.com>
+
+	[BZ #887]
+	* math/libm-test.inc (logb_test_downward): New test to expose
+	erroneous negative sign on -0.0 result of logb[l](1) in FE_DOWNWARD
+	rounding mode.
+
 2012-04-27  Joseph Myers  <joseph@codesourcery.com>
 
 	[BZ #14027]
diff --git a/NEWS b/NEWS
index cd52364..0f060a7 100644
--- a/NEWS
+++ b/NEWS
@@ -9,20 +9,20 @@ Version 2.16
 
 * The following bugs are resolved with this release:
 
-  174, 350, 369, 411, 706, 2074, 2541, 2547, 2548, 2551, 2552, 2553, 2554,
-  2562, 2563, 2565, 2566, 2576, 2636, 2678, 3335, 3768, 3866, 3868, 3976,
-  3992, 4026, 4108, 4596, 4822, 5077, 5461, 5805, 5993, 6471, 6486, 6578,
-  6649, 6730, 6770, 6794, 6884, 6890, 6894, 6895, 6907, 6911, 7064, 9739,
-  9902, 10110, 10135, 10140, 10153, 10210, 10254, 10346, 10545, 10716,
-  11174, 11322, 11365, 11451, 11494, 11521, 11959, 12047, 12340, 13058,
-  13525, 13526, 13527, 13528, 13529, 13530, 13531, 13532, 13533, 13547,
-  13551, 13552, 13553, 13555, 13559, 13566, 13583, 13592, 13618, 13637,
-  13656, 13658, 13673, 13691, 13695, 13704, 13705, 13706, 13726, 13738,
-  13739, 13760, 13761, 13786, 13792, 13806, 13824, 13840, 13841, 13844,
-  13846, 13851, 13852, 13854, 13871, 13872, 13873, 13879, 13883, 13886,
-  13892, 13895, 13908, 13910, 13911, 13912, 13913, 13915, 13916, 13917,
-  13918, 13919, 13920, 13921, 13926, 13927, 13928, 13938, 13963, 13967,
-  13970, 13973, 14027
+  174, 350, 369, 411, 887, 706, 2074, 2541, 2547, 2548, 2551, 2552, 2553,
+  2554, 2562, 2563, 2565, 2566, 2576, 2636, 2678, 3335, 3768, 3866, 3868,
+  3976, 3992, 4026, 4108, 4596, 4822, 5077, 5461, 5805, 5993, 6471, 6486,
+  6578, 6649, 6730, 6770, 6794, 6884, 6890, 6894, 6895, 6907, 6911, 7064,
+  9739, 9902, 10110, 10135, 10140, 10153, 10210, 10254, 10346, 10545,
+  10716, 11174, 11322, 11365, 11451, 11494, 11521, 11959, 12047, 12340,
+  13058, 13525, 13526, 13527, 13528, 13529, 13530, 13531, 13532, 13533,
+  13547, 13551, 13552, 13553, 13555, 13559, 13566, 13583, 13592, 13618,
+  13637, 13656, 13658, 13673, 13691, 13695, 13704, 13705, 13706, 13726,
+  13738, 13739, 13760, 13761, 13786, 13792, 13806, 13824, 13840, 13841,
+  13844, 13846, 13851, 13852, 13854, 13871, 13872, 13873, 13879, 13883,
+  13886, 13892, 13895, 13908, 13910, 13911, 13912, 13913, 13915, 13916,
+  13917, 13918, 13919, 13920, 13921, 13926, 13927, 13928, 13938, 13963,
+  13967, 13970, 13973, 14027
 
 * ISO C11 support:
 
diff --git a/math/libm-test.inc b/math/libm-test.inc
index e0ac613..d11cd1f 100644
--- a/math/libm-test.inc
+++ b/math/libm-test.inc
@@ -5101,6 +5101,40 @@ logb_test (void)
   END (logb);
 }
 
+static void
+logb_test_downward (void)
+{
+  int save_round_mode;
+  errno = 0;
+
+  FUNC(logb) (0);
+  if (errno == ENOSYS)
+    /* Function not implemented.  */
+    return;
+
+  START (logb_downward);
+
+  save_round_mode = fegetround ();
+
+  if (!fesetround (FE_DOWNWARD))
+    {
+
+      /* IEEE 754-2008 says (section 5.3.3) that "logB(1) is +0.".  Libm
+         should not return -0 from logb in any rounding mode.  PowerPC32 has
+         failed with this test for power4 logb (and logbl on all PowerPC
+         platforms) in the past due to instruction selection.  GCC PR 52775
+         provides the availability of the fcfid insn in 32-bit mode which
+         eliminates the use of fsub in this instance and prevents the negative
+         signed 0.0.  */
+
+      /* BZ #887  .*/
+      TEST_f_f (logb, 1.000e+0, plus_zero);
+    }
+
+  fesetround (save_round_mode);
+
+  END (logb_downward);
+}
 
 static void
 lround_test (void)
@@ -8210,6 +8244,7 @@ main (int argc, char **argv)
   log1p_test ();
   log2_test ();
   logb_test ();
+  logb_test_downward ();
   modf_test ();
   ilogb_test ();
   scalb_test ();

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

Summary of changes:
 ChangeLog          |    7 +++++++
 NEWS               |   28 ++++++++++++++--------------
 math/libm-test.inc |   35 +++++++++++++++++++++++++++++++++++
 3 files changed, 56 insertions(+), 14 deletions(-)


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]