How can I perform atomic operations like atomicCAS with ArrayFire to avoid locking?
atomicCAS
(that is the same across all backends)