OmniSciDB  d2f719934e
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
l0::L0CommandList Class Reference

#include <L0Mgr.h>

Public Member Functions

void copy (void *dst, const void *src, const size_t num_bytes)
 
template<typename... Args>
void launch (L0Kernel &kernel, Args &&...args)
 
void submit (L0CommandQueue &queue)
 

Detailed Description

Definition at line 144 of file L0Mgr.h.

Member Function Documentation

void l0::L0CommandList::copy ( void *  dst,
const void *  src,
const size_t  num_bytes 
)

Definition at line 99 of file L0Mgr.cpp.

References L0_SAFE_CALL.

99  {
100  L0_SAFE_CALL(
101  zeCommandListAppendMemoryCopy(handle_, dst, src, num_bytes, nullptr, 0, nullptr));
102  L0_SAFE_CALL(zeCommandListAppendBarrier(handle_, nullptr, 0, nullptr));
103 }
#define L0_SAFE_CALL(call)
Definition: Utils.h:19
template<typename... Args>
void l0::L0CommandList::launch ( L0Kernel kernel,
Args &&...  args 
)
inline

Definition at line 154 of file L0Mgr.h.

References run_benchmark_import::args, and L0_SAFE_CALL.

154  {
155 #ifdef HAVE_L0
156  set_kernel_args<0>(kernel.handle(), std::forward<Args>(args)...);
157 
158  L0_SAFE_CALL(zeCommandListAppendLaunchKernel(
159  handle_, kernel.handle(), &kernel.group_size(), nullptr, 0, nullptr));
160 
161  L0_SAFE_CALL(zeCommandListAppendBarrier(handle_, nullptr, 0, nullptr));
162 #endif
163  }
#define L0_SAFE_CALL(call)
Definition: Utils.h:19
void l0::L0CommandList::submit ( L0CommandQueue queue)

Definition at line 84 of file L0Mgr.cpp.

References L0_SAFE_CALL.

84  {
85  L0_SAFE_CALL(zeCommandListClose(handle_));
86  L0_SAFE_CALL(zeCommandQueueExecuteCommandLists(queue.handle(), 1, &handle_, nullptr));
88  zeCommandQueueSynchronize(queue.handle(), std::numeric_limits<uint32_t>::max()));
89 }
#define L0_SAFE_CALL(call)
Definition: Utils.h:19

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