1617a3babSopenharmony_ci 2617a3babSopenharmony_ciRWBuffer<uint> s_uintbuff; // UINT RWBuffer ... 3617a3babSopenharmony_ci 4617a3babSopenharmony_cifloat4 main() : SV_Target 5617a3babSopenharmony_ci{ 6617a3babSopenharmony_ci int Loc; // ... with INT variables 7617a3babSopenharmony_ci int Inc; 8617a3babSopenharmony_ci int Orig; 9617a3babSopenharmony_ci 10617a3babSopenharmony_ci // This must select the uint flavor of SPIR-V atomic op, and promote 11617a3babSopenharmony_ci // the other arguments as required. The output value from the 12617a3babSopenharmony_ci // imageAtomicAdd AST will be converted to an int for 'Orig'. 13617a3babSopenharmony_ci InterlockedAdd(s_uintbuff[Loc], Inc, Orig); 14617a3babSopenharmony_ci 15617a3babSopenharmony_ci return float4(0,0,0,0); 16617a3babSopenharmony_ci} 17617a3babSopenharmony_ci 18