Bug 91193

Summary: [290x] Dota2 reborn ingame rendering breaks with git-af4b9c7
Product: Mesa Reporter: Sebastian Parborg <darkdefende>
Component: Drivers/Gallium/radeonsiAssignee: Default DRI bug account <dri-devel>
Status: RESOLVED FIXED QA Contact: Default DRI bug account <dri-devel>
Severity: normal    
Priority: medium CC: darkdefende
Version: git   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: radeonsi: Count TGSI_SEMANTIC_CLIPDIST again for the VS export count

Description Sebastian Parborg 2015-07-02 16:53:36 UTC
I've had some problems with Dota2 ingame rendering for a while now. The icons on the minimap flickers and some parts of the ground too. The ground only flickers if normal maps are turned on.

I have uploaded two videos on github to demonstrate the issue:
https://github.com/DarkDefender/dota2_reborn_issue

Here is the issue on the Dota2 reborn bugtracker:
https://github.com/ValveSoftware/Dota-2-Reborn/issues/150

It seems like this commit broke the ingame rendering:
http://cgit.freedesktop.org/mesa/mesa/commit/?id=af4b9c7c2e119d373f9684119b833a8b62cbb756

With the previous commit:
http://cgit.freedesktop.org/mesa/mesa/commit/?id=e4339bc9886a26d75b924ad045c3ddd003f802c3
it seems to render fine.
Comment 1 Sylvain BERTRAND 2015-07-03 00:42:04 UTC
Reverting those commits fixed the flickering on my tahiti xt.
Comment 2 Michel Dänzer 2015-07-03 00:56:05 UTC
Created attachment 116901 [details] [review]
radeonsi: Count TGSI_SEMANTIC_CLIPDIST again for the VS export count

Does this patch fix the problem?
Comment 3 Christoph Haag 2015-07-03 11:44:14 UTC
(In reply to Michel Dänzer from comment #2)
> Created attachment 116901 [details] [review] [review]
> radeonsi: Count TGSI_SEMANTIC_CLIPDIST again for the VS export count
> 
> Does this patch fix the problem?

As far as I can see, yes, removing only the TGSI_SEMANTIC_CLIPDIST case makes the corrupted texture flicker and the shadow flicker go away.
Comment 4 Sebastian Parborg 2015-07-05 10:46:46 UTC
Seems to solve it for me also.
I'm guessing that this is just a temporary workaround?
Comment 5 Michel Dänzer 2015-07-06 01:30:16 UTC
(In reply to Sebastian Parborg from comment #4)
> I'm guessing that this is just a temporary workaround?

No, I think it's the proper fix. TGSI_SEMANTIC_CLIPDIST values are also passed to the pixel shader as a varying, so they need to be counted here.

I'll submit the patch to the mesa-dev mailing list for review.
Comment 6 Michel Dänzer 2015-07-07 03:56:18 UTC
Commit: 248b26429f52d0f19949a083aa3e0aeebcbe2138
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=248b26429f52d0f19949a083aa3e0aeebcbe2138

Author: Michel Dänzer <michel.daenzer@amd.com>
Date:   Mon Jul  6 17:23:07 2015 +0900

radeonsi: Use param export count from si_llvm_export_vs in si_shader_vs

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.