diff --git a/rehlds/engine/sys_dll.cpp b/rehlds/engine/sys_dll.cpp index 329ed09..22c6dee 100644 --- a/rehlds/engine/sys_dll.cpp +++ b/rehlds/engine/sys_dll.cpp @@ -212,15 +212,18 @@ enginefuncs_t g_engfuncsExportedToDlls; #ifdef _WIN32 void Sys_SetupFPUOptions() { +#ifndef __SSE__ static uint8 fpuOpts[32]; __asm { fnstenv byte ptr fpuOpts } fpuOpts[0] |= 0x3Fu; __asm { fldenv byte ptr fpuOpts } +#endif } -NOINLINE void Sys_InitFPUControlWords() +void Sys_InitFPUControlWords() { +#ifndef __SSE__ int fpucw = 0; __asm { fnstcw fpucw } @@ -228,9 +231,10 @@ NOINLINE void Sys_InitFPUControlWords() g_FPUCW_Mask_Prec_64Bit_2 = (fpucw & 0xF0FF) | 0x300; g_FPUCW_Mask_Round_Trunc = (fpucw & 0xF0FF) | 0xC00; g_FPUCW_Mask_Round_Up = (fpucw & 0xF0FF) | 0x800; +#endif } -void __cdecl Sys_SetStartTime() +void Sys_SetStartTime() { int startTimeArg; @@ -277,15 +281,19 @@ void __cdecl Sys_InitHardwareTimer() } int g_SavedFPUCW1 = 0; -NOINLINE void Sys_FPUCW_Push_Prec64() { +void Sys_FPUCW_Push_Prec64() { +#ifndef __SSE__ uint16 tmp = g_FPUCW_Mask_Prec_64Bit; __asm { fnstcw g_SavedFPUCW1 } __asm { fldcw tmp } +#endif } -NOINLINE void Sys_FPUCW_Pop_Prec64() { +void Sys_FPUCW_Pop_Prec64() { +#ifndef __SSE__ uint16 tmp = g_SavedFPUCW1; __asm { fldcw tmp } +#endif } #endif // _WIN32