|
device::id_t | device_id () const noexcept |
| The raw CUDA ID for the device w.r.t. which the event is defined.
|
|
context::handle_t | context_handle () const noexcept |
| The raw CUDA handle for the context in which the represented stream is defined.
|
|
event::handle_t | handle () const noexcept |
| The raw CUDA handle for this event.
|
|
bool | is_owning () const noexcept |
| True if this wrapper is responsible for telling CUDA to destroy the event upon the wrapper's own destruction.
|
|
bool | holds_primary_context_reference () const noexcept |
| True if this wrapper has been associated with an increase of the device's primary context's reference count.
|
|
device_t | device () const |
| The device w.r.t. which the event is defined.
|
|
context_t | context () const |
| The context in which this stream was defined.
|
|
bool | has_occurred () const |
| Has this event already occurred, or is it still pending on a stream? More...
|
|
bool | query () const |
| An alias for {event_t::has_occurred()} - to conform to how the CUDA runtime API names this functionality.
|
|
void | record () const |
| Schedule a specified event to occur (= to fire) when all activities already scheduled on the event's device's default stream have concluded. More...
|
|
void | record (const stream_t &stream) const |
| Schedule a specified event to occur (= to fire) when all activities already scheduled on the stream have concluded. More...
|
|
void | fire (const stream_t &stream) const |
| Records the event and ensures it has occurred before returning (by synchronizing the stream). More...
|
|
void | synchronize () const |
| See. More...
|
|
| event_t (const event_t &other)=delete |
|
| event_t (event_t &&other) noexcept |
|
event_t & | operator= (const event_t &)=delete |
|
event_t & | operator= (event_t &&other) noexcept |
|
Wrapper class for a CUDA event.
Use this class - built around an event handle - to perform almost, if not all, event-related operations the CUDA Runtime API is capable of.
- Note
- By default this class has RAII semantics, i.e. it has the runtime create an event on construction and destroy it on destruction, and isn't merely an ephemeral wrapper one could apply and discard; but this second kind of semantics is also (sort of) supported, through the event_t::owning_ field.