Author: jilles
Date: Mon Jun  9 21:35:36 2014
New Revision: 267307
URL: http://svnweb.freebsd.org/changeset/base/267307

Log:
  siglongjmp(): Preserve floating point exception flags on i386 and amd64.
  
  Per POSIX, siglongjmp() shall be equivalent to longjmp() except that it must
  match sigsetjmp() instead of setjmp() and except for the effect on the
  signal mask. Therefore, it should preserve the floating point exception
  flags.
  
  This was fixed for longjmp() and _longjmp() in r180080 and r180081 for amd64
  and i386 respectively.

Modified:
  head/lib/libc/amd64/gen/sigsetjmp.S
  head/lib/libc/i386/gen/sigsetjmp.S

Modified: head/lib/libc/amd64/gen/sigsetjmp.S
==============================================================================
--- head/lib/libc/amd64/gen/sigsetjmp.S Mon Jun  9 21:06:46 2014        
(r267306)
+++ head/lib/libc/amd64/gen/sigsetjmp.S Mon Jun  9 21:35:36 2014        
(r267307)
@@ -105,7 +105,6 @@ ENTRY(__siglongjmp)
        movq    40(%rdx),%r13
        movq    48(%rdx),%r14
        movq    56(%rdx),%r15
-       fninit
        fldcw   64(%rdx)
        testq   %rax,%rax
        jnz     1f

Modified: head/lib/libc/i386/gen/sigsetjmp.S
==============================================================================
--- head/lib/libc/i386/gen/sigsetjmp.S  Mon Jun  9 21:06:46 2014        
(r267306)
+++ head/lib/libc/i386/gen/sigsetjmp.S  Mon Jun  9 21:35:36 2014        
(r267307)
@@ -115,7 +115,6 @@ ENTRY(__siglongjmp)
        movl    12(%edx),%ebp
        movl    16(%edx),%esi
        movl    20(%edx),%edi
-       fninit
        fldcw   24(%edx)
        testl   %eax,%eax
        jnz     1f
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to