18 template<
typename TDim,
typename TIdx>
26 template<
typename TGr
idBlockExtent,
typename TBlockThreadExtent,
typename TThreadElemExtent>
28 TGridBlockExtent
const& gridBlockExtent = TGridBlockExtent(),
29 TBlockThreadExtent
const& blockThreadExtent = TBlockThreadExtent(),
30 TThreadElemExtent
const& threadElemExtent = TThreadElemExtent())
58 template<
typename TWorkDiv>
71 template<
typename TWorkDiv>
82 return a.m_gridBlockExtent == b.m_gridBlockExtent && a.m_blockThreadExtent == b.m_blockThreadExtent
83 && a.m_threadElemExtent == b.m_threadElemExtent;
88 return os <<
"{gridBlockExtent: " << workDiv.m_gridBlockExtent
89 <<
", blockThreadExtent: " << workDiv.m_blockThreadExtent
90 <<
", threadElemExtent: " << workDiv.m_threadElemExtent <<
"}";
101 template<
typename TDim,
typename TIdx>
110 template<
typename TDim,
typename TIdx>
117 template<
typename TDim,
typename TIdx>
124 template<
typename TDim,
typename TIdx>
131 return workDiv.m_gridBlockExtent;
136 template<
typename TDim,
typename TIdx>
143 return workDiv.m_blockThreadExtent;
148 template<
typename TDim,
typename TIdx>
155 return workDiv.m_threadElemExtent;
A basic class holding the work division as grid block extent, block thread and thread element extent.
ALPAKA_FN_HOST friend auto operator<<(std::ostream &os, WorkDivMembers const &workDiv) -> std::ostream &
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC auto operator=(TWorkDiv const &other) -> WorkDivMembers< TDim, TIdx > &
auto operator=(WorkDivMembers &&) -> WorkDivMembers &=default
ALPAKA_FN_HOST_ACC WorkDivMembers()=delete
Vec< TDim, TIdx > m_blockThreadExtent
Vec< TDim, TIdx > m_gridBlockExtent
Vec< TDim, TIdx > m_threadElemExtent
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC WorkDivMembers(TWorkDiv const &other)
ALPAKA_FN_HOST_ACC constexpr friend auto operator==(WorkDivMembers const &a, WorkDivMembers const &b) -> bool
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC WorkDivMembers(alpaka::Vec< TDim, TIdx > const &gridBlockExtent, alpaka::Vec< TDim, TIdx > const &blockThreadExtent, alpaka::Vec< TDim, TIdx > const &elemExtent)
Accepts single specific type and is called without explicit template parameters.
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC WorkDivMembers(TGridBlockExtent const &gridBlockExtent=TGridBlockExtent(), TBlockThreadExtent const &blockThreadExtent=TBlockThreadExtent(), TThreadElemExtent const &threadElemExtent=TThreadElemExtent())
Accepts different alpaka vector types and takes the last TDim number of items.
auto operator=(WorkDivMembers const &) -> WorkDivMembers &=default
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC WorkDivMembers(WorkDivMembers const &other)
WorkDivMembers(WorkDivMembers &&)=default
#define ALPAKA_FN_HOST_ACC
#define ALPAKA_NO_HOST_ACC_WARNING
Disable nvcc warning: 'calling a host function from host device function.' Usage: ALPAKA_NO_HOST_ACC_...
The alpaka accelerator library.
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC auto getWorkDiv(TWorkDiv const &workDiv) -> Vec< Dim< TWorkDiv >, Idx< TWorkDiv >>
Get the extent requested.
ALPAKA_NO_HOST_ACC_WARNING ALPAKA_FN_HOST_ACC WorkDivMembers(alpaka::Vec< TDim, TIdx > const &gridBlockExtent, alpaka::Vec< TDim, TIdx > const &blockThreadExtent, alpaka::Vec< TDim, TIdx > const &elemExtent) -> WorkDivMembers< TDim, TIdx >
Deduction guide for the constructor which can be called without explicit template type parameters.
ALPAKA_NO_HOST_ACC_WARNING constexpr ALPAKA_FN_HOST_ACC auto subVecEnd(TVec const &vec)
ALPAKA_NO_HOST_ACC_WARNING constexpr ALPAKA_FN_HOST_ACC auto getExtentVecEnd(T const &object={}) -> Vec< TDim, Idx< T >>
Tag used in class inheritance hierarchies that describes that a specific interface (TInterface) is im...
The dimension getter type trait.
ALPAKA_NO_HOST_ACC_WARNING static ALPAKA_FN_HOST_ACC auto getWorkDiv(WorkDivMembers< TDim, TIdx > const &workDiv) -> Vec< TDim, TIdx >
ALPAKA_NO_HOST_ACC_WARNING static ALPAKA_FN_HOST_ACC auto getWorkDiv(WorkDivMembers< TDim, TIdx > const &workDiv) -> Vec< TDim, TIdx >
ALPAKA_NO_HOST_ACC_WARNING static ALPAKA_FN_HOST_ACC auto getWorkDiv(WorkDivMembers< TDim, TIdx > const &workDiv) -> Vec< TDim, TIdx >