Created attachment 101697 [details]
Experimental patch that appears to work around flickering shadows issue.
Shadows are intermittently disappearing during trace playback. The effect is random (run to run), but consistent (within a run). We’ve triaged to the point we believe it has to do with uniform buffer update timing or caching. Inserting a batch buffer flush only for glBufferSubData with GL_UNIFORM_BUFFER circumvents the issue, but we do not considered it a fix. It does hack around it with no performance loss. More research is needed to find real root cause.
I found that adding BRW_NEW_FS_PROG_DATA to gen7_sf_clip_viewport fixes the flickering shadows. But I could not find any documented reason that would
explain why the additional _3DSTATE_VIEWPORT_STATE_POINTERS_SF_CL commands should
This issue is cropping up in the newly released Dota 2 Reborn Beta. Someone is reporting seeing the bug here:
I am seeing it on Intel Iris Pro both in mesa 10.3.2 and mesa 10.5.8 on Ubuntu 14.10 x86_64 Intel(R) Core(TM) i7-4770R CPU @ 3.20GHz
I can't fully rule out an application bug at this point (I'm a developer on Dota 2 Reborn), but I'm not seeing the behavior on any other GPU/driver.
Created attachment 116847 [details] [review]
[PATCH] i965: allocate at least 1 BLEND_STATE element
I found the root cause for this.
_3DSTATE_BLEND_STATE_POINTERS was pointing to random state data.
That sometimes used alpha testing that suppressed rendering to depth buffer.
Previous workarounds were just increasing the chance that the data was harmless.
They created more state data that was workable as BLEND_STATE.
on Feb 28, 2017 at 05:28:06.
(provided by the Example extension).