Celeritas
0.5.0-56+6b053cd
|
#include <cstddef>
#include <type_traits>
#include "corecel/Config.hh"
#include "corecel/Assert.hh"
#include "corecel/Macros.hh"
#include "Device.hh"
Classes | |
struct | celeritas::KernelAttributes |
Immutable attributes of a kernel function. More... | |
Functions | |
template<class F > | |
KernelAttributes | celeritas::make_kernel_attributes (F *func, unsigned int threads_per_block=0) |
Build kernel attributes from a global kernel function. More... | |
KernelAttributes celeritas::make_kernel_attributes | ( | F * | func, |
unsigned int | threads_per_block = 0 |
||
) |
Build kernel attributes from a global kernel function.
This can only be called from CUDA/HIP code. It assumes that the block size is constant across the execution of the program and that the kernel is only called by the device that's active at this time.
The special value of zero threads per block causes the kernel attributes to default to the compile-time maximum number of threads per block as specified by launch bounds.