summaryrefslogtreecommitdiffstats
path: root/src/compiler/nir/nir_opt_access.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/nir/nir_opt_access.c')
-rw-r--r--src/compiler/nir/nir_opt_access.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/compiler/nir/nir_opt_access.c b/src/compiler/nir/nir_opt_access.c
index ec316a8947e..766f056568a 100644
--- a/src/compiler/nir/nir_opt_access.c
+++ b/src/compiler/nir/nir_opt_access.c
@@ -134,6 +134,16 @@ gather_intrinsic(struct access_state *state, nir_intrinsic_instr *instr)
state->image_barriers = true;
break;
+ case nir_intrinsic_scoped_memory_barrier:
+ /* TODO: Could be more granular if we had nir_var_mem_image. */
+ if (nir_intrinsic_memory_modes(instr) & (nir_var_mem_ubo |
+ nir_var_mem_ssbo |
+ nir_var_uniform)) {
+ state->buffer_barriers = true;
+ state->image_barriers = true;
+ }
+ break;
+
default:
break;
}