Alpaka utilities
Getting an alpaka device
Provides a function to get an alpaka device by its index.
- Authors
Simone Balducci, Felice Pantaleo, Marco Rovere, Wahid Redjeb, Aurora Perego, Francesco Giacomini
-
namespace clue
Functions
-
inline clue::Device get_device(uint32_t device_id)
Get the alpaka device corresponding to a given index.
- Parameters:
- uint32_t device_id
The index of the device
- Returns:
The alpaka device corresponding to the given index
Getting an alpaka queue
Provides functions to get an alpaka queue from a device index or a device object.
- Authors
Simone Balducci, Felice Pantaleo, Marco Rovere, Wahid Redjeb, Aurora Perego, Francesco Giacomini
-
namespace clue
Functions
-
template<std::integral TIdx>
inline clue::Queue get_queue(TIdx device_id = TIdx{})
Get an alpaka queue created from a device correspoding to a given index.
- Template Parameters:
- std::integral TIdx
The type of the device index, must be an integral type
- Parameters:
- TIdx device_id = TIdx{}
The index of the device
- Returns:
An alpaka queue created from the device corresponding to the given index
-
template<concepts::device TDevice>
inline clue::Queue get_queue(const TDevice &device)
Get an alpaka queue created from a given device.
- Template Parameters:
- concepts::device TDevice
The type of the device, must satisfy the concepts::device concept
- Parameters:
- const TDevice &device
The device to create the queue from
- Returns:
An alpaka queue created from the given device