r600/sb: insert the else clause when we might depart from a loop
authorDave Airlie <airlied@redhat.com>
Tue, 30 Jan 2018 06:38:51 +0000 (16:38 +1000)
committerDave Airlie <airlied@redhat.com>
Tue, 30 Jan 2018 18:47:29 +0000 (04:47 +1000)
commit8d633f067b8a3d74e3f39faea0773a229d4b93b3
treef0286c53c95fac21048dd05ec22f133af6206b7c
parent1a9aa69ae85d7eb1baae1f2ee6af84d6fbd22de7
r600/sb: insert the else clause when we might depart from a loop

If there is a break inside the else clause and this means we
are breaking from a loop, the loop finalise will want to insert
the LOOP_BREAK/CONTINUE instruction, however if we don't emit
the else there is no where for these to end up, so they will end
up in the wrong place.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101442
Tested-By: Gert Wollny <gw.fossdev@gmail.com>
Cc: <mesa-stable@lists.freedesktop.org>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
src/gallium/drivers/r600/sb/sb_bc_finalize.cpp