Kernel execution dimensions. More...
#include <kernel.hpp>
Classes | |
| struct | dimension |
Public Member Functions | |
| dimension & | operator[] (std::size_t idx) |
Kernel execution dimensions.
This structure offers an alternative way to set and reuse kernel execution dimensions.
Example:
{.cpp}
// Create work_size object
hpx::opencl::work_size<1> dim;
// Set dimensions.
dim[0].offset = 0;
dim[0].size = 2048;
// Set local work size.
// This can be left out.
// OpenCL will then automatically determine the best local work size.
dim[0].local_size = 64;
// Enqueue a kernel using the work_size object
event kernel_event = kernel.enqueue(dim).get();
1.7.6.1