From f09db0bed5fa0227e10c8e911a118803f23a8fac Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Tue, 7 Jan 2020 14:11:55 -0600 Subject: nir: Handle more barriers in dead_write and copy_prop Reviewed-by: Caio Marcelo de Oliveira Filho Part-of: --- src/compiler/nir/nir_opt_copy_prop_vars.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/compiler/nir/nir_opt_copy_prop_vars.c') diff --git a/src/compiler/nir/nir_opt_copy_prop_vars.c b/src/compiler/nir/nir_opt_copy_prop_vars.c index c4544eac0f2..fdbf62c3599 100644 --- a/src/compiler/nir/nir_opt_copy_prop_vars.c +++ b/src/compiler/nir/nir_opt_copy_prop_vars.c @@ -807,6 +807,19 @@ copy_prop_vars_block(struct copy_prop_var_state *state, nir_var_mem_shared); break; + case nir_intrinsic_memory_barrier_buffer: + case nir_intrinsic_memory_barrier_atomic_counter: + if (debug) dump_instr(instr); + + apply_barrier_for_modes(copies, nir_var_mem_ssbo); + break; + + case nir_intrinsic_memory_barrier_shared: + if (debug) dump_instr(instr); + + apply_barrier_for_modes(copies, nir_var_mem_shared); + break; + case nir_intrinsic_scoped_memory_barrier: if (debug) dump_instr(instr); -- cgit v1.2.3