From bc21013d217d7c11903a5651667603efa941e7b1 Mon Sep 17 00:00:00 2001 From: Fabio Arnold Date: Wed, 18 Mar 2026 23:06:39 +0100 Subject: [PATCH] PPC: zero sign extend sint32 only --- src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp index 4b53ecfd..8b3c358c 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp @@ -435,7 +435,7 @@ static void PPCInterpreter_MULHWU_(PPCInterpreter_t* hCPU, uint32 opcode) static void PPCInterpreter_MULLW(PPCInterpreter_t* hCPU, uint32 opcode) { PPC_OPC_TEMPL3_XO(); - sint64 result = (sint64)hCPU->gpr[rA] * (sint64)hCPU->gpr[rB]; + sint64 result = (sint64)(sint32)hCPU->gpr[rA] * (sint64)(sint32)hCPU->gpr[rB]; hCPU->gpr[rD] = (uint32)result; if (opHasRC()) ppc_update_cr0(hCPU, hCPU->gpr[rD]);