This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug math/18593] csin, csinh bad overflow results in directed rounding modes
- From: "cvs-commit at gcc dot gnu.org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Wed, 24 Jun 2015 16:21:51 +0000
- Subject: [Bug math/18593] csin, csinh bad overflow results in directed rounding modes
- Auto-submitted: auto-generated
- References: <bug-18593-131 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=18593
--- 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 ac831b362ad6ecd49643625481ec700a9812e52f (commit)
from 8475ab16848cf2adb6ce3446749c2f1d10233286 (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=ac831b362ad6ecd49643625481ec700a9812e52f
commit ac831b362ad6ecd49643625481ec700a9812e52f
Author: Joseph Myers <joseph@codesourcery.com>
Date: Wed Jun 24 16:20:48 2015 +0000
Fix csin, csinh overflow in directed rounding modes (bug 18593).
csin and csinh can produce bad results when overflowing in directed
rounding modes, because a multiplication that can overflow is followed
by a possible negation. This patch fixes this by negating one of the
arguments of the multiplication before the multiplication instead of
negating the result.
The new tests for this issue are added to auto-libm-test-in, starting
use of that file for csin and csinh. The issue was found in the
course of moving existing tests for csin and csinh (existing tests, by
being enabled in more cases than previously, showed the issue for
float and double but not for long double); that move will now be done
separately.
Tested for x86_64 and x86 and ulps updated accordingly.
[BZ #18593]
* math/s_csin.c (__csin): Negate before rather than after possibly
overflowing multiplication.
* math/s_csinf.c (__csinf): Likewise.
* math/s_csinh.c (__csinh): Likewise.
* math/s_csinhf.c (__csinhf): Likewise.
* math/s_csinhl.c (__csinhl): Likewise.
* math/s_csinl.c (__csinl): Likewise.
* math/auto-libm-test-in: Add some tests of csin and csinh.
* math/auto-libm-test-out: Regenerated.
* math/libm-test.inc (csin_test_data): Use AUTO_TESTS_c_c.
(csinh_test_data): Likewise.
* sysdeps/x86_64/fpu/libm-test-ulps: Update.
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 14 +++
NEWS | 2 +-
math/auto-libm-test-in | 10 ++
math/auto-libm-test-out | 200 +++++++++++++++++++++++++++++++++++++
math/libm-test.inc | 4 +
math/s_csin.c | 6 +-
math/s_csinf.c | 6 +-
math/s_csinh.c | 6 +-
math/s_csinhf.c | 6 +-
math/s_csinhl.c | 6 +-
math/s_csinl.c | 6 +-
sysdeps/x86_64/fpu/libm-test-ulps | 8 +-
12 files changed, 251 insertions(+), 23 deletions(-)
--
You are receiving this mail because:
You are on the CC list for the bug.