parent
8686536d7d
commit
d04e67be3d
|
@ -14,6 +14,7 @@ enum class BooleanSetting(
|
|||
MAIN_SKIP_IPL(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "SkipIPL", true),
|
||||
MAIN_DSP_HLE(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "DSPHLE", true),
|
||||
MAIN_FASTMEM(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "Fastmem", true),
|
||||
MAIN_FASTMEM_ARENA(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "FastmemArena", true),
|
||||
MAIN_CPU_THREAD(Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "CPUThread", true),
|
||||
MAIN_SYNC_ON_SKIP_IDLE(
|
||||
Settings.FILE_DOLPHIN,
|
||||
|
@ -897,6 +898,7 @@ enum class BooleanSetting(
|
|||
companion object {
|
||||
private val NOT_RUNTIME_EDITABLE_ARRAY = arrayOf(
|
||||
MAIN_DSP_HLE,
|
||||
MAIN_FASTMEM_ARENA,
|
||||
MAIN_CPU_THREAD,
|
||||
MAIN_ENABLE_CHEATS,
|
||||
MAIN_OVERRIDE_REGION_SETTINGS,
|
||||
|
|
|
@ -1941,6 +1941,14 @@ class SettingsFragmentPresenter(
|
|||
0
|
||||
)
|
||||
)
|
||||
sl.add(
|
||||
InvertedSwitchSetting(
|
||||
context,
|
||||
BooleanSetting.MAIN_FASTMEM_ARENA,
|
||||
R.string.debug_fastmem_arena,
|
||||
0
|
||||
)
|
||||
)
|
||||
|
||||
sl.add(HeaderSetting(context, R.string.debug_jit_header, 0))
|
||||
sl.add(
|
||||
|
|
|
@ -399,6 +399,7 @@
|
|||
<string name="debug_submenu">Debug</string>
|
||||
<string name="debug_warning">Warning: Debug settings will slow emulation</string>
|
||||
<string name="debug_fastmem">Disable Fastmem</string>
|
||||
<string name="debug_fastmem_arena">Disable Fastmem Arena</string>
|
||||
<string name="debug_jit_header">Jit</string>
|
||||
<string name="debug_jitoff">Jit Disabled</string>
|
||||
<string name="debug_jitloadstoreoff">Jit Load Store Disabled</string>
|
||||
|
|
|
@ -38,6 +38,7 @@ const Info<PowerPC::CPUCore> MAIN_CPU_CORE{{System::Main, "Core", "CPUCore"},
|
|||
PowerPC::DefaultCPUCore()};
|
||||
const Info<bool> MAIN_JIT_FOLLOW_BRANCH{{System::Main, "Core", "JITFollowBranch"}, true};
|
||||
const Info<bool> MAIN_FASTMEM{{System::Main, "Core", "Fastmem"}, true};
|
||||
const Info<bool> MAIN_FASTMEM_ARENA{{System::Main, "Core", "FastmemArena"}, true};
|
||||
const Info<bool> MAIN_ACCURATE_CPU_CACHE{{System::Main, "Core", "AccurateCPUCache"}, false};
|
||||
const Info<bool> MAIN_DSP_HLE{{System::Main, "Core", "DSPHLE"}, true};
|
||||
const Info<int> MAIN_MAX_FALLBACK{{System::Main, "Core", "MaxFallback"}, 100};
|
||||
|
|
|
@ -56,6 +56,7 @@ extern const Info<bool> MAIN_SKIP_IPL;
|
|||
extern const Info<PowerPC::CPUCore> MAIN_CPU_CORE;
|
||||
extern const Info<bool> MAIN_JIT_FOLLOW_BRANCH;
|
||||
extern const Info<bool> MAIN_FASTMEM;
|
||||
extern const Info<bool> MAIN_FASTMEM_ARENA;
|
||||
extern const Info<bool> MAIN_ACCURATE_CPU_CACHE;
|
||||
// Should really be in the DSP section, but we're kind of stuck with bad decisions made in the past.
|
||||
extern const Info<bool> MAIN_DSP_HLE;
|
||||
|
|
|
@ -251,8 +251,7 @@ bool Jit64::BackPatch(SContext* ctx)
|
|||
|
||||
void Jit64::Init()
|
||||
{
|
||||
auto& memory = m_system.GetMemory();
|
||||
jo.fastmem_arena = memory.InitFastmemArena();
|
||||
InitFastmemArena();
|
||||
|
||||
RefreshConfig();
|
||||
|
||||
|
|
|
@ -47,8 +47,7 @@ JitArm64::~JitArm64() = default;
|
|||
|
||||
void JitArm64::Init()
|
||||
{
|
||||
auto& memory = m_system.GetMemory();
|
||||
jo.fastmem_arena = memory.InitFastmemArena();
|
||||
InitFastmemArena();
|
||||
|
||||
RefreshConfig();
|
||||
|
||||
|
|
|
@ -140,6 +140,12 @@ void JitBase::RefreshConfig()
|
|||
jo.div_by_zero_exceptions = m_enable_div_by_zero_exceptions;
|
||||
}
|
||||
|
||||
void JitBase::InitFastmemArena()
|
||||
{
|
||||
auto& memory = m_system.GetMemory();
|
||||
jo.fastmem_arena = Config::Get(Config::MAIN_FASTMEM_ARENA) && memory.InitFastmemArena();
|
||||
}
|
||||
|
||||
void JitBase::InitBLROptimization()
|
||||
{
|
||||
m_enable_blr_optimization =
|
||||
|
|
|
@ -166,6 +166,8 @@ protected:
|
|||
bool DoesConfigNeedRefresh();
|
||||
void RefreshConfig();
|
||||
|
||||
void InitFastmemArena();
|
||||
|
||||
void InitBLROptimization();
|
||||
void ProtectStack();
|
||||
void UnprotectStack();
|
||||
|
|
|
@ -139,6 +139,7 @@ void MenuBar::OnEmulationStateChanged(Core::State state)
|
|||
m_jit_interpreter_core->setEnabled(running);
|
||||
m_jit_block_linking->setEnabled(!running);
|
||||
m_jit_disable_cache->setEnabled(!running);
|
||||
m_jit_disable_fastmem_arena->setEnabled(!running);
|
||||
m_jit_clear_cache->setEnabled(running);
|
||||
m_jit_log_coverage->setEnabled(!running);
|
||||
m_jit_search_instruction->setEnabled(running);
|
||||
|
@ -847,6 +848,12 @@ void MenuBar::AddJITMenu()
|
|||
connect(m_jit_disable_fastmem, &QAction::toggled,
|
||||
[](bool enabled) { Config::SetBaseOrCurrent(Config::MAIN_FASTMEM, !enabled); });
|
||||
|
||||
m_jit_disable_fastmem_arena = m_jit->addAction(tr("Disable Fastmem Arena"));
|
||||
m_jit_disable_fastmem_arena->setCheckable(true);
|
||||
m_jit_disable_fastmem_arena->setChecked(!Config::Get(Config::MAIN_FASTMEM_ARENA));
|
||||
connect(m_jit_disable_fastmem_arena, &QAction::toggled,
|
||||
[](bool enabled) { Config::SetBaseOrCurrent(Config::MAIN_FASTMEM_ARENA, !enabled); });
|
||||
|
||||
m_jit_clear_cache = m_jit->addAction(tr("Clear Cache"), this, &MenuBar::ClearCache);
|
||||
|
||||
m_jit->addSeparator();
|
||||
|
|
|
@ -264,6 +264,7 @@ private:
|
|||
QAction* m_jit_block_linking;
|
||||
QAction* m_jit_disable_cache;
|
||||
QAction* m_jit_disable_fastmem;
|
||||
QAction* m_jit_disable_fastmem_arena;
|
||||
QAction* m_jit_clear_cache;
|
||||
QAction* m_jit_log_coverage;
|
||||
QAction* m_jit_search_instruction;
|
||||
|
|
Loading…
Reference in New Issue