mirror of https://github.com/PCSX2/pcsx2.git
VU-JIT: Backup non cached VI before writing to it when load != write
This commit is contained in:
parent
0e0d7a5441
commit
535ad110e3
|
@ -1025,7 +1025,17 @@ public:
|
||||||
// allocate a new register for writing to
|
// allocate a new register for writing to
|
||||||
int x = findFreeGPR(viWriteReg);
|
int x = findFreeGPR(viWriteReg);
|
||||||
const xRegister32& gprX = xRegister32::GetInstance(x);
|
const xRegister32& gprX = xRegister32::GetInstance(x);
|
||||||
|
|
||||||
writeBackReg(gprX, true);
|
writeBackReg(gprX, true);
|
||||||
|
|
||||||
|
// writeReg not cached, needs backing up
|
||||||
|
if (backup && gprMap[x].VIreg != viWriteReg)
|
||||||
|
{
|
||||||
|
xMOVZX(gprX, ptr16[&getVI(viWriteReg)]);
|
||||||
|
writeVIBackup(gprX);
|
||||||
|
backup = false;
|
||||||
|
}
|
||||||
|
|
||||||
if (zext_if_dirty)
|
if (zext_if_dirty)
|
||||||
xMOVZX(gprX, xRegister16(i));
|
xMOVZX(gprX, xRegister16(i));
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue