public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug math/18961] New: [i386] exp missing underflows
@ 2015-09-14 22:22 jsm28 at gcc dot gnu.org
  2015-09-14 22:41 ` [Bug math/18961] " cvs-commit at gcc dot gnu.org
  2015-09-14 22:42 ` jsm28 at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: jsm28 at gcc dot gnu.org @ 2015-09-14 22:22 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=18961

            Bug ID: 18961
           Summary: [i386] exp missing underflows
           Product: glibc
           Version: 2.22
            Status: NEW
          Severity: normal
          Priority: P2
         Component: math
          Assignee: unassigned at sourceware dot org
          Reporter: jsm28 at gcc dot gnu.org
  Target Milestone: ---
              Host: i?86-*-*

On i386, the double version of exp can miss underflow exceptions if the result
is in the subnormal range for double but the last 11 bits of the 64-bit
extended-precision mantissa happen to be zero.  E.g. (examples producing this
may vary depending on x86 implementations):

Failure: exp (-0x2.c469d9p+8): Exception "Underflow" not set
Failure: exp (-0x2.c46d96p+8): Exception "Underflow" not set
Failure: exp_downward (-0x2.c46727p+8): Exception "Underflow" not set
Failure: exp_downward (-0x2.c469dep+8): Exception "Underflow" not set
Failure: exp_downward (-0x2.c46c04p+8): Exception "Underflow" not set
Failure: exp_towardzero (-0x2.c46adep+8): Exception "Underflow" not set
Failure: exp_towardzero (-0x2.c471b3p+8): Exception "Underflow" not set
Failure: exp_upward (-0x2.c46993p+8): Exception "Underflow" not set

Failure: exp_towardzero (-0x2.c49fap+8): Exception "Underflow" not set
Failure: exp_towardzero (-0x2.c4ac1p+8): Exception "Underflow" not set
Failure: exp_towardzero (-0x2.c4d89p+8): Exception "Underflow" not set

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug math/18961] [i386] exp missing underflows
  2015-09-14 22:22 [Bug math/18961] New: [i386] exp missing underflows jsm28 at gcc dot gnu.org
@ 2015-09-14 22:41 ` cvs-commit at gcc dot gnu.org
  2015-09-14 22:42 ` jsm28 at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2015-09-14 22:41 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=18961

--- 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  de5e81691c80468ff97c5260b4020aeaecfe418d (commit)
      from  903af5af9a0404c1dfeb7b4db6d5a23a1e45593f (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=de5e81691c80468ff97c5260b4020aeaecfe418d

commit de5e81691c80468ff97c5260b4020aeaecfe418d
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Mon Sep 14 22:40:05 2015 +0000

    Fix i386 exp missing underflows (bug 18961).

    On i386, the double version of exp can miss underflow exceptions if
    the result is in the subnormal range for double but the last 11 bits
    of the 64-bit extended-precision mantissa happen to be zero.  This
    patch forces the exception in a similar way to previous fixes.

    As with the exp2 fixes, the expf changes may in fact not be needed to
    ensure underflow exceptions, but are included for consistency and to
    fix the exp part of bug 18875 by ensuring that excess range and
    precision is removed from underflowing return values.

    Tested for x86_64 and x86.

        [BZ #18875]
        [BZ #18961]
        * sysdeps/i386/fpu/e_exp.S (dbl_min): New object.
        (MO): New macro.
        (__ieee754_exp): For small results, force underflow exception and
        remove excess range and precision from return value.
        (__exp_finite): Likewise.
        * sysdeps/i386/fpu/e_expf.S (flt_min): New object.
        (MO): New macro.
        (__ieee754_expf): For small results, force underflow exception and
        remove excess range and precision from return value.
        (__expf_finite): Likewise.
        * math/auto-libm-test-in: Add more tests of exp.
        * math/auto-libm-test-out: Regenerated.

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

Summary of changes:
 ChangeLog                 |   15 ++
 NEWS                      |    2 +-
 math/auto-libm-test-in    |   11 +
 math/auto-libm-test-out   |  583 +++++++++++++++++++++++++++++++++++++++++++++
 sysdeps/i386/fpu/e_exp.S  |   53 ++++-
 sysdeps/i386/fpu/e_expf.S |   53 ++++-
 6 files changed, 712 insertions(+), 5 deletions(-)

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug math/18961] [i386] exp missing underflows
  2015-09-14 22:22 [Bug math/18961] New: [i386] exp missing underflows jsm28 at gcc dot gnu.org
  2015-09-14 22:41 ` [Bug math/18961] " cvs-commit at gcc dot gnu.org
@ 2015-09-14 22:42 ` jsm28 at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: jsm28 at gcc dot gnu.org @ 2015-09-14 22:42 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=18961

Joseph Myers <jsm28 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED
   Target Milestone|---                         |2.23

--- Comment #2 from Joseph Myers <jsm28 at gcc dot gnu.org> ---
Fixed for 2.23.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-09-14 22:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-09-14 22:22 [Bug math/18961] New: [i386] exp missing underflows jsm28 at gcc dot gnu.org
2015-09-14 22:41 ` [Bug math/18961] " cvs-commit at gcc dot gnu.org
2015-09-14 22:42 ` jsm28 at gcc dot gnu.org

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).