DPC++ Runtime
Runtime libraries for oneAPI DPC++
|
|
Go to the documentation of this file.
58 cl_device_id
get()
const;
67 throw invalid_object_error(
"This instance of device is a host instance",
68 PI_ERROR_INVALID_DEVICE);
80 throw invalid_object_error(
"This instance of device is a host instance",
81 PI_ERROR_INVALID_DEVICE);
89 bool is_host()
const {
return MIsHostDevice; }
135 create_sub_devices(
const cl_device_partition_property *Properties,
136 size_t SubDevicesCount)
const;
148 std::vector<device> create_sub_devices(
size_t ComputeUnits)
const;
160 create_sub_devices(
const std::vector<size_t> &Counts)
const;
184 std::vector<device> create_sub_devices()
const;
201 template <
typename Param>
typename Param::return_type
get_info()
const {
203 return get_device_info_host<Param>();
205 return get_device_info<Param>(this->getHandleRef(), this->
getPlugin());
228 bool has(aspect Aspect)
const;
233 static std::shared_ptr<device_impl> getHostDeviceImpl();
235 bool isAssertFailSupported()
const;
239 std::string getDeviceName()
const;
243 uint64_t getCurrentDeviceTime();
253 bool MIsAssertFailSupported =
false;
254 mutable std::string MDeviceName;
255 mutable std::once_flag MDeviceNameFlag;
256 std::pair<uint64_t, uint64_t> MDeviceHostBaseTime;
partition_affinity_domain
bool has_extension(const sycl::platform &SyclPlatform, const std::string &Extension)
std::shared_ptr< detail::platform_impl > PlatformImplPtr
bool is_accelerator() const
Check if device is an accelerator device.
#define __SYCL_INLINE_VER_NAMESPACE(X)
const RT::PiDevice & getHandleRef() const
Get constant reference to PI device.
---— Error handling, matching OpenCL plugin semantics.
const plugin & getPlugin()
::pi_device_type PiDeviceType
constexpr tuple_element< I, tuple< Types... > >::type & get(sycl::detail::tuple< Types... > &Arg) noexcept
The plugin class provides a unified interface to the underlying low-level runtimes for the device-agn...
RT::PiDevice & getHandleRef()
Get reference to PI device.
@ PI_DEVICE_TYPE_GPU
A PI device that is a GPU.
@ PI_DEVICE_TYPE_ACC
A PI device that is a dedicated accelerator.
RT::PiDeviceType get_device_type() const
Return device type.
uintptr_t pi_native_handle
bool is_host() const
Check if SYCL device is a host device.
@ PI_DEVICE_TYPE_CPU
A PI device that is the host processor.
const plugin & getPlugin() const
bool isRootDevice() const
bool is_cpu() const
Check if device is a CPU device.
Param::return_type get_info() const
Queries this SYCL device for information requested by the template parameter param.
bool is_gpu() const
Check if device is a GPU device.