return NULL;
nir_alu_instr *alu = nir_instr_as_alu(ssa->parent_instr);
- return (alu->op == nir_op_imov || alu->op == nir_op_fmov) ? alu : NULL;
+ return (alu->op == nir_op_mov) ? alu : NULL;
}
static bool
*/
b->cursor = nir_after_phis(block);
- def = mov->op == nir_op_imov ?
- nir_imov_alu(b, mov->src[0], def->num_components) :
- nir_fmov_alu(b, mov->src[0], def->num_components);
+ def = nir_mov_alu(b, mov->src[0], def->num_components);
}
assert(phi->dest.is_ssa);
return progress;
}
+bool
+nir_opt_remove_phis_block(nir_block *block)
+{
+ nir_builder b;
+ nir_builder_init(&b, nir_cf_node_get_function(&block->cf_node));
+ return remove_phis_block(block, &b);
+}
+
static bool
nir_opt_remove_phis_impl(nir_function_impl *impl)
{