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.17-739-g0323d08


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  0323d08657f111267efa47bd448fbf6cd76befe8 (commit)
      from  dd4259b9f76fa8fd3690a91608d2e3a94e2d6713 (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=0323d08657f111267efa47bd448fbf6cd76befe8

commit 0323d08657f111267efa47bd448fbf6cd76befe8
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Fri May 24 20:52:55 2013 +0000

    Fix ldbl-96 hypotl of subnormals (bug 15529).

diff --git a/ChangeLog b/ChangeLog
index bddd4d5..6c5111c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2013-05-24  Joseph Myers  <joseph@codesourcery.com>
 
+	[BZ #15529]
+	* sysdeps/ieee754/ldbl-96/e_hypotl.c (__ieee754_hypotl): Set high
+	bit of mantissa of 2^16382.
+	* math/libm-test.inc (hypot_test_data): Add more tests.
+
 	* math/libm-test.inc: Add drem and pow10 to list of tested
 	functions.
 	(pow10_test): New function.
diff --git a/NEWS b/NEWS
index a9377eb..c25b62e 100644
--- a/NEWS
+++ b/NEWS
@@ -18,7 +18,8 @@ Version 2.18
   15287, 15304, 15305, 15307, 15309, 15327, 15330, 15335, 15336, 15337,
   15339, 15342, 15346, 15359, 15361, 15366, 15380, 15381, 15394, 15395,
   15405, 15406, 15409, 15416, 15418, 15419, 15423, 15424, 15426, 15429,
-  15441, 15442, 15448, 15480, 15485, 15488, 15490, 15493, 15497, 15506.
+  15441, 15442, 15448, 15480, 15485, 15488, 15490, 15493, 15497, 15506,
+  15529.
 
 * CVE-2013-0242 Buffer overrun in regexp matcher has been fixed (Bugzilla
   #15078).
diff --git a/math/libm-test.inc b/math/libm-test.inc
index 91af668..7a6bf09 100644
--- a/math/libm-test.inc
+++ b/math/libm-test.inc
@@ -9387,6 +9387,19 @@ static const struct test_ff_f_data hypot_test_data[] =
 #if defined TEST_LDOUBLE && LDBL_MAX_EXP >= 16384 && !defined TEST_INLINE
     TEST_ff_f (hypot, 0x3p16381L, 0x4p16381L, 0x5p16381L),
 #endif
+
+    TEST_ff_f (hypot, 0x1p-149L, 0x1p-149L, 1.9817352931807469938024533350782879785095e-45L, UNDERFLOW_EXCEPTION_FLOAT),
+
+#ifndef TEST_FLOAT
+    TEST_ff_f (hypot, 0x1p-1074L, 0x1p-1074L, 6.9871433705131320800651344656990806305791e-324L, UNDERFLOW_EXCEPTION_DOUBLE),
+#endif
+
+#if defined TEST_LDOUBLE && LDBL_MIN_EXP <= -16381 && !defined TEST_INLINE
+    TEST_ff_f (hypot, 0x1p-16445L, 0x1p-16445L, 5.1550906155442528702558159159596215039925e-4951L, UNDERFLOW_EXCEPTION),
+# if LDBL_MANT_DIG >= 113
+    TEST_ff_f (hypot, 0x1p-16494L, 0x1p-16494L, 9.1572804726500807075521065242888978445857e-4966L, UNDERFLOW_EXCEPTION),
+# endif
+#endif
   };
 
 static void
diff --git a/sysdeps/ieee754/ldbl-96/e_hypotl.c b/sysdeps/ieee754/ldbl-96/e_hypotl.c
index 306f929..7895488 100644
--- a/sysdeps/ieee754/ldbl-96/e_hypotl.c
+++ b/sysdeps/ieee754/ldbl-96/e_hypotl.c
@@ -85,7 +85,7 @@ long double __ieee754_hypotl(long double x, long double y)
 		u_int32_t high,low;
 		GET_LDOUBLE_WORDS(exp,high,low,b);
 		if((high|low)==0) return a;
-		SET_LDOUBLE_WORDS(t1, 0x7ffd, 0, 0);	/* t1=2^16382 */
+		SET_LDOUBLE_WORDS(t1, 0x7ffd, 0x80000000, 0); /* t1=2^16382 */
 		b *= t1;
 		a *= t1;
 		k -= 16382;

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

Summary of changes:
 ChangeLog                          |    5 +++++
 NEWS                               |    3 ++-
 math/libm-test.inc                 |   13 +++++++++++++
 sysdeps/ieee754/ldbl-96/e_hypotl.c |    2 +-
 4 files changed, 21 insertions(+), 2 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]