Sheri Zhang | 67354e0 | 2021-06-30 16:08:29 +0100 | [diff] [blame] | 1 | /******************************************************************************* |
| 2 | * Copyright (c) 2019 The Khronos Group Inc. |
| 3 | * |
| 4 | * Permission is hereby granted, free of charge, to any person obtaining a |
| 5 | * copy of this software and/or associated documentation files (the |
| 6 | * "Materials"), to deal in the Materials without restriction, including |
| 7 | * without limitation the rights to use, copy, modify, merge, publish, |
| 8 | * distribute, sublicense, and/or sell copies of the Materials, and to |
| 9 | * permit persons to whom the Materials are furnished to do so, subject to |
| 10 | * the following conditions: |
| 11 | * |
| 12 | * The above copyright notice and this permission notice shall be included |
| 13 | * in all copies or substantial portions of the Materials. |
| 14 | * |
| 15 | * MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS |
| 16 | * KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS |
| 17 | * SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT |
| 18 | * https://www.khronos.org/registry/ |
| 19 | * |
| 20 | * THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, |
| 21 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF |
| 22 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. |
| 23 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY |
| 24 | * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, |
| 25 | * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE |
| 26 | * MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. |
| 27 | ******************************************************************************/ |
| 28 | |
| 29 | #ifndef OPENCL_CL_ICD_H |
| 30 | #define OPENCL_CL_ICD_H |
| 31 | |
| 32 | #include <CL/cl.h> |
| 33 | #include <CL/cl_egl.h> |
| 34 | #include <CL/cl_ext.h> |
| 35 | #include <CL/cl_gl.h> |
| 36 | |
| 37 | #ifdef __cplusplus |
| 38 | extern "C" { |
| 39 | #endif |
| 40 | |
| 41 | /* |
| 42 | * This file contains pointer type definitions for each of the CL API calls as |
| 43 | * well as a type definition for the dispatch table used by the Khronos ICD |
| 44 | * loader (see cl_khr_icd extension specification for background). |
| 45 | */ |
| 46 | |
| 47 | /* API function pointer definitions */ |
| 48 | |
| 49 | // Platform APIs |
| 50 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetPlatformIDs)( |
| 51 | cl_uint num_entries, cl_platform_id *platforms, |
| 52 | cl_uint *num_platforms) CL_API_SUFFIX__VERSION_1_0; |
| 53 | |
| 54 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetPlatformInfo)( |
| 55 | cl_platform_id platform, cl_platform_info param_name, |
| 56 | size_t param_value_size, void *param_value, |
| 57 | size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 58 | |
| 59 | // Device APIs |
| 60 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetDeviceIDs)( |
| 61 | cl_platform_id platform, cl_device_type device_type, cl_uint num_entries, |
| 62 | cl_device_id *devices, cl_uint *num_devices) CL_API_SUFFIX__VERSION_1_0; |
| 63 | |
| 64 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetDeviceInfo)( |
| 65 | cl_device_id device, cl_device_info param_name, size_t param_value_size, |
| 66 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 67 | |
| 68 | #ifdef CL_VERSION_1_2 |
| 69 | |
| 70 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clCreateSubDevices)( |
| 71 | cl_device_id in_device, |
| 72 | const cl_device_partition_property *partition_properties, |
| 73 | cl_uint num_entries, cl_device_id *out_devices, cl_uint *num_devices); |
| 74 | |
| 75 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainDevice)( |
| 76 | cl_device_id device) CL_API_SUFFIX__VERSION_1_2; |
| 77 | |
| 78 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseDevice)( |
| 79 | cl_device_id device) CL_API_SUFFIX__VERSION_1_2; |
| 80 | |
| 81 | #else |
| 82 | |
| 83 | typedef void *cl_api_clCreateSubDevices; |
| 84 | typedef void *cl_api_clRetainDevice; |
| 85 | typedef void *cl_api_clReleaseDevice; |
| 86 | |
| 87 | #endif |
| 88 | |
| 89 | // Context APIs |
| 90 | typedef CL_API_ENTRY cl_context(CL_API_CALL *cl_api_clCreateContext)( |
| 91 | const cl_context_properties *properties, cl_uint num_devices, |
| 92 | const cl_device_id *devices, |
| 93 | void(CL_CALLBACK *pfn_notify)(const char *, const void *, size_t, void *), |
| 94 | void *user_data, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 95 | |
| 96 | typedef CL_API_ENTRY cl_context(CL_API_CALL *cl_api_clCreateContextFromType)( |
| 97 | const cl_context_properties *properties, cl_device_type device_type, |
| 98 | void(CL_CALLBACK *pfn_notify)(const char *, const void *, size_t, void *), |
| 99 | void *user_data, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 100 | |
| 101 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainContext)( |
| 102 | cl_context context) CL_API_SUFFIX__VERSION_1_0; |
| 103 | |
| 104 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseContext)( |
| 105 | cl_context context) CL_API_SUFFIX__VERSION_1_0; |
| 106 | |
| 107 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetContextInfo)( |
| 108 | cl_context context, cl_context_info param_name, size_t param_value_size, |
| 109 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 110 | |
| 111 | // Command Queue APIs |
| 112 | typedef CL_API_ENTRY cl_command_queue(CL_API_CALL *cl_api_clCreateCommandQueue)( |
| 113 | cl_context context, cl_device_id device, |
| 114 | cl_command_queue_properties properties, |
| 115 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 116 | |
| 117 | #ifdef CL_VERSION_2_0 |
| 118 | |
| 119 | typedef CL_API_ENTRY |
| 120 | cl_command_queue(CL_API_CALL *cl_api_clCreateCommandQueueWithProperties)( |
| 121 | cl_context /* context */, cl_device_id /* device */, |
| 122 | const cl_queue_properties * /* properties */, |
| 123 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_2_0; |
| 124 | |
| 125 | #else |
| 126 | |
| 127 | typedef void *cl_api_clCreateCommandQueueWithProperties; |
| 128 | |
| 129 | #endif |
| 130 | |
| 131 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainCommandQueue)( |
| 132 | cl_command_queue command_queue) CL_API_SUFFIX__VERSION_1_0; |
| 133 | |
| 134 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseCommandQueue)( |
| 135 | cl_command_queue command_queue) CL_API_SUFFIX__VERSION_1_0; |
| 136 | |
| 137 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetCommandQueueInfo)( |
| 138 | cl_command_queue command_queue, cl_command_queue_info param_name, |
| 139 | size_t param_value_size, void *param_value, |
| 140 | size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 141 | |
| 142 | // Memory Object APIs |
| 143 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateBuffer)( |
| 144 | cl_context context, cl_mem_flags flags, size_t size, void *host_ptr, |
| 145 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 146 | |
| 147 | #ifdef CL_VERSION_1_2 |
| 148 | |
| 149 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateImage)( |
| 150 | cl_context context, cl_mem_flags flags, const cl_image_format *image_format, |
| 151 | const cl_image_desc *image_desc, void *host_ptr, |
| 152 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 153 | |
| 154 | #else |
| 155 | |
| 156 | typedef void *cl_api_clCreateImage; |
| 157 | |
| 158 | #endif |
| 159 | |
| 160 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainMemObject)( |
| 161 | cl_mem memobj) CL_API_SUFFIX__VERSION_1_0; |
| 162 | |
| 163 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseMemObject)( |
| 164 | cl_mem memobj) CL_API_SUFFIX__VERSION_1_0; |
| 165 | |
| 166 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetSupportedImageFormats)( |
| 167 | cl_context context, cl_mem_flags flags, cl_mem_object_type image_type, |
| 168 | cl_uint num_entries, cl_image_format *image_formats, |
| 169 | cl_uint *num_image_formats) CL_API_SUFFIX__VERSION_1_0; |
| 170 | |
| 171 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetMemObjectInfo)( |
| 172 | cl_mem memobj, cl_mem_info param_name, size_t param_value_size, |
| 173 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 174 | |
| 175 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetImageInfo)( |
| 176 | cl_mem image, cl_image_info param_name, size_t param_value_size, |
| 177 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 178 | |
| 179 | #ifdef CL_VERSION_2_0 |
| 180 | |
| 181 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreatePipe)( |
| 182 | cl_context /* context */, cl_mem_flags /* flags */, |
| 183 | cl_uint /* pipe_packet_size */, cl_uint /* pipe_max_packets */, |
| 184 | const cl_pipe_properties * /* properties */, |
| 185 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_2_0; |
| 186 | |
| 187 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetPipeInfo)( |
| 188 | cl_mem /* pipe */, cl_pipe_info /* param_name */, |
| 189 | size_t /* param_value_size */, void * /* param_value */, |
| 190 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_2_0; |
| 191 | |
| 192 | typedef CL_API_ENTRY void *(CL_API_CALL *cl_api_clSVMAlloc)( |
| 193 | cl_context /* context */, cl_svm_mem_flags /* flags */, size_t /* size */, |
| 194 | unsigned int /* alignment */)CL_API_SUFFIX__VERSION_2_0; |
| 195 | |
| 196 | typedef CL_API_ENTRY void(CL_API_CALL *cl_api_clSVMFree)( |
| 197 | cl_context /* context */, |
| 198 | void * /* svm_pointer */) CL_API_SUFFIX__VERSION_2_0; |
| 199 | |
| 200 | #else |
| 201 | |
| 202 | typedef void *cl_api_clCreatePipe; |
| 203 | typedef void *cl_api_clGetPipeInfo; |
| 204 | typedef void *cl_api_clSVMAlloc; |
| 205 | typedef void *cl_api_clSVMFree; |
| 206 | |
| 207 | #endif |
| 208 | |
| 209 | // Sampler APIs |
| 210 | typedef CL_API_ENTRY cl_sampler(CL_API_CALL *cl_api_clCreateSampler)( |
| 211 | cl_context context, cl_bool normalized_coords, |
| 212 | cl_addressing_mode addressing_mode, cl_filter_mode filter_mode, |
| 213 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 214 | |
| 215 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainSampler)( |
| 216 | cl_sampler sampler) CL_API_SUFFIX__VERSION_1_0; |
| 217 | |
| 218 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseSampler)( |
| 219 | cl_sampler sampler) CL_API_SUFFIX__VERSION_1_0; |
| 220 | |
| 221 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetSamplerInfo)( |
| 222 | cl_sampler sampler, cl_sampler_info param_name, size_t param_value_size, |
| 223 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 224 | |
| 225 | #ifdef CL_VERSION_2_0 |
| 226 | |
| 227 | typedef CL_API_ENTRY |
| 228 | cl_sampler(CL_API_CALL *cl_api_clCreateSamplerWithProperties)( |
| 229 | cl_context /* context */, |
| 230 | const cl_sampler_properties * /* sampler_properties */, |
| 231 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_2_0; |
| 232 | |
| 233 | #else |
| 234 | |
| 235 | typedef void *cl_api_clCreateSamplerWithProperties; |
| 236 | |
| 237 | #endif |
| 238 | |
| 239 | // Program Object APIs |
| 240 | typedef CL_API_ENTRY cl_program(CL_API_CALL *cl_api_clCreateProgramWithSource)( |
| 241 | cl_context context, cl_uint count, const char **strings, |
| 242 | const size_t *lengths, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 243 | |
| 244 | typedef CL_API_ENTRY cl_program(CL_API_CALL *cl_api_clCreateProgramWithBinary)( |
| 245 | cl_context context, cl_uint num_devices, const cl_device_id *device_list, |
| 246 | const size_t *lengths, const unsigned char **binaries, |
| 247 | cl_int *binary_status, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 248 | |
| 249 | #ifdef CL_VERSION_1_2 |
| 250 | |
| 251 | typedef CL_API_ENTRY |
| 252 | cl_program(CL_API_CALL *cl_api_clCreateProgramWithBuiltInKernels)( |
| 253 | cl_context context, cl_uint num_devices, const cl_device_id *device_list, |
| 254 | const char *kernel_names, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 255 | |
| 256 | #else |
| 257 | |
| 258 | typedef void *cl_api_clCreateProgramWithBuiltInKernels; |
| 259 | |
| 260 | #endif |
| 261 | |
| 262 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainProgram)( |
| 263 | cl_program program) CL_API_SUFFIX__VERSION_1_0; |
| 264 | |
| 265 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseProgram)( |
| 266 | cl_program program) CL_API_SUFFIX__VERSION_1_0; |
| 267 | |
| 268 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clBuildProgram)( |
| 269 | cl_program program, cl_uint num_devices, const cl_device_id *device_list, |
| 270 | const char *options, |
| 271 | void(CL_CALLBACK *pfn_notify)(cl_program program, void *user_data), |
| 272 | void *user_data) CL_API_SUFFIX__VERSION_1_0; |
| 273 | |
| 274 | #ifdef CL_VERSION_1_2 |
| 275 | |
| 276 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clCompileProgram)( |
| 277 | cl_program program, cl_uint num_devices, const cl_device_id *device_list, |
| 278 | const char *options, cl_uint num_input_headers, |
| 279 | const cl_program *input_headers, const char **header_include_names, |
| 280 | void(CL_CALLBACK *pfn_notify)(cl_program program, void *user_data), |
| 281 | void *user_data) CL_API_SUFFIX__VERSION_1_2; |
| 282 | |
| 283 | typedef CL_API_ENTRY cl_program(CL_API_CALL *cl_api_clLinkProgram)( |
| 284 | cl_context context, cl_uint num_devices, const cl_device_id *device_list, |
| 285 | const char *options, cl_uint num_input_programs, |
| 286 | const cl_program *input_programs, |
| 287 | void(CL_CALLBACK *pfn_notify)(cl_program program, void *user_data), |
| 288 | void *user_data, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 289 | |
| 290 | #else |
| 291 | |
| 292 | typedef void *cl_api_clCompileProgram; |
| 293 | typedef void *cl_api_clLinkProgram; |
| 294 | |
| 295 | #endif |
| 296 | |
| 297 | #ifdef CL_VERSION_2_2 |
| 298 | |
| 299 | typedef CL_API_ENTRY |
| 300 | cl_int(CL_API_CALL *cl_api_clSetProgramSpecializationConstant)( |
| 301 | cl_program program, cl_uint spec_id, size_t spec_size, |
| 302 | const void *spec_value) CL_API_SUFFIX__VERSION_2_2; |
| 303 | |
| 304 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetProgramReleaseCallback)( |
| 305 | cl_program program, |
| 306 | void(CL_CALLBACK *pfn_notify)(cl_program program, void *user_data), |
| 307 | void *user_data) CL_API_SUFFIX__VERSION_2_2; |
| 308 | |
| 309 | #else |
| 310 | |
| 311 | typedef void *cl_api_clSetProgramSpecializationConstant; |
| 312 | typedef void *cl_api_clSetProgramReleaseCallback; |
| 313 | |
| 314 | #endif |
| 315 | |
| 316 | #ifdef CL_VERSION_1_2 |
| 317 | |
| 318 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clUnloadPlatformCompiler)( |
| 319 | cl_platform_id platform) CL_API_SUFFIX__VERSION_1_2; |
| 320 | |
| 321 | #else |
| 322 | |
| 323 | typedef void *cl_api_clUnloadPlatformCompiler; |
| 324 | |
| 325 | #endif |
| 326 | |
| 327 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetProgramInfo)( |
| 328 | cl_program program, cl_program_info param_name, size_t param_value_size, |
| 329 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 330 | |
| 331 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetProgramBuildInfo)( |
| 332 | cl_program program, cl_device_id device, cl_program_build_info param_name, |
| 333 | size_t param_value_size, void *param_value, |
| 334 | size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 335 | |
| 336 | // Kernel Object APIs |
| 337 | typedef CL_API_ENTRY cl_kernel(CL_API_CALL *cl_api_clCreateKernel)( |
| 338 | cl_program program, const char *kernel_name, |
| 339 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 340 | |
| 341 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clCreateKernelsInProgram)( |
| 342 | cl_program program, cl_uint num_kernels, cl_kernel *kernels, |
| 343 | cl_uint *num_kernels_ret) CL_API_SUFFIX__VERSION_1_0; |
| 344 | |
| 345 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainKernel)( |
| 346 | cl_kernel kernel) CL_API_SUFFIX__VERSION_1_0; |
| 347 | |
| 348 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseKernel)( |
| 349 | cl_kernel kernel) CL_API_SUFFIX__VERSION_1_0; |
| 350 | |
| 351 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetKernelArg)( |
| 352 | cl_kernel kernel, cl_uint arg_index, size_t arg_size, |
| 353 | const void *arg_value) CL_API_SUFFIX__VERSION_1_0; |
| 354 | |
| 355 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetKernelInfo)( |
| 356 | cl_kernel kernel, cl_kernel_info param_name, size_t param_value_size, |
| 357 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 358 | |
| 359 | #ifdef CL_VERSION_1_2 |
| 360 | |
| 361 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetKernelArgInfo)( |
| 362 | cl_kernel kernel, cl_uint arg_indx, cl_kernel_arg_info param_name, |
| 363 | size_t param_value_size, void *param_value, |
| 364 | size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_2; |
| 365 | |
| 366 | #else |
| 367 | |
| 368 | typedef void *cl_api_clGetKernelArgInfo; |
| 369 | |
| 370 | #endif |
| 371 | |
| 372 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetKernelWorkGroupInfo)( |
| 373 | cl_kernel kernel, cl_device_id device, cl_kernel_work_group_info param_name, |
| 374 | size_t param_value_size, void *param_value, |
| 375 | size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 376 | |
| 377 | #ifdef CL_VERSION_2_0 |
| 378 | |
| 379 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetKernelArgSVMPointer)( |
| 380 | cl_kernel /* kernel */, cl_uint /* arg_index */, |
| 381 | const void * /* arg_value */) CL_API_SUFFIX__VERSION_2_0; |
| 382 | |
| 383 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetKernelExecInfo)( |
| 384 | cl_kernel /* kernel */, cl_kernel_exec_info /* param_name */, |
| 385 | size_t /* param_value_size */, |
| 386 | const void * /* param_value */) CL_API_SUFFIX__VERSION_2_0; |
| 387 | |
| 388 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetKernelSubGroupInfoKHR)( |
| 389 | cl_kernel /* in_kernel */, cl_device_id /*in_device*/, |
| 390 | cl_kernel_sub_group_info /* param_name */, size_t /*input_value_size*/, |
| 391 | const void * /*input_value*/, size_t /*param_value_size*/, |
| 392 | void * /*param_value*/, |
| 393 | size_t * /*param_value_size_ret*/) CL_EXT_SUFFIX__VERSION_2_0; |
| 394 | |
| 395 | #else |
| 396 | |
| 397 | typedef void *cl_api_clSetKernelArgSVMPointer; |
| 398 | typedef void *cl_api_clSetKernelExecInfo; |
| 399 | typedef void *cl_api_clGetKernelSubGroupInfoKHR; |
| 400 | |
| 401 | #endif |
| 402 | |
| 403 | // Event Object APIs |
| 404 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clWaitForEvents)( |
| 405 | cl_uint num_events, const cl_event *event_list) CL_API_SUFFIX__VERSION_1_0; |
| 406 | |
| 407 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetEventInfo)( |
| 408 | cl_event event, cl_event_info param_name, size_t param_value_size, |
| 409 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 410 | |
| 411 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainEvent)(cl_event event) |
| 412 | CL_API_SUFFIX__VERSION_1_0; |
| 413 | |
| 414 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseEvent)(cl_event event) |
| 415 | CL_API_SUFFIX__VERSION_1_0; |
| 416 | |
| 417 | // Profiling APIs |
| 418 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetEventProfilingInfo)( |
| 419 | cl_event event, cl_profiling_info param_name, size_t param_value_size, |
| 420 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 421 | |
| 422 | // Flush and Finish APIs |
| 423 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clFlush)( |
| 424 | cl_command_queue command_queue) CL_API_SUFFIX__VERSION_1_0; |
| 425 | |
| 426 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clFinish)( |
| 427 | cl_command_queue command_queue) CL_API_SUFFIX__VERSION_1_0; |
| 428 | |
| 429 | // Enqueued Commands APIs |
| 430 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueReadBuffer)( |
| 431 | cl_command_queue command_queue, cl_mem buffer, cl_bool blocking_read, |
| 432 | size_t offset, size_t cb, void *ptr, cl_uint num_events_in_wait_list, |
| 433 | const cl_event *event_wait_list, |
| 434 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 435 | |
| 436 | #ifdef CL_VERSION_1_1 |
| 437 | |
| 438 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueReadBufferRect)( |
| 439 | cl_command_queue command_queue, cl_mem buffer, cl_bool blocking_read, |
| 440 | const size_t *buffer_origin, const size_t *host_origin, |
| 441 | const size_t *region, size_t buffer_row_pitch, size_t buffer_slice_pitch, |
| 442 | size_t host_row_pitch, size_t host_slice_pitch, void *ptr, |
| 443 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 444 | cl_event *event) CL_API_SUFFIX__VERSION_1_1; |
| 445 | |
| 446 | #else |
| 447 | |
| 448 | typedef void *cl_api_clEnqueueReadBufferRect; |
| 449 | |
| 450 | #endif |
| 451 | |
| 452 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueWriteBuffer)( |
| 453 | cl_command_queue command_queue, cl_mem buffer, cl_bool blocking_write, |
| 454 | size_t offset, size_t cb, const void *ptr, cl_uint num_events_in_wait_list, |
| 455 | const cl_event *event_wait_list, |
| 456 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 457 | |
| 458 | #ifdef CL_VERSION_1_1 |
| 459 | |
| 460 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueWriteBufferRect)( |
| 461 | cl_command_queue command_queue, cl_mem buffer, cl_bool blocking_read, |
| 462 | const size_t *buffer_origin, const size_t *host_origin, |
| 463 | const size_t *region, size_t buffer_row_pitch, size_t buffer_slice_pitch, |
| 464 | size_t host_row_pitch, size_t host_slice_pitch, const void *ptr, |
| 465 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 466 | cl_event *event) CL_API_SUFFIX__VERSION_1_1; |
| 467 | |
| 468 | #else |
| 469 | |
| 470 | typedef void *cl_api_clEnqueueWriteBufferRect; |
| 471 | |
| 472 | #endif |
| 473 | |
| 474 | #ifdef CL_VERSION_1_2 |
| 475 | |
| 476 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueFillBuffer)( |
| 477 | cl_command_queue command_queue, cl_mem buffer, const void *pattern, |
| 478 | size_t pattern_size, size_t offset, size_t cb, |
| 479 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 480 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 481 | |
| 482 | #else |
| 483 | |
| 484 | typedef void *cl_api_clEnqueueFillBuffer; |
| 485 | |
| 486 | #endif |
| 487 | |
| 488 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueCopyBuffer)( |
| 489 | cl_command_queue command_queue, cl_mem src_buffer, cl_mem dst_buffer, |
| 490 | size_t src_offset, size_t dst_offset, size_t cb, |
| 491 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 492 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 493 | |
| 494 | #ifdef CL_VERSION_1_1 |
| 495 | |
| 496 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueCopyBufferRect)( |
| 497 | cl_command_queue command_queue, cl_mem src_buffer, cl_mem dst_buffer, |
| 498 | const size_t *src_origin, const size_t *dst_origin, const size_t *region, |
| 499 | size_t src_row_pitch, size_t src_slice_pitch, size_t dst_row_pitch, |
| 500 | size_t dst_slice_pitch, cl_uint num_events_in_wait_list, |
| 501 | const cl_event *event_wait_list, |
| 502 | cl_event *event) CL_API_SUFFIX__VERSION_1_1; |
| 503 | |
| 504 | #else |
| 505 | |
| 506 | typedef void *cl_api_clEnqueueCopyBufferRect; |
| 507 | |
| 508 | #endif |
| 509 | |
| 510 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueReadImage)( |
| 511 | cl_command_queue command_queue, cl_mem image, cl_bool blocking_read, |
| 512 | const size_t *origin, const size_t *region, size_t row_pitch, |
| 513 | size_t slice_pitch, void *ptr, cl_uint num_events_in_wait_list, |
| 514 | const cl_event *event_wait_list, |
| 515 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 516 | |
| 517 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueWriteImage)( |
| 518 | cl_command_queue command_queue, cl_mem image, cl_bool blocking_write, |
| 519 | const size_t *origin, const size_t *region, size_t input_row_pitch, |
| 520 | size_t input_slice_pitch, const void *ptr, cl_uint num_events_in_wait_list, |
| 521 | const cl_event *event_wait_list, |
| 522 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 523 | |
| 524 | #ifdef CL_VERSION_1_2 |
| 525 | |
| 526 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueFillImage)( |
| 527 | cl_command_queue command_queue, cl_mem image, const void *fill_color, |
| 528 | const size_t origin[3], const size_t region[3], |
| 529 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 530 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 531 | |
| 532 | #else |
| 533 | |
| 534 | typedef void *cl_api_clEnqueueFillImage; |
| 535 | |
| 536 | #endif |
| 537 | |
| 538 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueCopyImage)( |
| 539 | cl_command_queue command_queue, cl_mem src_image, cl_mem dst_image, |
| 540 | const size_t *src_origin, const size_t *dst_origin, const size_t *region, |
| 541 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 542 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 543 | |
| 544 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueCopyImageToBuffer)( |
| 545 | cl_command_queue command_queue, cl_mem src_image, cl_mem dst_buffer, |
| 546 | const size_t *src_origin, const size_t *region, size_t dst_offset, |
| 547 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 548 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 549 | |
| 550 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueCopyBufferToImage)( |
| 551 | cl_command_queue command_queue, cl_mem src_buffer, cl_mem dst_image, |
| 552 | size_t src_offset, const size_t *dst_origin, const size_t *region, |
| 553 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 554 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 555 | |
| 556 | typedef CL_API_ENTRY void *(CL_API_CALL *cl_api_clEnqueueMapBuffer)( |
| 557 | cl_command_queue command_queue, cl_mem buffer, cl_bool blocking_map, |
| 558 | cl_map_flags map_flags, size_t offset, size_t cb, |
| 559 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 560 | cl_event *event, cl_int *errcode_ret)CL_API_SUFFIX__VERSION_1_0; |
| 561 | |
| 562 | typedef CL_API_ENTRY void *(CL_API_CALL *cl_api_clEnqueueMapImage)( |
| 563 | cl_command_queue command_queue, cl_mem image, cl_bool blocking_map, |
| 564 | cl_map_flags map_flags, const size_t *origin, const size_t *region, |
| 565 | size_t *image_row_pitch, size_t *image_slice_pitch, |
| 566 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 567 | cl_event *event, cl_int *errcode_ret)CL_API_SUFFIX__VERSION_1_0; |
| 568 | |
| 569 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueUnmapMemObject)( |
| 570 | cl_command_queue command_queue, cl_mem memobj, void *mapped_ptr, |
| 571 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 572 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 573 | |
| 574 | #ifdef CL_VERSION_1_2 |
| 575 | |
| 576 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueMigrateMemObjects)( |
| 577 | cl_command_queue command_queue, cl_uint num_mem_objects, |
| 578 | const cl_mem *mem_objects, cl_mem_migration_flags flags, |
| 579 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 580 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 581 | |
| 582 | #else |
| 583 | |
| 584 | typedef void *cl_api_clEnqueueMigrateMemObjects; |
| 585 | |
| 586 | #endif |
| 587 | |
| 588 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueNDRangeKernel)( |
| 589 | cl_command_queue command_queue, cl_kernel kernel, cl_uint work_dim, |
| 590 | const size_t *global_work_offset, const size_t *global_work_size, |
| 591 | const size_t *local_work_size, cl_uint num_events_in_wait_list, |
| 592 | const cl_event *event_wait_list, |
| 593 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 594 | |
| 595 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueTask)( |
| 596 | cl_command_queue command_queue, cl_kernel kernel, |
| 597 | cl_uint num_events_in_wait_list, const cl_event *event_wait_list, |
| 598 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 599 | |
| 600 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueNativeKernel)( |
| 601 | cl_command_queue command_queue, void(CL_CALLBACK *user_func)(void *), |
| 602 | void *args, size_t cb_args, cl_uint num_mem_objects, const cl_mem *mem_list, |
| 603 | const void **args_mem_loc, cl_uint num_events_in_wait_list, |
| 604 | const cl_event *event_wait_list, |
| 605 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 606 | |
| 607 | #ifdef CL_VERSION_1_2 |
| 608 | |
| 609 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueMarkerWithWaitList)( |
| 610 | cl_command_queue command_queue, cl_uint num_events_in_wait_list, |
| 611 | const cl_event *event_wait_list, |
| 612 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 613 | |
| 614 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueBarrierWithWaitList)( |
| 615 | cl_command_queue command_queue, cl_uint num_events_in_wait_list, |
| 616 | const cl_event *event_wait_list, |
| 617 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 618 | |
| 619 | typedef CL_API_ENTRY void *( |
| 620 | CL_API_CALL *cl_api_clGetExtensionFunctionAddressForPlatform)( |
| 621 | cl_platform_id platform, |
| 622 | const char *function_name)CL_API_SUFFIX__VERSION_1_2; |
| 623 | |
| 624 | #else |
| 625 | |
| 626 | typedef void *cl_api_clEnqueueMarkerWithWaitList; |
| 627 | typedef void *cl_api_clEnqueueBarrierWithWaitList; |
| 628 | typedef void *cl_api_clGetExtensionFunctionAddressForPlatform; |
| 629 | |
| 630 | #endif |
| 631 | |
| 632 | // Shared Virtual Memory APIs |
| 633 | |
| 634 | #ifdef CL_VERSION_2_0 |
| 635 | |
| 636 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueSVMFree)( |
| 637 | cl_command_queue /* command_queue */, cl_uint /* num_svm_pointers */, |
| 638 | void ** /* svm_pointers */, |
| 639 | void(CL_CALLBACK *pfn_free_func)(cl_command_queue /* queue */, |
| 640 | cl_uint /* num_svm_pointers */, |
| 641 | void ** /* svm_pointers[] */, |
| 642 | void * /* user_data */), |
| 643 | void * /* user_data */, cl_uint /* num_events_in_wait_list */, |
| 644 | const cl_event * /* event_wait_list */, |
| 645 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 646 | |
| 647 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueSVMMemcpy)( |
| 648 | cl_command_queue /* command_queue */, cl_bool /* blocking_copy */, |
| 649 | void * /* dst_ptr */, const void * /* src_ptr */, size_t /* size */, |
| 650 | cl_uint /* num_events_in_wait_list */, |
| 651 | const cl_event * /* event_wait_list */, |
| 652 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 653 | |
| 654 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueSVMMemFill)( |
| 655 | cl_command_queue /* command_queue */, void * /* svm_ptr */, |
| 656 | const void * /* pattern */, size_t /* pattern_size */, size_t /* size */, |
| 657 | cl_uint /* num_events_in_wait_list */, |
| 658 | const cl_event * /* event_wait_list */, |
| 659 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 660 | |
| 661 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueSVMMap)( |
| 662 | cl_command_queue /* command_queue */, cl_bool /* blocking_map */, |
| 663 | cl_map_flags /* map_flags */, void * /* svm_ptr */, size_t /* size */, |
| 664 | cl_uint /* num_events_in_wait_list */, |
| 665 | const cl_event * /* event_wait_list */, |
| 666 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 667 | |
| 668 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueSVMUnmap)( |
| 669 | cl_command_queue /* command_queue */, void * /* svm_ptr */, |
| 670 | cl_uint /* num_events_in_wait_list */, |
| 671 | const cl_event * /* event_wait_list */, |
| 672 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 673 | |
| 674 | #else |
| 675 | |
| 676 | typedef void *cl_api_clEnqueueSVMFree; |
| 677 | typedef void *cl_api_clEnqueueSVMMemcpy; |
| 678 | typedef void *cl_api_clEnqueueSVMMemFill; |
| 679 | typedef void *cl_api_clEnqueueSVMMap; |
| 680 | typedef void *cl_api_clEnqueueSVMUnmap; |
| 681 | |
| 682 | #endif |
| 683 | |
| 684 | // Deprecated APIs |
| 685 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetCommandQueueProperty)( |
| 686 | cl_command_queue command_queue, cl_command_queue_properties properties, |
| 687 | cl_bool enable, cl_command_queue_properties *old_properties) |
| 688 | CL_EXT_SUFFIX__VERSION_1_0_DEPRECATED; |
| 689 | |
| 690 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateImage2D)( |
| 691 | cl_context context, cl_mem_flags flags, const cl_image_format *image_format, |
| 692 | size_t image_width, size_t image_height, size_t image_row_pitch, |
| 693 | void *host_ptr, cl_int *errcode_ret) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 694 | |
| 695 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateImage3D)( |
| 696 | cl_context context, cl_mem_flags flags, const cl_image_format *image_format, |
| 697 | size_t image_width, size_t image_height, size_t image_depth, |
| 698 | size_t image_row_pitch, size_t image_slice_pitch, void *host_ptr, |
| 699 | cl_int *errcode_ret) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 700 | |
| 701 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clUnloadCompiler)(void) |
| 702 | CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 703 | |
| 704 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueMarker)( |
| 705 | cl_command_queue command_queue, |
| 706 | cl_event *event) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 707 | |
| 708 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueWaitForEvents)( |
| 709 | cl_command_queue command_queue, cl_uint num_events, |
| 710 | const cl_event *event_list) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 711 | |
| 712 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueBarrier)( |
| 713 | cl_command_queue command_queue) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 714 | |
| 715 | typedef CL_API_ENTRY void *(CL_API_CALL *cl_api_clGetExtensionFunctionAddress)( |
| 716 | const char *function_name)CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 717 | |
| 718 | // GL and other APIs |
| 719 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromGLBuffer)( |
| 720 | cl_context context, cl_mem_flags flags, cl_GLuint bufobj, |
| 721 | int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 722 | |
| 723 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromGLTexture)( |
| 724 | cl_context context, cl_mem_flags flags, cl_GLenum target, cl_GLint miplevel, |
| 725 | cl_GLuint texture, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 726 | |
| 727 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromGLTexture2D)( |
| 728 | cl_context context, cl_mem_flags flags, cl_GLenum target, cl_GLint miplevel, |
| 729 | cl_GLuint texture, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 730 | |
| 731 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromGLTexture3D)( |
| 732 | cl_context context, cl_mem_flags flags, cl_GLenum target, cl_GLint miplevel, |
| 733 | cl_GLuint texture, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 734 | |
| 735 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromGLRenderbuffer)( |
| 736 | cl_context context, cl_mem_flags flags, cl_GLuint renderbuffer, |
| 737 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 738 | |
| 739 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetGLObjectInfo)( |
| 740 | cl_mem memobj, cl_gl_object_type *gl_object_type, |
| 741 | cl_GLuint *gl_object_name) CL_API_SUFFIX__VERSION_1_0; |
| 742 | |
| 743 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetGLTextureInfo)( |
| 744 | cl_mem memobj, cl_gl_texture_info param_name, size_t param_value_size, |
| 745 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_1_0; |
| 746 | |
| 747 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueAcquireGLObjects)( |
| 748 | cl_command_queue command_queue, cl_uint num_objects, |
| 749 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 750 | const cl_event *event_wait_list, |
| 751 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 752 | |
| 753 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueReleaseGLObjects)( |
| 754 | cl_command_queue command_queue, cl_uint num_objects, |
| 755 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 756 | const cl_event *event_wait_list, |
| 757 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 758 | |
| 759 | /* cl_khr_gl_sharing */ |
| 760 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetGLContextInfoKHR)( |
| 761 | const cl_context_properties *properties, cl_gl_context_info param_name, |
| 762 | size_t param_value_size, void *param_value, size_t *param_value_size_ret); |
| 763 | |
| 764 | /* cl_khr_gl_event */ |
| 765 | typedef CL_API_ENTRY cl_event(CL_API_CALL *cl_api_clCreateEventFromGLsyncKHR)( |
| 766 | cl_context context, cl_GLsync sync, cl_int *errcode_ret); |
| 767 | |
| 768 | #if defined(_WIN32) |
| 769 | |
| 770 | /* cl_khr_d3d10_sharing */ |
| 771 | |
| 772 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetDeviceIDsFromD3D10KHR)( |
| 773 | cl_platform_id platform, cl_d3d10_device_source_khr d3d_device_source, |
| 774 | void *d3d_object, cl_d3d10_device_set_khr d3d_device_set, |
| 775 | cl_uint num_entries, cl_device_id *devices, |
| 776 | cl_uint *num_devices) CL_API_SUFFIX__VERSION_1_0; |
| 777 | |
| 778 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromD3D10BufferKHR)( |
| 779 | cl_context context, cl_mem_flags flags, ID3D10Buffer *resource, |
| 780 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 781 | |
| 782 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromD3D10Texture2DKHR)( |
| 783 | cl_context context, cl_mem_flags flags, ID3D10Texture2D *resource, |
| 784 | UINT subresource, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 785 | |
| 786 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromD3D10Texture3DKHR)( |
| 787 | cl_context context, cl_mem_flags flags, ID3D10Texture3D *resource, |
| 788 | UINT subresource, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_0; |
| 789 | |
| 790 | typedef CL_API_ENTRY |
| 791 | cl_int(CL_API_CALL *cl_api_clEnqueueAcquireD3D10ObjectsKHR)( |
| 792 | cl_command_queue command_queue, cl_uint num_objects, |
| 793 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 794 | const cl_event *event_wait_list, |
| 795 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 796 | |
| 797 | typedef CL_API_ENTRY |
| 798 | cl_int(CL_API_CALL *cl_api_clEnqueueReleaseD3D10ObjectsKHR)( |
| 799 | cl_command_queue command_queue, cl_uint num_objects, |
| 800 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 801 | const cl_event *event_wait_list, |
| 802 | cl_event *event) CL_API_SUFFIX__VERSION_1_0; |
| 803 | |
| 804 | extern CL_API_ENTRY cl_int CL_API_CALL clGetDeviceIDsFromD3D10KHR( |
| 805 | cl_platform_id platform, cl_d3d10_device_source_khr d3d_device_source, |
| 806 | void *d3d_object, cl_d3d10_device_set_khr d3d_device_set, |
| 807 | cl_uint num_entries, cl_device_id *devices, cl_uint *num_devices); |
| 808 | |
| 809 | extern CL_API_ENTRY cl_mem CL_API_CALL |
| 810 | clCreateFromD3D10BufferKHR(cl_context context, cl_mem_flags flags, |
| 811 | ID3D10Buffer *resource, cl_int *errcode_ret); |
| 812 | |
| 813 | extern CL_API_ENTRY cl_mem CL_API_CALL clCreateFromD3D10Texture2DKHR( |
| 814 | cl_context context, cl_mem_flags flags, ID3D10Texture2D *resource, |
| 815 | UINT subresource, cl_int *errcode_ret); |
| 816 | |
| 817 | extern CL_API_ENTRY cl_mem CL_API_CALL clCreateFromD3D10Texture3DKHR( |
| 818 | cl_context context, cl_mem_flags flags, ID3D10Texture3D *resource, |
| 819 | UINT subresource, cl_int *errcode_ret); |
| 820 | |
| 821 | extern CL_API_ENTRY cl_int CL_API_CALL clEnqueueAcquireD3D10ObjectsKHR( |
| 822 | cl_command_queue command_queue, cl_uint num_objects, |
| 823 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 824 | const cl_event *event_wait_list, cl_event *event); |
| 825 | |
| 826 | extern CL_API_ENTRY cl_int CL_API_CALL clEnqueueReleaseD3D10ObjectsKHR( |
| 827 | cl_command_queue command_queue, cl_uint num_objects, |
| 828 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 829 | const cl_event *event_wait_list, cl_event *event); |
| 830 | |
| 831 | /* cl_khr_d3d11_sharing */ |
| 832 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetDeviceIDsFromD3D11KHR)( |
| 833 | cl_platform_id platform, cl_d3d11_device_source_khr d3d_device_source, |
| 834 | void *d3d_object, cl_d3d11_device_set_khr d3d_device_set, |
| 835 | cl_uint num_entries, cl_device_id *devices, |
| 836 | cl_uint *num_devices) CL_API_SUFFIX__VERSION_1_2; |
| 837 | |
| 838 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromD3D11BufferKHR)( |
| 839 | cl_context context, cl_mem_flags flags, ID3D11Buffer *resource, |
| 840 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 841 | |
| 842 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromD3D11Texture2DKHR)( |
| 843 | cl_context context, cl_mem_flags flags, ID3D11Texture2D *resource, |
| 844 | UINT subresource, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 845 | |
| 846 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromD3D11Texture3DKHR)( |
| 847 | cl_context context, cl_mem_flags flags, ID3D11Texture3D *resource, |
| 848 | UINT subresource, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 849 | |
| 850 | typedef CL_API_ENTRY |
| 851 | cl_int(CL_API_CALL *cl_api_clEnqueueAcquireD3D11ObjectsKHR)( |
| 852 | cl_command_queue command_queue, cl_uint num_objects, |
| 853 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 854 | const cl_event *event_wait_list, |
| 855 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 856 | |
| 857 | typedef CL_API_ENTRY |
| 858 | cl_int(CL_API_CALL *cl_api_clEnqueueReleaseD3D11ObjectsKHR)( |
| 859 | cl_command_queue command_queue, cl_uint num_objects, |
| 860 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 861 | const cl_event *event_wait_list, |
| 862 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 863 | |
| 864 | /* cl_khr_dx9_media_sharing */ |
| 865 | typedef CL_API_ENTRY |
| 866 | cl_int(CL_API_CALL *cl_api_clGetDeviceIDsFromDX9MediaAdapterKHR)( |
| 867 | cl_platform_id platform, cl_uint num_media_adapters, |
| 868 | cl_dx9_media_adapter_type_khr *media_adapters_type, void *media_adapters, |
| 869 | cl_dx9_media_adapter_set_khr media_adapter_set, cl_uint num_entries, |
| 870 | cl_device_id *devices, cl_uint *num_devices) CL_API_SUFFIX__VERSION_1_2; |
| 871 | |
| 872 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromDX9MediaSurfaceKHR)( |
| 873 | cl_context context, cl_mem_flags flags, |
| 874 | cl_dx9_media_adapter_type_khr adapter_type, void *surface_info, |
| 875 | cl_uint plane, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_1_2; |
| 876 | |
| 877 | typedef CL_API_ENTRY |
| 878 | cl_int(CL_API_CALL *cl_api_clEnqueueAcquireDX9MediaSurfacesKHR)( |
| 879 | cl_command_queue command_queue, cl_uint num_objects, |
| 880 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 881 | const cl_event *event_wait_list, |
| 882 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 883 | |
| 884 | typedef CL_API_ENTRY |
| 885 | cl_int(CL_API_CALL *cl_api_clEnqueueReleaseDX9MediaSurfacesKHR)( |
| 886 | cl_command_queue command_queue, cl_uint num_objects, |
| 887 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 888 | const cl_event *event_wait_list, |
| 889 | cl_event *event) CL_API_SUFFIX__VERSION_1_2; |
| 890 | |
| 891 | /* cl_khr_d3d11_sharing */ |
| 892 | extern CL_API_ENTRY cl_int CL_API_CALL clGetDeviceIDsFromD3D11KHR( |
| 893 | cl_platform_id platform, cl_d3d11_device_source_khr d3d_device_source, |
| 894 | void *d3d_object, cl_d3d11_device_set_khr d3d_device_set, |
| 895 | cl_uint num_entries, cl_device_id *devices, cl_uint *num_devices); |
| 896 | |
| 897 | extern CL_API_ENTRY cl_mem CL_API_CALL |
| 898 | clCreateFromD3D11BufferKHR(cl_context context, cl_mem_flags flags, |
| 899 | ID3D11Buffer *resource, cl_int *errcode_ret); |
| 900 | |
| 901 | extern CL_API_ENTRY cl_mem CL_API_CALL clCreateFromD3D11Texture2DKHR( |
| 902 | cl_context context, cl_mem_flags flags, ID3D11Texture2D *resource, |
| 903 | UINT subresource, cl_int *errcode_ret); |
| 904 | |
| 905 | extern CL_API_ENTRY cl_mem CL_API_CALL clCreateFromD3D11Texture3DKHR( |
| 906 | cl_context context, cl_mem_flags flags, ID3D11Texture3D *resource, |
| 907 | UINT subresource, cl_int *errcode_ret); |
| 908 | |
| 909 | extern CL_API_ENTRY cl_int CL_API_CALL clEnqueueAcquireD3D11ObjectsKHR( |
| 910 | cl_command_queue command_queue, cl_uint num_objects, |
| 911 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 912 | const cl_event *event_wait_list, cl_event *event); |
| 913 | |
| 914 | extern CL_API_ENTRY cl_int CL_API_CALL clEnqueueReleaseD3D11ObjectsKHR( |
| 915 | cl_command_queue command_queue, cl_uint num_objects, |
| 916 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 917 | const cl_event *event_wait_list, cl_event *event); |
| 918 | |
| 919 | /* cl_khr_dx9_media_sharing */ |
| 920 | extern CL_API_ENTRY cl_int CL_API_CALL clGetDeviceIDsFromDX9MediaAdapterKHR( |
| 921 | cl_platform_id platform, cl_uint num_media_adapters, |
| 922 | cl_dx9_media_adapter_type_khr *media_adapter_type, void *media_adapters, |
| 923 | cl_dx9_media_adapter_set_khr media_adapter_set, cl_uint num_entries, |
| 924 | cl_device_id *devices, cl_uint *num_devices); |
| 925 | |
| 926 | extern CL_API_ENTRY cl_mem CL_API_CALL clCreateFromDX9MediaSurfaceKHR( |
| 927 | cl_context context, cl_mem_flags flags, |
| 928 | cl_dx9_media_adapter_type_khr adapter_type, void *surface_info, |
| 929 | cl_uint plane, cl_int *errcode_ret); |
| 930 | |
| 931 | extern CL_API_ENTRY cl_int CL_API_CALL clEnqueueAcquireDX9MediaSurfacesKHR( |
| 932 | cl_command_queue command_queue, cl_uint num_objects, |
| 933 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 934 | const cl_event *event_wait_list, cl_event *event); |
| 935 | |
| 936 | extern CL_API_ENTRY cl_int CL_API_CALL clEnqueueReleaseDX9MediaSurfacesKHR( |
| 937 | cl_command_queue command_queue, cl_uint num_objects, |
| 938 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 939 | const cl_event *event_wait_list, cl_event *event); |
| 940 | |
| 941 | #else |
| 942 | |
| 943 | /* cl_khr_d3d10_sharing */ |
| 944 | typedef void *cl_api_clGetDeviceIDsFromD3D10KHR; |
| 945 | typedef void *cl_api_clCreateFromD3D10BufferKHR; |
| 946 | typedef void *cl_api_clCreateFromD3D10Texture2DKHR; |
| 947 | typedef void *cl_api_clCreateFromD3D10Texture3DKHR; |
| 948 | typedef void *cl_api_clEnqueueAcquireD3D10ObjectsKHR; |
| 949 | typedef void *cl_api_clEnqueueReleaseD3D10ObjectsKHR; |
| 950 | |
| 951 | /* cl_khr_d3d11_sharing */ |
| 952 | typedef void *cl_api_clGetDeviceIDsFromD3D11KHR; |
| 953 | typedef void *cl_api_clCreateFromD3D11BufferKHR; |
| 954 | typedef void *cl_api_clCreateFromD3D11Texture2DKHR; |
| 955 | typedef void *cl_api_clCreateFromD3D11Texture3DKHR; |
| 956 | typedef void *cl_api_clEnqueueAcquireD3D11ObjectsKHR; |
| 957 | typedef void *cl_api_clEnqueueReleaseD3D11ObjectsKHR; |
| 958 | |
| 959 | /* cl_khr_dx9_media_sharing */ |
| 960 | typedef void *cl_api_clCreateFromDX9MediaSurfaceKHR; |
| 961 | typedef void *cl_api_clEnqueueAcquireDX9MediaSurfacesKHR; |
| 962 | typedef void *cl_api_clEnqueueReleaseDX9MediaSurfacesKHR; |
| 963 | typedef void *cl_api_clGetDeviceIDsFromDX9MediaAdapterKHR; |
| 964 | |
| 965 | #endif |
| 966 | |
| 967 | /* OpenCL 1.1 */ |
| 968 | |
| 969 | #ifdef CL_VERSION_1_1 |
| 970 | |
| 971 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetEventCallback)( |
| 972 | cl_event /* event */, cl_int /* command_exec_callback_type */, |
| 973 | void(CL_CALLBACK * /* pfn_notify */)(cl_event, cl_int, void *), |
| 974 | void * /* user_data */) CL_API_SUFFIX__VERSION_1_1; |
| 975 | |
| 976 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateSubBuffer)( |
| 977 | cl_mem /* buffer */, cl_mem_flags /* flags */, |
| 978 | cl_buffer_create_type /* buffer_create_type */, |
| 979 | const void * /* buffer_create_info */, |
| 980 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_1; |
| 981 | |
| 982 | typedef CL_API_ENTRY |
| 983 | cl_int(CL_API_CALL *cl_api_clSetMemObjectDestructorCallback)( |
| 984 | cl_mem /* memobj */, |
| 985 | void(CL_CALLBACK * /*pfn_notify*/)(cl_mem /* memobj */, |
| 986 | void * /*user_data*/), |
| 987 | void * /*user_data */) CL_API_SUFFIX__VERSION_1_1; |
| 988 | |
| 989 | typedef CL_API_ENTRY cl_event(CL_API_CALL *cl_api_clCreateUserEvent)( |
| 990 | cl_context /* context */, |
| 991 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_1; |
| 992 | |
| 993 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetUserEventStatus)( |
| 994 | cl_event /* event */, |
| 995 | cl_int /* execution_status */) CL_API_SUFFIX__VERSION_1_1; |
| 996 | |
| 997 | #else |
| 998 | |
| 999 | typedef void *cl_api_clSetEventCallback; |
| 1000 | typedef void *cl_api_clCreateSubBuffer; |
| 1001 | typedef void *cl_api_clSetMemObjectDestructorCallback; |
| 1002 | typedef void *cl_api_clCreateUserEvent; |
| 1003 | typedef void *cl_api_clSetUserEventStatus; |
| 1004 | |
| 1005 | #endif |
| 1006 | |
| 1007 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clCreateSubDevicesEXT)( |
| 1008 | cl_device_id in_device, |
| 1009 | const cl_device_partition_property_ext *partition_properties, |
| 1010 | cl_uint num_entries, cl_device_id *out_devices, cl_uint *num_devices); |
| 1011 | |
| 1012 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clRetainDeviceEXT)( |
| 1013 | cl_device_id device) CL_API_SUFFIX__VERSION_1_0; |
| 1014 | |
| 1015 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clReleaseDeviceEXT)( |
| 1016 | cl_device_id device) CL_API_SUFFIX__VERSION_1_0; |
| 1017 | |
| 1018 | /* cl_khr_egl_image */ |
| 1019 | typedef CL_API_ENTRY cl_mem(CL_API_CALL *cl_api_clCreateFromEGLImageKHR)( |
| 1020 | cl_context context, CLeglDisplayKHR display, CLeglImageKHR image, |
| 1021 | cl_mem_flags flags, const cl_egl_image_properties_khr *properties, |
| 1022 | cl_int *errcode_ret); |
| 1023 | |
| 1024 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueAcquireEGLObjectsKHR)( |
| 1025 | cl_command_queue command_queue, cl_uint num_objects, |
| 1026 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 1027 | const cl_event *event_wait_list, cl_event *event); |
| 1028 | |
| 1029 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueReleaseEGLObjectsKHR)( |
| 1030 | cl_command_queue command_queue, cl_uint num_objects, |
| 1031 | const cl_mem *mem_objects, cl_uint num_events_in_wait_list, |
| 1032 | const cl_event *event_wait_list, cl_event *event); |
| 1033 | |
| 1034 | /* cl_khr_egl_event */ |
| 1035 | typedef CL_API_ENTRY cl_event(CL_API_CALL *cl_api_clCreateEventFromEGLSyncKHR)( |
| 1036 | cl_context context, CLeglSyncKHR sync, CLeglDisplayKHR display, |
| 1037 | cl_int *errcode_ret); |
| 1038 | |
| 1039 | #ifdef CL_VERSION_2_1 |
| 1040 | |
| 1041 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clSetDefaultDeviceCommandQueue)( |
| 1042 | cl_context context, cl_device_id device, |
| 1043 | cl_command_queue command_queue) CL_API_SUFFIX__VERSION_2_1; |
| 1044 | |
| 1045 | typedef CL_API_ENTRY cl_program(CL_API_CALL *cl_api_clCreateProgramWithIL)( |
| 1046 | cl_context context, const void *il, size_t length, |
| 1047 | cl_int *errcode_ret) CL_API_SUFFIX__VERSION_2_1; |
| 1048 | |
| 1049 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetKernelSubGroupInfo)( |
| 1050 | cl_kernel kernel, cl_device_id device, cl_kernel_sub_group_info param_name, |
| 1051 | size_t input_value_size, const void *input_value, size_t param_value_size, |
| 1052 | void *param_value, size_t *param_value_size_ret) CL_API_SUFFIX__VERSION_2_1; |
| 1053 | |
| 1054 | typedef CL_API_ENTRY cl_kernel(CL_API_CALL *cl_api_clCloneKernel)( |
| 1055 | cl_kernel source_kernel, cl_int *errcode_ret) CL_API_SUFFIX__VERSION_2_1; |
| 1056 | |
| 1057 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clEnqueueSVMMigrateMem)( |
| 1058 | cl_command_queue command_queue, cl_uint num_svm_pointers, |
| 1059 | const void **svm_pointers, const size_t *sizes, |
| 1060 | cl_mem_migration_flags flags, cl_uint num_events_in_wait_list, |
| 1061 | const cl_event *event_wait_list, |
| 1062 | cl_event *event) CL_API_SUFFIX__VERSION_2_1; |
| 1063 | |
| 1064 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetDeviceAndHostTimer)( |
| 1065 | cl_device_id device, cl_ulong *device_timestamp, |
| 1066 | cl_ulong *host_timestamp) CL_API_SUFFIX__VERSION_2_1; |
| 1067 | |
| 1068 | typedef CL_API_ENTRY cl_int(CL_API_CALL *cl_api_clGetHostTimer)( |
| 1069 | cl_device_id device, cl_ulong *host_timestamp) CL_API_SUFFIX__VERSION_2_1; |
| 1070 | |
| 1071 | #else |
| 1072 | |
| 1073 | typedef void *cl_api_clSetDefaultDeviceCommandQueue; |
| 1074 | typedef void *cl_api_clCreateProgramWithIL; |
| 1075 | typedef void *cl_api_clGetKernelSubGroupInfo; |
| 1076 | typedef void *cl_api_clCloneKernel; |
| 1077 | typedef void *cl_api_clEnqueueSVMMigrateMem; |
| 1078 | typedef void *cl_api_clGetDeviceAndHostTimer; |
| 1079 | typedef void *cl_api_clGetHostTimer; |
| 1080 | |
| 1081 | #endif |
| 1082 | |
| 1083 | /* Vendor dispatch table struture */ |
| 1084 | |
| 1085 | typedef struct _cl_icd_dispatch { |
| 1086 | /* OpenCL 1.0 */ |
| 1087 | cl_api_clGetPlatformIDs clGetPlatformIDs; |
| 1088 | cl_api_clGetPlatformInfo clGetPlatformInfo; |
| 1089 | cl_api_clGetDeviceIDs clGetDeviceIDs; |
| 1090 | cl_api_clGetDeviceInfo clGetDeviceInfo; |
| 1091 | cl_api_clCreateContext clCreateContext; |
| 1092 | cl_api_clCreateContextFromType clCreateContextFromType; |
| 1093 | cl_api_clRetainContext clRetainContext; |
| 1094 | cl_api_clReleaseContext clReleaseContext; |
| 1095 | cl_api_clGetContextInfo clGetContextInfo; |
| 1096 | cl_api_clCreateCommandQueue clCreateCommandQueue; |
| 1097 | cl_api_clRetainCommandQueue clRetainCommandQueue; |
| 1098 | cl_api_clReleaseCommandQueue clReleaseCommandQueue; |
| 1099 | cl_api_clGetCommandQueueInfo clGetCommandQueueInfo; |
| 1100 | cl_api_clSetCommandQueueProperty clSetCommandQueueProperty; |
| 1101 | cl_api_clCreateBuffer clCreateBuffer; |
| 1102 | cl_api_clCreateImage2D clCreateImage2D; |
| 1103 | cl_api_clCreateImage3D clCreateImage3D; |
| 1104 | cl_api_clRetainMemObject clRetainMemObject; |
| 1105 | cl_api_clReleaseMemObject clReleaseMemObject; |
| 1106 | cl_api_clGetSupportedImageFormats clGetSupportedImageFormats; |
| 1107 | cl_api_clGetMemObjectInfo clGetMemObjectInfo; |
| 1108 | cl_api_clGetImageInfo clGetImageInfo; |
| 1109 | cl_api_clCreateSampler clCreateSampler; |
| 1110 | cl_api_clRetainSampler clRetainSampler; |
| 1111 | cl_api_clReleaseSampler clReleaseSampler; |
| 1112 | cl_api_clGetSamplerInfo clGetSamplerInfo; |
| 1113 | cl_api_clCreateProgramWithSource clCreateProgramWithSource; |
| 1114 | cl_api_clCreateProgramWithBinary clCreateProgramWithBinary; |
| 1115 | cl_api_clRetainProgram clRetainProgram; |
| 1116 | cl_api_clReleaseProgram clReleaseProgram; |
| 1117 | cl_api_clBuildProgram clBuildProgram; |
| 1118 | cl_api_clUnloadCompiler clUnloadCompiler; |
| 1119 | cl_api_clGetProgramInfo clGetProgramInfo; |
| 1120 | cl_api_clGetProgramBuildInfo clGetProgramBuildInfo; |
| 1121 | cl_api_clCreateKernel clCreateKernel; |
| 1122 | cl_api_clCreateKernelsInProgram clCreateKernelsInProgram; |
| 1123 | cl_api_clRetainKernel clRetainKernel; |
| 1124 | cl_api_clReleaseKernel clReleaseKernel; |
| 1125 | cl_api_clSetKernelArg clSetKernelArg; |
| 1126 | cl_api_clGetKernelInfo clGetKernelInfo; |
| 1127 | cl_api_clGetKernelWorkGroupInfo clGetKernelWorkGroupInfo; |
| 1128 | cl_api_clWaitForEvents clWaitForEvents; |
| 1129 | cl_api_clGetEventInfo clGetEventInfo; |
| 1130 | cl_api_clRetainEvent clRetainEvent; |
| 1131 | cl_api_clReleaseEvent clReleaseEvent; |
| 1132 | cl_api_clGetEventProfilingInfo clGetEventProfilingInfo; |
| 1133 | cl_api_clFlush clFlush; |
| 1134 | cl_api_clFinish clFinish; |
| 1135 | cl_api_clEnqueueReadBuffer clEnqueueReadBuffer; |
| 1136 | cl_api_clEnqueueWriteBuffer clEnqueueWriteBuffer; |
| 1137 | cl_api_clEnqueueCopyBuffer clEnqueueCopyBuffer; |
| 1138 | cl_api_clEnqueueReadImage clEnqueueReadImage; |
| 1139 | cl_api_clEnqueueWriteImage clEnqueueWriteImage; |
| 1140 | cl_api_clEnqueueCopyImage clEnqueueCopyImage; |
| 1141 | cl_api_clEnqueueCopyImageToBuffer clEnqueueCopyImageToBuffer; |
| 1142 | cl_api_clEnqueueCopyBufferToImage clEnqueueCopyBufferToImage; |
| 1143 | cl_api_clEnqueueMapBuffer clEnqueueMapBuffer; |
| 1144 | cl_api_clEnqueueMapImage clEnqueueMapImage; |
| 1145 | cl_api_clEnqueueUnmapMemObject clEnqueueUnmapMemObject; |
| 1146 | cl_api_clEnqueueNDRangeKernel clEnqueueNDRangeKernel; |
| 1147 | cl_api_clEnqueueTask clEnqueueTask; |
| 1148 | cl_api_clEnqueueNativeKernel clEnqueueNativeKernel; |
| 1149 | cl_api_clEnqueueMarker clEnqueueMarker; |
| 1150 | cl_api_clEnqueueWaitForEvents clEnqueueWaitForEvents; |
| 1151 | cl_api_clEnqueueBarrier clEnqueueBarrier; |
| 1152 | cl_api_clGetExtensionFunctionAddress clGetExtensionFunctionAddress; |
| 1153 | cl_api_clCreateFromGLBuffer clCreateFromGLBuffer; |
| 1154 | cl_api_clCreateFromGLTexture2D clCreateFromGLTexture2D; |
| 1155 | cl_api_clCreateFromGLTexture3D clCreateFromGLTexture3D; |
| 1156 | cl_api_clCreateFromGLRenderbuffer clCreateFromGLRenderbuffer; |
| 1157 | cl_api_clGetGLObjectInfo clGetGLObjectInfo; |
| 1158 | cl_api_clGetGLTextureInfo clGetGLTextureInfo; |
| 1159 | cl_api_clEnqueueAcquireGLObjects clEnqueueAcquireGLObjects; |
| 1160 | cl_api_clEnqueueReleaseGLObjects clEnqueueReleaseGLObjects; |
| 1161 | cl_api_clGetGLContextInfoKHR clGetGLContextInfoKHR; |
| 1162 | |
| 1163 | /* cl_khr_d3d10_sharing */ |
| 1164 | cl_api_clGetDeviceIDsFromD3D10KHR clGetDeviceIDsFromD3D10KHR; |
| 1165 | cl_api_clCreateFromD3D10BufferKHR clCreateFromD3D10BufferKHR; |
| 1166 | cl_api_clCreateFromD3D10Texture2DKHR clCreateFromD3D10Texture2DKHR; |
| 1167 | cl_api_clCreateFromD3D10Texture3DKHR clCreateFromD3D10Texture3DKHR; |
| 1168 | cl_api_clEnqueueAcquireD3D10ObjectsKHR clEnqueueAcquireD3D10ObjectsKHR; |
| 1169 | cl_api_clEnqueueReleaseD3D10ObjectsKHR clEnqueueReleaseD3D10ObjectsKHR; |
| 1170 | |
| 1171 | /* OpenCL 1.1 */ |
| 1172 | cl_api_clSetEventCallback clSetEventCallback; |
| 1173 | cl_api_clCreateSubBuffer clCreateSubBuffer; |
| 1174 | cl_api_clSetMemObjectDestructorCallback clSetMemObjectDestructorCallback; |
| 1175 | cl_api_clCreateUserEvent clCreateUserEvent; |
| 1176 | cl_api_clSetUserEventStatus clSetUserEventStatus; |
| 1177 | cl_api_clEnqueueReadBufferRect clEnqueueReadBufferRect; |
| 1178 | cl_api_clEnqueueWriteBufferRect clEnqueueWriteBufferRect; |
| 1179 | cl_api_clEnqueueCopyBufferRect clEnqueueCopyBufferRect; |
| 1180 | |
| 1181 | /* cl_ext_device_fission */ |
| 1182 | cl_api_clCreateSubDevicesEXT clCreateSubDevicesEXT; |
| 1183 | cl_api_clRetainDeviceEXT clRetainDeviceEXT; |
| 1184 | cl_api_clReleaseDeviceEXT clReleaseDeviceEXT; |
| 1185 | |
| 1186 | /* cl_khr_gl_event */ |
| 1187 | cl_api_clCreateEventFromGLsyncKHR clCreateEventFromGLsyncKHR; |
| 1188 | |
| 1189 | /* OpenCL 1.2 */ |
| 1190 | cl_api_clCreateSubDevices clCreateSubDevices; |
| 1191 | cl_api_clRetainDevice clRetainDevice; |
| 1192 | cl_api_clReleaseDevice clReleaseDevice; |
| 1193 | cl_api_clCreateImage clCreateImage; |
| 1194 | cl_api_clCreateProgramWithBuiltInKernels clCreateProgramWithBuiltInKernels; |
| 1195 | cl_api_clCompileProgram clCompileProgram; |
| 1196 | cl_api_clLinkProgram clLinkProgram; |
| 1197 | cl_api_clUnloadPlatformCompiler clUnloadPlatformCompiler; |
| 1198 | cl_api_clGetKernelArgInfo clGetKernelArgInfo; |
| 1199 | cl_api_clEnqueueFillBuffer clEnqueueFillBuffer; |
| 1200 | cl_api_clEnqueueFillImage clEnqueueFillImage; |
| 1201 | cl_api_clEnqueueMigrateMemObjects clEnqueueMigrateMemObjects; |
| 1202 | cl_api_clEnqueueMarkerWithWaitList clEnqueueMarkerWithWaitList; |
| 1203 | cl_api_clEnqueueBarrierWithWaitList clEnqueueBarrierWithWaitList; |
| 1204 | cl_api_clGetExtensionFunctionAddressForPlatform |
| 1205 | clGetExtensionFunctionAddressForPlatform; |
| 1206 | cl_api_clCreateFromGLTexture clCreateFromGLTexture; |
| 1207 | |
| 1208 | /* cl_khr_d3d11_sharing */ |
| 1209 | cl_api_clGetDeviceIDsFromD3D11KHR clGetDeviceIDsFromD3D11KHR; |
| 1210 | cl_api_clCreateFromD3D11BufferKHR clCreateFromD3D11BufferKHR; |
| 1211 | cl_api_clCreateFromD3D11Texture2DKHR clCreateFromD3D11Texture2DKHR; |
| 1212 | cl_api_clCreateFromD3D11Texture3DKHR clCreateFromD3D11Texture3DKHR; |
| 1213 | cl_api_clCreateFromDX9MediaSurfaceKHR clCreateFromDX9MediaSurfaceKHR; |
| 1214 | cl_api_clEnqueueAcquireD3D11ObjectsKHR clEnqueueAcquireD3D11ObjectsKHR; |
| 1215 | cl_api_clEnqueueReleaseD3D11ObjectsKHR clEnqueueReleaseD3D11ObjectsKHR; |
| 1216 | |
| 1217 | /* cl_khr_dx9_media_sharing */ |
| 1218 | cl_api_clGetDeviceIDsFromDX9MediaAdapterKHR |
| 1219 | clGetDeviceIDsFromDX9MediaAdapterKHR; |
| 1220 | cl_api_clEnqueueAcquireDX9MediaSurfacesKHR |
| 1221 | clEnqueueAcquireDX9MediaSurfacesKHR; |
| 1222 | cl_api_clEnqueueReleaseDX9MediaSurfacesKHR |
| 1223 | clEnqueueReleaseDX9MediaSurfacesKHR; |
| 1224 | |
| 1225 | /* cl_khr_egl_image */ |
| 1226 | cl_api_clCreateFromEGLImageKHR clCreateFromEGLImageKHR; |
| 1227 | cl_api_clEnqueueAcquireEGLObjectsKHR clEnqueueAcquireEGLObjectsKHR; |
| 1228 | cl_api_clEnqueueReleaseEGLObjectsKHR clEnqueueReleaseEGLObjectsKHR; |
| 1229 | |
| 1230 | /* cl_khr_egl_event */ |
| 1231 | cl_api_clCreateEventFromEGLSyncKHR clCreateEventFromEGLSyncKHR; |
| 1232 | |
| 1233 | /* OpenCL 2.0 */ |
| 1234 | cl_api_clCreateCommandQueueWithProperties clCreateCommandQueueWithProperties; |
| 1235 | cl_api_clCreatePipe clCreatePipe; |
| 1236 | cl_api_clGetPipeInfo clGetPipeInfo; |
| 1237 | cl_api_clSVMAlloc clSVMAlloc; |
| 1238 | cl_api_clSVMFree clSVMFree; |
| 1239 | cl_api_clEnqueueSVMFree clEnqueueSVMFree; |
| 1240 | cl_api_clEnqueueSVMMemcpy clEnqueueSVMMemcpy; |
| 1241 | cl_api_clEnqueueSVMMemFill clEnqueueSVMMemFill; |
| 1242 | cl_api_clEnqueueSVMMap clEnqueueSVMMap; |
| 1243 | cl_api_clEnqueueSVMUnmap clEnqueueSVMUnmap; |
| 1244 | cl_api_clCreateSamplerWithProperties clCreateSamplerWithProperties; |
| 1245 | cl_api_clSetKernelArgSVMPointer clSetKernelArgSVMPointer; |
| 1246 | cl_api_clSetKernelExecInfo clSetKernelExecInfo; |
| 1247 | |
| 1248 | /* cl_khr_sub_groups */ |
| 1249 | cl_api_clGetKernelSubGroupInfoKHR clGetKernelSubGroupInfoKHR; |
| 1250 | |
| 1251 | /* OpenCL 2.1 */ |
| 1252 | cl_api_clCloneKernel clCloneKernel; |
| 1253 | cl_api_clCreateProgramWithIL clCreateProgramWithIL; |
| 1254 | cl_api_clEnqueueSVMMigrateMem clEnqueueSVMMigrateMem; |
| 1255 | cl_api_clGetDeviceAndHostTimer clGetDeviceAndHostTimer; |
| 1256 | cl_api_clGetHostTimer clGetHostTimer; |
| 1257 | cl_api_clGetKernelSubGroupInfo clGetKernelSubGroupInfo; |
| 1258 | cl_api_clSetDefaultDeviceCommandQueue clSetDefaultDeviceCommandQueue; |
| 1259 | |
| 1260 | /* OpenCL 2.2 */ |
| 1261 | cl_api_clSetProgramReleaseCallback clSetProgramReleaseCallback; |
| 1262 | cl_api_clSetProgramSpecializationConstant clSetProgramSpecializationConstant; |
| 1263 | } cl_icd_dispatch; |
| 1264 | |
| 1265 | #ifdef __cplusplus |
| 1266 | } |
| 1267 | #endif |
| 1268 | |
| 1269 | #endif /* #ifndef OPENCL_CL_ICD_H */ |