diff --git a/UI/GameSettingsScreen.cpp b/UI/GameSettingsScreen.cpp index 8da29cf909..e747372492 100644 --- a/UI/GameSettingsScreen.cpp +++ b/UI/GameSettingsScreen.cpp @@ -434,9 +434,7 @@ void GameSettingsScreen::update(InputState &input) { g_Config.iFpsLimit = alternateSpeedTable[iAlternateSpeedPercent_]; if (g_Config.bShowDebugStats != showDebugStats_) { // This affects the jit. - if (MIPSComp::jit) { - MIPSComp::jit->ClearCache(); - } + NativeMessageReceived("clear jit", ""); g_Config.bShowDebugStats = showDebugStats_; } } diff --git a/UI/MiscScreens.cpp b/UI/MiscScreens.cpp index 06ff21594e..8bba528671 100644 --- a/UI/MiscScreens.cpp +++ b/UI/MiscScreens.cpp @@ -101,7 +101,7 @@ void DrawBackground(float alpha) { void HandleCommonMessages(const char *message, const char *value, ScreenManager *manager) { if (!strcmp(message, "clear jit")) { - if (MIPSComp::jit) { + if (MIPSComp::jit && PSP_IsInited()) { MIPSComp::jit->ClearCache(); } }