Properly restore the SSE control word with __control87_2

This commit is contained in:
Chris Robinson 2012-09-16 06:01:48 -07:00
parent df2e82da78
commit 95535ce99e

View File

@ -227,7 +227,7 @@ void RestoreFPUMode(const FPUCtl *ctl)
__control87_2(ctl->state, _MCW_RC|_MCW_PC, &mode, NULL);
#ifdef HAVE_SSE
if((CPUCapFlags&CPU_CAP_SSE))
__control87_2(ctl->sse_state, _MCW_DN, NULL, &mode);
__control87_2(ctl->sse_state, _MCW_RC|_MCW_PC|_MCW_DN, NULL, &mode);
#endif
#elif defined(HAVE__CONTROLFP)
_controlfp(ctl->state, _MCW_RC|_MCW_PC);