#include <ScopedContext.h>
Public Member Functions | |
template<typename F > | |
void | pushNextTask (F &&f) |
void | replaceWaitingTaskHolder (edm::WaitingTaskWithArenaHolder waitingTaskHolder) |
ScopedContextAcquire (const ProductBase &data, edm::WaitingTaskWithArenaHolder waitingTaskHolder) | |
Constructor to (possibly) re-use a CUDA stream (no need for context beyond acquire()) More... | |
ScopedContextAcquire (const ProductBase &data, edm::WaitingTaskWithArenaHolder waitingTaskHolder, ContextState &state) | |
Constructor to (possibly) re-use a CUDA stream, and the context is needed after acquire() More... | |
ScopedContextAcquire (edm::StreamID streamID, edm::WaitingTaskWithArenaHolder waitingTaskHolder) | |
Constructor to create a new CUDA stream (no need for context beyond acquire()) More... | |
ScopedContextAcquire (edm::StreamID streamID, edm::WaitingTaskWithArenaHolder waitingTaskHolder, ContextState &state) | |
Constructor to create a new CUDA stream, and the context is needed after acquire() More... | |
~ScopedContextAcquire () | |
Public Member Functions inherited from cms::cuda::impl::ScopedContextGetterBase | |
template<typename T > | |
const T & | get (const edm::Event &iEvent, edm::EDGetTokenT< Product< T >> token) |
template<typename T > | |
const T & | get (const Product< T > &data) |
Public Member Functions inherited from cms::cuda::impl::ScopedContextBase | |
int | device () const |
cudaStream_t | stream () const |
const SharedStreamPtr & | streamPtr () const |
Private Member Functions | |
void | throwNoState () |
Private Attributes | |
ContextState * | contextState_ = nullptr |
impl::ScopedContextHolderHelper | holderHelper_ |
Additional Inherited Members | |
Protected Member Functions inherited from cms::cuda::impl::ScopedContextGetterBase | |
template<typename... Args> | |
ScopedContextGetterBase (Args &&... args) | |
void | synchronizeStreams (int dataDevice, cudaStream_t dataStream, bool available, cudaEvent_t dataEvent) |
Protected Member Functions inherited from cms::cuda::impl::ScopedContextBase | |
ScopedContextBase (const ProductBase &data) | |
ScopedContextBase (edm::StreamID streamID) | |
ScopedContextBase (int device, SharedStreamPtr stream) | |
The aim of this class is to do necessary per-event "initialization" in ExternalWork acquire():
Definition at line 101 of file ScopedContext.h.
|
inlineexplicit |
Constructor to create a new CUDA stream (no need for context beyond acquire())
Definition at line 104 of file ScopedContext.h.
References eostools::move().
|
inlineexplicit |
Constructor to create a new CUDA stream, and the context is needed after acquire()
Definition at line 108 of file ScopedContext.h.
References eostools::move().
|
inlineexplicit |
Constructor to (possibly) re-use a CUDA stream (no need for context beyond acquire())
Definition at line 114 of file ScopedContext.h.
References eostools::move().
|
inlineexplicit |
Constructor to (possibly) re-use a CUDA stream, and the context is needed after acquire()
Definition at line 118 of file ScopedContext.h.
References eostools::move().
cms::cuda::ScopedContextAcquire::~ScopedContextAcquire | ( | ) |
Definition at line 93 of file ScopedContext.cc.
References contextState_, cms::cuda::impl::ScopedContextBase::device(), cms::cuda::impl::ScopedContextHolderHelper::enqueueCallback(), holderHelper_, cms::cuda::ContextState::set(), cms::cuda::impl::ScopedContextBase::stream(), and cms::cuda::impl::ScopedContextBase::streamPtr().
|
inline |
Definition at line 126 of file ScopedContext.h.
References contextState_, f, holderHelper_, cms::cuda::impl::ScopedContextHolderHelper::pushNextTask(), and throwNoState().
|
inline |
Definition at line 132 of file ScopedContext.h.
References holderHelper_, eostools::move(), and cms::cuda::impl::ScopedContextHolderHelper::replaceWaitingTaskHolder().
|
private |
Definition at line 100 of file ScopedContext.cc.
References Exception.
Referenced by pushNextTask().
|
private |
Definition at line 140 of file ScopedContext.h.
Referenced by pushNextTask(), and ~ScopedContextAcquire().
|
private |
Definition at line 139 of file ScopedContext.h.
Referenced by pushNextTask(), replaceWaitingTaskHolder(), and ~ScopedContextAcquire().