diff options
author | Jason Ekstrand <[email protected]> | 2019-09-09 13:38:37 -0500 |
---|---|---|
committer | Dylan Baker <[email protected]> | 2019-09-23 11:11:59 -0700 |
commit | dc7129777fd3077a8c00ff0d4d7bc0e20dc4f04b (patch) | |
tree | 92d6c049d8af216f1146f9bd13a6410e7a48ead0 /src/compiler/glsl/xxd.py | |
parent | 6485fd83623099034727f14ba9253941fcfc6725 (diff) |
nir/repair_ssa: Replace the unreachable check with the phi builder
In a3268599f3c9, I attempted to fix nir_repair_ssa for unreachable
blocks. However, that commit missed the possibility that the use is in
a block which, itself, is unreachable. In this case, we can end up in
an infinite loop trying to replace a def with itself. Even though a
no-op replacement is a fine operation, it keeps extending the end of the
uses list as we're walking it. Instead of explicitly checking for the
group of conditions, just check if the phi builder gives us a different
def. That's guaranteed to be 100% reliable and, while it lacks symmetry
with the is_valid checks, should be more reliable.
Fixes: a3268599 "nir/repair_ssa: Repair dominance for unreachable..."
Reviewed-by: Ian Romanick <[email protected]>
(cherry picked from commit d63162cff0e0922fc3c2ef5dfd4402004caf141e)
Diffstat (limited to 'src/compiler/glsl/xxd.py')
0 files changed, 0 insertions, 0 deletions