Autodetect number of threads (remove setting). Fix some bugs.

This commit is contained in:
Henrik Rydgård committed 2021-06-12 21:06:59 +02:00
1 parent 03c79ae055
commit 0fa27ff9d7
14 files changed
+112 -40

No files matched your search

-7
View File
@@ -423,12 +423,6 @@ std::string CreateRandMAC() {
return randStream.str();
}
static int DefaultNumWorkers() {
// Let's cap the global thread pool at 16 threads. Nothing we do really should have much
// use for more...
return std::min(16, cpu_info.num_cores);
}
static int DefaultCpuCore() {
#if PPSSPP_ARCH(ARM) || PPSSPP_ARCH(ARM64) || PPSSPP_ARCH(X86) || PPSSPP_ARCH(AMD64)
return (int)CPUCore::JIT;
@@ -473,7 +467,6 @@ static ConfigSetting generalSettings[] = {
ConfigSetting("DiscordPresence", &g_Config.bDiscordPresence, true, true, false), // Or maybe it makes sense to have it per-game? Race conditions abound...
ConfigSetting("UISound", &g_Config.bUISound, false, true, false),
ReportedConfigSetting("NumWorkerThreads", &g_Config.iNumWorkerThreads, &DefaultNumWorkers, true, true),
ConfigSetting("AutoLoadSaveState", &g_Config.iAutoLoadSaveState, 0, true, true),
ReportedConfigSetting("EnableCheats", &g_Config.bEnableCheats, false, true, true),
ConfigSetting("CwCheatRefreshRate", &g_Config.iCwCheatRefreshRate, 77, true, true),