make xor enable in SSEonly + fast math

This commit is contained in:
Recep Aslantas
2024-04-01 13:23:52 +03:00
parent d8e933b5b1
commit 1d09c41e18

View File

@@ -55,8 +55,20 @@
#endif
/* Note that `0x80000000` corresponds to `INT_MIN` for a 32-bit int. */
#define GLMM_NEGZEROf ((int)0x80000000) /* 0x80000000 ---> -0.0f */
#define GLMM_POSZEROf ((int)0x00000000) /* 0x00000000 ---> +0.0f */
#if defined(__SSE2__)
# define GLMM_NEGZEROf ((int)0x80000000) /* 0x80000000 ---> -0.0f */
# define GLMM_POSZEROf ((int)0x00000000) /* 0x00000000 ---> +0.0f */
#else
# ifdef CGLM_FAST_MATH
union { int i; float f; } static GLMM_NEGZEROf_TU = { .i = 0x80000000 };
# define GLMM_NEGZEROf GLMM_NEGZEROf_TU.f
# define GLMM_POSZEROf 0.0f
# else
# define GLMM_NEGZEROf -0.0f
# define GLMM_POSZEROf 0.0f
# endif
#endif
#if defined(__SSE2__)
# define GLMM__SIGNMASKf(X, Y, Z, W) \