[Bug 105670] [regression][hang] Trine1EE hangs GPU after loading screen on Mesa3D-17.3 and later
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Tue Mar 27 23:54:32 UTC 2018
https://bugs.freedesktop.org/show_bug.cgi?id=105670
--- Comment #19 from Timothy Arceri <t_arceri at yahoo.com.au> ---
Ok here is a piglit test for the original GLSL IR bug:
https://patchwork.freedesktop.org/patch/213332/
The NIR bug is a little harder to test reliably for since it depends on the
order in which optimisations are called so I just going to leave it for now.
Anyway this bug should now be fixed with the following commits:
commit 56b867395dee1a48594b27987d3bf68a4e745dda
Author: Timothy Arceri <tarceri at itsqueeze.com>
Date: Mon Mar 26 10:31:26 2018 +1100
glsl: fix infinite loop caused by bug in loop unrolling pass
Just checking for 2 jumps is not enough to be sure we can do a
complex loop unroll. We need to make sure we also have also found
2 loop terminators.
Without this we were attempting to unroll a loop where the second
jump was nested inside multiple ifs which loop analysis is unable
to detect as a terminator. We ended up splicing out the first
terminator but failed to actually unroll the loop, this resulted
in the creation of a possible infinite loop.
Fixes: 646621c66da9 "glsl: make loop unrolling more like the nir unrolling
path"
Tested-by: Gert Wollny <gw.fossdev at gmail.com>
Reviewed-by: Ian Romanick <ian.d.romanick at intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105670
commit 629ee690addad9b3dc8f68cfff5ae09858f31caf
Author: Timothy Arceri <tarceri at itsqueeze.com>
Date: Mon Mar 26 11:41:51 2018 +1100
nir: fix crash in loop unroll corner case
When an if nesting inside anouther if is optimised away we can
end up with a loop terminator and following block that looks like
this:
if ssa_596 {
block block_5:
/* preds: block_4 */
vec1 32 ssa_601 = load_const (0xffffffff /* -nan */)
break
/* succs: block_8 */
} else {
block block_6:
/* preds: block_4 */
/* succs: block_7 */
}
block block_7:
/* preds: block_6 */
vec1 32 ssa_602 = phi block_6: ssa_552
vec1 32 ssa_603 = phi block_6: ssa_553
vec1 32 ssa_604 = iadd ssa_551, ssa_66
The problem is the phis. Loop unrolling expects the last block in
the loop to be empty once we splice the instructions in the last
block into the continue branch. The problem is we cant move phis
so here we lower the phis to regs when preparing the loop for
unrolling. As it could be possible to have multiple additional
blocks/ifs following the terminator we just convert all phis at
the top level of the loop body for simplicity.
We also add some comments to loop_prepare_for_unroll() while we
are here.
Fixes: 51daccb289eb "nir: add a loop unrolling pass"
Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105670
--
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/20180327/7cd64d58/attachment-0001.html>
More information about the intel-3d-bugs
mailing list