A handle to one SYCL device: its type and its index among devices of that type.
Definition at line 179 of file sycl-device-queue.hh.
#include <batchlas/util/sycl-device-queue.hh>
|
default |
The host device (index 0).
|
inline |
The idx-th device of type, as numbered by get_devices().
Definition at line 187 of file sycl-device-queue.hh.
|
inline |
The first device of the named type.
| type | "cpu", "gpu" or "accelerator" (case-insensitive) |
| batchlas::device_error | if no device of that type exists |
| batchlas::invalid_argument | for any other string |
Definition at line 193 of file sycl-device-queue.hh.
|
inline |
Definition at line 211 of file sycl-device-queue.hh.
|
static |
Every device of type, in the SYCL runtime's order.
|
inlinestatic |
The first GPU, else the first CPU, else the host device.
Definition at line 214 of file sycl-device-queue.hh.
|
inlinestatic |
default_device(), except the first CPU device for a double or complex<double> T when that default is a GPU without fp64 (an Apple GPU), which cannot run T kernels.
Definition at line 227 of file sycl-device-queue.hh.
| std::string batchlas::Device::get_name | ( | ) | const |
The device's name as reported by SYCL.
| Vendor batchlas::Device::get_vendor | ( | ) | const |
The device's vendor.
| size_t batchlas::Device::get_property | ( | DeviceProperty | property | ) | const |
The value of one device property (units as documented on DeviceProperty).
| bool batchlas::Device::supports_sub_group_size | ( | size_t | size | ) | const |
True when size is one of the device's supported sub-group sizes.
| int batchlas::Device::cuda_compute_capability | ( | ) | const |
CUDA compute capability as major*10+minor (89 = sm_89, 120 = sm_120), or 0 for a non-CUDA device.
Memoized per device. Kernel selection derives its device key from it (sm_89), which picks the per-device table in tuned/.
| bool batchlas::Device::supports_fp64 | ( | ) | const |
True when the device runs double-precision kernels (sycl::aspect::fp64).
Memoized per device. False on Apple GPUs, where a Backend::SYCL build without BATCHLAS_HAS_DEVICE_FP64 has no double or complex<double> kernels.
| size_t batchlas::Device::idx = 0 |
Index among devices of type.
Definition at line 263 of file sycl-device-queue.hh.
| DeviceType batchlas::Device::type = DeviceType::HOST |
The device's type.
Definition at line 264 of file sycl-device-queue.hh.