nir: use src for ssa helper
authorTimothy Arceri <t_arceri@yahoo.com.au>
Tue, 2 Jun 2015 09:26:42 +0000 (19:26 +1000)
committerTimothy Arceri <t_arceri@yahoo.com.au>
Tue, 2 Jun 2015 20:50:39 +0000 (06:50 +1000)
Reviewed-by: Thomas Helland <thomashelland90@gmail.com>
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
src/glsl/nir/glsl_to_nir.cpp

index af758ceb020e10cb9b39ad4224837f66b2f08564..ad8cfad627bd80b29272e519eadc4f344e590e3e 100644 (file)
@@ -930,13 +930,9 @@ nir_visitor::evaluate_rvalue(ir_rvalue* ir)
    }
 
    nir_dest *dest = get_instr_dest(this->result);
-
    assert(dest->is_ssa);
-   nir_src src = NIR_SRC_INIT;
-   src.is_ssa = true;
-   src.ssa = &dest->ssa;
 
-   return src;
+   return nir_src_for_ssa(&dest->ssa);
 }
 
 nir_alu_instr *