atomicAdd
함수
Adds value to the atomic location as one indivisible step and returns the value it held before (atomicAdd(bins[i], 1)).
이름마다 붙은 시그니처와 설명은 커밋 26de7be8의 컴파일러 소스에서 그대로 가져온 영어 원문입니다.
구문
declare function atomicAdd<T extends u32 | i32>(location: atomic<T>, value: T): T매개변수
-
locationatomic<T> -
valueT
반환값
T
설명
Wraps at 32 bits. Compiles to atomicAdd(&bins[i], v) on WGSL only.
대상별 출력
- WGSL
-
atomicAdd(&a, b) - GLSL ES 3.00
- atomicAdd has no GLSL ES 3.00 spelling (no storage buffers, no atomics)