summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorConnor Abbott <[email protected]>2016-04-08 17:18:45 -0400
committerJason Ekstrand <[email protected]>2016-04-28 15:52:17 -0700
commitc1b37c08bf34a3244476f10a7084803b8a58b3d8 (patch)
treed8406cd3ea58c089b6369d7d4282772bd09d5acd
parentceed12557dcba4e0e60e06d03a717d5e21880e16 (diff)
nir/move_vec_src_uses_to_dest: fixup for new foreach_block()
Reviewed-by: Jason Ekstrand <[email protected]>
-rw-r--r--src/compiler/nir/nir_move_vec_src_uses_to_dest.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/compiler/nir/nir_move_vec_src_uses_to_dest.c b/src/compiler/nir/nir_move_vec_src_uses_to_dest.c
index 7ff4fe8c377..a437fe88d07 100644
--- a/src/compiler/nir/nir_move_vec_src_uses_to_dest.c
+++ b/src/compiler/nir/nir_move_vec_src_uses_to_dest.c
@@ -62,7 +62,7 @@ ssa_def_dominates_instr(nir_ssa_def *def, nir_instr *instr)
}
static bool
-move_vec_src_uses_to_dest_block(nir_block *block, void *shader)
+move_vec_src_uses_to_dest_block(nir_block *block)
{
nir_foreach_instr(block, instr) {
if (instr->type != nir_instr_type_alu)
@@ -181,7 +181,10 @@ nir_move_vec_src_uses_to_dest_impl(nir_shader *shader, nir_function_impl *impl)
nir_metadata_require(impl, nir_metadata_dominance);
nir_index_instrs(impl);
- nir_foreach_block_call(impl, move_vec_src_uses_to_dest_block, shader);
+
+ nir_foreach_block(block, impl) {
+ move_vec_src_uses_to_dest_block(block);
+ }
nir_metadata_preserve(impl, nir_metadata_block_index |
nir_metadata_dominance);