nir/lower_goto_if: Replace a tripple loop with a double loop
authorJason Ekstrand <jason@jlekstrand.net>
Wed, 12 Aug 2020 22:59:53 +0000 (17:59 -0500)
committerMarge Bot <eric+marge@anholt.net>
Fri, 14 Aug 2020 20:35:37 +0000 (20:35 +0000)
commitd2bf850672bb3691044d773c9fd96d0e80c7fcf3
tree894024235c30137072f65f6d42c99e12302e45bd
parentb892d473b4e9399697d45a98d6cf02fa0e900e7f
nir/lower_goto_if: Replace a tripple loop with a double loop

If there's some reason why this needs to be a tripple loop, I'm not
seeing it.  As far as I can tell, all the inner-most loop does is look
for the next remaining block not already in cur_level->blocks.  There's
no reason to re-walk the whole set every time just to do that.

Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/2401>
src/compiler/nir/nir_lower_goto_ifs.c