From: Jason Ekstrand Date: Wed, 9 Sep 2015 23:03:10 +0000 (-0700) Subject: nir/from_ssa: Use instr_rewrite_dest X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ca11c3c0a4726d4f51436d714ef81ef9a01348ea;p=mesa.git nir/from_ssa: Use instr_rewrite_dest Reviewed-by: Eduardo Lima Mitev --- diff --git a/src/glsl/nir/nir_from_ssa.c b/src/glsl/nir/nir_from_ssa.c index 084f43da87c..eaf883dbaa0 100644 --- a/src/glsl/nir/nir_from_ssa.c +++ b/src/glsl/nir/nir_from_ssa.c @@ -512,9 +512,7 @@ rewrite_ssa_def(nir_ssa_def *def, void *void_state) */ nir_dest *dest = exec_node_data(nir_dest, def, ssa); - *dest = nir_dest_for_reg(reg); - dest->reg.parent_instr = state->instr; - list_addtail(&dest->reg.def_link, ®->defs); + nir_instr_rewrite_dest(state->instr, dest, nir_dest_for_reg(reg)); return true; }