mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-11 01:08:39 +12:00
rsx: Reset ZCULL statistics at the end of a frame
- Workaround for games that leak zpass/zstats. The information is useless anyway without a clear op so it should be fine.
This commit is contained in:
parent
198c84cabf
commit
eb140c52a4
1 changed files with 10 additions and 1 deletions
|
@ -2560,6 +2560,15 @@ namespace rsx
|
||||||
Emu.Pause();
|
Emu.Pause();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (zcull_ctrl->has_pending())
|
||||||
|
{
|
||||||
|
// NOTE: This is a workaround for buggy games.
|
||||||
|
// Some applications leave the zpass/stats gathering active but don't use the information.
|
||||||
|
// This can lead to the zcull unit using up all the memory queueing up operations that never get consumed.
|
||||||
|
// Seen in Diablo III and Yakuza 5
|
||||||
|
zcull_ctrl->clear(this, CELL_GCM_ZPASS_PIXEL_CNT | CELL_GCM_ZCULL_STATS);
|
||||||
|
}
|
||||||
|
|
||||||
// Save current state
|
// Save current state
|
||||||
m_queued_flip.stats = m_frame_stats;
|
m_queued_flip.stats = m_frame_stats;
|
||||||
m_queued_flip.push(buffer);
|
m_queued_flip.push(buffer);
|
||||||
|
@ -2930,7 +2939,7 @@ namespace rsx
|
||||||
|
|
||||||
void ZCULL_control::clear(class ::rsx::thread* ptimer, u32 type)
|
void ZCULL_control::clear(class ::rsx::thread* ptimer, u32 type)
|
||||||
{
|
{
|
||||||
if (type != CELL_GCM_ZPASS_PIXEL_CNT)
|
if (!(type & CELL_GCM_ZPASS_PIXEL_CNT))
|
||||||
{
|
{
|
||||||
// Other types do not generate queries at the moment
|
// Other types do not generate queries at the moment
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue