diff options
author | Cedric Nugteren <web@cedricnugteren.nl> | 2017-11-19 20:05:15 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-19 20:05:15 +0100 |
commit | da76d7ab81555452a1049eb1a6d130073427067d (patch) | |
tree | 92439d8bee44c34d63f288a73bdc372ba84dc42b /src/clpp11.hpp | |
parent | c41d219ea42087c1b8d933b733b381005123cb91 (diff) | |
parent | defad3d1a249dd5f8c011cf28cc3c888d710d56a (diff) |
Merge pull request #216 from CNugteren/integrated_tuner
Integrated tuner
Diffstat (limited to 'src/clpp11.hpp')
-rw-r--r-- | src/clpp11.hpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/clpp11.hpp b/src/clpp11.hpp index 82fc44fd..0db64ad9 100644 --- a/src/clpp11.hpp +++ b/src/clpp11.hpp @@ -352,6 +352,13 @@ class Device { std::string{"."} + std::to_string(GetInfo<cl_uint>(CL_DEVICE_COMPUTE_CAPABILITY_MINOR_NV)); } + // Retrieves the above extra information (if present) + std::string GetExtraInfo() const { + if (HasExtension("cl_amd_device_attribute_query")) { return AMDBoardName(); } + if (HasExtension("cl_nv_device_attribute_query")) { return NVIDIAComputeCapability(); } + else { return std::string{""}; } + } + // Accessor to the private data-member const RawDeviceID& operator()() const { return device_; } private: |