Shadow of Mordor beta has missing geometry with gl 4.3
https://bugs.freedesktop.org/show_bug.cgi?id=95198
Bug ID: 95198
Summary: Shadow of Mordor beta has missing geometry with gl 4.3
Product: Mesa
Version: git
Hardware: Other
OS: All
Status: NEW
Severity: normal
Priority: medium
Component: Drivers/Gallium/radeonsi
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
Created attachment 123332
--> https://bugs.freedesktop.org/attachment.cgi?id=123332&action=edit
screenshot.png
The public version of Shadow of Mordor worked fine for me, so I don't think this is a dupe of #92059.
However there's a beta (v1.1?) that supports compute shaders and GL 4.3. If I run it with MESA_GL_VERSION_OVERRIDE=4.3 MESA_GLSL_VERSION_OVERRIDE=430 and set texture quality to Medium, I get missing geometry as the attached picture.
I'm trying to apitrace it but unfortunately the error doesn't appear when running under apitrace.
Also, glretrace refuses to work with forced gl-versions?
I either get:
MESA_GL_VERSION_OVERRIDE=4.3 MESA_GLSL_VERSION_OVERRIDE=430 glretrace ShadowOfMordor.2.trace
error: context mismatch: expected OpenGL 1.0, but got OpenGL 4.3 core
Or:
glretrace ShadowOfMordor.2.trace
error: xlib: BadMatch (invalid parameter attributes)
error: xlib: BadMatch (invalid parameter attributes)
error: failed to create OpenGL 4.3 core context.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
Ernst Sj�strand <[email protected]> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]
--- Comment #1 from Ernst Sj�strand <[email protected]> ---
Card: Radeon Fury
OS: Ubuntu 16.04
Mesa: 11.3~git160426193800.912ed84
Kernel: From 4.7-wip up to MAINTAINERS: Remove unneded wildcard for the Radeon/AMDGPU drivers
LLVM: 3.9~svn267193-0~x~padoka0
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
Ernst Sj�strand <[email protected]> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #123332|text/plain |image/png
mime type| |Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #2 from Ernst Sj�strand <[email protected]> ---
I get very different behavior if I patch Mesa to report 4.3 support vs. MESA_GL_VERSION_OVERRIDE=4.3 MESA_GLSL_VERSION_OVERRIDE=430. Is that intended? There's no environment variable that behaves like if I did such a Mesa patch?
Short story, much fewer issues (or harder to repro?) when patching Mesa to report 4.3.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #3 from Nicolai H�hnle <[email protected]> ---
I'm not sure why that is, but I'd say it's good news. Perhaps you can provide an apitrace of the remaining problems?
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #4 from Ernst Sj�strand <[email protected]> --- Indeed!
So here's a trace that shows extreme "shinyness" on the benchmark's loading screen for a few frames just before the benchmark starts. I've seen this ingame also, but I wanted to keep the trace as small as possible:
https://www.dropbox.com/s/2vkesni8o4y03dp/ShadowOfMordor.trace?dl=0
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #5 from John <[email protected]> ---
I was going to create a new bug but I think my issue may be the same.
With llvm-svn up to revision 267861 everything works fine, but starting with revision 268162 I get the same issue as in Ersnt's screenshot.
My console prints many of these :
LLVM triggered Diagnostic Handler: LDS size exceeds device maximum LLVM failed to compile shader
radeonsi: can't create a shader
Card is 280x so a bit different.
I am on latest mesa-git, and linux 4.5 (patched to get computer shader). Downgrading llvm-svn fixes the issue right away.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #6 from Nicolai H�hnle <[email protected]> ---
Hi John, that precise LLVM revision doesn't exist (or rather, it's not a change in LLVM itself), and the commits around it don't look obviously related. Did you arrive there by a bisect?
You could help by providing the output when running with R600_DEBUG=ps,vs,tcs,tes,gs.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #7 from Bas Nieuwenhuizen <[email protected]> --- Nicolai, the direct cause is probably in r267922 ("AMDGPU: Emit error if too much LDS is used") which is between his good and bad revision and introduces the error.
If I run the non-beta locally I don't get any shader that uses more than 1024 bytes of LDS.
John, did you get this error using the shadow of mordor beta?
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #8 from John <[email protected]> --- Hi Nicolai,
Oh no, these are just 2 "versions" of the llvm-svn package I get from lcarlier's mesa-git repository. I assumed they matched the llvm revision I can see when browsing https://llvm.org/svn/llvm-project/cfe/trunk.
I can bisect if needed.
I'll attach the output you've asked for it.
Hi Bas,
I get the same issue whereas on the beta or the official build from steam.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
John <[email protected]> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]
--- Comment #9 from John <[email protected]> --- Created attachment 123504
--> https://bugs.freedesktop.org/attachment.cgi?id=123504&action=edit
R600_DEBUG=ps,vs,tcs,tes,gs steam's output.
I tried to clean up the log up to the start of the game and till the end, but it is still pretty big, and probably include more than needed.
I'd guess you may be able to pinpoint better by looking around "LLVM triggered Diagnostic Handler: LDS size exceeds device maximum".
Thank you!
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #10 from Nicolai H�hnle <[email protected]> --- Created attachment 123521
--> https://bugs.freedesktop.org/attachment.cgi?id=123521&action=edit
bandaid patch for SI
Hi John, please try the attached patch - it should help slightly.
Generally speaking, it looks like tesselation support is a bit of a mess :(
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #11 from John <[email protected]> --- Created attachment 123530
--> https://bugs.freedesktop.org/attachment.cgi?id=123530&action=edit
R600_DEBUG=ps,vs,tcs,tes,gs steam's output with Nicolai's patch
I have patched mesa and rebuilt it, but I don't see any difference. Here's the new log.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
Nicolai H�hnle <[email protected]> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #123521|0 |1
is obsolete| |
--- Comment #12 from Nicolai H�hnle <[email protected]> --- Created attachment 123543
--> https://bugs.freedesktop.org/attachment.cgi?id=123543&action=edit
bandaid patch for SI v2
Sorry, there was a stupid mistake in my proposed patch. This one should work :)
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #13 from John <[email protected]> ---
Hmmm, only the comments seem to have changed between the 2 patches, the code change is the same isn't it?
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #14 from John <[email protected]> ---
I tried to guess the typo and replaced patch_dw_size by lds_dwords in the code change, as patch_dw_size is not used past lds_dwords' declaration. So far it seems to work fine; I saw no visual issue and there is no error printed in the terminal either.
I'll be glad to test a proper solution when you find one as well. Are you going to submit this patch in the meantime or should I keep patching my daily mesa-git?
Thank you!
John
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
Nicolai H�hnle <[email protected]> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED--- Comment #15 from Nicolai H�hnle <[email protected]> --- The patch is now in Mesa git master.
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
https://bugs.freedesktop.org/show_bug.cgi?id=95198
--- Comment #16 from John <[email protected]> --- Cool, thank you!
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel