public inbox for glibc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug math/16408] New: ldbl-128ibm expm1l bad overflow handling @ 2014-01-07 21:31 jsm28 at gcc dot gnu.org 2014-01-08 13:33 ` [Bug math/16408] " cvs-commit at gcc dot gnu.org ` (2 more replies) 0 siblings, 3 replies; 4+ messages in thread From: jsm28 at gcc dot gnu.org @ 2014-01-07 21:31 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=16408 Bug ID: 16408 Summary: ldbl-128ibm expm1l bad overflow handling Product: glibc Version: 2.19 Status: NEW Severity: normal Priority: P2 Component: math Assignee: unassigned at sourceware dot org Reporter: jsm28 at gcc dot gnu.org The ldbl-128ibm expm1l implementation produces NaN results on some overflowing inputs (maybe some non-overflow cases as well): Failure: expm1 (0x2.c5c4p+12): Exception "Invalid operation" set Failure: Test: expm1 (0x2.c5c4p+12) Result: is: qNaN should be: inf inf -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug math/16408] ldbl-128ibm expm1l bad overflow handling 2014-01-07 21:31 [Bug math/16408] New: ldbl-128ibm expm1l bad overflow handling jsm28 at gcc dot gnu.org @ 2014-01-08 13:33 ` cvs-commit at gcc dot gnu.org 2014-01-08 13:36 ` jsm28 at gcc dot gnu.org 2014-06-13 9:10 ` fweimer at redhat dot com 2 siblings, 0 replies; 4+ messages in thread From: cvs-commit at gcc dot gnu.org @ 2014-01-08 13:33 UTC (permalink / raw) To: glibc-bugs http://sourceware.org/bugzilla/show_bug.cgi?id=16408 --- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> --- 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 4c327f2ad89cff8e1fb6f7fe09b398119783553a (commit) from 6e067a5128c08f9a34ff4f69db02546d75dfa15c (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 ----------------------------------------------------------------- https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=4c327f2ad89cff8e1fb6f7fe09b398119783553a commit 4c327f2ad89cff8e1fb6f7fe09b398119783553a Author: Joseph Myers <joseph@codesourcery.com> Date: Wed Jan 8 13:32:39 2014 +0000 Fix ldbl-128ibm expm1l on large arguments (bug 16408). This patch fixes bug 16408, ldbl-128ibm expm1l returning NaN for some large arguments. The basic problem is that the approach of converting the exponent to the form n * log(2) + y, where -0.5 <= y <= 0.5, then computing 2^n * expm1(y) + (2^n - 1) falls over when 2^n overflows (starting slightly before the point where expm1 overflows, when y is negative and n is the least integer for which 2^n overflows). The ldbl-128 code, and the x86/x86_64 code, make expm1l fall back to expl for large positive arguments to avoid this issue. This patch makes the ldbl-128ibm code do the same. (The problem appears for the particular argument in the testsuite because the ldbl-128ibm code also uses an overflow threshold that's for ldbl-128 and is too big for ldbl-128ibm, but the problem described applies for large non-overflowing cases as well, although during the freeze is not a suitable time for making the expm1 tests cover cases close to overflow more thoroughly.) This leaves some code for large positive arguments in expm1l that is now dead. To keep the code for ldbl-128 and ldbl-128ibm similar, and to avoid unnecessary changes during the freeze, the patch doesn't remove it; instead I propose to file a bug in Bugzilla as a reminder that this code (for overflow, including errno setting, and for arguments of +Inf) is no longer needed and should be removed from both those expm1l implementations. Tested powerpc32. * sysdeps/ieee754/ldbl-128ibm/s_expm1l.c (__expm1l): Use __expl for large positive arguments. ----------------------------------------------------------------------- Summary of changes: ChangeLog | 6 ++++++ NEWS | 2 +- sysdeps/ieee754/ldbl-128ibm/s_expm1l.c | 2 ++ 3 files changed, 9 insertions(+), 1 deletions(-) -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug math/16408] ldbl-128ibm expm1l bad overflow handling 2014-01-07 21:31 [Bug math/16408] New: ldbl-128ibm expm1l bad overflow handling jsm28 at gcc dot gnu.org 2014-01-08 13:33 ` [Bug math/16408] " cvs-commit at gcc dot gnu.org @ 2014-01-08 13:36 ` jsm28 at gcc dot gnu.org 2014-06-13 9:10 ` fweimer at redhat dot com 2 siblings, 0 replies; 4+ messages in thread From: jsm28 at gcc dot gnu.org @ 2014-01-08 13:36 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=16408 Joseph Myers <jsm28 at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #2 from Joseph Myers <jsm28 at gcc dot gnu.org> --- Fixed for 2.19. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug math/16408] ldbl-128ibm expm1l bad overflow handling 2014-01-07 21:31 [Bug math/16408] New: ldbl-128ibm expm1l bad overflow handling jsm28 at gcc dot gnu.org 2014-01-08 13:33 ` [Bug math/16408] " cvs-commit at gcc dot gnu.org 2014-01-08 13:36 ` jsm28 at gcc dot gnu.org @ 2014-06-13 9:10 ` fweimer at redhat dot com 2 siblings, 0 replies; 4+ messages in thread From: fweimer at redhat dot com @ 2014-06-13 9:10 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=16408 Florian Weimer <fweimer at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Flags| |security- -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-06-13 9:10 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2014-01-07 21:31 [Bug math/16408] New: ldbl-128ibm expm1l bad overflow handling jsm28 at gcc dot gnu.org 2014-01-08 13:33 ` [Bug math/16408] " cvs-commit at gcc dot gnu.org 2014-01-08 13:36 ` jsm28 at gcc dot gnu.org 2014-06-13 9:10 ` fweimer at redhat dot com
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).