This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug math/19181] [i386/x86_64] fesetenv (FE_DFL_ENV), fesetenv (FE_NOMASK_ENV) do not clear SSE exceptions


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

--- 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  0b9af583a5c2d68085e88cece13952bf05dc4882 (commit)
      from  eae6c382bdca2e7ac582a69d56c9c228b678ee67 (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=0b9af583a5c2d68085e88cece13952bf05dc4882

commit 0b9af583a5c2d68085e88cece13952bf05dc4882
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Wed Oct 28 18:50:20 2015 +0000

    Fix i386/x86_64 fesetenv SSE exception clearing (bug 19181).

    The i386 and x86_64 versions of fesetenv, when called with FE_DFL_ENV
    or FE_NOMASK_ENV as argument, do not clear SSE exceptions raised in
    MXCSR.  These arguments should, like other fenv_t values, represent
    the whole of the floating-point state, so such exceptions should be
    cleared; this patch adds the required clearing.  (Discovered while
    working on bug 16068.)

    Tested for x86_64 and x86.

        [BZ #19181]
        * sysdeps/i386/fpu/fesetenv.c (__fesetenv): Clear already-raised
        SSE exceptions when argument is FE_DFL_ENV or FE_NOMASK_ENV.
        * sysdeps/x86_64/fpu/fesetenv.c (__fesetenv): Likewise.
        * math/test-fenv-clear-main.c: New file.
        * math/test-fenv-clear.c: Likewise.
        * math/Makefile (tests): Add test-fenv-clear.
        * sysdeps/x86/fpu/test-fenv-clear-sse.c: New file.
        * sysdeps/x86/fpu/Makefile [$(subdir) = math] (tests): Add
        test-fenv-clear-sse.
        [$(subdir) = math] (CFLAGS-test-fenv-clear-sse.c): New variable.

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

Summary of changes:
 ChangeLog                             |   12 ++++
 NEWS                                  |    2 +-
 math/Makefile                         |    2 +-
 math/test-fenv-clear-main.c           |   91 +++++++++++++++++++++++++++++++++
 math/test-fenv-clear.c                |    2 +
 sysdeps/i386/fpu/fesetenv.c           |    4 ++
 sysdeps/x86/fpu/Makefile              |    3 +-
 sysdeps/x86/fpu/test-fenv-clear-sse.c |   45 ++++++++++++++++
 sysdeps/x86_64/fpu/fesetenv.c         |    4 ++
 9 files changed, 162 insertions(+), 3 deletions(-)
 create mode 100644 math/test-fenv-clear-main.c
 create mode 100644 math/test-fenv-clear.c
 create mode 100644 sysdeps/x86/fpu/test-fenv-clear-sse.c

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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]