DPC++ Runtime
Runtime libraries for oneAPI DPC++
_pi_event Struct Reference

PI Event mapping to CUevent. More...

#include <cuda/pi_cuda.hpp>

Collaboration diagram for _pi_event:

Public Types

using native_type = CUevent
 
using native_type = hipEvent_t
 

Public Member Functions

pi_result record ()
 
pi_result wait ()
 
pi_result start ()
 
native_type get () const noexcept
 
pi_queue get_queue () const noexcept
 
CUstream get_stream () const noexcept
 
pi_command_type get_command_type () const noexcept
 
pi_uint32 get_reference_count () const noexcept
 
bool is_recorded () const noexcept
 
bool is_started () const noexcept
 
bool is_completed () const noexcept
 
pi_int32 get_execution_status () const noexcept
 
pi_context get_context () const noexcept
 
pi_uint32 increment_reference_count ()
 
pi_uint32 decrement_reference_count ()
 
pi_uint32 get_event_id () const noexcept
 
pi_uint64 get_queued_time () const
 
pi_uint64 get_start_time () const
 
pi_uint64 get_end_time () const
 
pi_result release ()
 
 ~_pi_event ()
 
 _pi_event ()
 
pi_result record ()
 
pi_result wait ()
 
pi_result start ()
 
native_type get () const noexcept
 
pi_queue get_queue () const noexcept
 
pi_command_type get_command_type () const noexcept
 
pi_uint32 get_reference_count () const noexcept
 
bool is_recorded () const noexcept
 
bool is_started () const noexcept
 
bool is_completed () const noexcept
 
pi_int32 get_execution_status () const noexcept
 
pi_context get_context () const noexcept
 
pi_uint32 increment_reference_count ()
 
pi_uint32 decrement_reference_count ()
 
pi_uint32 get_event_id () const noexcept
 
pi_uint64 get_queued_time () const
 
pi_uint64 get_start_time () const
 
pi_uint64 get_end_time () const
 
pi_result release ()
 
 ~_pi_event ()
 
 _pi_event (ze_event_handle_t ZeEvent, ze_event_pool_handle_t ZeEventPool, pi_context Context, pi_command_type CommandType, bool OwnZeEvent)
 
bool isHostVisible () const
 
pi_result getOrCreateHostVisibleEvent (ze_event_handle_t &HostVisibleEvent)
 
bool isProfilingEnabled () const
 
pi_result cleanup (pi_queue LockedQueue=nullptr)
 

Static Public Member Functions

static pi_event make_native (pi_command_type type, pi_queue queue, CUstream stream)
 
static pi_event make_native (pi_command_type type, pi_queue queue)
 

Public Attributes

cm_support::CmEvent * CmEventPtr = nullptr
 
cm_support::CmQueue * OwnerQueue = nullptr
 
pi_context Context = nullptr
 
bool IsDummyEvent = false
 
ze_event_handle_t ZeEvent
 
bool OwnZeEvent
 
ze_event_pool_handle_t ZeEventPool
 
pi_event HostVisibleEvent = {nullptr}
 
ze_command_list_handle_t ZeCommandList
 
pi_queue Queue = {nullptr}
 
pi_command_type CommandType
 
void * CommandData
 
_pi_ze_event_list_t WaitList
 
bool CleanedUp = {false}
 
bool Completed = {false}
 

Detailed Description

PI Event mapping to CUevent.

PI Event mapping to hipEvent_t.

Definition at line 460 of file pi_cuda.hpp.

Member Typedef Documentation

◆ native_type [1/2]

using _pi_event::native_type = hipEvent_t

Definition at line 406 of file pi_hip.hpp.

◆ native_type [2/2]

Definition at line 462 of file pi_cuda.hpp.

Constructor & Destructor Documentation

◆ ~_pi_event() [1/2]

_pi_event::~_pi_event ( )

Definition at line 423 of file pi_cuda.cpp.

References cuda_piContextRelease(), and cuda_piQueueRelease().

◆ _pi_event() [1/2]

_pi_event::_pi_event ( )
inline

Definition at line 194 of file pi_esimd_emulator.hpp.

Referenced by make_native().

◆ ~_pi_event() [2/2]

_pi_event::~_pi_event ( )

◆ _pi_event() [2/2]

_pi_event::_pi_event ( ze_event_handle_t  ZeEvent,
ze_event_pool_handle_t  ZeEventPool,
pi_context  Context,
pi_command_type  CommandType,
bool  OwnZeEvent 
)
inline

Definition at line 1194 of file pi_level_zero.hpp.

Member Function Documentation

◆ cleanup()

◆ decrement_reference_count() [1/2]

pi_uint32 _pi_event::decrement_reference_count ( )
inline

Definition at line 444 of file pi_hip.hpp.

◆ decrement_reference_count() [2/2]

pi_uint32 _pi_event::decrement_reference_count ( )
inline

Definition at line 502 of file pi_cuda.hpp.

◆ get() [1/2]

native_type _pi_event::get ( ) const
inlinenoexcept

Definition at line 414 of file pi_hip.hpp.

◆ get() [2/2]

native_type _pi_event::get ( ) const
inlinenoexcept

Definition at line 470 of file pi_cuda.hpp.

Referenced by cl::sycl::detail::Command::waitForEvents().

◆ get_command_type() [1/2]

pi_command_type _pi_event::get_command_type ( ) const
inlinenoexcept

Definition at line 418 of file pi_hip.hpp.

◆ get_command_type() [2/2]

pi_command_type _pi_event::get_command_type ( ) const
inlinenoexcept

Definition at line 476 of file pi_cuda.hpp.

◆ get_context() [1/2]

pi_context _pi_event::get_context ( ) const
inlinenoexcept

Definition at line 440 of file pi_hip.hpp.

◆ get_context() [2/2]

pi_context _pi_event::get_context ( ) const
inlinenoexcept

Definition at line 498 of file pi_cuda.hpp.

Referenced by cuda_piEventsWait(), and hip_piEventsWait().

◆ get_end_time() [1/2]

pi_uint64 _pi_event::get_end_time ( ) const

◆ get_end_time() [2/2]

pi_uint64 _pi_event::get_end_time ( ) const

Definition at line 483 of file pi_cuda.cpp.

References _pi_platform::evBase_, is_recorded(), and is_started().

◆ get_event_id() [1/2]

pi_uint32 _pi_event::get_event_id ( ) const
inlinenoexcept

Definition at line 446 of file pi_hip.hpp.

◆ get_event_id() [2/2]

pi_uint32 _pi_event::get_event_id ( ) const
inlinenoexcept

Definition at line 504 of file pi_cuda.hpp.

◆ get_execution_status() [1/2]

pi_int32 _pi_event::get_execution_status ( ) const
inlinenoexcept

◆ get_execution_status() [2/2]

pi_int32 _pi_event::get_execution_status ( ) const
inlinenoexcept

◆ get_queue() [1/2]

pi_queue _pi_event::get_queue ( ) const
inlinenoexcept

Definition at line 416 of file pi_hip.hpp.

◆ get_queue() [2/2]

pi_queue _pi_event::get_queue ( ) const
inlinenoexcept

Definition at line 472 of file pi_cuda.hpp.

◆ get_queued_time() [1/2]

pi_uint64 _pi_event::get_queued_time ( ) const

◆ get_queued_time() [2/2]

pi_uint64 _pi_event::get_queued_time ( ) const

Definition at line 465 of file pi_cuda.cpp.

References _pi_platform::evBase_, and is_started().

◆ get_reference_count() [1/2]

pi_uint32 _pi_event::get_reference_count ( ) const
inlinenoexcept

Definition at line 420 of file pi_hip.hpp.

◆ get_reference_count() [2/2]

pi_uint32 _pi_event::get_reference_count ( ) const
inlinenoexcept

Definition at line 478 of file pi_cuda.hpp.

◆ get_start_time() [1/2]

pi_uint64 _pi_event::get_start_time ( ) const

◆ get_start_time() [2/2]

pi_uint64 _pi_event::get_start_time ( ) const

Definition at line 474 of file pi_cuda.cpp.

References _pi_platform::evBase_, and is_started().

◆ get_stream()

CUstream _pi_event::get_stream ( ) const
inlinenoexcept

Definition at line 474 of file pi_cuda.hpp.

◆ getOrCreateHostVisibleEvent()

pi_result _pi_event::getOrCreateHostVisibleEvent ( ze_event_handle_t HostVisibleEvent)

◆ increment_reference_count() [1/2]

pi_uint32 _pi_event::increment_reference_count ( )
inline

Definition at line 442 of file pi_hip.hpp.

◆ increment_reference_count() [2/2]

pi_uint32 _pi_event::increment_reference_count ( )
inline

Definition at line 500 of file pi_cuda.hpp.

◆ is_completed() [1/2]

bool _pi_event::is_completed ( ) const
noexcept

◆ is_completed() [2/2]

bool _pi_event::is_completed ( ) const
noexcept

Definition at line 448 of file pi_cuda.cpp.

Referenced by get_execution_status().

◆ is_recorded() [1/2]

bool _pi_event::is_recorded ( ) const
inlinenoexcept

Definition at line 422 of file pi_hip.hpp.

◆ is_recorded() [2/2]

bool _pi_event::is_recorded ( ) const
inlinenoexcept

Definition at line 480 of file pi_cuda.hpp.

Referenced by get_end_time(), get_execution_status(), and record().

◆ is_started() [1/2]

bool _pi_event::is_started ( ) const
inlinenoexcept

Definition at line 424 of file pi_hip.hpp.

◆ is_started() [2/2]

bool _pi_event::is_started ( ) const
inlinenoexcept

Definition at line 482 of file pi_cuda.hpp.

Referenced by get_end_time(), get_queued_time(), get_start_time(), record(), and start().

◆ isHostVisible()

bool _pi_event::isHostVisible ( ) const
inline

Definition at line 1221 of file pi_level_zero.hpp.

Referenced by _pi_context::decrementUnreleasedEventsInPool().

◆ isProfilingEnabled()

bool _pi_event::isProfilingEnabled ( ) const
inline

◆ make_native() [1/2]

static pi_event _pi_event::make_native ( pi_command_type  type,
pi_queue  queue 
)
inlinestatic

Definition at line 461 of file pi_hip.hpp.

References _pi_event().

◆ make_native() [2/2]

◆ record() [1/2]

pi_result _pi_event::record ( )

◆ record() [2/2]

◆ release() [1/2]

pi_result _pi_event::release ( )

◆ release() [2/2]

◆ start() [1/2]

pi_result _pi_event::start ( )

◆ start() [2/2]

pi_result _pi_event::start ( )

◆ wait() [1/2]

pi_result _pi_event::wait ( )

◆ wait() [2/2]

pi_result _pi_event::wait ( )

Definition at line 522 of file pi_cuda.cpp.

Member Data Documentation

◆ CleanedUp

bool _pi_event::CleanedUp = {false}

◆ CmEventPtr

cm_support::CmEvent* _pi_event::CmEventPtr = nullptr

Definition at line 196 of file pi_esimd_emulator.hpp.

Referenced by piEventRelease(), and piEventsWait().

◆ CommandData

void* _pi_event::CommandData

Definition at line 1247 of file pi_level_zero.hpp.

Referenced by cleanup(), and EventRelease().

◆ CommandType

pi_command_type _pi_event::CommandType

Definition at line 1240 of file pi_level_zero.hpp.

Referenced by cleanup(), EventRelease(), and piEventGetInfo().

◆ Completed

bool _pi_event::Completed = {false}

Definition at line 1267 of file pi_level_zero.hpp.

Referenced by piEventGetInfo(), and _pi_queue::synchronize().

◆ Context

pi_context _pi_event::Context = nullptr

Definition at line 198 of file pi_esimd_emulator.hpp.

Referenced by EventRelease(), piEventGetInfo(), and piEventGetProfilingInfo().

◆ HostVisibleEvent

pi_event _pi_event::HostVisibleEvent = {nullptr}

◆ IsDummyEvent

bool _pi_event::IsDummyEvent = false

Definition at line 199 of file pi_esimd_emulator.hpp.

Referenced by piEventRelease().

◆ OwnerQueue

cm_support::CmQueue* _pi_event::OwnerQueue = nullptr

Definition at line 197 of file pi_esimd_emulator.hpp.

Referenced by piEventRelease().

◆ OwnZeEvent

bool _pi_event::OwnZeEvent

Definition at line 1205 of file pi_level_zero.hpp.

Referenced by EventRelease().

◆ Queue

◆ WaitList

_pi_ze_event_list_t _pi_event::WaitList

Definition at line 1253 of file pi_level_zero.hpp.

Referenced by cleanup().

◆ ZeCommandList

ze_command_list_handle_t _pi_event::ZeCommandList

◆ ZeEvent

◆ ZeEventPool

ze_event_pool_handle_t _pi_event::ZeEventPool

Definition at line 1208 of file pi_level_zero.hpp.

Referenced by _pi_context::decrementUnreleasedEventsInPool().


The documentation for this struct was generated from the following files: