Skip to content
Snippets Groups Projects
Commit f5e98396 authored by Nat Goodspeed's avatar Nat Goodspeed
Browse files

DRTVWR-418: Replace preprocessor tests for Windows-specific _M_AMD64

with tests on ADDRESS_SIZE, which is now set on the compiler command line.
parent d833e45c
No related branches found
No related tags found
No related merge requests found
...@@ -139,7 +139,7 @@ ...@@ -139,7 +139,7 @@
#pragma warning (disable : 4180) // qualifier applied to function type has no meaning; ignored #pragma warning (disable : 4180) // qualifier applied to function type has no meaning; ignored
//#pragma warning( disable : 4284 ) // silly MS warning deep inside their <map> include file //#pragma warning( disable : 4284 ) // silly MS warning deep inside their <map> include file
#ifdef _M_AMD64 #if ADDRESS_SIZE == 64
// That one is all over the place for x64 builds. // That one is all over the place for x64 builds.
#pragma warning( disable : 4267 ) // 'var' : conversion from 'size_t' to 'type', possible loss of data) #pragma warning( disable : 4267 ) // 'var' : conversion from 'size_t' to 'type', possible loss of data)
#endif #endif
......
...@@ -153,7 +153,7 @@ inline F64 llabs(const F64 a) ...@@ -153,7 +153,7 @@ inline F64 llabs(const F64 a)
inline S32 lltrunc( F32 f ) inline S32 lltrunc( F32 f )
{ {
#if LL_WINDOWS && !defined( __INTEL_COMPILER ) && !defined( _M_AMD64 ) #if LL_WINDOWS && !defined( __INTEL_COMPILER ) && (ADDRESS_SIZE == 32)
// Avoids changing the floating point control word. // Avoids changing the floating point control word.
// Add or subtract 0.5 - epsilon and then round // Add or subtract 0.5 - epsilon and then round
const static U32 zpfp[] = { 0xBEFFFFFF, 0x3EFFFFFF }; const static U32 zpfp[] = { 0xBEFFFFFF, 0x3EFFFFFF };
...@@ -179,7 +179,7 @@ inline S32 lltrunc( F64 f ) ...@@ -179,7 +179,7 @@ inline S32 lltrunc( F64 f )
inline S32 llfloor( F32 f ) inline S32 llfloor( F32 f )
{ {
#if LL_WINDOWS && !defined( __INTEL_COMPILER ) && !defined( _M_AMD64 ) #if LL_WINDOWS && !defined( __INTEL_COMPILER ) && (ADDRESS_SIZE == 32)
// Avoids changing the floating point control word. // Avoids changing the floating point control word.
// Accurate (unlike Stereopsis version) for all values between S32_MIN and S32_MAX and slightly faster than Stereopsis version. // Accurate (unlike Stereopsis version) for all values between S32_MIN and S32_MAX and slightly faster than Stereopsis version.
// Add -(0.5 - epsilon) and then round // Add -(0.5 - epsilon) and then round
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
#error "Please include llmath.h before this file." #error "Please include llmath.h before this file."
#endif #endif
#if ( ( LL_DARWIN || LL_LINUX ) && !(__SSE2__) ) || ( LL_WINDOWS && ( _M_IX86_FP < 2 && !_M_AMD64 ) ) #if ( ( LL_DARWIN || LL_LINUX ) && !(__SSE2__) ) || ( LL_WINDOWS && ( _M_IX86_FP < 2 && ADDRESS_SIZE == 32 ) )
#error SSE2 not enabled. LLVector4a and related class will not compile. #error SSE2 not enabled. LLVector4a and related class will not compile.
#endif #endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment