[Bug 109573] dEQP-VK.spirv_assembly.instruction.graphics.module.same_module

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Feb 7 02:40:23 UTC 2019


Kenneth Graunke <kenneth at whitecape.org> changed:

           What    |Removed                     |Added
             Status|NEW                         |ASSIGNED

--- Comment #1 from Kenneth Graunke <kenneth at whitecape.org> ---
I looked into this for a few hours today, it's unfortunately a bit more
complicated than I'd hoped.  My patch is correct, it's just exposing a
pre-existing issue.

That test has a single SPIR-V module containing multiple shader stages.  When
compiling that module, we generate shader inputs and outputs for every
stage...in a NIR shader targeting a particular shader stage.  So, we suddenly
have VS output variables in a TCS.  The TCS expects outputs to be per-vertex
arrays (or marked patch).  VS outputs are not.  So, they are illegal in a TCS.

In particular, there is a gl_PerVertex output variable for another stage in the
TCS, which is being structure split, giving us top-level output for clipdist[x]
and culldist[x].  But in a TCS, those would need an extra dimension -
dist[x][y].  The validator tries to enforce that variables marked 'compact'
must be arrays, and after unwrapping the per-vertex IO array dimension, it sees
simply 'float', which is rightly illegal.

I'm testing a patch to remove dead input/output variables at the end of
spirv_to_nir(), which should eliminate the invalid ones before the validator
ever sees the shenanigans.  Jason recommended this, and we take a similar
approach already in some cases.

You are receiving this mail because:
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/intel-3d-bugs/attachments/20190207/fb3bfb10/attachment.html>

More information about the intel-3d-bugs mailing list