alpaka
Abstraction Library for Parallel Kernel Acceleration
Loading...
Searching...
No Matches
alpaka::onAcc::atomic Namespace Reference

Functions

ALPAKA_FN_ACC void alpakaAtomicInvoke (auto &&fn, concepts::Acc auto const &acc, auto *inOut, auto &&... args)
 Defines the equivalent of an atomic invoke for user defined functors.
template<typename T>
ALPAKA_FN_ACC void alpakaAtomicInvoke (std::plus< T >, concepts::Acc auto const &acc, auto *inOut, auto &&... args)

Function Documentation

◆ alpakaAtomicInvoke() [1/2]

ALPAKA_FN_ACC void alpaka::onAcc::atomic::alpakaAtomicInvoke ( auto && fn,
concepts::Acc auto const & acc,
auto * inOut,
auto &&... args )

Defines the equivalent of an atomic invoke for user defined functors.

This function can be specialized within the namespace of the user functor type and will be found via ADL. Typically, this functor is used within the reduce and transformReduce algorithm. The implementation must implement the functor equivalent atomic function.

Parameters
fnnon-atomic user functor
inOutpointer to the values which is updated
argsarguments normally forwarded to the user functor

Definition at line 199 of file atomic.hpp.

◆ alpakaAtomicInvoke() [2/2]

template<typename T>
ALPAKA_FN_ACC void alpaka::onAcc::atomic::alpakaAtomicInvoke ( std::plus< T > ,
concepts::Acc auto const & acc,
auto * inOut,
auto &&... args )

Definition at line 210 of file atomic.hpp.