nir: Add new barrier functions for compute shaders
When these functions are called in glsl-ir, we create a corresponding nir intrinsic function call. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net>
This commit is contained in:
@@ -91,6 +91,17 @@ BARRIER(memory_barrier)
|
||||
*/
|
||||
INTRINSIC(shader_clock, 0, ARR(), true, 1, 0, 0, NIR_INTRINSIC_CAN_ELIMINATE)
|
||||
|
||||
/*
|
||||
* Memory barrier with semantics analogous to the compute shader
|
||||
* groupMemoryBarrier(), memoryBarrierAtomicCounter(), memoryBarrierBuffer(),
|
||||
* memoryBarrierImage() and memoryBarrierShared() GLSL intrinsics.
|
||||
*/
|
||||
BARRIER(group_memory_barrier)
|
||||
BARRIER(memory_barrier_atomic_counter)
|
||||
BARRIER(memory_barrier_buffer)
|
||||
BARRIER(memory_barrier_image)
|
||||
BARRIER(memory_barrier_shared)
|
||||
|
||||
/** A conditional discard, with a single boolean source. */
|
||||
INTRINSIC(discard_if, 1, ARR(1), false, 0, 0, 0, 0)
|
||||
|
||||
|
Reference in New Issue
Block a user