mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-09 08:21:29 +12:00
ppu: improve vnmsubfp instruction
This commit is contained in:
parent
733efc6b0d
commit
2ed6e51d24
2 changed files with 2 additions and 2 deletions
|
@ -1363,7 +1363,7 @@ bool ppu_interpreter::VMULOUH(ppu_thread& ppu, ppu_opcode_t op)
|
||||||
|
|
||||||
bool ppu_interpreter::VNMSUBFP(ppu_thread& ppu, ppu_opcode_t op)
|
bool ppu_interpreter::VNMSUBFP(ppu_thread& ppu, ppu_opcode_t op)
|
||||||
{
|
{
|
||||||
ppu.vr[op.vd].vf = _mm_sub_ps(ppu.vr[op.vb].vf, _mm_mul_ps(ppu.vr[op.va].vf, ppu.vr[op.vc].vf));
|
ppu.vr[op.vd].vf = _mm_xor_ps(_mm_sub_ps(_mm_mul_ps(ppu.vr[op.va].vf, ppu.vr[op.vc].vf), ppu.vr[op.vb].vf), _mm_set1_ps(-0.0f));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1175,7 +1175,7 @@ void PPUTranslator::VMULOUH(ppu_opcode_t op)
|
||||||
void PPUTranslator::VNMSUBFP(ppu_opcode_t op)
|
void PPUTranslator::VNMSUBFP(ppu_opcode_t op)
|
||||||
{
|
{
|
||||||
const auto acb = GetVrs(VrType::vf, op.va, op.vc, op.vb);
|
const auto acb = GetVrs(VrType::vf, op.va, op.vc, op.vb);
|
||||||
SetVr(op.vd, m_ir->CreateFSub(acb[2], m_ir->CreateFMul(acb[0], acb[1])));
|
SetVr(op.vd, m_ir->CreateFNeg(m_ir->CreateFSub(m_ir->CreateFMul(acb[0], acb[1]), acb[2])));
|
||||||
}
|
}
|
||||||
|
|
||||||
void PPUTranslator::VNOR(ppu_opcode_t op)
|
void PPUTranslator::VNOR(ppu_opcode_t op)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue