Use proper macros instead of magic numbers
This commit is contained in:
parent
90db129d60
commit
cfae2cc254
@ -7,7 +7,7 @@
|
||||
#include <intrin.h>
|
||||
#endif
|
||||
#ifdef HAVE_SSE_INTRINSICS
|
||||
#include <xmmintrin.h>
|
||||
#include <emmintrin.h>
|
||||
#endif
|
||||
|
||||
#include "cpu_caps.h"
|
||||
@ -20,8 +20,8 @@ void FPUCtl::enter() noexcept
|
||||
#if defined(HAVE_SSE_INTRINSICS)
|
||||
this->sse_state = _mm_getcsr();
|
||||
unsigned int sseState{this->sse_state};
|
||||
sseState |= 0x8000; /* set flush-to-zero */
|
||||
sseState |= 0x0040; /* set denormals-are-zero */
|
||||
sseState &= ~(_MM_FLUSH_ZERO_MASK | _MM_DENORMALS_ZERO_MASK);
|
||||
sseState |= _MM_FLUSH_ZERO_ON | _MM_DENORMALS_ZERO_ON;
|
||||
_mm_setcsr(sseState);
|
||||
|
||||
#elif defined(__GNUC__) && defined(HAVE_SSE)
|
||||
|
Loading…
x
Reference in New Issue
Block a user