From mboxrd@z Thu Jan 1 00:00:00 1970 From: bugzilla-daemon@freedesktop.org Subject: [Bug 93594] Flickering Shadows in The Talos Principle Date: Thu, 18 Feb 2016 15:25:02 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0179044483==" Return-path: Received: from culpepper.freedesktop.org (culpepper.freedesktop.org [IPv6:2610:10:20:722:a800:ff:fe98:4b55]) by gabe.freedesktop.org (Postfix) with ESMTP id D02E76EC45 for ; Thu, 18 Feb 2016 15:25:05 +0000 (UTC) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============0179044483== Content-Type: multipart/alternative; boundary="14558091051.CEB3C0.9647"; charset="UTF-8" --14558091051.CEB3C0.9647 Date: Thu, 18 Feb 2016 15:25:05 +0000 MIME-Version: 1.0 Content-Type: text/plain https://bugs.freedesktop.org/show_bug.cgi?id=93594 --- Comment #16 from Nicolai Hähnle --- Interesting information about D3D10, thank you. The GLSL 4.50 spec says: "The discard keyword is only allowed within fragment shaders. It can be used within a fragment shader to abandon the operation on the current fragment. This keyword causes the fragment to be discarded and no updates to any buffers will occur. Control flow exits the shader, and subsequent implicit or explicit derivatives are undefined when this exit is non-uniform." One annoying aspect of this language is that one can reasonably read it as non-uniformity only being relevant for non-helper fragments. If a pixel quad is partial covered by the original primitive, and discard is used in a way that keeps the covered pixels but discard the helper ones, should derivatives be defined or not? As Michel said, I am indeed currently working on a patch changing exec mask behavior in LLVM for stores and atomics in pixel shaders. While what I have so far does not fix this bug yet, it already requires switching back and forth between WQM and non-WQM/"exact" modes. Extending this to keep full quads alive after KILL_IF should not add much more overhead. -- You are receiving this mail because: You are the assignee for the bug. --14558091051.CEB3C0.9647 Date: Thu, 18 Feb 2016 15:25:05 +0000 MIME-Version: 1.0 Content-Type: text/html

Comment # 16 on bug 93594 from
Interesting information about D3D10, thank you.

The GLSL 4.50 spec says:

"The discard keyword is only allowed within fragment shaders. It can be used
within a fragment shader to abandon the operation on the current fragment. This
keyword causes the fragment to be discarded and no updates to any buffers will
occur. Control flow exits the shader, and subsequent implicit or explicit
derivatives are undefined when this exit is non-uniform."

One annoying aspect of this language is that one can reasonably read it as
non-uniformity only being relevant for non-helper fragments. If a pixel quad is
partial covered by the original primitive, and discard is used in a way that
keeps the covered pixels but discard the helper ones, should derivatives be
defined or not?

As Michel said, I am indeed currently working on a patch changing exec mask
behavior in LLVM for stores and atomics in pixel shaders. While what I have so
far does not fix this bug yet, it already requires switching back and forth
between WQM and non-WQM/"exact" modes. Extending this to keep full quads alive
after KILL_IF should not add much more overhead.


You are receiving this mail because:
  • You are the assignee for the bug.
--14558091051.CEB3C0.9647-- --===============0179044483== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KZHJpLWRldmVs IG1haWxpbmcgbGlzdApkcmktZGV2ZWxAbGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHBzOi8vbGlz dHMuZnJlZWRlc2t0b3Aub3JnL21haWxtYW4vbGlzdGluZm8vZHJpLWRldmVsCg== --===============0179044483==--