diff options
author | Joseph Myers <joseph@codesourcery.com> | 2014-03-24 12:18:45 +0000 |
---|---|---|
committer | Joseph Myers <joseph@codesourcery.com> | 2014-03-24 12:18:45 +0000 |
commit | b376a11a19aa7b64107081e4eed2327c25a131be (patch) | |
tree | 09e60db7b0fad49f557d8b109e861d58945943f8 /nptl/tst-sem10.c | |
parent | 1ca2d03e3e4c8b27a666676bb5b92e6f5d6f2a07 (diff) | |
download | glibc-b376a11a19aa7b64107081e4eed2327c25a131be.tar glibc-b376a11a19aa7b64107081e4eed2327c25a131be.tar.gz glibc-b376a11a19aa7b64107081e4eed2327c25a131be.tar.bz2 glibc-b376a11a19aa7b64107081e4eed2327c25a131be.zip |
Fix dbl-64 exp overflow/underflow in non-default rounding modes (bug 16284).
The dbl-64 version of exp needs round-to-nearest mode for its internal
computations, but that has the consequence of inappropriate
overflowing and underflowing results in other rounding modes. This
patch fixes this by recomputing the relevant results in cases where
the round-to-nearest result overflows to infinity or underflows to
zero (most of the diffs are actually just consequent reindentation).
Tests are enabled in all rounding modes for complex functions using
exp - but not for cexp because it turns out there are bugs causing
spurious underflows for cexp for some tests, which will need to be
fixed separately (I suspect ccos ccosh csin csinh ctan ctanh have
similar bugs, just not shown by the present set of test inputs).
Tested x86_64 and x86 and ulps updated accordingly.
[BZ #16284]
* sysdeps/ieee754/dbl-64/e_exp.c (__ieee754_exp): Use original
rounding mode to recompute results that overflow to infinity or
underflow to zero.
* math/auto-libm-test-in: Don't mark tests as expected to fail for
bug 16284.
* math/auto-libm-test-out: Regenerated.
* math/libm-test.inc (ccos_test): Use ALL_RM_TEST.
(ccosh_test): Likewise.
(csin_test_data): Use plus_oflow.
(csin_test): Use ALL_RM_TEST.
(csinh_test_data): Use plus_oflow.
(csinh_test): Use ALL_RM_TEST.
* sysdeps/i386/fpu/libm-test-ulps: Update.
* sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
Diffstat (limited to 'nptl/tst-sem10.c')
0 files changed, 0 insertions, 0 deletions