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-752-g6c23e11


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  6c23e11c4dd036e65073d4e4d6bc971a445deaea (commit)
      from  62881be42dd5a81785f630658c6762b214056978 (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=6c23e11c4dd036e65073d4e4d6bc971a445deaea

commit 6c23e11c4dd036e65073d4e4d6bc971a445deaea
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Sun May 6 18:20:21 2012 +0000

    Fix libm-test.inc ulps calculation for subnormals (bug 14064).

diff --git a/ChangeLog b/ChangeLog
index af9aac0..4109a75 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2012-05-06  Joseph Myers  <joseph@codesourcery.com>
+
+	[BZ #14064]
+	* math/libm-test.inc (check_float_internal): Correct ulp
+	calculation for subnormal expected results.
+
 2012-05-06  Andreas Jaeger  <aj@suse.de>
 
 	* Makeconfig (+math-flags): New, set to -frounding-math.
diff --git a/NEWS b/NEWS
index 036d8d4..66b1041 100644
--- a/NEWS
+++ b/NEWS
@@ -23,7 +23,7 @@ Version 2.16
   13854, 13871, 13872, 13873, 13879, 13883, 13886, 13892, 13895, 13908,
   13910, 13911, 13912, 13913, 13915, 13916, 13917, 13918, 13919, 13920,
   13921, 13922, 13924, 13926, 13927, 13928, 13938, 13941, 13942, 13963,
-  13967, 13970, 13973, 14027, 14033, 14034, 14040, 14049, 14055
+  13967, 13970, 13973, 14027, 14033, 14034, 14040, 14049, 14055, 14064
 
 * ISO C11 support:
 
diff --git a/math/libm-test.inc b/math/libm-test.inc
index 59192ed..d65c3e5 100644
--- a/math/libm-test.inc
+++ b/math/libm-test.inc
@@ -503,8 +503,9 @@ check_float_internal (const char *test_name, FLOAT computed, FLOAT expected,
 	  ulp = diff / FUNC(ldexp) (1.0, FUNC(ilogb) (expected) - MANT_DIG);
 	  break;
 	case FP_SUBNORMAL:
-	  ulp = (FUNC(ldexp) (diff, MANT_DIG)
-		 / FUNC(ldexp) (1.0, FUNC(ilogb) (expected)));
+	  /* 1ulp for a subnormal value, shifted by MANT_DIG, is the
+	     least normal value.  */
+	  ulp = (FUNC(ldexp) (diff, MANT_DIG) / min_value);
 	  break;
 	default:
 	  /* It should never happen. */

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

Summary of changes:
 ChangeLog          |    6 ++++++
 NEWS               |    2 +-
 math/libm-test.inc |    5 +++--
 3 files changed, 10 insertions(+), 3 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]