VERY experimental Nintendo Switch 2 emulator
C++
armemu: Fix SMUAD, SMUSD, and SMLAD
Lioncashd5bcddb77c99
diff --git a/src/core/arm/interpreter/armemu.cpp b/src/core/arm/interpreter/armemu.cppindex 967506f459..e4159ceb0a 100644--- a/src/core/arm/interpreter/armemu.cpp+++ b/src/core/arm/interpreter/armemu.cpp@@ -6243,16 +6243,16 @@ L_stm_s_takeabort:// SMUADif ((instr & 0xf0d0) == 0xf010) {- state->Reg[rd_idx] = (rn_lo * rn_hi) + (rm_lo * rm_hi);+ state->Reg[rd_idx] = (rn_lo * rm_lo) + (rn_hi * rm_hi);}// SMUSDelse if ((instr & 0xf0d0) == 0xf050) {- state->Reg[rd_idx] = (rn_lo * rn_hi) - (rm_lo * rm_hi);+ state->Reg[rd_idx] = (rn_lo * rm_lo) - (rn_hi * rm_hi);}// SMLADelse {const u8 ra_idx = BITS(12, 15);- state->Reg[rd_idx] = (rn_lo * rn_hi) + (rm_lo * rm_hi) + (s32)state->Reg[ra_idx];+ state->Reg[rd_idx] = (rn_lo * rm_lo) + (rn_hi * rm_hi) + (s32)state->Reg[ra_idx];}return 1;} else {