24.02.1
|
OpenCL device type class. More...
#include <CLDevice.h>
Public Member Functions | |
CLDevice () | |
Default Constructor. More... | |
CLDevice (const cl::Device &cl_device) | |
Constructor. More... | |
const GPUTarget & | target () const |
Returns the GPU target of the cl device. More... | |
size_t | compute_units () const |
Returns the number of compute units available. More... | |
const cl::Device & | cl_device () const |
Returns the underlying cl device object. More... | |
CLVersion | version () const |
Returns the device's CL version. More... | |
std::string | device_version () const |
Returns the device version as a string. More... | |
DeviceType | type () const override |
Device type accessor. More... | |
bool | supported (const std::string &extension) const override |
Check if extensions on a device are supported. More... | |
std::tuple< bool, std::string > | is_non_uniform_workgroup_supported () const |
Returns whether non-uniform workgroup is supported and the build options. More... | |
Public Member Functions inherited from IDevice | |
virtual | ~IDevice ()=default |
Virtual Destructor. More... | |
OpenCL device type class.
Initializes and stores all the information about a cl device, working mainly as a cache mechanism.
Definition at line 43 of file CLDevice.h.
|
inline |
Default Constructor.
Definition at line 47 of file CLDevice.h.
|
inline |
Constructor.
[in] | cl_device | OpenCL device |
Definition at line 55 of file CLDevice.h.
References CLDevice::cl_device(), CLDeviceOptions::compute_units, CLDeviceOptions::device_version, CLDeviceOptions::extensions, check_header_guards::extensions, arm_compute::G76, arm_compute::get_cl_version(), arm_compute::get_target_from_name(), CLDeviceOptions::gpu_target, and CLDeviceOptions::version.
|
inline |
Returns the underlying cl device object.
Definition at line 110 of file CLDevice.h.
Referenced by CLDevice::CLDevice(), CLCompileContext::default_ndrange(), CLCompileContext::get_device(), and CLCompileContext::max_local_workgroup_size().
|
inline |
Returns the number of compute units available.
Definition at line 101 of file CLDevice.h.
References CLDeviceOptions::compute_units.
Referenced by CLCompileContext::get_num_compute_units().
|
inline |
Returns the device version as a string.
Definition at line 128 of file CLDevice.h.
References CLDeviceOptions::device_version.
Referenced by CLCompileContext::get_ddk_version(), and CLCompileContext::get_device_version().
|
inline |
Returns whether non-uniform workgroup is supported and the build options.
If the feature is supported, the appropriate build options will be appended to the specified string.
Definition at line 152 of file CLDevice.h.
References arm_compute::CL20, arm_compute::CL30, arm_compute::get_cl_non_uniform_work_group_supported(), CLDevice::supported(), and CLDevice::version().
|
inlineoverridevirtual |
Check if extensions on a device are supported.
[in] | extension | An extension to check if it's supported. |
Implements IDevice.
Definition at line 139 of file CLDevice.h.
References CLDeviceOptions::extensions.
Referenced by CLCompileContext::fp16_supported(), CLCompileContext::int64_base_atomics_supported(), and CLDevice::is_non_uniform_workgroup_supported().
|
inline |
Returns the GPU target of the cl device.
Definition at line 92 of file CLDevice.h.
References CLDeviceOptions::gpu_target.
Referenced by CLCompileContext::get_gpu_target().
|
inlineoverridevirtual |
Device type accessor.
Implements IDevice.
Definition at line 134 of file CLDevice.h.
References arm_compute::CL.
|
inline |
Returns the device's CL version.
Definition at line 119 of file CLDevice.h.
References CLDeviceOptions::version.
Referenced by CLDevice::is_non_uniform_workgroup_supported().