SPIRV-Cross/reference/shaders-no-opt/asm/comp/atomic-load-store.asm.comp
Hans-Kristian Arntzen 9b7140e2ba Implement OpAtomicLoad/OpAtomicStore.
Need some emulation on GLSL/HLSL, fix bug with atomic store on MSL.
2020-04-27 12:11:46 +02:00

17 lines
252 B
Plaintext

#version 450
layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
layout(binding = 0, std430) buffer SSBO
{
uint a;
uint b;
} _5;
void main()
{
uint _20 = atomicAdd(_5.b, 0u);
uint c = _20;
atomicExchange(_5.a, c);
}