12 #include <type_traits>
22 template<
typename TPlatform>
29 template<
typename T,
typename TSfinae =
void>
32 template<
typename TPlatform>
35 std::enable_if_t<interface::ImplementsInterface<ConceptPlatform, TPlatform>::value>>
41 template<
typename T,
typename TSfinae =
void>
45 template<
typename T,
typename TSfinae =
void>
54 template<
typename TPlatform>
61 template<
typename TPlatform>
68 template<
typename TPlatform>
71 std::vector<Dev<TPlatform>> devs;
74 devs.reserve(devCount);
75 for(std::size_t devIdx(0); devIdx < devCount; ++devIdx)
85 template<
typename TPlatform,
typename TProperty>
89 std::enable_if_t<interface::ImplementsInterface<ConceptPlatform, TPlatform>::value>>
typename detail::ImplementationBaseType< TInterface, TDerived >::type ImplementationBase
Returns the type that implements the given interface in the inheritance hierarchy.
The alpaka accelerator library.
typename trait::DevType< T >::type Dev
The device type trait alias template to remove the ::type.
ALPAKA_FN_HOST auto getDevCount(TPlatform const &platform)
constexpr bool isPlatform
True if TPlatform is a platform, i.e. if it implements the ConceptPlatform concept.
ALPAKA_FN_HOST auto getDevByIdx(TPlatform const &platform, std::size_t const &devIdx) -> Dev< TPlatform >
ALPAKA_FN_HOST auto getDevs(TPlatform const &platform) -> std::vector< Dev< TPlatform >>
typename trait::PlatformType< T >::type Platform
The platform type trait alias template to remove the ::type.
Checks whether the interface is implemented by the given class.
The device count get trait.
Queue for an accelerator.