From 5015260a0598ada4865b2c6086fc669505f64749 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Tue, 26 Apr 2016 20:30:10 -0700 Subject: nir: Switch the arguments to nir_foreach_use and friends This matches the "foreach x in container" pattern found in many other programming languages. Generated by the following regular expression: s/nir_foreach_use(\([^,]*\),\s*\([^,]*\))/nir_foreach_use(\2, \1)/ and similar expressions for nir_foreach_use_safe, etc. Reviewed-by: Ian Romanick --- src/mesa/drivers/dri/i965/brw_nir_opt_peephole_ffma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa/drivers') diff --git a/src/mesa/drivers/dri/i965/brw_nir_opt_peephole_ffma.c b/src/mesa/drivers/dri/i965/brw_nir_opt_peephole_ffma.c index e7df80db491..86fcdd4789a 100644 --- a/src/mesa/drivers/dri/i965/brw_nir_opt_peephole_ffma.c +++ b/src/mesa/drivers/dri/i965/brw_nir_opt_peephole_ffma.c @@ -44,7 +44,7 @@ are_all_uses_fadd(nir_ssa_def *def) if (!list_empty(&def->if_uses)) return false; - nir_foreach_use(def, use_src) { + nir_foreach_use(use_src, def) { nir_instr *use_instr = use_src->parent_instr; if (use_instr->type != nir_instr_type_alu) -- cgit v1.2.3