29 alpaka::concepts::Vector T_NumBlocks,
30 alpaka::concepts::Vector<
typename T_NumBlocks::type, T_NumBlocks::dim()> T_NumThreads,
31 alpaka::concepts::Executor T_Executor = alpaka::exec::AnyExecutor>
44 T_NumBlocks
const& numBlocks,
45 T_NumThreads
const& numThreadsPerBlock,
46 T_Executor executor = T_Executor{})
47 : m_numBlocks(numBlocks)
48 , m_numThreads(numThreadsPerBlock)
50 alpaka::unused(executor);
68 [[nodiscard]]
static consteval uint32_t
dim()
70 return T_NumThreads::dim();
74 template<alpaka::concepts::VectorOrScalar T_NumBlocks, alpaka::concepts::VectorOrScalar T_NumThreads>
82 ThreadSpec(T_NumBlocks
const&, T_NumThreads
const&, T_Executor)
114 template<
typename T,
typename T_IndexType = alpaka::NotRequired, u
int32_t T_dim = alpaka::notRequiredDim>
117 && (std::same_as<T_IndexType, alpaka::NotRequired> || std::same_as<typename T::index_type, T_IndexType>)
123 return s <<
"ThreadSpec{ blocks=" << t.getNumBlocks() <<
", threads=" << t.getNumThreads() <<
" }";
Concept to check for an executor.
Concept to check if a type is a vector or scalar variable.
Concept to check if a type is a vector.
Concept to check if a type is a ThreadSpec.
Functionality which is usable on the host CPU controller thread.
std::ostream & operator<<(std::ostream &s, DeviceProperties const &p)
ThreadSpec(T_NumBlocks const &, T_NumThreads const &) -> ThreadSpec< alpaka::trait::getVec_t< T_NumBlocks >, alpaka::trait::getVec_t< T_NumThreads > >
constexpr bool isThreadSpec_v
typename GetVec< T >::type getVec_t
constexpr uint32_t notRequiredDim
Backend-specific description of the actual block and thread launch shape.
typename T_NumBlocks::UniVec NumBlocksVecType
static constexpr T_Executor getExecutor()
typename T_NumBlocks::type index_type
constexpr NumBlocksVecType const & getNumBlocks() const noexcept
constexpr ThreadSpec(T_NumBlocks const &numBlocks, T_NumThreads const &numThreadsPerBlock, T_Executor executor=T_Executor{})
T_NumThreads NumThreadsVecType
constexpr NumThreadsVecType const & getNumThreads() const noexcept
static consteval uint32_t dim()