[Mesa-dev] [PATCH 2/8] clover: Add device_clc_version to device.[hc]pp

Aaron Watry awatry at gmail.com
Sun Aug 6 00:26:35 UTC 2017


On Fri, Aug 4, 2017 at 1:14 PM, Jan Vesely <jan.vesely at rutgers.edu> wrote:
> On Sun, 2017-07-30 at 20:26 -0500, Aaron Watry wrote:
>> device_version and device_clc_version are not necessarily the same for
>> devices that support CL 1.0, but have a 1.1 compiler and the necessary
>> extensions.
>>
>> CC: Jan Vesey <jan.vesely at rutgers.edu>
>
> I think you might consider squashing 1/8 and 2/8. squashed or not:
> Reviewed-by: Jan Vesely <jan.vesely at rutgers.edu>

Thanks. I'll squash and push them both.

--Aaron

>
> Jan
>
>> ---
>>  src/gallium/state_trackers/clover/api/device.cpp  | 2 +-
>>  src/gallium/state_trackers/clover/core/device.cpp | 5 +++++
>>  src/gallium/state_trackers/clover/core/device.hpp | 1 +
>>  3 files changed, 7 insertions(+), 1 deletion(-)
>>
>> diff --git a/src/gallium/state_trackers/clover/api/device.cpp b/src/gallium/state_trackers/clover/api/device.cpp
>> index 18ed2f059f..b1b7917e4e 100644
>> --- a/src/gallium/state_trackers/clover/api/device.cpp
>> +++ b/src/gallium/state_trackers/clover/api/device.cpp
>> @@ -368,7 +368,7 @@ clGetDeviceInfo(cl_device_id d_dev, cl_device_info param,
>>        break;
>>
>>     case CL_DEVICE_OPENCL_C_VERSION:
>> -      buf.as_string() = "OpenCL C " + dev.device_version() + " ";
>> +      buf.as_string() = "OpenCL C " + dev.device_clc_version() + " ";
>>        break;
>>
>>     case CL_DEVICE_PRINTF_BUFFER_SIZE:
>> diff --git a/src/gallium/state_trackers/clover/core/device.cpp b/src/gallium/state_trackers/clover/core/device.cpp
>> index 0277495506..68856ae36b 100644
>> --- a/src/gallium/state_trackers/clover/core/device.cpp
>> +++ b/src/gallium/state_trackers/clover/core/device.cpp
>> @@ -245,3 +245,8 @@ std::string
>>  device::device_version() const {
>>      return "1.1";
>>  }
>> +
>> +std::string
>> +device::device_clc_version() const {
>> +    return "1.1";
>> +}
>> diff --git a/src/gallium/state_trackers/clover/core/device.hpp b/src/gallium/state_trackers/clover/core/device.hpp
>> index 3cf7e20be5..efc217aedb 100644
>> --- a/src/gallium/state_trackers/clover/core/device.hpp
>> +++ b/src/gallium/state_trackers/clover/core/device.hpp
>> @@ -75,6 +75,7 @@ namespace clover {
>>        std::string device_name() const;
>>        std::string vendor_name() const;
>>        std::string device_version() const;
>> +      std::string device_clc_version() const;
>>        enum pipe_shader_ir ir_format() const;
>>        std::string ir_target() const;
>>        enum pipe_endian endianness() const;


More information about the mesa-dev mailing list