diff options
author | Jordan Justen <[email protected]> | 2014-11-05 00:47:41 -0800 |
---|---|---|
committer | Jordan Justen <[email protected]> | 2015-09-10 16:46:29 -0700 |
commit | 34cff76fc2da1ce9abad6e2b1856fec6a950d19c (patch) | |
tree | ff07e0c10a8255d38db80a5cedbecbe9518ab72f /src/mesa/drivers/dri/i965/brw_fs_nir.cpp | |
parent | b01d0473917ba15de3aa146006bfef5836d10e93 (diff) |
i965/cs: Enable barrier in MEDIA_INTERFACE_DESCRIPTOR
Enable barrier in MEDIA_INTERFACE_DESCRIPTOR if the program uses the
barrier() GLSL function.
On Ivy Bridge and Haswell, this allows the piglit test
tests/spec/arb_compute_shader/execution/simple-barrier-atomics.shader_test
to pass. On gen8, this enables a similar test with a local group size
of 896 to pass.
Signed-off-by: Jordan Justen <[email protected]>
Reviewed-by: Kristian Høgsberg <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_fs_nir.cpp')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp index 1cc7b021928..8c3c4aed707 100644 --- a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp @@ -1705,6 +1705,8 @@ fs_visitor::nir_emit_intrinsic(const fs_builder &bld, nir_intrinsic_instr *instr case nir_intrinsic_barrier: emit_barrier(); + if (stage == MESA_SHADER_COMPUTE) + ((struct brw_cs_prog_data *) prog_data)->uses_barrier = true; break; default: |