nir/lower_int_to_float: Make sure the cursor is in the right spot.
authorEmma Anholt <emma@anholt.net>
Thu, 3 Jun 2021 18:10:48 +0000 (11:10 -0700)
committerMarge Bot <eric+marge@anholt.net>
Fri, 18 Jun 2021 04:30:43 +0000 (04:30 +0000)
commitaba8b6675ae3ddc136f4f48cbabb7d3e24c6d58b
tree054ee11ed3a28b75e91202bf368cc77dd9f132ad
parent31ab2735dbc64c5d67b7db3ef75e9fd5969f4b2a
nir/lower_int_to_float: Make sure the cursor is in the right spot.

We need to make get it updated after we may have nir_instr_remove()d an
instruction, and when we cross blocks.  This didn't really matter before
because the only builder usage was idiv, which other users of
lower_int_to_float were probably never hitting.

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11329>
src/compiler/nir/nir_lower_int_to_float.c