From 884130f95c1573b047bdce67aa4d168838a25737 Mon Sep 17 00:00:00 2001 From: "Admiral H. Curtiss" Date: Tue, 10 Jan 2023 06:55:12 +0100 Subject: [PATCH] HW/Memmap: Avoid ppcState global. --- Source/Core/Core/HW/Memmap.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Source/Core/Core/HW/Memmap.cpp b/Source/Core/Core/HW/Memmap.cpp index e0350712e6..f17cfd12b1 100644 --- a/Source/Core/Core/HW/Memmap.cpp +++ b/Source/Core/Core/HW/Memmap.cpp @@ -482,8 +482,9 @@ u8* MemoryManager::GetPointer(u32 address) const return m_exram + (address & GetExRamMask()); } - PanicAlertFmt("Unknown Pointer {:#010x} PC {:#010x} LR {:#010x}", address, PowerPC::ppcState.pc, - LR(PowerPC::ppcState)); + auto& ppc_state = Core::System::GetInstance().GetPPCState(); + PanicAlertFmt("Unknown Pointer {:#010x} PC {:#010x} LR {:#010x}", address, ppc_state.pc, + LR(ppc_state)); return nullptr; }