GCC: disable using intrinsics by default

This commit is contained in:
s1lent 2018-10-26 23:30:18 +07:00
parent 7aeca162d6
commit b732b47874
No known key found for this signature in database
GPG Key ID: 0FE401DC73916B5C
5 changed files with 8 additions and 6 deletions

View File

@ -48,7 +48,7 @@
#include <functional>
// enable SSE code only if it's enabled in compiler options
#if defined(__SSE__) || defined(__SSE2__) || defined(_M_IX86_FP) || defined(_M_AMD64) || defined(_M_X64)
#if (defined(REHLDS_SSE) || defined(REGAMEDLL_SSE)) && (defined(__SSE__) || defined(__SSE2__) || defined(_M_IX86_FP) || defined(_M_AMD64) || defined(_M_X64))
// #error "SSE enabled"
#define HAVE_SSE
#endif

View File

@ -907,7 +907,7 @@
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>REGAMEDLL_ADD;REGAMEDLL_API;REGAMEDLL_FIXES;REGAMEDLL_SELF;UNICODE_FIXES;REGAMEDLL_CHECKS;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>REGAMEDLL_ADD;REGAMEDLL_API;REGAMEDLL_SSE;REGAMEDLL_FIXES;REGAMEDLL_SELF;UNICODE_FIXES;REGAMEDLL_CHECKS;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointModel>Fast</FloatingPointModel>
<AdditionalOptions>/arch:IA32 %(AdditionalOptions)</AdditionalOptions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
@ -943,7 +943,7 @@
<WarningLevel>Level3</WarningLevel>
<Optimization>Full</Optimization>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>REGAMEDLL_ADD;REGAMEDLL_API;REGAMEDLL_FIXES;REGAMEDLL_SELF;REGAMEDLL_CHECKS;UNICODE_FIXES;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>REGAMEDLL_ADD;REGAMEDLL_SSE;REGAMEDLL_API;REGAMEDLL_FIXES;REGAMEDLL_SELF;REGAMEDLL_CHECKS;UNICODE_FIXES;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointModel>Fast</FloatingPointModel>
<AdditionalOptions>/arch:IA32 %(AdditionalOptions)</AdditionalOptions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
@ -988,7 +988,7 @@
<WarningLevel>Level3</WarningLevel>
<Optimization>Full</Optimization>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>PLAY_GAMEDLL;REGAMEDLL_SELF;REGAMEDLL_API;REGAMEDLL_CHECKS;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>PLAY_GAMEDLL;REGAMEDLL_SELF;REGAMEDLL_API;REGAMEDLL_SSE;REGAMEDLL_CHECKS;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointModel>Precise</FloatingPointModel>
<AdditionalOptions>/arch:IA32 %(AdditionalOptions)</AdditionalOptions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
@ -1033,7 +1033,7 @@
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>PLAY_GAMEDLL;REGAMEDLL_SELF;REGAMEDLL_CHECKS;REGAMEDLL_API;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>PLAY_GAMEDLL;REGAMEDLL_SELF;REGAMEDLL_CHECKS;REGAMEDLL_API;REGAMEDLL_SSE;CLIENT_WEAPONS;USE_BREAKPAD_HANDLER;USE_QSTRING;DEDICATED;_CRT_SECURE_NO_WARNINGS;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointModel>Precise</FloatingPointModel>
<AdditionalOptions>/arch:IA32 %(AdditionalOptions)</AdditionalOptions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>

View File

@ -27,7 +27,7 @@ rootProject.ext.createGccConfig = { boolean release, BinaryKind binKind ->
)
)
} else {
//debug
// debug
cfg = new GccToolchainConfig(
compilerOptions: new GccToolchainConfig.CompilerOptions(
optimizationLevel: OptimizationLevel.DISABLE,

View File

@ -60,6 +60,7 @@ rootProject.ext.createIccConfig = { boolean release, BinaryKind binKind ->
)
}
cfg.singleDefines('REGAMEDLL_SSE')
cfg.singleDefines('LINUX', '_LINUX')
return cfg
}

View File

@ -129,6 +129,7 @@ rootProject.ext.createMsvcConfig = { boolean release, BinaryKind binKind ->
cfg.compilerOptions.args "/FS", "/I${kitPath}Include/${ucrtVersion}/ucrt";
cfg.linkerOptions.args("/LIBPATH:${kitPath}Lib/${ucrtVersion}/ucrt/x86");
cfg.singleDefines('REGAMEDLL_SSE')
return cfg
}