This is the mail archive of the cygwin-cvs@cygwin.com mailing list for the Cygwin 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]

[newlib-cygwin] Save and restore MXCSR register in delayed signal handling


https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=bfe23aa4373141e9f2c57f06438ab97142f60083

commit bfe23aa4373141e9f2c57f06438ab97142f60083
Author: Corinna Vinschen <corinna@vinschen.de>
Date:   Sat Nov 28 11:10:41 2015 +0100

    Save and restore MXCSR register in delayed signal handling
    
    	* gendef (sigdelayed): Save and restore content of the MXCSR register
    	on x86_64.
    
    Signed-off-by: Corinna Vinschen <corinna@vinschen.de>

Diff:
---
 winsup/cygwin/ChangeLog | 5 +++++
 winsup/cygwin/gendef    | 2 ++
 2 files changed, 7 insertions(+)

diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 474bbc8..8bffa81 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,8 @@
+2015-11-28  Corinna Vinschen  <corinna@vinschen.de>
+
+	* gendef (sigdelayed): Save and restore content of the MXCSR register
+	on x86_64.
+
 2015-11-27  Corinna Vinschen  <corinna@vinschen.de>
 
 	* cygtls.h (_cygtls::wait_signal_arrived): Renamed from
diff --git a/winsup/cygwin/gendef b/winsup/cygwin/gendef
index 9868277..9d6f1b4 100755
--- a/winsup/cygwin/gendef
+++ b/winsup/cygwin/gendef
@@ -229,6 +229,7 @@ sigdelayed:
 	.seh_pushreg %rax
 	subq	\$0x128,%rsp
 	.seh_stackalloc 0x128
+	stmxcsr	0x124(%rsp)
 	fnstcw	0x120(%rsp)
 	movdqa	%xmm15,0x110(%rsp)
 	movdqa	%xmm14,0x100(%rsp)
@@ -290,6 +291,7 @@ sigdelayed:
 	movdqa	0x110(%rsp),%xmm15
 	fninit
 	fldcw	0x120(%rsp)
+	ldmxcsr	0x124(%rsp)
 	addq	\$0x128,%rsp
 	popq	%rax
 	popq	%rbx


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