OmniSciDB  c0231cc57d
 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 145 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:20
template<typename... Args>
void l0::L0CommandList::launch ( L0Kernel kernel,
Args &&...  args 
)
inline

Definition at line 155 of file L0Mgr.h.

References run_benchmark_import::args, and L0_SAFE_CALL.

155  {
156 #ifdef HAVE_L0
157  set_kernel_args<0>(kernel.handle(), std::forward<Args>(args)...);
158 
159  L0_SAFE_CALL(zeCommandListAppendLaunchKernel(
160  handle_, kernel.handle(), &kernel.group_size(), nullptr, 0, nullptr));
161 
162  L0_SAFE_CALL(zeCommandListAppendBarrier(handle_, nullptr, 0, nullptr));
163 #endif
164  }
#define L0_SAFE_CALL(call)
Definition: Utils.h:20
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:20

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