atomic_fetch_max Function

Atomically computes the maximum of a value and the value of a memory location and stores the maximum value to the memory location.

inline int atomic_fetch_max(
   _Inout_ int * _Dest,
   int _Value                     
) restrict(amp);

inline unsigned int atomic_fetch_max(
   _Inout_ unsigned int * _Dest,
   unsigned int _Value                     
) restrict(amp);


  • _Dest
    Pointer to the destination location.

  • _Value
    The value to be compared.

Return Value

The original value of the memory location.


Header: amp.h

Namespace: Concurrency

See Also


Concurrency Namespace (C++ AMP)