From: bugzilla-daemon@freedesktop.org
To: dri-devel@lists.freedesktop.org
Subject: [Bug 99780] Flickering artifacts in radeonsi driver with divergent texture reads.
Date: Sun, 12 Feb 2017 15:34:55 +0000 [thread overview]
Message-ID: <bug-99780-502@http.bugs.freedesktop.org/> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 4070 bytes --]
https://bugs.freedesktop.org/show_bug.cgi?id=99780
Bug ID: 99780
Summary: Flickering artifacts in radeonsi driver with divergent
texture reads.
Product: Mesa
Version: unspecified
Hardware: x86-64 (AMD64)
OS: Linux (All)
Status: NEW
Severity: normal
Priority: medium
Component: Drivers/Gallium/radeonsi
Assignee: dri-devel@lists.freedesktop.org
Reporter: dark_sylinc@yahoo.com.ar
QA Contact: dri-devel@lists.freedesktop.org
Created attachment 129530
--> https://bugs.freedesktop.org/attachment.cgi?id=129530&action=edit
Sample repro
I'm an Ogre3D developer.
We noticed after updating to LLVM 4.0 that there were visual glitches:
http://imgur.com/43tIuI6
http://imgur.com/iBhxoBj
(this glitches tend to flicker over time *even if everything is stationary*)
This bug is *NOT* present if using LLVM 3.9.1
This bug happens with radeon open source drivers. Using llvmpipe works as
intended.
I tried to reproduce this bug in a clean environment but failed. So instead I
stripped down as much as possible to a minimal repro sample out of our code;
which I am attaching.
We noticed that this flicker happens alongside the difference between the PSSM
splits, but not always:
http://imgur.com/130B4mE
We added a tint to differentiate the splits. But as you can see there are a few
artifacts that happens within one tint; though the vast majority of the
artifacts happens alongside the line.
A PSSM split in shader code means this:
uniform sampler2DShadow texShadowMap[2];
float fShadow = 1.0;
vec3 tint = vec3( 1, 1, 1 );
if( inPs.depth <= pass.pssmSplitPoints0 )
{
fShadow = getShadow( texShadowMap[0], inPs.posL0, vec4( 0.000488281,
0.000488281, 1, 1 ) );
tint = vec3( 0.0, 0, 1 );
}
else if( inPs.depth <= pass.pssmSplitPoints1 )
{
fShadow = getShadow( texShadowMap[1], inPs.posL1, vec4( 0.000976562,
0.000976562, 1, 1 ) );
tint = vec3(0.0, 1.0, 0.0 );
}
Everything from inPs comes from the vertex shader.
After stripping down as much as possible, our getShadow declaration is this:
float getShadow( sampler2DShadow shadowMap, vec4 psPosLN, vec4 invShadowMapSize
)
{
float fDepth = psPosLN.z;
vec2 uv = psPosLN.xy / psPosLN.w;
float retVal = 0;
vec2 fW;
vec4 c;
retVal += texture( shadowMap, vec3( uv, fDepth ) ).r;
return retVal;
}
I've seen a similar artifact before in the Windows AMD drivers back when I was
experimenting with bindless textures and I purposedly managed to mix textures
from divergent branches into the same wavefront. Not sure if that's what's
happening here though.
Just run launchapp.sh; select OpenGL renderer, and click accept. It will launch
the sample.
NOTE: If when running the sample you encounter this problem:
Created GL 4.3 context
libGL error: failed to create drawable
libGL error: failed to create drawable
X Error of failed request: 0
Major opcode of failed request: 156 (GLX)
Minor opcode of failed request: 26 (X_GLXMakeContextCurrent)
Serial number of failed request: 28
Current serial number in output stream: 28
The just run it again. I do not know why this happens, it happens rarely (like
1 in 10 runs) and I haven't yet been able to determine why. It sounds like a
race condition inside Mesa (because the bug won't manifest while debugging
where loading is significantly slowed down loading all symbols), but I don't
have enough evidence to back this up, and it's not the reason of this bug
ticket.
If you have more issues running the sample let me know, I can provide
assistance. This sample needs SDL2 to be installed in your system.
I'm using AMD Radeon HD 7770 1GB
Ubuntu 16.10
Mesa git 5bc222ebafddd14f2329f5096287b51d798a6431
LLVM 4.0 SVN 293947
Kernel 4.8.0-37-generic
--
You are receiving this mail because:
You are the assignee for the bug.
[-- Attachment #1.2: Type: text/html, Size: 5682 bytes --]
[-- Attachment #2: Type: text/plain, Size: 160 bytes --]
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next reply other threads:[~2017-02-12 15:34 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-12 15:34 bugzilla-daemon [this message]
2017-02-12 15:38 ` [Bug 99780] Flickering artifacts in radeonsi driver with divergent texture reads bugzilla-daemon
2017-02-12 15:39 ` bugzilla-daemon
2017-02-12 16:19 ` bugzilla-daemon
2017-02-12 16:20 ` bugzilla-daemon
2017-02-12 16:30 ` bugzilla-daemon
2017-02-12 16:31 ` bugzilla-daemon
2017-02-12 17:34 ` bugzilla-daemon
2017-02-12 17:54 ` bugzilla-daemon
2017-02-12 23:42 ` bugzilla-daemon
2017-02-15 15:21 ` bugzilla-daemon
2017-02-16 16:24 ` bugzilla-daemon
2017-02-16 18:47 ` bugzilla-daemon
2017-03-15 13:46 ` bugzilla-daemon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-99780-502@http.bugs.freedesktop.org/ \
--to=bugzilla-daemon@freedesktop.org \
--cc=dri-devel@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.