Add a fastmem option for enabling and disabling fastmem at runtime.
This commit is contained in:
parent
bf5a046b82
commit
47f1505499
|
@ -201,6 +201,7 @@ void SConfig::SaveSettings()
|
||||||
// Core
|
// Core
|
||||||
ini.Set("Core", "HLE_BS2", m_LocalCoreStartupParameter.bHLE_BS2);
|
ini.Set("Core", "HLE_BS2", m_LocalCoreStartupParameter.bHLE_BS2);
|
||||||
ini.Set("Core", "CPUCore", m_LocalCoreStartupParameter.iCPUCore);
|
ini.Set("Core", "CPUCore", m_LocalCoreStartupParameter.iCPUCore);
|
||||||
|
ini.Set("Core", "Fastmem", m_LocalCoreStartupParameter.bFastmem);
|
||||||
ini.Set("Core", "CPUThread", m_LocalCoreStartupParameter.bCPUThread);
|
ini.Set("Core", "CPUThread", m_LocalCoreStartupParameter.bCPUThread);
|
||||||
ini.Set("Core", "DSPThread", m_LocalCoreStartupParameter.bDSPThread);
|
ini.Set("Core", "DSPThread", m_LocalCoreStartupParameter.bDSPThread);
|
||||||
ini.Set("Core", "DSPHLE", m_LocalCoreStartupParameter.bDSPHLE);
|
ini.Set("Core", "DSPHLE", m_LocalCoreStartupParameter.bDSPHLE);
|
||||||
|
@ -354,6 +355,7 @@ void SConfig::LoadSettings()
|
||||||
#else
|
#else
|
||||||
ini.Get("Core", "CPUCore", &m_LocalCoreStartupParameter.iCPUCore, 1);
|
ini.Get("Core", "CPUCore", &m_LocalCoreStartupParameter.iCPUCore, 1);
|
||||||
#endif
|
#endif
|
||||||
|
ini.Get("Core", "Fastmem", &m_LocalCoreStartupParameter.bFastmem, true);
|
||||||
ini.Get("Core", "DSPThread", &m_LocalCoreStartupParameter.bDSPThread, false);
|
ini.Get("Core", "DSPThread", &m_LocalCoreStartupParameter.bDSPThread, false);
|
||||||
ini.Get("Core", "DSPHLE", &m_LocalCoreStartupParameter.bDSPHLE, true);
|
ini.Get("Core", "DSPHLE", &m_LocalCoreStartupParameter.bDSPHLE, true);
|
||||||
ini.Get("Core", "CPUThread", &m_LocalCoreStartupParameter.bCPUThread, true);
|
ini.Get("Core", "CPUThread", &m_LocalCoreStartupParameter.bCPUThread, true);
|
||||||
|
|
|
@ -299,6 +299,7 @@ void CpuThread()
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(_M_X64) || _M_ARM
|
#if defined(_M_X64) || _M_ARM
|
||||||
|
if (_CoreParameter.bFastmem)
|
||||||
EMM::InstallExceptionHandler(); // Let's run under memory watch
|
EMM::InstallExceptionHandler(); // Let's run under memory watch
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -60,6 +60,7 @@ void SCoreStartupParameter::LoadDefaults()
|
||||||
bRunCompareServer = false;
|
bRunCompareServer = false;
|
||||||
bDSPHLE = true;
|
bDSPHLE = true;
|
||||||
bDSPThread = true;
|
bDSPThread = true;
|
||||||
|
bFastmem = true;
|
||||||
bEnableFPRF = false;
|
bEnableFPRF = false;
|
||||||
bMMU = false;
|
bMMU = false;
|
||||||
bDCBZOFF = false;
|
bDCBZOFF = false;
|
||||||
|
|
|
@ -82,6 +82,7 @@ struct SCoreStartupParameter
|
||||||
bool bJITILTimeProfiling;
|
bool bJITILTimeProfiling;
|
||||||
bool bJITILOutputIR;
|
bool bJITILOutputIR;
|
||||||
|
|
||||||
|
bool bFastmem;
|
||||||
bool bEnableFPRF;
|
bool bEnableFPRF;
|
||||||
|
|
||||||
bool bCPUThread;
|
bool bCPUThread;
|
||||||
|
|
|
@ -111,9 +111,9 @@ void EmuCodeBlock::SafeLoadToEAX(const Gen::OpArg & opAddress, int accessSize, s
|
||||||
{
|
{
|
||||||
#if defined(_M_X64)
|
#if defined(_M_X64)
|
||||||
#ifdef ENABLE_MEM_CHECK
|
#ifdef ENABLE_MEM_CHECK
|
||||||
if (!Core::g_CoreStartupParameter.bMMU && !Core::g_CoreStartupParameter.bEnableDebugging)
|
if (!Core::g_CoreStartupParameter.bMMU && !Core::g_CoreStartupParameter.bEnableDebugging && Core::g_CoreStartupParameter.bFastmem)
|
||||||
#else
|
#else
|
||||||
if (!Core::g_CoreStartupParameter.bMMU)
|
if (!Core::g_CoreStartupParameter.bMMU && Core::g_CoreStartupParameter.bFastmem)
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
UnsafeLoadToEAX(opAddress, accessSize, offset, signExtend);
|
UnsafeLoadToEAX(opAddress, accessSize, offset, signExtend);
|
||||||
|
|
Loading…
Reference in New Issue