This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch master updated. glibc-2.22-589-ge6a6b1c
- From: jsm28 at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 9 Dec 2015 23:51:35 -0000
- Subject: GNU C Library master sources branch master updated. glibc-2.22-589-ge6a6b1c
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 e6a6b1c3de62f3ae3f0e5ac5bdcc49a3342f03e7 (commit)
from f517e06ab71e07b24bf085063b0ba2d072da4a56 (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=e6a6b1c3de62f3ae3f0e5ac5bdcc49a3342f03e7
commit e6a6b1c3de62f3ae3f0e5ac5bdcc49a3342f03e7
Author: Joseph Myers <joseph@codesourcery.com>
Date: Wed Dec 9 23:51:11 2015 +0000
Fix ldbl-128ibm logl inaccuracy near 1 (bug 19351).
The ldbl-128ibm implementation of logl is inaccurate for arguments
near 1, because when deciding whether to bypass a series expansion for
log(1+z), where z = x-1, it compares the square of z rather than z
itself with an epsilon value. This patch fixes that comparison, so
eliminating the test failures for inaccuracy of logl in such cases.
Tested for powerpc.
[BZ #19351]
* sysdeps/ieee754/ldbl-128ibm/e_logl.c (__ieee754_logl): When
expanding log(1+z), compare z rather than its square with epsilon
to determine when to avoid evaluating the expansion.
diff --git a/ChangeLog b/ChangeLog
index 1c7b198..ec8807c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2015-12-09 Joseph Myers <joseph@codesourcery.com>
+ [BZ #19351]
+ * sysdeps/ieee754/ldbl-128ibm/e_logl.c (__ieee754_logl): When
+ expanding log(1+z), compare z rather than its square with epsilon
+ to determine when to avoid evaluating the expansion.
+
[BZ #19350]
* sysdeps/ieee754/ldbl-128ibm/e_sinhl.c (__ieee754_sinhl):
Increase overflow threshold.
diff --git a/sysdeps/ieee754/ldbl-128ibm/e_logl.c b/sysdeps/ieee754/ldbl-128ibm/e_logl.c
index dcac380..14acfc2 100644
--- a/sysdeps/ieee754/ldbl-128ibm/e_logl.c
+++ b/sysdeps/ieee754/ldbl-128ibm/e_logl.c
@@ -270,7 +270,7 @@ __ieee754_logl(long double x)
/* Series expansion of log(1+z). */
w = z * z;
/* Avoid spurious underflows. */
- if (__glibc_unlikely(w <= ldbl_epsilon))
+ if (__glibc_unlikely (fabsl (z) <= ldbl_epsilon))
y = 0.0L;
else
{
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 5 +++++
sysdeps/ieee754/ldbl-128ibm/e_logl.c | 2 +-
2 files changed, 6 insertions(+), 1 deletions(-)
hooks/post-receive
--
GNU C Library master sources