mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-23 03:02:53 +01:00
ppu-interpreter: improve fnmadd/fnmadds instructions (#5183)
* ppu-interpreter: improve fnmadd instruction * ppu-interpreter: improve fnmadds instruction
This commit is contained in:
parent
49e5212a8f
commit
cc846eb670
@ -4662,7 +4662,7 @@ bool ppu_interpreter::FNMSUBS(ppu_thread& ppu, ppu_opcode_t op)
|
||||
|
||||
bool ppu_interpreter::FNMADDS(ppu_thread& ppu, ppu_opcode_t op)
|
||||
{
|
||||
ppu.fpr[op.frd] = f32(-(ppu.fpr[op.fra] * ppu.fpr[op.frc]) - ppu.fpr[op.frb]);
|
||||
ppu.fpr[op.frd] = f32(-(ppu.fpr[op.fra] * ppu.fpr[op.frc] + ppu.fpr[op.frb]));
|
||||
if (UNLIKELY(op.rc)) fmt::throw_exception("%s: op.rc", __func__); //ppu_cr_set(ppu, 1, ppu.fpscr.fg, ppu.fpscr.fl, ppu.fpscr.fe, ppu.fpscr.fu);
|
||||
return true;
|
||||
}
|
||||
@ -4815,7 +4815,7 @@ bool ppu_interpreter::FNMSUB(ppu_thread& ppu, ppu_opcode_t op)
|
||||
|
||||
bool ppu_interpreter::FNMADD(ppu_thread& ppu, ppu_opcode_t op)
|
||||
{
|
||||
ppu.fpr[op.frd] = -(ppu.fpr[op.fra] * ppu.fpr[op.frc]) - ppu.fpr[op.frb];
|
||||
ppu.fpr[op.frd] = -(ppu.fpr[op.fra] * ppu.fpr[op.frc] + ppu.fpr[op.frb]);
|
||||
if (UNLIKELY(op.rc)) fmt::throw_exception("%s: op.rc", __func__); //ppu_cr_set(ppu, 1, ppu.fpscr.fg, ppu.fpscr.fl, ppu.fpscr.fe, ppu.fpscr.fu);
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user