From 8cfe42ca6a922eaa199781d18850bfbfcd16df4f Mon Sep 17 00:00:00 2001 From: Simon Richter Date: Mon, 13 May 2013 20:21:16 +0200 Subject: [PATCH] Add clGetDeviceInfo(..., CL_BUILT_IN_KERNELS, ...) Currently, there are no built-in kernels, so this function returns an empty string. Reviewed-by: Zhigang Gong --- src/cl_device_id.c | 1 + src/cl_device_id.h | 2 ++ src/cl_gt_device.h | 1 + 3 files changed, 4 insertions(+) diff --git a/src/cl_device_id.c b/src/cl_device_id.c index 6300b41..136f3b1 100644 --- a/src/cl_device_id.c +++ b/src/cl_device_id.c @@ -230,6 +230,7 @@ cl_get_device_info(cl_device_id device, DECL_STRING_FIELD(PROFILE, profile) DECL_STRING_FIELD(OPENCL_C_VERSION, opencl_c_version) DECL_STRING_FIELD(EXTENSIONS, extensions); + DECL_STRING_FIELD(BUILT_IN_KERNELS, built_in_kernels) case CL_DRIVER_VERSION: if (param_value_size_ret) { diff --git a/src/cl_device_id.h b/src/cl_device_id.h index d199ecb..0608047 100644 --- a/src/cl_device_id.h +++ b/src/cl_device_id.h @@ -84,6 +84,7 @@ struct _cl_device_id { const char *opencl_c_version; const char *extensions; const char *driver_version; + const char *built_in_kernels; size_t name_sz; size_t vendor_sz; size_t version_sz; @@ -91,6 +92,7 @@ struct _cl_device_id { size_t opencl_c_version_sz; size_t extensions_sz; size_t driver_version_sz; + size_t built_in_kernels_sz; /* Kernel specific info that we're assigning statically */ size_t wg_sz; size_t compile_wg_sz[3]; diff --git a/src/cl_gt_device.h b/src/cl_gt_device.h index f26cd8a..a535452 100644 --- a/src/cl_gt_device.h +++ b/src/cl_gt_device.h @@ -72,6 +72,7 @@ DECL_INFO_STRING(version, OCL_VERSION_STRING) DECL_INFO_STRING(profile, "FULL_PROFILE") DECL_INFO_STRING(opencl_c_version, "OpenCL 1.10") DECL_INFO_STRING(extensions, "") +DECL_INFO_STRING(built_in_kernels, "") DECL_INFO_STRING(driver_version, LIBCL_VERSION_STRING) #undef DECL_INFO_STRING -- 2.7.4