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-434-g7726d6a


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  7726d6a95d5a2c08c8d43186002f040b9b889c27 (commit)
      from  83d1aec8fc5f4250e6d5f44eeef30c923e140ca4 (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=7726d6a95d5a2c08c8d43186002f040b9b889c27

commit 7726d6a95d5a2c08c8d43186002f040b9b889c27
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Mon Mar 19 20:11:09 2012 +0000

    Fix atan2 spurious exceptions (bug 11451).

diff --git a/ChangeLog b/ChangeLog
index 0874b04..8ac195a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2012-03-19  Joseph Myers  <joseph@codesourcery.com>
 
+	[BZ #11451]
+	* sysdeps/ieee754/dbl-64/e_atan2.c (__ieee754_atan2): Scale large
+	x and y.
+	* math/libm-test.inc (atan2_test): Add another test.
+
 	* Makerules (common-objdir-compile): Remove.
 	* sysdeps/unix/Makefile (config-generated): Do not add
 	$(unix-generated) to variable.
diff --git a/NEWS b/NEWS
index 5af4f68..df8e1f0 100644
--- a/NEWS
+++ b/NEWS
@@ -12,11 +12,11 @@ Version 2.16
   174, 350, 411, 2541, 2547, 2548, 2551, 2552, 2553, 2554, 2562, 2563, 2565,
   2566, 2576, 3335, 3976, 3992, 4026, 4108, 4596, 4822, 5077, 5461, 5805,
   5993, 6471, 6884, 6907, 6911, 9739, 9902, 10110, 10135, 10140, 10210,
-  10545, 10716, 11174, 11322, 11365, 11494, 12047, 13058, 13525, 13526,
-  13527, 13528, 13529, 13530, 13531, 13532, 13533, 13547, 13551, 13552,
-  13553, 13555, 13559, 13566, 13583, 13618, 13637, 13656, 13658, 13673,
-  13695, 13704, 13706, 13726, 13738, 13786, 13792, 13806, 13840, 13841,
-  13844, 13846, 13851, 13852, 13854
+  10545, 10716, 11174, 11322, 11365, 11451, 11494, 12047, 13058, 13525,
+  13526, 13527, 13528, 13529, 13530, 13531, 13532, 13533, 13547, 13551,
+  13552, 13553, 13555, 13559, 13566, 13583, 13618, 13637, 13656, 13658,
+  13673, 13695, 13704, 13706, 13726, 13738, 13786, 13792, 13806, 13840,
+  13841, 13844, 13846, 13851, 13852, 13854
 
 * ISO C11 support:
 
diff --git a/math/libm-test.inc b/math/libm-test.inc
index 5638b76..817864a 100644
--- a/math/libm-test.inc
+++ b/math/libm-test.inc
@@ -949,6 +949,8 @@ atan2_test (void)
   TEST_ff_f (atan2, minus_infty, minus_infty, -M_PI_34l);
   TEST_ff_f (atan2, nan_value, nan_value, nan_value);
 
+  TEST_ff_f (atan2, max_value, max_value, M_PI_4l);
+
   TEST_ff_f (atan2, 0.75L, 1, 0.643501108793284386802809228717322638L);
   TEST_ff_f (atan2, -0.75L, 1.0L, -0.643501108793284386802809228717322638L);
   TEST_ff_f (atan2, 0.75L, -1.0L, 2.49809154479650885165983415456218025L);
diff --git a/sysdeps/ieee754/dbl-64/e_atan2.c b/sysdeps/ieee754/dbl-64/e_atan2.c
index dcef55f..497afca 100644
--- a/sysdeps/ieee754/dbl-64/e_atan2.c
+++ b/sysdeps/ieee754/dbl-64/e_atan2.c
@@ -1,7 +1,7 @@
 /*
  * IBM Accurate Mathematical Library
  * written by International Business Machines Corp.
- * Copyright (C) 2001, 2011 Free Software Foundation
+ * Copyright (C) 2001-2012 Free Software Foundation
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU Lesser General Public License as published by
@@ -153,6 +153,13 @@ __ieee754_atan2(double y,double x) {
   /* if either x or y is extremely close to zero, scale abs(x), abs(y). */
   if (ax<twom500.d || ay<twom500.d) { ax*=two500.d;  ay*=two500.d; }
 
+  /* Likewise for large x and y.  */
+  if (ax > two500.d || ay > two500.d)
+    {
+      ax *= twom500.d;
+      ay *= twom500.d;
+    }
+
   /* x,y which are neither special nor extreme */
   if (ay<ax) {
     u=ay/ax;

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

Summary of changes:
 ChangeLog                        |    5 +++++
 NEWS                             |   10 +++++-----
 math/libm-test.inc               |    2 ++
 sysdeps/ieee754/dbl-64/e_atan2.c |    9 ++++++++-
 4 files changed, 20 insertions(+), 6 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]