mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-07 23:41:26 +12:00
PPU: minor improvement for LWARX/LDARX
Improve chances of loading actual data in memory.
This commit is contained in:
parent
f2d2a6b605
commit
2f329cf7b5
1 changed files with 7 additions and 3 deletions
|
@ -1197,14 +1197,18 @@ static T ppu_load_acquire_reservation(ppu_thread& ppu, u32 addr)
|
||||||
|
|
||||||
if (!ppu.use_full_rdata)
|
if (!ppu.use_full_rdata)
|
||||||
{
|
{
|
||||||
|
if (ppu.rtime & vm::rsrv_shared_mask)
|
||||||
|
{
|
||||||
|
// Let the ongoing operation some tiny time to complete
|
||||||
|
busy_wait(100);
|
||||||
|
ppu.rtime &= ~vm::rsrv_shared_mask;
|
||||||
|
}
|
||||||
|
|
||||||
if (data.load() != rdata)
|
if (data.load() != rdata)
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Clear some possible lock bits which are permitted
|
|
||||||
ppu.rtime &= -128;
|
|
||||||
|
|
||||||
// Store only 64 bits of reservation data
|
// Store only 64 bits of reservation data
|
||||||
std::memcpy(&ppu.rdata[addr & 0x78], &rdata, 8);
|
std::memcpy(&ppu.rdata[addr & 0x78], &rdata, 8);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue