diff options
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/nir/nir_lower_atomics_to_ssbo.c | 7 | ||||
-rw-r--r-- | src/compiler/nir/nir_opt_combine_stores.c | 1 | ||||
-rw-r--r-- | src/compiler/nir/nir_opt_copy_prop_vars.c | 1 | ||||
-rw-r--r-- | src/compiler/nir/nir_opt_dead_write_vars.c | 1 |
4 files changed, 7 insertions, 3 deletions
diff --git a/src/compiler/nir/nir_lower_atomics_to_ssbo.c b/src/compiler/nir/nir_lower_atomics_to_ssbo.c index 918f060a8df..7ff0123b7bb 100644 --- a/src/compiler/nir/nir_lower_atomics_to_ssbo.c +++ b/src/compiler/nir/nir_lower_atomics_to_ssbo.c @@ -47,6 +47,13 @@ lower_instr(nir_intrinsic_instr *instr, unsigned ssbo_offset, nir_builder *b) b->cursor = nir_before_instr(&instr->instr); switch (instr->intrinsic) { + case nir_intrinsic_memory_barrier_atomic_counter: + /* Atomic counters are now SSBOs so memoryBarrierAtomicCounter() is now + * memoryBarrierBuffer(). + */ + instr->intrinsic = nir_intrinsic_memory_barrier_buffer; + return true; + case nir_intrinsic_ssbo_atomic_add: case nir_intrinsic_ssbo_atomic_imin: case nir_intrinsic_ssbo_atomic_umin: diff --git a/src/compiler/nir/nir_opt_combine_stores.c b/src/compiler/nir/nir_opt_combine_stores.c index 791ec094c00..285a2564a95 100644 --- a/src/compiler/nir/nir_opt_combine_stores.c +++ b/src/compiler/nir/nir_opt_combine_stores.c @@ -311,7 +311,6 @@ combine_stores_block(struct combine_stores_state *state, nir_block *block) nir_var_mem_shared); break; - case nir_intrinsic_memory_barrier_atomic_counter: case nir_intrinsic_memory_barrier_buffer: combine_stores_with_modes(state, nir_var_mem_ssbo); break; diff --git a/src/compiler/nir/nir_opt_copy_prop_vars.c b/src/compiler/nir/nir_opt_copy_prop_vars.c index dbce55bfb8c..54fbad221a7 100644 --- a/src/compiler/nir/nir_opt_copy_prop_vars.c +++ b/src/compiler/nir/nir_opt_copy_prop_vars.c @@ -808,7 +808,6 @@ copy_prop_vars_block(struct copy_prop_var_state *state, 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); diff --git a/src/compiler/nir/nir_opt_dead_write_vars.c b/src/compiler/nir/nir_opt_dead_write_vars.c index 578e8706818..0980647c63d 100644 --- a/src/compiler/nir/nir_opt_dead_write_vars.c +++ b/src/compiler/nir/nir_opt_dead_write_vars.c @@ -140,7 +140,6 @@ remove_dead_write_vars_local(void *mem_ctx, nir_block *block) } case nir_intrinsic_memory_barrier_buffer: - case nir_intrinsic_memory_barrier_atomic_counter: clear_unused_for_modes(&unused_writes, nir_var_mem_ssbo); break; |