diff options
author | Eric Anholt <eric@anholt.net> | 2015-01-26 14:37:42 -0800 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2015-01-29 11:43:33 -0800 |
commit | 9a3a60cb138ea9a7fb29368c8c8efe614a7d80fe (patch) | |
tree | 35eaefceb6842c67c9c63d8c93578cf73506714d | |
parent | 68d476167c0d23e3f050ce3a882fc7b741c18d09 (diff) |
nir: Don't try to to-SSA ALU instructions that are already SSA.
Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
-rw-r--r-- | src/glsl/nir/nir_to_ssa.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/glsl/nir/nir_to_ssa.c b/src/glsl/nir/nir_to_ssa.c index 9c577fa992..dbe1699c54 100644 --- a/src/glsl/nir/nir_to_ssa.c +++ b/src/glsl/nir/nir_to_ssa.c @@ -239,6 +239,9 @@ rewrite_alu_instr_forward(nir_alu_instr *instr, rewrite_state *state) nir_foreach_src(&instr->instr, rewrite_use, state); + if (instr->dest.dest.is_ssa) + return; + nir_register *reg = instr->dest.dest.reg.reg; unsigned index = reg->index; |