像原子操作设置目的位置的值。
inline int atomic_exchange(
_Inout_ int * _Dest,
int _Value
) restrict(amp);
inline unsigned int atomic_exchange(
_Inout_ unsigned int * _Dest,
unsigned int _Value
) restrict(amp);
inline float atomic_exchange(
_Inout_ float * _Dest,
float _Value
) restrict(amp);
参数
_Dest
指向目标位置的指针。_Value
新值。
返回值
目的位置的初始值。
要求
**标头:**amp.h
**命名空间:**并发