summaryrefslogtreecommitdiffstats
path: root/src/glsl/nir/nir_opt_dce.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2014-12-15 17:32:56 -0800
committerJason Ekstrand <[email protected]>2015-01-15 07:20:22 -0800
commit2c7da78805175f36879111306ac37c12d33bf65b (patch)
tree5fbfa3578dae242c5fa29cf46c647af351fda881 /src/glsl/nir/nir_opt_dce.c
parent675ffdef3010400567a5f6f790f1f7bd2fede717 (diff)
nir: Make load_const SSA-only
As it was, we weren't ever using load_const in a non-SSA way. This allows us to substantially simplify the load_const instruction. If we ever need a non-SSA constant load, we can do a load_const and an imov. Reviewed-by: Connor Abbott <[email protected]>
Diffstat (limited to 'src/glsl/nir/nir_opt_dce.c')
-rw-r--r--src/glsl/nir/nir_opt_dce.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/src/glsl/nir/nir_opt_dce.c b/src/glsl/nir/nir_opt_dce.c
index 8a7490dc3e0..9778e9ed6a6 100644
--- a/src/glsl/nir/nir_opt_dce.c
+++ b/src/glsl/nir/nir_opt_dce.c
@@ -69,7 +69,6 @@ init_instr(nir_instr *instr, struct exec_list *worklist)
nir_alu_instr *alu_instr;
nir_intrinsic_instr *intrin_instr;
nir_tex_instr *tex_instr;
- nir_load_const_instr *load_const_instr;
instr->live = false;
@@ -104,12 +103,6 @@ init_instr(nir_instr *instr, struct exec_list *worklist)
worklist_push(worklist, instr);
break;
- case nir_instr_type_load_const:
- load_const_instr = nir_instr_as_load_const(instr);
- if (!load_const_instr->dest.is_ssa)
- worklist_push(worklist, instr);
- break;
-
default:
break;
}