| Submitter | Rainer Orth |
|---|---|
| Date | Aug. 26, 2010, 3:28 p.m. |
| Message ID | <yddsk2175rl.fsf@manam.CeBiTec.Uni-Bielefeld.DE> |
| Download | mbox | patch |
| Permalink | /patch/62783/ |
| State | New |
| Headers | show |
Comments
Patch
diff -r 0cf77b5772bf libgfortran/config/fpu-387.h --- a/libgfortran/config/fpu-387.h Mon Aug 23 13:25:29 2010 +0200 +++ b/libgfortran/config/fpu-387.h Thu Aug 26 17:23:39 2010 +0200 @@ -64,7 +64,6 @@ if (edx & bit_SSE) { struct sigaction act, oact; - unsigned int cw_sse; act.sa_handler = sigill_hdlr; sigemptyset (&act.sa_mask); @@ -72,7 +71,9 @@ act.sa_flags = SA_SIGINFO; sigaction (SIGILL, &act, &oact); - asm volatile ("stmxcsr %0" : "=m" (cw_sse)); + /* We need a single SSE instruction here so the handler can safely skip + over it. */ + __asm__ volatile ("movss %xmm2,%xmm1"); sigaction (SIGILL, &oact, NULL);