From 3e50b0e3205e023c9f318d69fdfdaf4ff15947a3 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sat, 7 Apr 2018 22:18:42 -0400 Subject: [PATCH] PPCDebugInterface: Remove redundant HostRead_U32() call in Disassemble() We already read the necessary information with the HostRead_Instruction() call. Internally, it calls HostRead_U32() as well, so there's no difference in behavior. --- Source/Core/Core/Debugger/PPCDebugInterface.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Source/Core/Core/Debugger/PPCDebugInterface.cpp b/Source/Core/Core/Debugger/PPCDebugInterface.cpp index 42694a09fe..e202f2a536 100644 --- a/Source/Core/Core/Debugger/PPCDebugInterface.cpp +++ b/Source/Core/Core/Debugger/PPCDebugInterface.cpp @@ -28,11 +28,9 @@ std::string PPCDebugInterface::Disassemble(unsigned int address) return "(No RAM here)"; } - u32 op = PowerPC::HostRead_Instruction(address); + const u32 op = PowerPC::HostRead_Instruction(address); std::string disasm = GekkoDisassembler::Disassemble(op, address); - - UGeckoInstruction inst; - inst.hex = PowerPC::HostRead_U32(address); + const UGeckoInstruction inst{op}; if (inst.OPCD == 1) {