From: Jason Ekstrand Date: Sat, 25 May 2019 04:29:15 +0000 (-0500) Subject: nir/opt_deref: Report progress if we remove a deref X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=db6d9cdf0661fbe25b1bc767920a5f6a0944935b;p=mesa.git nir/opt_deref: Report progress if we remove a deref Fixes: a1c688517de "nir/opt_deref: Properly optimize ptr_as_array..." Reviewed-by: Dave Airlie Part-of: --- diff --git a/src/compiler/nir/nir_deref.c b/src/compiler/nir/nir_deref.c index 09eaa524e42..61cf71e3460 100644 --- a/src/compiler/nir/nir_deref.c +++ b/src/compiler/nir/nir_deref.c @@ -943,7 +943,9 @@ opt_deref_cast(nir_builder *b, nir_deref_instr *cast) /* If uses would be a bit crazy */ assert(list_is_empty(&cast->dest.ssa.if_uses)); - nir_deref_instr_remove_if_unused(cast); + if (nir_deref_instr_remove_if_unused(cast)) + progress = true; + return progress; }