diff options
author | Jason Ekstrand <[email protected]> | 2016-09-15 21:12:34 -0700 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2016-10-03 16:17:12 -0700 |
commit | 6ffbfc760da14fc710a05438b9fd9eff034128da (patch) | |
tree | d0d2f0d3f98c7a3a13e53e67d38426b2a520732b /src/gallium/state_trackers | |
parent | 7697b4b98b155c818811709becdb408772371538 (diff) |
nir/spirv/cfg: Use a nop intrinsic for tagging the ends of blocks
Previously, we were saving off the last nir_block in a vtn_block before
moving on so that we could find the nir_block again when it came time to
handle phi sources. Unfortunately, NIR's control flow modification code is
inconsistent when it comes to how it splits blocks so the block pointer we
saved off may point to a block somewhere else in the shader by the time we
get around to handling phi sources. In order to get around this, we insert
a nop instruction and use that as the logical end of our block. Since the
control flow manipulation code respects instructions, the nop will keeps
its place like any other instruction and we can easily find the end of our
block when we need it.
This fixes a bug triggered by a couple of vkQuake shaders.
Signed-off-by: Jason Ekstrand <[email protected]>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97233
Cc: "12.0" <[email protected]>
Tested-by: Dave Airlie <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers')
0 files changed, 0 insertions, 0 deletions