Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1 | /******************************************************************************* |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 2 | * Copyright (c) 2008-2015 The Khronos Group Inc. |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 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 | * |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 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 | * |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 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_H |
| 30 | #define __OPENCL_CL_H |
| 31 | |
| 32 | #ifdef __APPLE__ |
| 33 | #include <OpenCL/cl_platform.h> |
| 34 | #else |
| 35 | #include <CL/cl_platform.h> |
| 36 | #endif |
| 37 | |
| 38 | #ifdef __cplusplus |
| 39 | extern "C" { |
| 40 | #endif |
| 41 | |
| 42 | /******************************************************************************/ |
| 43 | |
| 44 | typedef struct _cl_platform_id * cl_platform_id; |
| 45 | typedef struct _cl_device_id * cl_device_id; |
| 46 | typedef struct _cl_context * cl_context; |
| 47 | typedef struct _cl_command_queue * cl_command_queue; |
| 48 | typedef struct _cl_mem * cl_mem; |
| 49 | typedef struct _cl_program * cl_program; |
| 50 | typedef struct _cl_kernel * cl_kernel; |
| 51 | typedef struct _cl_event * cl_event; |
| 52 | typedef struct _cl_sampler * cl_sampler; |
| 53 | |
| 54 | typedef cl_uint cl_bool; /* WARNING! Unlike cl_ types in cl_platform.h, cl_bool is not guaranteed to be the same size as the bool in kernels. */ |
| 55 | typedef cl_ulong cl_bitfield; |
| 56 | typedef cl_bitfield cl_device_type; |
| 57 | typedef cl_uint cl_platform_info; |
| 58 | typedef cl_uint cl_device_info; |
| 59 | typedef cl_bitfield cl_device_fp_config; |
| 60 | typedef cl_uint cl_device_mem_cache_type; |
| 61 | typedef cl_uint cl_device_local_mem_type; |
| 62 | typedef cl_bitfield cl_device_exec_capabilities; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 63 | typedef cl_bitfield cl_device_svm_capabilities; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 64 | typedef cl_bitfield cl_command_queue_properties; |
| 65 | typedef intptr_t cl_device_partition_property; |
| 66 | typedef cl_bitfield cl_device_affinity_domain; |
| 67 | |
| 68 | typedef intptr_t cl_context_properties; |
| 69 | typedef cl_uint cl_context_info; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 70 | typedef cl_bitfield cl_queue_properties; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 71 | typedef cl_uint cl_command_queue_info; |
| 72 | typedef cl_uint cl_channel_order; |
| 73 | typedef cl_uint cl_channel_type; |
| 74 | typedef cl_bitfield cl_mem_flags; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 75 | typedef cl_bitfield cl_svm_mem_flags; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 76 | typedef cl_uint cl_mem_object_type; |
| 77 | typedef cl_uint cl_mem_info; |
| 78 | typedef cl_bitfield cl_mem_migration_flags; |
| 79 | typedef cl_uint cl_image_info; |
| 80 | typedef cl_uint cl_buffer_create_type; |
| 81 | typedef cl_uint cl_addressing_mode; |
| 82 | typedef cl_uint cl_filter_mode; |
| 83 | typedef cl_uint cl_sampler_info; |
| 84 | typedef cl_bitfield cl_map_flags; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 85 | typedef intptr_t cl_pipe_properties; |
| 86 | typedef cl_uint cl_pipe_info; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 87 | typedef cl_uint cl_program_info; |
| 88 | typedef cl_uint cl_program_build_info; |
| 89 | typedef cl_uint cl_program_binary_type; |
| 90 | typedef cl_int cl_build_status; |
| 91 | typedef cl_uint cl_kernel_info; |
| 92 | typedef cl_uint cl_kernel_arg_info; |
| 93 | typedef cl_uint cl_kernel_arg_address_qualifier; |
| 94 | typedef cl_uint cl_kernel_arg_access_qualifier; |
| 95 | typedef cl_bitfield cl_kernel_arg_type_qualifier; |
| 96 | typedef cl_uint cl_kernel_work_group_info; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 97 | typedef cl_uint cl_kernel_sub_group_info; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 98 | typedef cl_uint cl_event_info; |
| 99 | typedef cl_uint cl_command_type; |
| 100 | typedef cl_uint cl_profiling_info; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 101 | typedef cl_bitfield cl_sampler_properties; |
| 102 | typedef cl_uint cl_kernel_exec_info; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 103 | |
| 104 | typedef struct _cl_image_format { |
| 105 | cl_channel_order image_channel_order; |
| 106 | cl_channel_type image_channel_data_type; |
| 107 | } cl_image_format; |
| 108 | |
| 109 | typedef struct _cl_image_desc { |
| 110 | cl_mem_object_type image_type; |
| 111 | size_t image_width; |
| 112 | size_t image_height; |
| 113 | size_t image_depth; |
| 114 | size_t image_array_size; |
| 115 | size_t image_row_pitch; |
| 116 | size_t image_slice_pitch; |
| 117 | cl_uint num_mip_levels; |
| 118 | cl_uint num_samples; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 119 | #ifdef __GNUC__ |
| 120 | __extension__ /* Prevents warnings about anonymous union in -pedantic builds */ |
| 121 | #endif |
| 122 | union { |
| 123 | cl_mem buffer; |
| 124 | cl_mem mem_object; |
| 125 | }; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 126 | } cl_image_desc; |
| 127 | |
| 128 | typedef struct _cl_buffer_region { |
| 129 | size_t origin; |
| 130 | size_t size; |
| 131 | } cl_buffer_region; |
| 132 | |
| 133 | |
| 134 | /******************************************************************************/ |
| 135 | |
| 136 | /* Error Codes */ |
| 137 | #define CL_SUCCESS 0 |
| 138 | #define CL_DEVICE_NOT_FOUND -1 |
| 139 | #define CL_DEVICE_NOT_AVAILABLE -2 |
| 140 | #define CL_COMPILER_NOT_AVAILABLE -3 |
| 141 | #define CL_MEM_OBJECT_ALLOCATION_FAILURE -4 |
| 142 | #define CL_OUT_OF_RESOURCES -5 |
| 143 | #define CL_OUT_OF_HOST_MEMORY -6 |
| 144 | #define CL_PROFILING_INFO_NOT_AVAILABLE -7 |
| 145 | #define CL_MEM_COPY_OVERLAP -8 |
| 146 | #define CL_IMAGE_FORMAT_MISMATCH -9 |
| 147 | #define CL_IMAGE_FORMAT_NOT_SUPPORTED -10 |
| 148 | #define CL_BUILD_PROGRAM_FAILURE -11 |
| 149 | #define CL_MAP_FAILURE -12 |
| 150 | #define CL_MISALIGNED_SUB_BUFFER_OFFSET -13 |
| 151 | #define CL_EXEC_STATUS_ERROR_FOR_EVENTS_IN_WAIT_LIST -14 |
| 152 | #define CL_COMPILE_PROGRAM_FAILURE -15 |
| 153 | #define CL_LINKER_NOT_AVAILABLE -16 |
| 154 | #define CL_LINK_PROGRAM_FAILURE -17 |
| 155 | #define CL_DEVICE_PARTITION_FAILED -18 |
| 156 | #define CL_KERNEL_ARG_INFO_NOT_AVAILABLE -19 |
| 157 | |
| 158 | #define CL_INVALID_VALUE -30 |
| 159 | #define CL_INVALID_DEVICE_TYPE -31 |
| 160 | #define CL_INVALID_PLATFORM -32 |
| 161 | #define CL_INVALID_DEVICE -33 |
| 162 | #define CL_INVALID_CONTEXT -34 |
| 163 | #define CL_INVALID_QUEUE_PROPERTIES -35 |
| 164 | #define CL_INVALID_COMMAND_QUEUE -36 |
| 165 | #define CL_INVALID_HOST_PTR -37 |
| 166 | #define CL_INVALID_MEM_OBJECT -38 |
| 167 | #define CL_INVALID_IMAGE_FORMAT_DESCRIPTOR -39 |
| 168 | #define CL_INVALID_IMAGE_SIZE -40 |
| 169 | #define CL_INVALID_SAMPLER -41 |
| 170 | #define CL_INVALID_BINARY -42 |
| 171 | #define CL_INVALID_BUILD_OPTIONS -43 |
| 172 | #define CL_INVALID_PROGRAM -44 |
| 173 | #define CL_INVALID_PROGRAM_EXECUTABLE -45 |
| 174 | #define CL_INVALID_KERNEL_NAME -46 |
| 175 | #define CL_INVALID_KERNEL_DEFINITION -47 |
| 176 | #define CL_INVALID_KERNEL -48 |
| 177 | #define CL_INVALID_ARG_INDEX -49 |
| 178 | #define CL_INVALID_ARG_VALUE -50 |
| 179 | #define CL_INVALID_ARG_SIZE -51 |
| 180 | #define CL_INVALID_KERNEL_ARGS -52 |
| 181 | #define CL_INVALID_WORK_DIMENSION -53 |
| 182 | #define CL_INVALID_WORK_GROUP_SIZE -54 |
| 183 | #define CL_INVALID_WORK_ITEM_SIZE -55 |
| 184 | #define CL_INVALID_GLOBAL_OFFSET -56 |
| 185 | #define CL_INVALID_EVENT_WAIT_LIST -57 |
| 186 | #define CL_INVALID_EVENT -58 |
| 187 | #define CL_INVALID_OPERATION -59 |
| 188 | #define CL_INVALID_GL_OBJECT -60 |
| 189 | #define CL_INVALID_BUFFER_SIZE -61 |
| 190 | #define CL_INVALID_MIP_LEVEL -62 |
| 191 | #define CL_INVALID_GLOBAL_WORK_SIZE -63 |
| 192 | #define CL_INVALID_PROPERTY -64 |
| 193 | #define CL_INVALID_IMAGE_DESCRIPTOR -65 |
| 194 | #define CL_INVALID_COMPILER_OPTIONS -66 |
| 195 | #define CL_INVALID_LINKER_OPTIONS -67 |
| 196 | #define CL_INVALID_DEVICE_PARTITION_COUNT -68 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 197 | #define CL_INVALID_PIPE_SIZE -69 |
| 198 | #define CL_INVALID_DEVICE_QUEUE -70 |
| 199 | #define CL_INVALID_SPEC_ID -71 |
| 200 | #define CL_MAX_SIZE_RESTRICTION_EXCEEDED -72 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 201 | |
| 202 | /* OpenCL Version */ |
| 203 | #define CL_VERSION_1_0 1 |
| 204 | #define CL_VERSION_1_1 1 |
| 205 | #define CL_VERSION_1_2 1 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 206 | #define CL_VERSION_2_0 1 |
| 207 | #define CL_VERSION_2_1 1 |
| 208 | #define CL_VERSION_2_2 1 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 209 | |
| 210 | /* cl_bool */ |
| 211 | #define CL_FALSE 0 |
| 212 | #define CL_TRUE 1 |
| 213 | #define CL_BLOCKING CL_TRUE |
| 214 | #define CL_NON_BLOCKING CL_FALSE |
| 215 | |
| 216 | /* cl_platform_info */ |
| 217 | #define CL_PLATFORM_PROFILE 0x0900 |
| 218 | #define CL_PLATFORM_VERSION 0x0901 |
| 219 | #define CL_PLATFORM_NAME 0x0902 |
| 220 | #define CL_PLATFORM_VENDOR 0x0903 |
| 221 | #define CL_PLATFORM_EXTENSIONS 0x0904 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 222 | #define CL_PLATFORM_HOST_TIMER_RESOLUTION 0x0905 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 223 | |
| 224 | /* cl_device_type - bitfield */ |
| 225 | #define CL_DEVICE_TYPE_DEFAULT (1 << 0) |
| 226 | #define CL_DEVICE_TYPE_CPU (1 << 1) |
| 227 | #define CL_DEVICE_TYPE_GPU (1 << 2) |
| 228 | #define CL_DEVICE_TYPE_ACCELERATOR (1 << 3) |
| 229 | #define CL_DEVICE_TYPE_CUSTOM (1 << 4) |
| 230 | #define CL_DEVICE_TYPE_ALL 0xFFFFFFFF |
| 231 | |
| 232 | /* cl_device_info */ |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 233 | #define CL_DEVICE_TYPE 0x1000 |
| 234 | #define CL_DEVICE_VENDOR_ID 0x1001 |
| 235 | #define CL_DEVICE_MAX_COMPUTE_UNITS 0x1002 |
| 236 | #define CL_DEVICE_MAX_WORK_ITEM_DIMENSIONS 0x1003 |
| 237 | #define CL_DEVICE_MAX_WORK_GROUP_SIZE 0x1004 |
| 238 | #define CL_DEVICE_MAX_WORK_ITEM_SIZES 0x1005 |
| 239 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_CHAR 0x1006 |
| 240 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_SHORT 0x1007 |
| 241 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT 0x1008 |
| 242 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_LONG 0x1009 |
| 243 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_FLOAT 0x100A |
| 244 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_DOUBLE 0x100B |
| 245 | #define CL_DEVICE_MAX_CLOCK_FREQUENCY 0x100C |
| 246 | #define CL_DEVICE_ADDRESS_BITS 0x100D |
| 247 | #define CL_DEVICE_MAX_READ_IMAGE_ARGS 0x100E |
| 248 | #define CL_DEVICE_MAX_WRITE_IMAGE_ARGS 0x100F |
| 249 | #define CL_DEVICE_MAX_MEM_ALLOC_SIZE 0x1010 |
| 250 | #define CL_DEVICE_IMAGE2D_MAX_WIDTH 0x1011 |
| 251 | #define CL_DEVICE_IMAGE2D_MAX_HEIGHT 0x1012 |
| 252 | #define CL_DEVICE_IMAGE3D_MAX_WIDTH 0x1013 |
| 253 | #define CL_DEVICE_IMAGE3D_MAX_HEIGHT 0x1014 |
| 254 | #define CL_DEVICE_IMAGE3D_MAX_DEPTH 0x1015 |
| 255 | #define CL_DEVICE_IMAGE_SUPPORT 0x1016 |
| 256 | #define CL_DEVICE_MAX_PARAMETER_SIZE 0x1017 |
| 257 | #define CL_DEVICE_MAX_SAMPLERS 0x1018 |
| 258 | #define CL_DEVICE_MEM_BASE_ADDR_ALIGN 0x1019 |
| 259 | #define CL_DEVICE_MIN_DATA_TYPE_ALIGN_SIZE 0x101A |
| 260 | #define CL_DEVICE_SINGLE_FP_CONFIG 0x101B |
| 261 | #define CL_DEVICE_GLOBAL_MEM_CACHE_TYPE 0x101C |
| 262 | #define CL_DEVICE_GLOBAL_MEM_CACHELINE_SIZE 0x101D |
| 263 | #define CL_DEVICE_GLOBAL_MEM_CACHE_SIZE 0x101E |
| 264 | #define CL_DEVICE_GLOBAL_MEM_SIZE 0x101F |
| 265 | #define CL_DEVICE_MAX_CONSTANT_BUFFER_SIZE 0x1020 |
| 266 | #define CL_DEVICE_MAX_CONSTANT_ARGS 0x1021 |
| 267 | #define CL_DEVICE_LOCAL_MEM_TYPE 0x1022 |
| 268 | #define CL_DEVICE_LOCAL_MEM_SIZE 0x1023 |
| 269 | #define CL_DEVICE_ERROR_CORRECTION_SUPPORT 0x1024 |
| 270 | #define CL_DEVICE_PROFILING_TIMER_RESOLUTION 0x1025 |
| 271 | #define CL_DEVICE_ENDIAN_LITTLE 0x1026 |
| 272 | #define CL_DEVICE_AVAILABLE 0x1027 |
| 273 | #define CL_DEVICE_COMPILER_AVAILABLE 0x1028 |
| 274 | #define CL_DEVICE_EXECUTION_CAPABILITIES 0x1029 |
| 275 | #define CL_DEVICE_QUEUE_PROPERTIES 0x102A /* deprecated */ |
| 276 | #define CL_DEVICE_QUEUE_ON_HOST_PROPERTIES 0x102A |
| 277 | #define CL_DEVICE_NAME 0x102B |
| 278 | #define CL_DEVICE_VENDOR 0x102C |
| 279 | #define CL_DRIVER_VERSION 0x102D |
| 280 | #define CL_DEVICE_PROFILE 0x102E |
| 281 | #define CL_DEVICE_VERSION 0x102F |
| 282 | #define CL_DEVICE_EXTENSIONS 0x1030 |
| 283 | #define CL_DEVICE_PLATFORM 0x1031 |
| 284 | #define CL_DEVICE_DOUBLE_FP_CONFIG 0x1032 |
| 285 | #define CL_DEVICE_HALF_FP_CONFIG 0x1033 |
| 286 | #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_HALF 0x1034 |
| 287 | #define CL_DEVICE_HOST_UNIFIED_MEMORY 0x1035 /* deprecated */ |
| 288 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_CHAR 0x1036 |
| 289 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_SHORT 0x1037 |
| 290 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_INT 0x1038 |
| 291 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_LONG 0x1039 |
| 292 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_FLOAT 0x103A |
| 293 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE 0x103B |
| 294 | #define CL_DEVICE_NATIVE_VECTOR_WIDTH_HALF 0x103C |
| 295 | #define CL_DEVICE_OPENCL_C_VERSION 0x103D |
| 296 | #define CL_DEVICE_LINKER_AVAILABLE 0x103E |
| 297 | #define CL_DEVICE_BUILT_IN_KERNELS 0x103F |
| 298 | #define CL_DEVICE_IMAGE_MAX_BUFFER_SIZE 0x1040 |
| 299 | #define CL_DEVICE_IMAGE_MAX_ARRAY_SIZE 0x1041 |
| 300 | #define CL_DEVICE_PARENT_DEVICE 0x1042 |
| 301 | #define CL_DEVICE_PARTITION_MAX_SUB_DEVICES 0x1043 |
| 302 | #define CL_DEVICE_PARTITION_PROPERTIES 0x1044 |
| 303 | #define CL_DEVICE_PARTITION_AFFINITY_DOMAIN 0x1045 |
| 304 | #define CL_DEVICE_PARTITION_TYPE 0x1046 |
| 305 | #define CL_DEVICE_REFERENCE_COUNT 0x1047 |
| 306 | #define CL_DEVICE_PREFERRED_INTEROP_USER_SYNC 0x1048 |
| 307 | #define CL_DEVICE_PRINTF_BUFFER_SIZE 0x1049 |
| 308 | #define CL_DEVICE_IMAGE_PITCH_ALIGNMENT 0x104A |
| 309 | #define CL_DEVICE_IMAGE_BASE_ADDRESS_ALIGNMENT 0x104B |
| 310 | #define CL_DEVICE_MAX_READ_WRITE_IMAGE_ARGS 0x104C |
| 311 | #define CL_DEVICE_MAX_GLOBAL_VARIABLE_SIZE 0x104D |
| 312 | #define CL_DEVICE_QUEUE_ON_DEVICE_PROPERTIES 0x104E |
| 313 | #define CL_DEVICE_QUEUE_ON_DEVICE_PREFERRED_SIZE 0x104F |
| 314 | #define CL_DEVICE_QUEUE_ON_DEVICE_MAX_SIZE 0x1050 |
| 315 | #define CL_DEVICE_MAX_ON_DEVICE_QUEUES 0x1051 |
| 316 | #define CL_DEVICE_MAX_ON_DEVICE_EVENTS 0x1052 |
| 317 | #define CL_DEVICE_SVM_CAPABILITIES 0x1053 |
| 318 | #define CL_DEVICE_GLOBAL_VARIABLE_PREFERRED_TOTAL_SIZE 0x1054 |
| 319 | #define CL_DEVICE_MAX_PIPE_ARGS 0x1055 |
| 320 | #define CL_DEVICE_PIPE_MAX_ACTIVE_RESERVATIONS 0x1056 |
| 321 | #define CL_DEVICE_PIPE_MAX_PACKET_SIZE 0x1057 |
| 322 | #define CL_DEVICE_PREFERRED_PLATFORM_ATOMIC_ALIGNMENT 0x1058 |
| 323 | #define CL_DEVICE_PREFERRED_GLOBAL_ATOMIC_ALIGNMENT 0x1059 |
| 324 | #define CL_DEVICE_PREFERRED_LOCAL_ATOMIC_ALIGNMENT 0x105A |
| 325 | #define CL_DEVICE_IL_VERSION 0x105B |
| 326 | #define CL_DEVICE_MAX_NUM_SUB_GROUPS 0x105C |
| 327 | #define CL_DEVICE_SUB_GROUP_INDEPENDENT_FORWARD_PROGRESS 0x105D |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 328 | |
| 329 | /* cl_device_fp_config - bitfield */ |
| 330 | #define CL_FP_DENORM (1 << 0) |
| 331 | #define CL_FP_INF_NAN (1 << 1) |
| 332 | #define CL_FP_ROUND_TO_NEAREST (1 << 2) |
| 333 | #define CL_FP_ROUND_TO_ZERO (1 << 3) |
| 334 | #define CL_FP_ROUND_TO_INF (1 << 4) |
| 335 | #define CL_FP_FMA (1 << 5) |
| 336 | #define CL_FP_SOFT_FLOAT (1 << 6) |
| 337 | #define CL_FP_CORRECTLY_ROUNDED_DIVIDE_SQRT (1 << 7) |
| 338 | |
| 339 | /* cl_device_mem_cache_type */ |
| 340 | #define CL_NONE 0x0 |
| 341 | #define CL_READ_ONLY_CACHE 0x1 |
| 342 | #define CL_READ_WRITE_CACHE 0x2 |
| 343 | |
| 344 | /* cl_device_local_mem_type */ |
| 345 | #define CL_LOCAL 0x1 |
| 346 | #define CL_GLOBAL 0x2 |
| 347 | |
| 348 | /* cl_device_exec_capabilities - bitfield */ |
| 349 | #define CL_EXEC_KERNEL (1 << 0) |
| 350 | #define CL_EXEC_NATIVE_KERNEL (1 << 1) |
| 351 | |
| 352 | /* cl_command_queue_properties - bitfield */ |
| 353 | #define CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE (1 << 0) |
| 354 | #define CL_QUEUE_PROFILING_ENABLE (1 << 1) |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 355 | #define CL_QUEUE_ON_DEVICE (1 << 2) |
| 356 | #define CL_QUEUE_ON_DEVICE_DEFAULT (1 << 3) |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 357 | |
| 358 | /* cl_context_info */ |
| 359 | #define CL_CONTEXT_REFERENCE_COUNT 0x1080 |
| 360 | #define CL_CONTEXT_DEVICES 0x1081 |
| 361 | #define CL_CONTEXT_PROPERTIES 0x1082 |
| 362 | #define CL_CONTEXT_NUM_DEVICES 0x1083 |
| 363 | |
| 364 | /* cl_context_properties */ |
| 365 | #define CL_CONTEXT_PLATFORM 0x1084 |
| 366 | #define CL_CONTEXT_INTEROP_USER_SYNC 0x1085 |
| 367 | |
| 368 | /* cl_device_partition_property */ |
| 369 | #define CL_DEVICE_PARTITION_EQUALLY 0x1086 |
| 370 | #define CL_DEVICE_PARTITION_BY_COUNTS 0x1087 |
| 371 | #define CL_DEVICE_PARTITION_BY_COUNTS_LIST_END 0x0 |
| 372 | #define CL_DEVICE_PARTITION_BY_AFFINITY_DOMAIN 0x1088 |
| 373 | |
| 374 | /* cl_device_affinity_domain */ |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 375 | #define CL_DEVICE_AFFINITY_DOMAIN_NUMA (1 << 0) |
| 376 | #define CL_DEVICE_AFFINITY_DOMAIN_L4_CACHE (1 << 1) |
| 377 | #define CL_DEVICE_AFFINITY_DOMAIN_L3_CACHE (1 << 2) |
| 378 | #define CL_DEVICE_AFFINITY_DOMAIN_L2_CACHE (1 << 3) |
| 379 | #define CL_DEVICE_AFFINITY_DOMAIN_L1_CACHE (1 << 4) |
| 380 | #define CL_DEVICE_AFFINITY_DOMAIN_NEXT_PARTITIONABLE (1 << 5) |
| 381 | |
| 382 | /* cl_device_svm_capabilities */ |
| 383 | #define CL_DEVICE_SVM_COARSE_GRAIN_BUFFER (1 << 0) |
| 384 | #define CL_DEVICE_SVM_FINE_GRAIN_BUFFER (1 << 1) |
| 385 | #define CL_DEVICE_SVM_FINE_GRAIN_SYSTEM (1 << 2) |
| 386 | #define CL_DEVICE_SVM_ATOMICS (1 << 3) |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 387 | |
| 388 | /* cl_command_queue_info */ |
| 389 | #define CL_QUEUE_CONTEXT 0x1090 |
| 390 | #define CL_QUEUE_DEVICE 0x1091 |
| 391 | #define CL_QUEUE_REFERENCE_COUNT 0x1092 |
| 392 | #define CL_QUEUE_PROPERTIES 0x1093 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 393 | #define CL_QUEUE_SIZE 0x1094 |
| 394 | #define CL_QUEUE_DEVICE_DEFAULT 0x1095 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 395 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 396 | /* cl_mem_flags and cl_svm_mem_flags - bitfield */ |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 397 | #define CL_MEM_READ_WRITE (1 << 0) |
| 398 | #define CL_MEM_WRITE_ONLY (1 << 1) |
| 399 | #define CL_MEM_READ_ONLY (1 << 2) |
| 400 | #define CL_MEM_USE_HOST_PTR (1 << 3) |
| 401 | #define CL_MEM_ALLOC_HOST_PTR (1 << 4) |
| 402 | #define CL_MEM_COPY_HOST_PTR (1 << 5) |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 403 | /* reserved (1 << 6) */ |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 404 | #define CL_MEM_HOST_WRITE_ONLY (1 << 7) |
| 405 | #define CL_MEM_HOST_READ_ONLY (1 << 8) |
| 406 | #define CL_MEM_HOST_NO_ACCESS (1 << 9) |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 407 | #define CL_MEM_SVM_FINE_GRAIN_BUFFER (1 << 10) /* used by cl_svm_mem_flags only */ |
| 408 | #define CL_MEM_SVM_ATOMICS (1 << 11) /* used by cl_svm_mem_flags only */ |
| 409 | #define CL_MEM_KERNEL_READ_AND_WRITE (1 << 12) |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 410 | |
| 411 | /* cl_mem_migration_flags - bitfield */ |
| 412 | #define CL_MIGRATE_MEM_OBJECT_HOST (1 << 0) |
| 413 | #define CL_MIGRATE_MEM_OBJECT_CONTENT_UNDEFINED (1 << 1) |
| 414 | |
| 415 | /* cl_channel_order */ |
| 416 | #define CL_R 0x10B0 |
| 417 | #define CL_A 0x10B1 |
| 418 | #define CL_RG 0x10B2 |
| 419 | #define CL_RA 0x10B3 |
| 420 | #define CL_RGB 0x10B4 |
| 421 | #define CL_RGBA 0x10B5 |
| 422 | #define CL_BGRA 0x10B6 |
| 423 | #define CL_ARGB 0x10B7 |
| 424 | #define CL_INTENSITY 0x10B8 |
| 425 | #define CL_LUMINANCE 0x10B9 |
| 426 | #define CL_Rx 0x10BA |
| 427 | #define CL_RGx 0x10BB |
| 428 | #define CL_RGBx 0x10BC |
| 429 | #define CL_DEPTH 0x10BD |
| 430 | #define CL_DEPTH_STENCIL 0x10BE |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 431 | #define CL_sRGB 0x10BF |
| 432 | #define CL_sRGBx 0x10C0 |
| 433 | #define CL_sRGBA 0x10C1 |
| 434 | #define CL_sBGRA 0x10C2 |
| 435 | #define CL_ABGR 0x10C3 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 436 | |
| 437 | /* cl_channel_type */ |
| 438 | #define CL_SNORM_INT8 0x10D0 |
| 439 | #define CL_SNORM_INT16 0x10D1 |
| 440 | #define CL_UNORM_INT8 0x10D2 |
| 441 | #define CL_UNORM_INT16 0x10D3 |
| 442 | #define CL_UNORM_SHORT_565 0x10D4 |
| 443 | #define CL_UNORM_SHORT_555 0x10D5 |
| 444 | #define CL_UNORM_INT_101010 0x10D6 |
| 445 | #define CL_SIGNED_INT8 0x10D7 |
| 446 | #define CL_SIGNED_INT16 0x10D8 |
| 447 | #define CL_SIGNED_INT32 0x10D9 |
| 448 | #define CL_UNSIGNED_INT8 0x10DA |
| 449 | #define CL_UNSIGNED_INT16 0x10DB |
| 450 | #define CL_UNSIGNED_INT32 0x10DC |
| 451 | #define CL_HALF_FLOAT 0x10DD |
| 452 | #define CL_FLOAT 0x10DE |
| 453 | #define CL_UNORM_INT24 0x10DF |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 454 | #define CL_UNORM_INT_101010_2 0x10E0 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 455 | |
| 456 | /* cl_mem_object_type */ |
| 457 | #define CL_MEM_OBJECT_BUFFER 0x10F0 |
| 458 | #define CL_MEM_OBJECT_IMAGE2D 0x10F1 |
| 459 | #define CL_MEM_OBJECT_IMAGE3D 0x10F2 |
| 460 | #define CL_MEM_OBJECT_IMAGE2D_ARRAY 0x10F3 |
| 461 | #define CL_MEM_OBJECT_IMAGE1D 0x10F4 |
| 462 | #define CL_MEM_OBJECT_IMAGE1D_ARRAY 0x10F5 |
| 463 | #define CL_MEM_OBJECT_IMAGE1D_BUFFER 0x10F6 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 464 | #define CL_MEM_OBJECT_PIPE 0x10F7 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 465 | |
| 466 | /* cl_mem_info */ |
| 467 | #define CL_MEM_TYPE 0x1100 |
| 468 | #define CL_MEM_FLAGS 0x1101 |
| 469 | #define CL_MEM_SIZE 0x1102 |
| 470 | #define CL_MEM_HOST_PTR 0x1103 |
| 471 | #define CL_MEM_MAP_COUNT 0x1104 |
| 472 | #define CL_MEM_REFERENCE_COUNT 0x1105 |
| 473 | #define CL_MEM_CONTEXT 0x1106 |
| 474 | #define CL_MEM_ASSOCIATED_MEMOBJECT 0x1107 |
| 475 | #define CL_MEM_OFFSET 0x1108 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 476 | #define CL_MEM_USES_SVM_POINTER 0x1109 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 477 | |
| 478 | /* cl_image_info */ |
| 479 | #define CL_IMAGE_FORMAT 0x1110 |
| 480 | #define CL_IMAGE_ELEMENT_SIZE 0x1111 |
| 481 | #define CL_IMAGE_ROW_PITCH 0x1112 |
| 482 | #define CL_IMAGE_SLICE_PITCH 0x1113 |
| 483 | #define CL_IMAGE_WIDTH 0x1114 |
| 484 | #define CL_IMAGE_HEIGHT 0x1115 |
| 485 | #define CL_IMAGE_DEPTH 0x1116 |
| 486 | #define CL_IMAGE_ARRAY_SIZE 0x1117 |
| 487 | #define CL_IMAGE_BUFFER 0x1118 |
| 488 | #define CL_IMAGE_NUM_MIP_LEVELS 0x1119 |
| 489 | #define CL_IMAGE_NUM_SAMPLES 0x111A |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 490 | |
| 491 | /* cl_pipe_info */ |
| 492 | #define CL_PIPE_PACKET_SIZE 0x1120 |
| 493 | #define CL_PIPE_MAX_PACKETS 0x1121 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 494 | |
| 495 | /* cl_addressing_mode */ |
| 496 | #define CL_ADDRESS_NONE 0x1130 |
| 497 | #define CL_ADDRESS_CLAMP_TO_EDGE 0x1131 |
| 498 | #define CL_ADDRESS_CLAMP 0x1132 |
| 499 | #define CL_ADDRESS_REPEAT 0x1133 |
| 500 | #define CL_ADDRESS_MIRRORED_REPEAT 0x1134 |
| 501 | |
| 502 | /* cl_filter_mode */ |
| 503 | #define CL_FILTER_NEAREST 0x1140 |
| 504 | #define CL_FILTER_LINEAR 0x1141 |
| 505 | |
| 506 | /* cl_sampler_info */ |
| 507 | #define CL_SAMPLER_REFERENCE_COUNT 0x1150 |
| 508 | #define CL_SAMPLER_CONTEXT 0x1151 |
| 509 | #define CL_SAMPLER_NORMALIZED_COORDS 0x1152 |
| 510 | #define CL_SAMPLER_ADDRESSING_MODE 0x1153 |
| 511 | #define CL_SAMPLER_FILTER_MODE 0x1154 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 512 | #define CL_SAMPLER_MIP_FILTER_MODE 0x1155 |
| 513 | #define CL_SAMPLER_LOD_MIN 0x1156 |
| 514 | #define CL_SAMPLER_LOD_MAX 0x1157 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 515 | |
| 516 | /* cl_map_flags - bitfield */ |
| 517 | #define CL_MAP_READ (1 << 0) |
| 518 | #define CL_MAP_WRITE (1 << 1) |
| 519 | #define CL_MAP_WRITE_INVALIDATE_REGION (1 << 2) |
| 520 | |
| 521 | /* cl_program_info */ |
| 522 | #define CL_PROGRAM_REFERENCE_COUNT 0x1160 |
| 523 | #define CL_PROGRAM_CONTEXT 0x1161 |
| 524 | #define CL_PROGRAM_NUM_DEVICES 0x1162 |
| 525 | #define CL_PROGRAM_DEVICES 0x1163 |
| 526 | #define CL_PROGRAM_SOURCE 0x1164 |
| 527 | #define CL_PROGRAM_BINARY_SIZES 0x1165 |
| 528 | #define CL_PROGRAM_BINARIES 0x1166 |
| 529 | #define CL_PROGRAM_NUM_KERNELS 0x1167 |
| 530 | #define CL_PROGRAM_KERNEL_NAMES 0x1168 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 531 | #define CL_PROGRAM_IL 0x1169 |
| 532 | #define CL_PROGRAM_SCOPE_GLOBAL_CTORS_PRESENT 0x116A |
| 533 | #define CL_PROGRAM_SCOPE_GLOBAL_DTORS_PRESENT 0x116B |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 534 | |
| 535 | /* cl_program_build_info */ |
| 536 | #define CL_PROGRAM_BUILD_STATUS 0x1181 |
| 537 | #define CL_PROGRAM_BUILD_OPTIONS 0x1182 |
| 538 | #define CL_PROGRAM_BUILD_LOG 0x1183 |
| 539 | #define CL_PROGRAM_BINARY_TYPE 0x1184 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 540 | #define CL_PROGRAM_BUILD_GLOBAL_VARIABLE_TOTAL_SIZE 0x1185 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 541 | |
| 542 | /* cl_program_binary_type */ |
| 543 | #define CL_PROGRAM_BINARY_TYPE_NONE 0x0 |
| 544 | #define CL_PROGRAM_BINARY_TYPE_COMPILED_OBJECT 0x1 |
| 545 | #define CL_PROGRAM_BINARY_TYPE_LIBRARY 0x2 |
| 546 | #define CL_PROGRAM_BINARY_TYPE_EXECUTABLE 0x4 |
| 547 | |
| 548 | /* cl_build_status */ |
| 549 | #define CL_BUILD_SUCCESS 0 |
| 550 | #define CL_BUILD_NONE -1 |
| 551 | #define CL_BUILD_ERROR -2 |
| 552 | #define CL_BUILD_IN_PROGRESS -3 |
| 553 | |
| 554 | /* cl_kernel_info */ |
| 555 | #define CL_KERNEL_FUNCTION_NAME 0x1190 |
| 556 | #define CL_KERNEL_NUM_ARGS 0x1191 |
| 557 | #define CL_KERNEL_REFERENCE_COUNT 0x1192 |
| 558 | #define CL_KERNEL_CONTEXT 0x1193 |
| 559 | #define CL_KERNEL_PROGRAM 0x1194 |
| 560 | #define CL_KERNEL_ATTRIBUTES 0x1195 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 561 | #define CL_KERNEL_MAX_NUM_SUB_GROUPS 0x11B9 |
| 562 | #define CL_KERNEL_COMPILE_NUM_SUB_GROUPS 0x11BA |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 563 | |
| 564 | /* cl_kernel_arg_info */ |
| 565 | #define CL_KERNEL_ARG_ADDRESS_QUALIFIER 0x1196 |
| 566 | #define CL_KERNEL_ARG_ACCESS_QUALIFIER 0x1197 |
| 567 | #define CL_KERNEL_ARG_TYPE_NAME 0x1198 |
| 568 | #define CL_KERNEL_ARG_TYPE_QUALIFIER 0x1199 |
| 569 | #define CL_KERNEL_ARG_NAME 0x119A |
| 570 | |
| 571 | /* cl_kernel_arg_address_qualifier */ |
| 572 | #define CL_KERNEL_ARG_ADDRESS_GLOBAL 0x119B |
| 573 | #define CL_KERNEL_ARG_ADDRESS_LOCAL 0x119C |
| 574 | #define CL_KERNEL_ARG_ADDRESS_CONSTANT 0x119D |
| 575 | #define CL_KERNEL_ARG_ADDRESS_PRIVATE 0x119E |
| 576 | |
| 577 | /* cl_kernel_arg_access_qualifier */ |
| 578 | #define CL_KERNEL_ARG_ACCESS_READ_ONLY 0x11A0 |
| 579 | #define CL_KERNEL_ARG_ACCESS_WRITE_ONLY 0x11A1 |
| 580 | #define CL_KERNEL_ARG_ACCESS_READ_WRITE 0x11A2 |
| 581 | #define CL_KERNEL_ARG_ACCESS_NONE 0x11A3 |
| 582 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 583 | /* cl_kernel_arg_type_qualifier */ |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 584 | #define CL_KERNEL_ARG_TYPE_NONE 0 |
| 585 | #define CL_KERNEL_ARG_TYPE_CONST (1 << 0) |
| 586 | #define CL_KERNEL_ARG_TYPE_RESTRICT (1 << 1) |
| 587 | #define CL_KERNEL_ARG_TYPE_VOLATILE (1 << 2) |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 588 | #define CL_KERNEL_ARG_TYPE_PIPE (1 << 3) |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 589 | |
| 590 | /* cl_kernel_work_group_info */ |
| 591 | #define CL_KERNEL_WORK_GROUP_SIZE 0x11B0 |
| 592 | #define CL_KERNEL_COMPILE_WORK_GROUP_SIZE 0x11B1 |
| 593 | #define CL_KERNEL_LOCAL_MEM_SIZE 0x11B2 |
| 594 | #define CL_KERNEL_PREFERRED_WORK_GROUP_SIZE_MULTIPLE 0x11B3 |
| 595 | #define CL_KERNEL_PRIVATE_MEM_SIZE 0x11B4 |
| 596 | #define CL_KERNEL_GLOBAL_WORK_SIZE 0x11B5 |
| 597 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 598 | /* cl_kernel_sub_group_info */ |
| 599 | #define CL_KERNEL_MAX_SUB_GROUP_SIZE_FOR_NDRANGE 0x2033 |
| 600 | #define CL_KERNEL_SUB_GROUP_COUNT_FOR_NDRANGE 0x2034 |
| 601 | #define CL_KERNEL_LOCAL_SIZE_FOR_SUB_GROUP_COUNT 0x11B8 |
| 602 | |
| 603 | /* cl_kernel_exec_info */ |
| 604 | #define CL_KERNEL_EXEC_INFO_SVM_PTRS 0x11B6 |
| 605 | #define CL_KERNEL_EXEC_INFO_SVM_FINE_GRAIN_SYSTEM 0x11B7 |
| 606 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 607 | /* cl_event_info */ |
| 608 | #define CL_EVENT_COMMAND_QUEUE 0x11D0 |
| 609 | #define CL_EVENT_COMMAND_TYPE 0x11D1 |
| 610 | #define CL_EVENT_REFERENCE_COUNT 0x11D2 |
| 611 | #define CL_EVENT_COMMAND_EXECUTION_STATUS 0x11D3 |
| 612 | #define CL_EVENT_CONTEXT 0x11D4 |
| 613 | |
| 614 | /* cl_command_type */ |
| 615 | #define CL_COMMAND_NDRANGE_KERNEL 0x11F0 |
| 616 | #define CL_COMMAND_TASK 0x11F1 |
| 617 | #define CL_COMMAND_NATIVE_KERNEL 0x11F2 |
| 618 | #define CL_COMMAND_READ_BUFFER 0x11F3 |
| 619 | #define CL_COMMAND_WRITE_BUFFER 0x11F4 |
| 620 | #define CL_COMMAND_COPY_BUFFER 0x11F5 |
| 621 | #define CL_COMMAND_READ_IMAGE 0x11F6 |
| 622 | #define CL_COMMAND_WRITE_IMAGE 0x11F7 |
| 623 | #define CL_COMMAND_COPY_IMAGE 0x11F8 |
| 624 | #define CL_COMMAND_COPY_IMAGE_TO_BUFFER 0x11F9 |
| 625 | #define CL_COMMAND_COPY_BUFFER_TO_IMAGE 0x11FA |
| 626 | #define CL_COMMAND_MAP_BUFFER 0x11FB |
| 627 | #define CL_COMMAND_MAP_IMAGE 0x11FC |
| 628 | #define CL_COMMAND_UNMAP_MEM_OBJECT 0x11FD |
| 629 | #define CL_COMMAND_MARKER 0x11FE |
| 630 | #define CL_COMMAND_ACQUIRE_GL_OBJECTS 0x11FF |
| 631 | #define CL_COMMAND_RELEASE_GL_OBJECTS 0x1200 |
| 632 | #define CL_COMMAND_READ_BUFFER_RECT 0x1201 |
| 633 | #define CL_COMMAND_WRITE_BUFFER_RECT 0x1202 |
| 634 | #define CL_COMMAND_COPY_BUFFER_RECT 0x1203 |
| 635 | #define CL_COMMAND_USER 0x1204 |
| 636 | #define CL_COMMAND_BARRIER 0x1205 |
| 637 | #define CL_COMMAND_MIGRATE_MEM_OBJECTS 0x1206 |
| 638 | #define CL_COMMAND_FILL_BUFFER 0x1207 |
| 639 | #define CL_COMMAND_FILL_IMAGE 0x1208 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 640 | #define CL_COMMAND_SVM_FREE 0x1209 |
| 641 | #define CL_COMMAND_SVM_MEMCPY 0x120A |
| 642 | #define CL_COMMAND_SVM_MEMFILL 0x120B |
| 643 | #define CL_COMMAND_SVM_MAP 0x120C |
| 644 | #define CL_COMMAND_SVM_UNMAP 0x120D |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 645 | |
| 646 | /* command execution status */ |
| 647 | #define CL_COMPLETE 0x0 |
| 648 | #define CL_RUNNING 0x1 |
| 649 | #define CL_SUBMITTED 0x2 |
| 650 | #define CL_QUEUED 0x3 |
| 651 | |
| 652 | /* cl_buffer_create_type */ |
| 653 | #define CL_BUFFER_CREATE_TYPE_REGION 0x1220 |
| 654 | |
| 655 | /* cl_profiling_info */ |
| 656 | #define CL_PROFILING_COMMAND_QUEUED 0x1280 |
| 657 | #define CL_PROFILING_COMMAND_SUBMIT 0x1281 |
| 658 | #define CL_PROFILING_COMMAND_START 0x1282 |
| 659 | #define CL_PROFILING_COMMAND_END 0x1283 |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 660 | #define CL_PROFILING_COMMAND_COMPLETE 0x1284 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 661 | |
| 662 | /********************************************************************************************************/ |
| 663 | |
| 664 | /* Platform API */ |
| 665 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 666 | clGetPlatformIDs(cl_uint /* num_entries */, |
| 667 | cl_platform_id * /* platforms */, |
| 668 | cl_uint * /* num_platforms */) CL_API_SUFFIX__VERSION_1_0; |
| 669 | |
| 670 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 671 | clGetPlatformInfo(cl_platform_id /* platform */, |
| 672 | cl_platform_info /* param_name */, |
| 673 | size_t /* param_value_size */, |
| 674 | void * /* param_value */, |
| 675 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 676 | |
| 677 | /* Device APIs */ |
| 678 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 679 | clGetDeviceIDs(cl_platform_id /* platform */, |
| 680 | cl_device_type /* device_type */, |
| 681 | cl_uint /* num_entries */, |
| 682 | cl_device_id * /* devices */, |
| 683 | cl_uint * /* num_devices */) CL_API_SUFFIX__VERSION_1_0; |
| 684 | |
| 685 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 686 | clGetDeviceInfo(cl_device_id /* device */, |
| 687 | cl_device_info /* param_name */, |
| 688 | size_t /* param_value_size */, |
| 689 | void * /* param_value */, |
| 690 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 691 | |
| 692 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 693 | clCreateSubDevices(cl_device_id /* in_device */, |
| 694 | const cl_device_partition_property * /* properties */, |
| 695 | cl_uint /* num_devices */, |
| 696 | cl_device_id * /* out_devices */, |
| 697 | cl_uint * /* num_devices_ret */) CL_API_SUFFIX__VERSION_1_2; |
| 698 | |
| 699 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 700 | clRetainDevice(cl_device_id /* device */) CL_API_SUFFIX__VERSION_1_2; |
| 701 | |
| 702 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 703 | clReleaseDevice(cl_device_id /* device */) CL_API_SUFFIX__VERSION_1_2; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 704 | |
| 705 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 706 | clSetDefaultDeviceCommandQueue(cl_context /* context */, |
| 707 | cl_device_id /* device */, |
| 708 | cl_command_queue /* command_queue */) CL_API_SUFFIX__VERSION_2_1; |
| 709 | |
| 710 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 711 | clGetDeviceAndHostTimer(cl_device_id /* device */, |
| 712 | cl_ulong* /* device_timestamp */, |
| 713 | cl_ulong* /* host_timestamp */) CL_API_SUFFIX__VERSION_2_1; |
| 714 | |
| 715 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 716 | clGetHostTimer(cl_device_id /* device */, |
| 717 | cl_ulong * /* host_timestamp */) CL_API_SUFFIX__VERSION_2_1; |
| 718 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 719 | |
| 720 | /* Context APIs */ |
| 721 | extern CL_API_ENTRY cl_context CL_API_CALL |
| 722 | clCreateContext(const cl_context_properties * /* properties */, |
| 723 | cl_uint /* num_devices */, |
| 724 | const cl_device_id * /* devices */, |
| 725 | void (CL_CALLBACK * /* pfn_notify */)(const char *, const void *, size_t, void *), |
| 726 | void * /* user_data */, |
| 727 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 728 | |
| 729 | extern CL_API_ENTRY cl_context CL_API_CALL |
| 730 | clCreateContextFromType(const cl_context_properties * /* properties */, |
| 731 | cl_device_type /* device_type */, |
| 732 | void (CL_CALLBACK * /* pfn_notify*/ )(const char *, const void *, size_t, void *), |
| 733 | void * /* user_data */, |
| 734 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 735 | |
| 736 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 737 | clRetainContext(cl_context /* context */) CL_API_SUFFIX__VERSION_1_0; |
| 738 | |
| 739 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 740 | clReleaseContext(cl_context /* context */) CL_API_SUFFIX__VERSION_1_0; |
| 741 | |
| 742 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 743 | clGetContextInfo(cl_context /* context */, |
| 744 | cl_context_info /* param_name */, |
| 745 | size_t /* param_value_size */, |
| 746 | void * /* param_value */, |
| 747 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 748 | |
| 749 | /* Command Queue APIs */ |
| 750 | extern CL_API_ENTRY cl_command_queue CL_API_CALL |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 751 | clCreateCommandQueueWithProperties(cl_context /* context */, |
| 752 | cl_device_id /* device */, |
| 753 | const cl_queue_properties * /* properties */, |
| 754 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_2_0; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 755 | |
| 756 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 757 | clRetainCommandQueue(cl_command_queue /* command_queue */) CL_API_SUFFIX__VERSION_1_0; |
| 758 | |
| 759 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 760 | clReleaseCommandQueue(cl_command_queue /* command_queue */) CL_API_SUFFIX__VERSION_1_0; |
| 761 | |
| 762 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 763 | clGetCommandQueueInfo(cl_command_queue /* command_queue */, |
| 764 | cl_command_queue_info /* param_name */, |
| 765 | size_t /* param_value_size */, |
| 766 | void * /* param_value */, |
| 767 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 768 | |
| 769 | /* Memory Object APIs */ |
| 770 | extern CL_API_ENTRY cl_mem CL_API_CALL |
| 771 | clCreateBuffer(cl_context /* context */, |
| 772 | cl_mem_flags /* flags */, |
| 773 | size_t /* size */, |
| 774 | void * /* host_ptr */, |
| 775 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 776 | |
| 777 | extern CL_API_ENTRY cl_mem CL_API_CALL |
| 778 | clCreateSubBuffer(cl_mem /* buffer */, |
| 779 | cl_mem_flags /* flags */, |
| 780 | cl_buffer_create_type /* buffer_create_type */, |
| 781 | const void * /* buffer_create_info */, |
| 782 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_1; |
| 783 | |
| 784 | extern CL_API_ENTRY cl_mem CL_API_CALL |
| 785 | clCreateImage(cl_context /* context */, |
| 786 | cl_mem_flags /* flags */, |
| 787 | const cl_image_format * /* image_format */, |
| 788 | const cl_image_desc * /* image_desc */, |
| 789 | void * /* host_ptr */, |
| 790 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_2; |
| 791 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 792 | extern CL_API_ENTRY cl_mem CL_API_CALL |
| 793 | clCreatePipe(cl_context /* context */, |
| 794 | cl_mem_flags /* flags */, |
| 795 | cl_uint /* pipe_packet_size */, |
| 796 | cl_uint /* pipe_max_packets */, |
| 797 | const cl_pipe_properties * /* properties */, |
| 798 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_2_0; |
| 799 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 800 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 801 | clRetainMemObject(cl_mem /* memobj */) CL_API_SUFFIX__VERSION_1_0; |
| 802 | |
| 803 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 804 | clReleaseMemObject(cl_mem /* memobj */) CL_API_SUFFIX__VERSION_1_0; |
| 805 | |
| 806 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 807 | clGetSupportedImageFormats(cl_context /* context */, |
| 808 | cl_mem_flags /* flags */, |
| 809 | cl_mem_object_type /* image_type */, |
| 810 | cl_uint /* num_entries */, |
| 811 | cl_image_format * /* image_formats */, |
| 812 | cl_uint * /* num_image_formats */) CL_API_SUFFIX__VERSION_1_0; |
| 813 | |
| 814 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 815 | clGetMemObjectInfo(cl_mem /* memobj */, |
| 816 | cl_mem_info /* param_name */, |
| 817 | size_t /* param_value_size */, |
| 818 | void * /* param_value */, |
| 819 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 820 | |
| 821 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 822 | clGetImageInfo(cl_mem /* image */, |
| 823 | cl_image_info /* param_name */, |
| 824 | size_t /* param_value_size */, |
| 825 | void * /* param_value */, |
| 826 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 827 | |
| 828 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 829 | clGetPipeInfo(cl_mem /* pipe */, |
| 830 | cl_pipe_info /* param_name */, |
| 831 | size_t /* param_value_size */, |
| 832 | void * /* param_value */, |
| 833 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_2_0; |
| 834 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 835 | |
| 836 | extern CL_API_ENTRY cl_int CL_API_CALL |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 837 | clSetMemObjectDestructorCallback(cl_mem /* memobj */, |
| 838 | void (CL_CALLBACK * /*pfn_notify*/)( cl_mem /* memobj */, void* /*user_data*/), |
| 839 | void * /*user_data */ ) CL_API_SUFFIX__VERSION_1_1; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 840 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 841 | /* SVM Allocation APIs */ |
| 842 | extern CL_API_ENTRY void * CL_API_CALL |
| 843 | clSVMAlloc(cl_context /* context */, |
| 844 | cl_svm_mem_flags /* flags */, |
| 845 | size_t /* size */, |
| 846 | cl_uint /* alignment */) CL_API_SUFFIX__VERSION_2_0; |
| 847 | |
| 848 | extern CL_API_ENTRY void CL_API_CALL |
| 849 | clSVMFree(cl_context /* context */, |
| 850 | void * /* svm_pointer */) CL_API_SUFFIX__VERSION_2_0; |
| 851 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 852 | /* Sampler APIs */ |
| 853 | extern CL_API_ENTRY cl_sampler CL_API_CALL |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 854 | clCreateSamplerWithProperties(cl_context /* context */, |
| 855 | const cl_sampler_properties * /* normalized_coords */, |
| 856 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_2_0; |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 857 | |
| 858 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 859 | clRetainSampler(cl_sampler /* sampler */) CL_API_SUFFIX__VERSION_1_0; |
| 860 | |
| 861 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 862 | clReleaseSampler(cl_sampler /* sampler */) CL_API_SUFFIX__VERSION_1_0; |
| 863 | |
| 864 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 865 | clGetSamplerInfo(cl_sampler /* sampler */, |
| 866 | cl_sampler_info /* param_name */, |
| 867 | size_t /* param_value_size */, |
| 868 | void * /* param_value */, |
| 869 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 870 | |
| 871 | /* Program Object APIs */ |
| 872 | extern CL_API_ENTRY cl_program CL_API_CALL |
| 873 | clCreateProgramWithSource(cl_context /* context */, |
| 874 | cl_uint /* count */, |
| 875 | const char ** /* strings */, |
| 876 | const size_t * /* lengths */, |
| 877 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 878 | |
| 879 | extern CL_API_ENTRY cl_program CL_API_CALL |
| 880 | clCreateProgramWithBinary(cl_context /* context */, |
| 881 | cl_uint /* num_devices */, |
| 882 | const cl_device_id * /* device_list */, |
| 883 | const size_t * /* lengths */, |
| 884 | const unsigned char ** /* binaries */, |
| 885 | cl_int * /* binary_status */, |
| 886 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 887 | |
| 888 | extern CL_API_ENTRY cl_program CL_API_CALL |
| 889 | clCreateProgramWithBuiltInKernels(cl_context /* context */, |
| 890 | cl_uint /* num_devices */, |
| 891 | const cl_device_id * /* device_list */, |
| 892 | const char * /* kernel_names */, |
| 893 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_2; |
| 894 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 895 | extern CL_API_ENTRY cl_program CL_API_CALL |
| 896 | clCreateProgramWithIL(cl_context /* context */, |
| 897 | const void* /* il */, |
| 898 | size_t /* length */, |
| 899 | cl_int* /* errcode_ret */) CL_API_SUFFIX__VERSION_2_1; |
| 900 | |
| 901 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 902 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 903 | clRetainProgram(cl_program /* program */) CL_API_SUFFIX__VERSION_1_0; |
| 904 | |
| 905 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 906 | clReleaseProgram(cl_program /* program */) CL_API_SUFFIX__VERSION_1_0; |
| 907 | |
| 908 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 909 | clBuildProgram(cl_program /* program */, |
| 910 | cl_uint /* num_devices */, |
| 911 | const cl_device_id * /* device_list */, |
| 912 | const char * /* options */, |
| 913 | void (CL_CALLBACK * /* pfn_notify */)(cl_program /* program */, void * /* user_data */), |
| 914 | void * /* user_data */) CL_API_SUFFIX__VERSION_1_0; |
| 915 | |
| 916 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 917 | clCompileProgram(cl_program /* program */, |
| 918 | cl_uint /* num_devices */, |
| 919 | const cl_device_id * /* device_list */, |
| 920 | const char * /* options */, |
| 921 | cl_uint /* num_input_headers */, |
| 922 | const cl_program * /* input_headers */, |
| 923 | const char ** /* header_include_names */, |
| 924 | void (CL_CALLBACK * /* pfn_notify */)(cl_program /* program */, void * /* user_data */), |
| 925 | void * /* user_data */) CL_API_SUFFIX__VERSION_1_2; |
| 926 | |
| 927 | extern CL_API_ENTRY cl_program CL_API_CALL |
| 928 | clLinkProgram(cl_context /* context */, |
| 929 | cl_uint /* num_devices */, |
| 930 | const cl_device_id * /* device_list */, |
| 931 | const char * /* options */, |
| 932 | cl_uint /* num_input_programs */, |
| 933 | const cl_program * /* input_programs */, |
| 934 | void (CL_CALLBACK * /* pfn_notify */)(cl_program /* program */, void * /* user_data */), |
| 935 | void * /* user_data */, |
| 936 | cl_int * /* errcode_ret */ ) CL_API_SUFFIX__VERSION_1_2; |
| 937 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 938 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 939 | clSetProgramReleaseCallback(cl_program /* program */, |
| 940 | void (CL_CALLBACK * /* pfn_notify */)(cl_program /* program */, void * /* user_data */), |
| 941 | void * /* user_data */) CL_API_SUFFIX__VERSION_2_2; |
| 942 | |
| 943 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 944 | clSetProgramSpecializationConstant(cl_program /* program */, |
| 945 | cl_uint /* spec_id */, |
| 946 | size_t /* spec_size */, |
| 947 | const void* /* spec_value */) CL_API_SUFFIX__VERSION_2_2; |
| 948 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 949 | |
| 950 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 951 | clUnloadPlatformCompiler(cl_platform_id /* platform */) CL_API_SUFFIX__VERSION_1_2; |
| 952 | |
| 953 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 954 | clGetProgramInfo(cl_program /* program */, |
| 955 | cl_program_info /* param_name */, |
| 956 | size_t /* param_value_size */, |
| 957 | void * /* param_value */, |
| 958 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 959 | |
| 960 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 961 | clGetProgramBuildInfo(cl_program /* program */, |
| 962 | cl_device_id /* device */, |
| 963 | cl_program_build_info /* param_name */, |
| 964 | size_t /* param_value_size */, |
| 965 | void * /* param_value */, |
| 966 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 967 | |
| 968 | /* Kernel Object APIs */ |
| 969 | extern CL_API_ENTRY cl_kernel CL_API_CALL |
| 970 | clCreateKernel(cl_program /* program */, |
| 971 | const char * /* kernel_name */, |
| 972 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 973 | |
| 974 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 975 | clCreateKernelsInProgram(cl_program /* program */, |
| 976 | cl_uint /* num_kernels */, |
| 977 | cl_kernel * /* kernels */, |
| 978 | cl_uint * /* num_kernels_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 979 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 980 | extern CL_API_ENTRY cl_kernel CL_API_CALL |
| 981 | clCloneKernel(cl_kernel /* source_kernel */, |
| 982 | cl_int* /* errcode_ret */) CL_API_SUFFIX__VERSION_2_1; |
| 983 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 984 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 985 | clRetainKernel(cl_kernel /* kernel */) CL_API_SUFFIX__VERSION_1_0; |
| 986 | |
| 987 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 988 | clReleaseKernel(cl_kernel /* kernel */) CL_API_SUFFIX__VERSION_1_0; |
| 989 | |
| 990 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 991 | clSetKernelArg(cl_kernel /* kernel */, |
| 992 | cl_uint /* arg_index */, |
| 993 | size_t /* arg_size */, |
| 994 | const void * /* arg_value */) CL_API_SUFFIX__VERSION_1_0; |
| 995 | |
| 996 | extern CL_API_ENTRY cl_int CL_API_CALL |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 997 | clSetKernelArgSVMPointer(cl_kernel /* kernel */, |
| 998 | cl_uint /* arg_index */, |
| 999 | const void * /* arg_value */) CL_API_SUFFIX__VERSION_2_0; |
| 1000 | |
| 1001 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1002 | clSetKernelExecInfo(cl_kernel /* kernel */, |
| 1003 | cl_kernel_exec_info /* param_name */, |
| 1004 | size_t /* param_value_size */, |
| 1005 | const void * /* param_value */) CL_API_SUFFIX__VERSION_2_0; |
| 1006 | |
| 1007 | extern CL_API_ENTRY cl_int CL_API_CALL |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1008 | clGetKernelInfo(cl_kernel /* kernel */, |
| 1009 | cl_kernel_info /* param_name */, |
| 1010 | size_t /* param_value_size */, |
| 1011 | void * /* param_value */, |
| 1012 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 1013 | |
| 1014 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1015 | clGetKernelArgInfo(cl_kernel /* kernel */, |
| 1016 | cl_uint /* arg_indx */, |
| 1017 | cl_kernel_arg_info /* param_name */, |
| 1018 | size_t /* param_value_size */, |
| 1019 | void * /* param_value */, |
| 1020 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_2; |
| 1021 | |
| 1022 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1023 | clGetKernelWorkGroupInfo(cl_kernel /* kernel */, |
| 1024 | cl_device_id /* device */, |
| 1025 | cl_kernel_work_group_info /* param_name */, |
| 1026 | size_t /* param_value_size */, |
| 1027 | void * /* param_value */, |
| 1028 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 1029 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 1030 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1031 | clGetKernelSubGroupInfo(cl_kernel /* kernel */, |
| 1032 | cl_device_id /* device */, |
| 1033 | cl_kernel_sub_group_info /* param_name */, |
| 1034 | size_t /* input_value_size */, |
| 1035 | const void* /*input_value */, |
| 1036 | size_t /* param_value_size */, |
| 1037 | void* /* param_value */, |
| 1038 | size_t* /* param_value_size_ret */ ) CL_API_SUFFIX__VERSION_2_1; |
| 1039 | |
| 1040 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1041 | /* Event Object APIs */ |
| 1042 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1043 | clWaitForEvents(cl_uint /* num_events */, |
| 1044 | const cl_event * /* event_list */) CL_API_SUFFIX__VERSION_1_0; |
| 1045 | |
| 1046 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1047 | clGetEventInfo(cl_event /* event */, |
| 1048 | cl_event_info /* param_name */, |
| 1049 | size_t /* param_value_size */, |
| 1050 | void * /* param_value */, |
| 1051 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 1052 | |
| 1053 | extern CL_API_ENTRY cl_event CL_API_CALL |
| 1054 | clCreateUserEvent(cl_context /* context */, |
| 1055 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_1; |
| 1056 | |
| 1057 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1058 | clRetainEvent(cl_event /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1059 | |
| 1060 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1061 | clReleaseEvent(cl_event /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1062 | |
| 1063 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1064 | clSetUserEventStatus(cl_event /* event */, |
| 1065 | cl_int /* execution_status */) CL_API_SUFFIX__VERSION_1_1; |
| 1066 | |
| 1067 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1068 | clSetEventCallback( cl_event /* event */, |
| 1069 | cl_int /* command_exec_callback_type */, |
| 1070 | void (CL_CALLBACK * /* pfn_notify */)(cl_event, cl_int, void *), |
| 1071 | void * /* user_data */) CL_API_SUFFIX__VERSION_1_1; |
| 1072 | |
| 1073 | /* Profiling APIs */ |
| 1074 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1075 | clGetEventProfilingInfo(cl_event /* event */, |
| 1076 | cl_profiling_info /* param_name */, |
| 1077 | size_t /* param_value_size */, |
| 1078 | void * /* param_value */, |
| 1079 | size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 1080 | |
| 1081 | /* Flush and Finish APIs */ |
| 1082 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1083 | clFlush(cl_command_queue /* command_queue */) CL_API_SUFFIX__VERSION_1_0; |
| 1084 | |
| 1085 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1086 | clFinish(cl_command_queue /* command_queue */) CL_API_SUFFIX__VERSION_1_0; |
| 1087 | |
| 1088 | /* Enqueued Commands APIs */ |
| 1089 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1090 | clEnqueueReadBuffer(cl_command_queue /* command_queue */, |
| 1091 | cl_mem /* buffer */, |
| 1092 | cl_bool /* blocking_read */, |
| 1093 | size_t /* offset */, |
| 1094 | size_t /* size */, |
| 1095 | void * /* ptr */, |
| 1096 | cl_uint /* num_events_in_wait_list */, |
| 1097 | const cl_event * /* event_wait_list */, |
| 1098 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1099 | |
| 1100 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1101 | clEnqueueReadBufferRect(cl_command_queue /* command_queue */, |
| 1102 | cl_mem /* buffer */, |
| 1103 | cl_bool /* blocking_read */, |
| 1104 | const size_t * /* buffer_offset */, |
| 1105 | const size_t * /* host_offset */, |
| 1106 | const size_t * /* region */, |
| 1107 | size_t /* buffer_row_pitch */, |
| 1108 | size_t /* buffer_slice_pitch */, |
| 1109 | size_t /* host_row_pitch */, |
| 1110 | size_t /* host_slice_pitch */, |
| 1111 | void * /* ptr */, |
| 1112 | cl_uint /* num_events_in_wait_list */, |
| 1113 | const cl_event * /* event_wait_list */, |
| 1114 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_1; |
| 1115 | |
| 1116 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1117 | clEnqueueWriteBuffer(cl_command_queue /* command_queue */, |
| 1118 | cl_mem /* buffer */, |
| 1119 | cl_bool /* blocking_write */, |
| 1120 | size_t /* offset */, |
| 1121 | size_t /* size */, |
| 1122 | const void * /* ptr */, |
| 1123 | cl_uint /* num_events_in_wait_list */, |
| 1124 | const cl_event * /* event_wait_list */, |
| 1125 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1126 | |
| 1127 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1128 | clEnqueueWriteBufferRect(cl_command_queue /* command_queue */, |
| 1129 | cl_mem /* buffer */, |
| 1130 | cl_bool /* blocking_write */, |
| 1131 | const size_t * /* buffer_offset */, |
| 1132 | const size_t * /* host_offset */, |
| 1133 | const size_t * /* region */, |
| 1134 | size_t /* buffer_row_pitch */, |
| 1135 | size_t /* buffer_slice_pitch */, |
| 1136 | size_t /* host_row_pitch */, |
| 1137 | size_t /* host_slice_pitch */, |
| 1138 | const void * /* ptr */, |
| 1139 | cl_uint /* num_events_in_wait_list */, |
| 1140 | const cl_event * /* event_wait_list */, |
| 1141 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_1; |
| 1142 | |
| 1143 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1144 | clEnqueueFillBuffer(cl_command_queue /* command_queue */, |
| 1145 | cl_mem /* buffer */, |
| 1146 | const void * /* pattern */, |
| 1147 | size_t /* pattern_size */, |
| 1148 | size_t /* offset */, |
| 1149 | size_t /* size */, |
| 1150 | cl_uint /* num_events_in_wait_list */, |
| 1151 | const cl_event * /* event_wait_list */, |
| 1152 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_2; |
| 1153 | |
| 1154 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1155 | clEnqueueCopyBuffer(cl_command_queue /* command_queue */, |
| 1156 | cl_mem /* src_buffer */, |
| 1157 | cl_mem /* dst_buffer */, |
| 1158 | size_t /* src_offset */, |
| 1159 | size_t /* dst_offset */, |
| 1160 | size_t /* size */, |
| 1161 | cl_uint /* num_events_in_wait_list */, |
| 1162 | const cl_event * /* event_wait_list */, |
| 1163 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1164 | |
| 1165 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1166 | clEnqueueCopyBufferRect(cl_command_queue /* command_queue */, |
| 1167 | cl_mem /* src_buffer */, |
| 1168 | cl_mem /* dst_buffer */, |
| 1169 | const size_t * /* src_origin */, |
| 1170 | const size_t * /* dst_origin */, |
| 1171 | const size_t * /* region */, |
| 1172 | size_t /* src_row_pitch */, |
| 1173 | size_t /* src_slice_pitch */, |
| 1174 | size_t /* dst_row_pitch */, |
| 1175 | size_t /* dst_slice_pitch */, |
| 1176 | cl_uint /* num_events_in_wait_list */, |
| 1177 | const cl_event * /* event_wait_list */, |
| 1178 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_1; |
| 1179 | |
| 1180 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1181 | clEnqueueReadImage(cl_command_queue /* command_queue */, |
| 1182 | cl_mem /* image */, |
| 1183 | cl_bool /* blocking_read */, |
| 1184 | const size_t * /* origin[3] */, |
| 1185 | const size_t * /* region[3] */, |
| 1186 | size_t /* row_pitch */, |
| 1187 | size_t /* slice_pitch */, |
| 1188 | void * /* ptr */, |
| 1189 | cl_uint /* num_events_in_wait_list */, |
| 1190 | const cl_event * /* event_wait_list */, |
| 1191 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1192 | |
| 1193 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1194 | clEnqueueWriteImage(cl_command_queue /* command_queue */, |
| 1195 | cl_mem /* image */, |
| 1196 | cl_bool /* blocking_write */, |
| 1197 | const size_t * /* origin[3] */, |
| 1198 | const size_t * /* region[3] */, |
| 1199 | size_t /* input_row_pitch */, |
| 1200 | size_t /* input_slice_pitch */, |
| 1201 | const void * /* ptr */, |
| 1202 | cl_uint /* num_events_in_wait_list */, |
| 1203 | const cl_event * /* event_wait_list */, |
| 1204 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1205 | |
| 1206 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1207 | clEnqueueFillImage(cl_command_queue /* command_queue */, |
| 1208 | cl_mem /* image */, |
| 1209 | const void * /* fill_color */, |
| 1210 | const size_t * /* origin[3] */, |
| 1211 | const size_t * /* region[3] */, |
| 1212 | cl_uint /* num_events_in_wait_list */, |
| 1213 | const cl_event * /* event_wait_list */, |
| 1214 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_2; |
| 1215 | |
| 1216 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1217 | clEnqueueCopyImage(cl_command_queue /* command_queue */, |
| 1218 | cl_mem /* src_image */, |
| 1219 | cl_mem /* dst_image */, |
| 1220 | const size_t * /* src_origin[3] */, |
| 1221 | const size_t * /* dst_origin[3] */, |
| 1222 | const size_t * /* region[3] */, |
| 1223 | cl_uint /* num_events_in_wait_list */, |
| 1224 | const cl_event * /* event_wait_list */, |
| 1225 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1226 | |
| 1227 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1228 | clEnqueueCopyImageToBuffer(cl_command_queue /* command_queue */, |
| 1229 | cl_mem /* src_image */, |
| 1230 | cl_mem /* dst_buffer */, |
| 1231 | const size_t * /* src_origin[3] */, |
| 1232 | const size_t * /* region[3] */, |
| 1233 | size_t /* dst_offset */, |
| 1234 | cl_uint /* num_events_in_wait_list */, |
| 1235 | const cl_event * /* event_wait_list */, |
| 1236 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1237 | |
| 1238 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1239 | clEnqueueCopyBufferToImage(cl_command_queue /* command_queue */, |
| 1240 | cl_mem /* src_buffer */, |
| 1241 | cl_mem /* dst_image */, |
| 1242 | size_t /* src_offset */, |
| 1243 | const size_t * /* dst_origin[3] */, |
| 1244 | const size_t * /* region[3] */, |
| 1245 | cl_uint /* num_events_in_wait_list */, |
| 1246 | const cl_event * /* event_wait_list */, |
| 1247 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1248 | |
| 1249 | extern CL_API_ENTRY void * CL_API_CALL |
| 1250 | clEnqueueMapBuffer(cl_command_queue /* command_queue */, |
| 1251 | cl_mem /* buffer */, |
| 1252 | cl_bool /* blocking_map */, |
| 1253 | cl_map_flags /* map_flags */, |
| 1254 | size_t /* offset */, |
| 1255 | size_t /* size */, |
| 1256 | cl_uint /* num_events_in_wait_list */, |
| 1257 | const cl_event * /* event_wait_list */, |
| 1258 | cl_event * /* event */, |
| 1259 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 1260 | |
| 1261 | extern CL_API_ENTRY void * CL_API_CALL |
| 1262 | clEnqueueMapImage(cl_command_queue /* command_queue */, |
| 1263 | cl_mem /* image */, |
| 1264 | cl_bool /* blocking_map */, |
| 1265 | cl_map_flags /* map_flags */, |
| 1266 | const size_t * /* origin[3] */, |
| 1267 | const size_t * /* region[3] */, |
| 1268 | size_t * /* image_row_pitch */, |
| 1269 | size_t * /* image_slice_pitch */, |
| 1270 | cl_uint /* num_events_in_wait_list */, |
| 1271 | const cl_event * /* event_wait_list */, |
| 1272 | cl_event * /* event */, |
| 1273 | cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0; |
| 1274 | |
| 1275 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1276 | clEnqueueUnmapMemObject(cl_command_queue /* command_queue */, |
| 1277 | cl_mem /* memobj */, |
| 1278 | void * /* mapped_ptr */, |
| 1279 | cl_uint /* num_events_in_wait_list */, |
| 1280 | const cl_event * /* event_wait_list */, |
| 1281 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1282 | |
| 1283 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1284 | clEnqueueMigrateMemObjects(cl_command_queue /* command_queue */, |
| 1285 | cl_uint /* num_mem_objects */, |
| 1286 | const cl_mem * /* mem_objects */, |
| 1287 | cl_mem_migration_flags /* flags */, |
| 1288 | cl_uint /* num_events_in_wait_list */, |
| 1289 | const cl_event * /* event_wait_list */, |
| 1290 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_2; |
| 1291 | |
| 1292 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1293 | clEnqueueNDRangeKernel(cl_command_queue /* command_queue */, |
| 1294 | cl_kernel /* kernel */, |
| 1295 | cl_uint /* work_dim */, |
| 1296 | const size_t * /* global_work_offset */, |
| 1297 | const size_t * /* global_work_size */, |
| 1298 | const size_t * /* local_work_size */, |
| 1299 | cl_uint /* num_events_in_wait_list */, |
| 1300 | const cl_event * /* event_wait_list */, |
| 1301 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1302 | |
| 1303 | extern CL_API_ENTRY cl_int CL_API_CALL |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1304 | clEnqueueNativeKernel(cl_command_queue /* command_queue */, |
| 1305 | void (CL_CALLBACK * /*user_func*/)(void *), |
| 1306 | void * /* args */, |
| 1307 | size_t /* cb_args */, |
| 1308 | cl_uint /* num_mem_objects */, |
| 1309 | const cl_mem * /* mem_list */, |
| 1310 | const void ** /* args_mem_loc */, |
| 1311 | cl_uint /* num_events_in_wait_list */, |
| 1312 | const cl_event * /* event_wait_list */, |
| 1313 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0; |
| 1314 | |
| 1315 | extern CL_API_ENTRY cl_int CL_API_CALL |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 1316 | clEnqueueMarkerWithWaitList(cl_command_queue /* command_queue */, |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1317 | cl_uint /* num_events_in_wait_list */, |
| 1318 | const cl_event * /* event_wait_list */, |
| 1319 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_2; |
| 1320 | |
| 1321 | extern CL_API_ENTRY cl_int CL_API_CALL |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 1322 | clEnqueueBarrierWithWaitList(cl_command_queue /* command_queue */, |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1323 | cl_uint /* num_events_in_wait_list */, |
| 1324 | const cl_event * /* event_wait_list */, |
| 1325 | cl_event * /* event */) CL_API_SUFFIX__VERSION_1_2; |
| 1326 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 1327 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1328 | clEnqueueSVMFree(cl_command_queue /* command_queue */, |
| 1329 | cl_uint /* num_svm_pointers */, |
| 1330 | void *[] /* svm_pointers[] */, |
| 1331 | void (CL_CALLBACK * /*pfn_free_func*/)(cl_command_queue /* queue */, |
| 1332 | cl_uint /* num_svm_pointers */, |
| 1333 | void *[] /* svm_pointers[] */, |
| 1334 | void * /* user_data */), |
| 1335 | void * /* user_data */, |
| 1336 | cl_uint /* num_events_in_wait_list */, |
| 1337 | const cl_event * /* event_wait_list */, |
| 1338 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 1339 | |
| 1340 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1341 | clEnqueueSVMMemcpy(cl_command_queue /* command_queue */, |
| 1342 | cl_bool /* blocking_copy */, |
| 1343 | void * /* dst_ptr */, |
| 1344 | const void * /* src_ptr */, |
| 1345 | size_t /* size */, |
| 1346 | cl_uint /* num_events_in_wait_list */, |
| 1347 | const cl_event * /* event_wait_list */, |
| 1348 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 1349 | |
| 1350 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1351 | clEnqueueSVMMemFill(cl_command_queue /* command_queue */, |
| 1352 | void * /* svm_ptr */, |
| 1353 | const void * /* pattern */, |
| 1354 | size_t /* pattern_size */, |
| 1355 | size_t /* size */, |
| 1356 | cl_uint /* num_events_in_wait_list */, |
| 1357 | const cl_event * /* event_wait_list */, |
| 1358 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 1359 | |
| 1360 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1361 | clEnqueueSVMMap(cl_command_queue /* command_queue */, |
| 1362 | cl_bool /* blocking_map */, |
| 1363 | cl_map_flags /* flags */, |
| 1364 | void * /* svm_ptr */, |
| 1365 | size_t /* size */, |
| 1366 | cl_uint /* num_events_in_wait_list */, |
| 1367 | const cl_event * /* event_wait_list */, |
| 1368 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 1369 | |
| 1370 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1371 | clEnqueueSVMUnmap(cl_command_queue /* command_queue */, |
| 1372 | void * /* svm_ptr */, |
| 1373 | cl_uint /* num_events_in_wait_list */, |
| 1374 | const cl_event * /* event_wait_list */, |
| 1375 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_0; |
| 1376 | |
| 1377 | extern CL_API_ENTRY cl_int CL_API_CALL |
| 1378 | clEnqueueSVMMigrateMem(cl_command_queue /* command_queue */, |
| 1379 | cl_uint /* num_svm_pointers */, |
| 1380 | const void ** /* svm_pointers */, |
| 1381 | const size_t * /* sizes */, |
| 1382 | cl_mem_migration_flags /* flags */, |
| 1383 | cl_uint /* num_events_in_wait_list */, |
| 1384 | const cl_event * /* event_wait_list */, |
| 1385 | cl_event * /* event */) CL_API_SUFFIX__VERSION_2_1; |
| 1386 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1387 | |
| 1388 | /* Extension function access |
| 1389 | * |
| 1390 | * Returns the extension function address for the given function name, |
| 1391 | * or NULL if a valid function can not be found. The client must |
| 1392 | * check to make sure the address is not NULL, before using or |
| 1393 | * calling the returned function address. |
| 1394 | */ |
| 1395 | extern CL_API_ENTRY void * CL_API_CALL |
| 1396 | clGetExtensionFunctionAddressForPlatform(cl_platform_id /* platform */, |
| 1397 | const char * /* func_name */) CL_API_SUFFIX__VERSION_1_2; |
| 1398 | |
| 1399 | |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 1400 | /* Deprecated OpenCL 1.1 APIs */ |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1401 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_mem CL_API_CALL |
| 1402 | clCreateImage2D(cl_context /* context */, |
| 1403 | cl_mem_flags /* flags */, |
| 1404 | const cl_image_format * /* image_format */, |
| 1405 | size_t /* image_width */, |
| 1406 | size_t /* image_height */, |
| 1407 | size_t /* image_row_pitch */, |
| 1408 | void * /* host_ptr */, |
| 1409 | cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 1410 | |
| 1411 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_mem CL_API_CALL |
| 1412 | clCreateImage3D(cl_context /* context */, |
| 1413 | cl_mem_flags /* flags */, |
| 1414 | const cl_image_format * /* image_format */, |
| 1415 | size_t /* image_width */, |
| 1416 | size_t /* image_height */, |
| 1417 | size_t /* image_depth */, |
| 1418 | size_t /* image_row_pitch */, |
| 1419 | size_t /* image_slice_pitch */, |
| 1420 | void * /* host_ptr */, |
| 1421 | cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 1422 | |
| 1423 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_int CL_API_CALL |
| 1424 | clEnqueueMarker(cl_command_queue /* command_queue */, |
| 1425 | cl_event * /* event */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 1426 | |
| 1427 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_int CL_API_CALL |
| 1428 | clEnqueueWaitForEvents(cl_command_queue /* command_queue */, |
| 1429 | cl_uint /* num_events */, |
| 1430 | const cl_event * /* event_list */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 1431 | |
| 1432 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_int CL_API_CALL |
| 1433 | clEnqueueBarrier(cl_command_queue /* command_queue */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 1434 | |
| 1435 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_int CL_API_CALL |
| 1436 | clUnloadCompiler(void) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
| 1437 | |
| 1438 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED void * CL_API_CALL |
| 1439 | clGetExtensionFunctionAddress(const char * /* func_name */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED; |
Pablo Tello | e86a09f | 2018-01-11 15:44:48 +0000 | [diff] [blame^] | 1440 | |
| 1441 | /* Deprecated OpenCL 2.0 APIs */ |
| 1442 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_2_DEPRECATED cl_command_queue CL_API_CALL |
| 1443 | clCreateCommandQueue(cl_context /* context */, |
| 1444 | cl_device_id /* device */, |
| 1445 | cl_command_queue_properties /* properties */, |
| 1446 | cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_2_DEPRECATED; |
| 1447 | |
| 1448 | |
| 1449 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_2_DEPRECATED cl_sampler CL_API_CALL |
| 1450 | clCreateSampler(cl_context /* context */, |
| 1451 | cl_bool /* normalized_coords */, |
| 1452 | cl_addressing_mode /* addressing_mode */, |
| 1453 | cl_filter_mode /* filter_mode */, |
| 1454 | cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_2_DEPRECATED; |
| 1455 | |
| 1456 | extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_2_DEPRECATED cl_int CL_API_CALL |
| 1457 | clEnqueueTask(cl_command_queue /* command_queue */, |
| 1458 | cl_kernel /* kernel */, |
| 1459 | cl_uint /* num_events_in_wait_list */, |
| 1460 | const cl_event * /* event_wait_list */, |
| 1461 | cl_event * /* event */) CL_EXT_SUFFIX__VERSION_1_2_DEPRECATED; |
| 1462 | |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 1463 | #ifdef __cplusplus |
| 1464 | } |
| 1465 | #endif |
| 1466 | |
| 1467 | #endif /* __OPENCL_CL_H */ |
| 1468 | |