Template Function ripple::thread_idx¶
Function Documentation¶
-
template<typename
Dim
>
autoripple
::
thread_idx
(Dim &&dim) noexcept -> size_t¶ Gets the value of the thread index int he block in the given dimension.
The dimension must be one of dim_x, dim_y, dim_z, or a value specifting the index of the dimension.
- Note
This index is local to the execution device, if multiple devices are used, the same thread index may be on both devices.
- Return
The index of the thread in the given dimension for the block its in.
- Parameters
dim
: the dimension to get the thread index for.
- Template Parameters
Dim
: the type of the dimension specifier.