mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-04-16 05:42:55 +00:00
Merge pull request #4945 from lioncash/jit-global
DolphinWX: Eliminate direct usage of the JIT global
This commit is contained in:
commit
51b654ed00
@ -24,10 +24,11 @@
|
|||||||
#include "Common/SymbolDB.h"
|
#include "Common/SymbolDB.h"
|
||||||
|
|
||||||
#include "Core/Boot/Boot.h"
|
#include "Core/Boot/Boot.h"
|
||||||
|
#include "Core/ConfigManager.h"
|
||||||
#include "Core/Core.h"
|
#include "Core/Core.h"
|
||||||
#include "Core/HLE/HLE.h"
|
#include "Core/HLE/HLE.h"
|
||||||
#include "Core/Host.h"
|
#include "Core/Host.h"
|
||||||
#include "Core/PowerPC/JitCommon/JitBase.h"
|
#include "Core/PowerPC/JitInterface.h"
|
||||||
#include "Core/PowerPC/PPCAnalyst.h"
|
#include "Core/PowerPC/PPCAnalyst.h"
|
||||||
#include "Core/PowerPC/PPCSymbolDB.h"
|
#include "Core/PowerPC/PPCSymbolDB.h"
|
||||||
#include "Core/PowerPC/PowerPC.h"
|
#include "Core/PowerPC/PowerPC.h"
|
||||||
@ -124,8 +125,7 @@ void CCodeWindow::OnProfilerMenu(wxCommandEvent& event)
|
|||||||
{
|
{
|
||||||
case IDM_PROFILE_BLOCKS:
|
case IDM_PROFILE_BLOCKS:
|
||||||
Core::SetState(Core::State::Paused);
|
Core::SetState(Core::State::Paused);
|
||||||
if (g_jit != nullptr)
|
JitInterface::ClearCache();
|
||||||
g_jit->ClearCache();
|
|
||||||
Profiler::g_ProfileBlocks = GetParentMenuBar()->IsChecked(IDM_PROFILE_BLOCKS);
|
Profiler::g_ProfileBlocks = GetParentMenuBar()->IsChecked(IDM_PROFILE_BLOCKS);
|
||||||
Core::SetState(Core::State::Running);
|
Core::SetState(Core::State::Running);
|
||||||
break;
|
break;
|
||||||
@ -135,25 +135,21 @@ void CCodeWindow::OnProfilerMenu(wxCommandEvent& event)
|
|||||||
|
|
||||||
if (Core::GetState() == Core::State::Paused && PowerPC::GetMode() == PowerPC::CoreMode::JIT)
|
if (Core::GetState() == Core::State::Paused && PowerPC::GetMode() == PowerPC::CoreMode::JIT)
|
||||||
{
|
{
|
||||||
if (g_jit != nullptr)
|
std::string filename = File::GetUserPath(D_DUMP_IDX) + "Debug/profiler.txt";
|
||||||
{
|
File::CreateFullPath(filename);
|
||||||
std::string filename = File::GetUserPath(D_DUMP_IDX) + "Debug/profiler.txt";
|
Profiler::WriteProfileResults(filename);
|
||||||
File::CreateFullPath(filename);
|
|
||||||
Profiler::WriteProfileResults(filename);
|
|
||||||
|
|
||||||
wxFileType* filetype = nullptr;
|
wxFileType* filetype = nullptr;
|
||||||
if (!(filetype = wxTheMimeTypesManager->GetFileTypeFromExtension("txt")))
|
if (!(filetype = wxTheMimeTypesManager->GetFileTypeFromExtension("txt")))
|
||||||
{
|
{
|
||||||
// From extension failed, trying with MIME type now
|
// From extension failed, trying with MIME type now
|
||||||
if (!(filetype = wxTheMimeTypesManager->GetFileTypeFromMimeType("text/plain")))
|
if (!(filetype = wxTheMimeTypesManager->GetFileTypeFromMimeType("text/plain")))
|
||||||
// MIME type failed, aborting mission
|
// MIME type failed, aborting mission
|
||||||
break;
|
break;
|
||||||
}
|
|
||||||
wxString OpenCommand;
|
|
||||||
OpenCommand = filetype->GetOpenCommand(StrToWxStr(filename));
|
|
||||||
if (!OpenCommand.IsEmpty())
|
|
||||||
wxExecute(OpenCommand, wxEXEC_SYNC);
|
|
||||||
}
|
}
|
||||||
|
wxString OpenCommand = filetype->GetOpenCommand(StrToWxStr(filename));
|
||||||
|
if (!OpenCommand.IsEmpty())
|
||||||
|
wxExecute(OpenCommand, wxEXEC_SYNC);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user