30 template<alpaka::concepts::Api T_Api, alpaka::concepts::DeviceKind T_DeviceKind>
37 *std::declval<PlatformHandle>().get(),
52 template<
typename T_Device>
75 return this->
get() == other.
get();
80 return this->
get() != other.
get();
143 return T_DeviceKind{};
160 template<
typename T_Device>
164 template<
typename T_Device>
179 template<
typename T_Type>
182 Vec const extentsVec = extents;
200 template<
typename T_Type>
203 Vec const extentsVec = extents;
222 template<
typename T_Type,
typename T_Device, alpaka::concepts::QueueKind T_QueueKind>
227 Vec const extentsVec = extents;
228 return internal::AllocUnified::
229 Op<T_Type, std::decay_t<
decltype(*queue.getDevice().
get())>,
ALPAKA_TYPEOF(extentsVec)>{}(
230 *queue.getDevice().
get(),
244 template<
typename T_Type>
247 Vec const extentsVec = extents;
263 template<
typename T_Type,
typename T_Device, alpaka::concepts::QueueKind T_QueueKind>
312 template<
typename T_Device, alpaka::concepts::QueueKind T_QueueKind>
316 *queue.getDevice().
get(),
329 template<
typename T_Api, alpaka::concepts::DeviceKind T_DeviceKind>
355 template<
typename T_DataType,
typename T_Api, alpaka::concepts::DeviceKind T_DeviceKind>
#define ALPAKA_TYPEOF(...)
Get the type of instance.
Concept to check for APIs.
Concept to check for an executor.
Interface concept for objects describing api-related multidimensional memory access.
Concept to check if a type is a queue kind.
Validates if T is a specialization of the unspecialized template type U.
Concept to check if a type is a vector or scalar variable.
Concept to check if something is a device.
Concept to check if a type is a FrameSpec.
constexpr AnyExecutor anyExecutor
Automatic executor selection.
constexpr auto getDeviceKind(auto &&any) -> decltype(GetDeviceType::Op< ALPAKA_TYPEOF(any)>{}(any))
constexpr auto getApi(auto &&any) -> decltype(GetApi::Op< ALPAKA_TYPEOF(any)>{}(any))
constexpr auto getSimdFrameSpec(auto const &internalDevice, alpaka::concepts::Executor auto executor, alpaka::concepts::VectorOrScalar auto const &extents)
Provides a SIMD optimized frame specification.
static auto makePlatform(auto api, alpaka::concepts::DeviceKind auto deviceType)
auto getNativeHandle(auto &&any)
constexpr auto getFrameSpec(auto const &internalDevice, alpaka::concepts::Executor auto executor, alpaka::concepts::VectorOrScalar auto const &extents)
Provide a frame specification for the given extents.
auto getExtents(auto &&any)
Functionality which is usable on the host CPU controller thread.
bool isDataAccessible(concepts::Device auto const &device, alpaka::concepts::IView auto const &view)
Check if the given view is accessible on the given device.
constexpr auto defaultExecutor(internal::concepts::DeviceHandle auto deviceHandle)
Select a default executor for the given device.
constexpr concepts::FrameSpec auto getSimdFrameSpec(Device< T_Api, T_DeviceKind > const &device, alpaka::concepts::Executor auto executor, alpaka::concepts::VectorOrScalar auto const &extents)
Provides a frame specification to operate on a given index range.
std::shared_ptr< T > Handle
auto allocUnified(concepts::Device auto const &device, alpaka::concepts::VectorOrScalar auto const &extents)
Allocate memory on the given device with unified virtual memory.
constexpr concepts::FrameSpec auto getFrameSpec(Device< T_Api, T_DeviceKind > const &device, alpaka::concepts::Executor auto executor, alpaka::concepts::VectorOrScalar auto const &extents)
Provides a frame specification to operate on a given index range.
auto allocLike(concepts::Device auto const &device, auto const &view)
Allocate memory on the given device based on a view.
Device(Handle< T_Device > &&) -> Device< ALPAKA_TYPEOF(alpaka::internal::getApi(std::declval< T_Device >())), ALPAKA_TYPEOF(alpaka::internal::getDeviceKind(std::declval< T_Device >()))>
auto allocMapped(concepts::Device auto const &device, alpaka::concepts::VectorOrScalar auto const &extents)
Allocate pinned memory on the host which is mapped into the address space of the device.
auto alloc(concepts::Device auto const &device, alpaka::concepts::VectorOrScalar auto const &extents)
Allocate memory on the given device.
constexpr auto nonBlocking
typename GetValueType< T >::type GetValueType_t
constexpr decltype(auto) getDeviceKind(auto &&any)
Get the device type of an object.
constexpr decltype(auto) getApi(auto &&any)
Get the API an object depends on.
constexpr decltype(auto) get(concepts::SpecializationOf< Dict > auto &t) noexcept
Description of a specific device that one can schedule kernels on.
ALPAKA_TYPEOF(internal::makePlatform(T_Api{}, T_DeviceKind{})) PlatformHandle
bool operator!=(Device const &other) const
bool operator==(Device const &other) const
auto makeQueue(alpaka::concepts::QueueKind auto kind)
Create a queue for this device.
constexpr auto getDeviceKind() const
auto getNativeHandle() const
void wait()
Blocks the caller until the given handle executes all work.
constexpr alpaka::concepts::Api auto getApi() const
size_t getFreeGlobalMemBytes() const
Device(Handle< T_Device > &&internalDeviceHandle)
std::string getName() const
ALPAKA_TYPEOF( internal::MakeDevice::Op< typename PlatformHandle::element_type >{}( *std::declval< PlatformHandle >().get(), 0u)) DeviceHandle
typename DeviceHandle::element_type element_type
DeviceProperties getDeviceProperties() const
Properties of a given device.