-
Notifications
You must be signed in to change notification settings - Fork 35
Closed
Description
OpenCL-Benchmark/src/opencl.hpp
Line 46 in a036229
| is_fp64_capable = (uint)cl_device.getInfo<CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE>()*(uint)contains(cl_device.getInfo<CL_DEVICE_EXTENSIONS>(), "cl_khr_fp64"); |
Hello,
I've been learning how it works and have some questions about it.
Firstly, I'm not sure about the logic it determines the support for the data types.
I believe CL_DEVICE_NATIVE_VECTOR_WIDTH_* doesn't necessarily reflect the presence of a given type support.
The specification only says,
If double precision is not supported, CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE must return 0.
If the cl_khr_fp16 extension is not supported,CL_DEVICE_NATIVE_VECTOR_WIDTH_HALF must return 0.
Not the other way around.
Checking support for the double/half types only need to query cl_khr_fp64, cl_khr_fp16 extensions respectively.
Also I wonder if the other types need to be checked because they're supposed to be supported as builtin scalar type.
I might be missing something but please have a look and let me know what you think about it.
Metadata
Metadata
Assignees
Labels
No labels