summaryrefslogtreecommitdiffstats
path: root/src/glsl/nir/nir_from_ssa.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2015-09-09 16:03:10 -0700
committerJason Ekstrand <[email protected]>2015-09-11 09:21:20 -0700
commitca11c3c0a4726d4f51436d714ef81ef9a01348ea (patch)
treef0977c65b1021d9ef96e4cf8ecb8ca20e8faec92 /src/glsl/nir/nir_from_ssa.c
parentcee29220e312f7c76a07343e501fa6a1c5f3d1aa (diff)
nir/from_ssa: Use instr_rewrite_dest
Reviewed-by: Eduardo Lima Mitev <[email protected]>
Diffstat (limited to 'src/glsl/nir/nir_from_ssa.c')
-rw-r--r--src/glsl/nir/nir_from_ssa.c4
1 files changed, 1 insertions, 3 deletions
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, &reg->defs);
+ nir_instr_rewrite_dest(state->instr, dest, nir_dest_for_reg(reg));
return true;
}