diff --git a/rpcs3/Emu/Cell/SPURecompiler.cpp b/rpcs3/Emu/Cell/SPURecompiler.cpp index 355ae0eb6f..8e9400e02d 100644 --- a/rpcs3/Emu/Cell/SPURecompiler.cpp +++ b/rpcs3/Emu/Cell/SPURecompiler.cpp @@ -6255,19 +6255,19 @@ public: } template - static auto mpyh(TA&& a, TB&& b) + auto mpyh(TA&& a, TB&& b) { - return (std::forward(a) >> 16) * (std::forward(b) << 16); + return bitcast(bitcast((std::forward(a) >> 16)) * bitcast(std::forward(b))) << 16; } template - static auto mpyu(TA&& a, TB&& b) + auto mpyu(TA&& a, TB&& b) { return (std::forward(a) << 16 >> 16) * (std::forward(b) << 16 >> 16); } template - static auto fm(TA&& a, TB&& b) + auto fm(TA&& a, TB&& b) { return (std::forward(a)) * (std::forward(b)); }