diff --git a/Source/Core/Core/BootManager.cpp b/Source/Core/Core/BootManager.cpp index 585e5d62e997..10169a65be51 100644 --- a/Source/Core/Core/BootManager.cpp +++ b/Source/Core/Core/BootManager.cpp @@ -75,6 +75,7 @@ struct ConfigCache bool bCPUThread; bool bJITFollowBranch; bool bSyncGPUOnSkipIdleHack; + bool bAlignmentExceptions; bool bFPRF; bool bAccurateNaNs; bool bMMU; @@ -109,6 +110,7 @@ void ConfigCache::SaveConfig(const SConfig& config) bCPUThread = config.bCPUThread; bJITFollowBranch = config.bJITFollowBranch; bSyncGPUOnSkipIdleHack = config.bSyncGPUOnSkipIdleHack; + bAlignmentExceptions = config.bAlignmentExceptions; bFPRF = config.bFPRF; bAccurateNaNs = config.bAccurateNaNs; bDisableICache = config.bDisableICache; @@ -154,6 +156,7 @@ void ConfigCache::RestoreConfig(SConfig* config) config->bCPUThread = bCPUThread; config->bJITFollowBranch = bJITFollowBranch; config->bSyncGPUOnSkipIdleHack = bSyncGPUOnSkipIdleHack; + config->bAlignmentExceptions = bAlignmentExceptions; config->bFPRF = bFPRF; config->bAccurateNaNs = bAccurateNaNs; config->bDisableICache = bDisableICache; @@ -256,6 +259,8 @@ bool BootCore(std::unique_ptr boot, const WindowSystemInfo& wsi) core_section->Get("JITFollowBranch", &StartUp.bJITFollowBranch, StartUp.bJITFollowBranch); core_section->Get("SyncOnSkipIdle", &StartUp.bSyncGPUOnSkipIdleHack, StartUp.bSyncGPUOnSkipIdleHack); + core_section->Get("AlignmentExceptions", &StartUp.bAlignmentExceptions, + StartUp.bAlignmentExceptions); core_section->Get("FPRF", &StartUp.bFPRF, StartUp.bFPRF); core_section->Get("AccurateNaNs", &StartUp.bAccurateNaNs, StartUp.bAccurateNaNs); core_section->Get("DisableICache", &StartUp.bDisableICache, StartUp.bDisableICache); @@ -366,6 +371,7 @@ bool BootCore(std::unique_ptr boot, const WindowSystemInfo& wsi) config_cache.bSetEXIDevice[0] = true; config_cache.bSetEXIDevice[1] = true; config_cache.bSetEXIDevice[2] = true; + StartUp.bAlignmentExceptions = netplay_settings.m_AlignmentExceptions; StartUp.bFPRF = netplay_settings.m_FPRF; StartUp.bAccurateNaNs = netplay_settings.m_AccurateNaNs; StartUp.bDisableICache = netplay_settings.m_DisableICache; diff --git a/Source/Core/Core/Config/MainSettings.cpp b/Source/Core/Core/Config/MainSettings.cpp index 550e1bdd8998..7d796038851f 100644 --- a/Source/Core/Core/Config/MainSettings.cpp +++ b/Source/Core/Core/Config/MainSettings.cpp @@ -86,6 +86,7 @@ const Info MAIN_SYNC_GPU_MIN_DISTANCE{{System::Main, "Core", "SyncGpuMinDis const Info MAIN_SYNC_GPU_OVERCLOCK{{System::Main, "Core", "SyncGpuOverclock"}, 1.0f}; const Info MAIN_FAST_DISC_SPEED{{System::Main, "Core", "FastDiscSpeed"}, false}; const Info MAIN_LOW_DCBZ_HACK{{System::Main, "Core", "LowDCBZHack"}, false}; +const Info MAIN_ALIGNMENT_EXCEPTIONS{{System::Main, "Core", "AlignmentExceptions"}, false}; const Info MAIN_FPRF{{System::Main, "Core", "FPRF"}, false}; const Info MAIN_ACCURATE_NANS{{System::Main, "Core", "AccurateNaNs"}, false}; const Info MAIN_DISABLE_ICACHE{{System::Main, "Core", "DisableICache"}, false}; diff --git a/Source/Core/Core/Config/MainSettings.h b/Source/Core/Core/Config/MainSettings.h index 413f2c85b951..2663202b5b9c 100644 --- a/Source/Core/Core/Config/MainSettings.h +++ b/Source/Core/Core/Config/MainSettings.h @@ -68,6 +68,7 @@ extern const Info MAIN_SYNC_GPU_MIN_DISTANCE; extern const Info MAIN_SYNC_GPU_OVERCLOCK; extern const Info MAIN_FAST_DISC_SPEED; extern const Info MAIN_LOW_DCBZ_HACK; +extern const Info MAIN_ALIGNMENT_EXCEPTIONS; extern const Info MAIN_FPRF; extern const Info MAIN_ACCURATE_NANS; extern const Info MAIN_DISABLE_ICACHE; diff --git a/Source/Core/Core/ConfigLoaders/NetPlayConfigLoader.cpp b/Source/Core/Core/ConfigLoaders/NetPlayConfigLoader.cpp index 983bf27040f5..093b0708433b 100644 --- a/Source/Core/Core/ConfigLoaders/NetPlayConfigLoader.cpp +++ b/Source/Core/Core/ConfigLoaders/NetPlayConfigLoader.cpp @@ -69,6 +69,7 @@ class NetPlayConfigLayerLoader final : public Config::ConfigLayerLoader layer->Set(Config::GFX_SAFE_TEXTURE_CACHE_COLOR_SAMPLES, m_settings.m_SafeTextureCacheColorSamples); layer->Set(Config::GFX_PERF_QUERIES_ENABLE, m_settings.m_PerfQueriesEnable); + layer->Set(Config::MAIN_ALIGNMENT_EXCEPTIONS, m_settings.m_AlignmentExceptions); layer->Set(Config::MAIN_FPRF, m_settings.m_FPRF); layer->Set(Config::MAIN_ACCURATE_NANS, m_settings.m_AccurateNaNs); layer->Set(Config::MAIN_DISABLE_ICACHE, m_settings.m_DisableICache); diff --git a/Source/Core/Core/ConfigManager.cpp b/Source/Core/Core/ConfigManager.cpp index 56985b1c3d3c..cd8e756fcd9d 100644 --- a/Source/Core/Core/ConfigManager.cpp +++ b/Source/Core/Core/ConfigManager.cpp @@ -213,6 +213,7 @@ void SConfig::SaveCoreSettings(IniFile& ini) core->Set("SyncGpuMaxDistance", iSyncGpuMaxDistance); core->Set("SyncGpuMinDistance", iSyncGpuMinDistance); core->Set("SyncGpuOverclock", fSyncGpuOverclock); + core->Set("AlignmentExceptions", bAlignmentExceptions); core->Set("FPRF", bFPRF); core->Set("AccurateNaNs", bAccurateNaNs); core->Set("SelectedLanguage", SelectedLanguage); @@ -509,6 +510,7 @@ void SConfig::LoadCoreSettings(IniFile& ini) core->Get("SyncGpuOverclock", &fSyncGpuOverclock, 1.0f); core->Get("FastDiscSpeed", &bFastDiscSpeed, false); core->Get("LowDCBZHack", &bLowDCBZHack, false); + core->Get("AlignmentExceptions", &bAlignmentExceptions, false); core->Get("FPRF", &bFPRF, false); core->Get("AccurateNaNs", &bAccurateNaNs, false); core->Get("DisableICache", &bDisableICache, false); @@ -747,6 +749,7 @@ void SConfig::LoadDefaults() bRunCompareServer = false; bDSPHLE = true; bFastmem = true; + bAlignmentExceptions = false; bFPRF = false; bAccurateNaNs = false; bDisableICache = false; diff --git a/Source/Core/Core/ConfigManager.h b/Source/Core/Core/ConfigManager.h index 50d8ebd3fe84..d6f717c79467 100644 --- a/Source/Core/Core/ConfigManager.h +++ b/Source/Core/Core/ConfigManager.h @@ -108,6 +108,7 @@ struct SConfig bool bJITRegisterCacheOff = false; bool bFastmem; + bool bAlignmentExceptions = false; bool bFPRF = false; bool bAccurateNaNs = false; bool bDisableICache = false; diff --git a/Source/Core/Core/NetPlayClient.cpp b/Source/Core/Core/NetPlayClient.cpp index 8f730038ef86..92e695ad28b2 100644 --- a/Source/Core/Core/NetPlayClient.cpp +++ b/Source/Core/Core/NetPlayClient.cpp @@ -831,6 +831,7 @@ void NetPlayClient::OnStartGame(sf::Packet& packet) packet >> m_net_settings.m_EFBEmulateFormatChanges; packet >> m_net_settings.m_SafeTextureCacheColorSamples; packet >> m_net_settings.m_PerfQueriesEnable; + packet >> m_net_settings.m_AlignmentExceptions; packet >> m_net_settings.m_FPRF; packet >> m_net_settings.m_AccurateNaNs; packet >> m_net_settings.m_DisableICache; diff --git a/Source/Core/Core/NetPlayProto.h b/Source/Core/Core/NetPlayProto.h index 4d3cf436fb3a..1b3ea74b3545 100644 --- a/Source/Core/Core/NetPlayProto.h +++ b/Source/Core/Core/NetPlayProto.h @@ -58,6 +58,7 @@ struct NetSettings bool m_EFBEmulateFormatChanges; int m_SafeTextureCacheColorSamples; bool m_PerfQueriesEnable; + bool m_AlignmentExceptions; bool m_FPRF; bool m_AccurateNaNs; bool m_DisableICache; diff --git a/Source/Core/Core/NetPlayServer.cpp b/Source/Core/Core/NetPlayServer.cpp index 806f4967acfd..6cfb2e87a91f 100644 --- a/Source/Core/Core/NetPlayServer.cpp +++ b/Source/Core/Core/NetPlayServer.cpp @@ -1329,6 +1329,7 @@ bool NetPlayServer::SetupNetSettings() settings.m_SafeTextureCacheColorSamples = Config::Get(Config::GFX_SAFE_TEXTURE_CACHE_COLOR_SAMPLES); settings.m_PerfQueriesEnable = Config::Get(Config::GFX_PERF_QUERIES_ENABLE); + settings.m_AlignmentExceptions = Config::Get(Config::MAIN_ALIGNMENT_EXCEPTIONS); settings.m_FPRF = Config::Get(Config::MAIN_FPRF); settings.m_AccurateNaNs = Config::Get(Config::MAIN_ACCURATE_NANS); settings.m_DisableICache = Config::Get(Config::MAIN_DISABLE_ICACHE); @@ -1505,6 +1506,7 @@ bool NetPlayServer::StartGame() spac << m_settings.m_EFBEmulateFormatChanges; spac << m_settings.m_SafeTextureCacheColorSamples; spac << m_settings.m_PerfQueriesEnable; + spac << m_settings.m_AlignmentExceptions; spac << m_settings.m_FPRF; spac << m_settings.m_AccurateNaNs; spac << m_settings.m_DisableICache;