1 /* Automatically generated from OpenCL registry files; DO NOT EDIT! */
3 #include "opencl_private.h"
4 #include "opencl_types.h"
7 WINE_DEFAULT_DEBUG_CHANNEL(opencl
);
9 cl_int WINAPI
clBuildProgram( cl_program program
, cl_uint num_devices
, const cl_device_id
* device_list
, const char* options
, void (WINAPI
* pfn_notify
)(cl_program program
, void* user_data
), void* user_data
)
11 struct clBuildProgram_params params
= { program
, num_devices
, device_list
, options
, pfn_notify
, user_data
};
12 TRACE( "(%p, %u, %p, %p, %p, %p)\n", program
, num_devices
, device_list
, options
, pfn_notify
, user_data
);
13 return OPENCL_CALL( clBuildProgram
, ¶ms
);
16 cl_int WINAPI
clCompileProgram( cl_program program
, cl_uint num_devices
, const cl_device_id
* device_list
, const char* options
, cl_uint num_input_headers
, const cl_program
* input_headers
, const char** header_include_names
, void (WINAPI
* pfn_notify
)(cl_program program
, void* user_data
), void* user_data
)
18 struct clCompileProgram_params params
= { program
, num_devices
, device_list
, options
, num_input_headers
, input_headers
, header_include_names
, pfn_notify
, user_data
};
19 TRACE( "(%p, %u, %p, %p, %u, %p, %p, %p, %p)\n", program
, num_devices
, device_list
, options
, num_input_headers
, input_headers
, header_include_names
, pfn_notify
, user_data
);
20 return OPENCL_CALL( clCompileProgram
, ¶ms
);
23 cl_mem WINAPI
clCreateBuffer( cl_context context
, cl_mem_flags flags
, size_t size
, void* host_ptr
, cl_int
* errcode_ret
)
26 struct clCreateBuffer_params params
= { &__retval
, context
, flags
, size
, host_ptr
, errcode_ret
};
27 TRACE( "(%p, %s, %Iu, %p, %p)\n", context
, wine_dbgstr_longlong(flags
), size
, host_ptr
, errcode_ret
);
28 OPENCL_CALL( clCreateBuffer
, ¶ms
);
32 cl_command_queue WINAPI
clCreateCommandQueue( cl_context context
, cl_device_id device
, cl_command_queue_properties properties
, cl_int
* errcode_ret
)
34 cl_command_queue __retval
;
35 struct clCreateCommandQueue_params params
= { &__retval
, context
, device
, properties
, errcode_ret
};
36 TRACE( "(%p, %p, %s, %p)\n", context
, device
, wine_dbgstr_longlong(properties
), errcode_ret
);
37 OPENCL_CALL( clCreateCommandQueue
, ¶ms
);
41 cl_context WINAPI
clCreateContext( const cl_context_properties
* properties
, cl_uint num_devices
, const cl_device_id
* devices
, void (WINAPI
* pfn_notify
)(const char* errinfo
, const void* private_info
, size_t cb
, void* user_data
), void* user_data
, cl_int
* errcode_ret
)
44 struct clCreateContext_params params
= { &__retval
, properties
, num_devices
, devices
, pfn_notify
, user_data
, errcode_ret
};
45 TRACE( "(%p, %u, %p, %p, %p, %p)\n", properties
, num_devices
, devices
, pfn_notify
, user_data
, errcode_ret
);
46 OPENCL_CALL( clCreateContext
, ¶ms
);
50 cl_context WINAPI
clCreateContextFromType( const cl_context_properties
* properties
, cl_device_type device_type
, void (WINAPI
* pfn_notify
)(const char* errinfo
, const void* private_info
, size_t cb
, void* user_data
), void* user_data
, cl_int
* errcode_ret
)
53 struct clCreateContextFromType_params params
= { &__retval
, properties
, device_type
, pfn_notify
, user_data
, errcode_ret
};
54 TRACE( "(%p, %s, %p, %p, %p)\n", properties
, wine_dbgstr_longlong(device_type
), pfn_notify
, user_data
, errcode_ret
);
55 OPENCL_CALL( clCreateContextFromType
, ¶ms
);
59 cl_mem WINAPI
clCreateImage( cl_context context
, cl_mem_flags flags
, const cl_image_format
* image_format
, const cl_image_desc
* image_desc
, void* host_ptr
, cl_int
* errcode_ret
)
62 struct clCreateImage_params params
= { &__retval
, context
, flags
, image_format
, image_desc
, host_ptr
, errcode_ret
};
63 TRACE( "(%p, %s, %p, %p, %p, %p)\n", context
, wine_dbgstr_longlong(flags
), image_format
, image_desc
, host_ptr
, errcode_ret
);
64 OPENCL_CALL( clCreateImage
, ¶ms
);
68 cl_mem WINAPI
clCreateImage2D( cl_context context
, cl_mem_flags flags
, const cl_image_format
* image_format
, size_t image_width
, size_t image_height
, size_t image_row_pitch
, void* host_ptr
, cl_int
* errcode_ret
)
71 struct clCreateImage2D_params params
= { &__retval
, context
, flags
, image_format
, image_width
, image_height
, image_row_pitch
, host_ptr
, errcode_ret
};
72 TRACE( "(%p, %s, %p, %Iu, %Iu, %Iu, %p, %p)\n", context
, wine_dbgstr_longlong(flags
), image_format
, image_width
, image_height
, image_row_pitch
, host_ptr
, errcode_ret
);
73 OPENCL_CALL( clCreateImage2D
, ¶ms
);
77 cl_mem WINAPI
clCreateImage3D( cl_context context
, cl_mem_flags flags
, const cl_image_format
* image_format
, size_t image_width
, size_t image_height
, size_t image_depth
, size_t image_row_pitch
, size_t image_slice_pitch
, void* host_ptr
, cl_int
* errcode_ret
)
80 struct clCreateImage3D_params params
= { &__retval
, context
, flags
, image_format
, image_width
, image_height
, image_depth
, image_row_pitch
, image_slice_pitch
, host_ptr
, errcode_ret
};
81 TRACE( "(%p, %s, %p, %Iu, %Iu, %Iu, %Iu, %Iu, %p, %p)\n", context
, wine_dbgstr_longlong(flags
), image_format
, image_width
, image_height
, image_depth
, image_row_pitch
, image_slice_pitch
, host_ptr
, errcode_ret
);
82 OPENCL_CALL( clCreateImage3D
, ¶ms
);
86 cl_kernel WINAPI
clCreateKernel( cl_program program
, const char* kernel_name
, cl_int
* errcode_ret
)
89 struct clCreateKernel_params params
= { &__retval
, program
, kernel_name
, errcode_ret
};
90 TRACE( "(%p, %p, %p)\n", program
, kernel_name
, errcode_ret
);
91 OPENCL_CALL( clCreateKernel
, ¶ms
);
95 cl_int WINAPI
clCreateKernelsInProgram( cl_program program
, cl_uint num_kernels
, cl_kernel
* kernels
, cl_uint
* num_kernels_ret
)
97 struct clCreateKernelsInProgram_params params
= { program
, num_kernels
, kernels
, num_kernels_ret
};
98 TRACE( "(%p, %u, %p, %p)\n", program
, num_kernels
, kernels
, num_kernels_ret
);
99 return OPENCL_CALL( clCreateKernelsInProgram
, ¶ms
);
102 cl_program WINAPI
clCreateProgramWithBinary( cl_context context
, cl_uint num_devices
, const cl_device_id
* device_list
, const size_t* lengths
, const unsigned char** binaries
, cl_int
* binary_status
, cl_int
* errcode_ret
)
105 struct clCreateProgramWithBinary_params params
= { &__retval
, context
, num_devices
, device_list
, lengths
, binaries
, binary_status
, errcode_ret
};
106 TRACE( "(%p, %u, %p, %p, %p, %p, %p)\n", context
, num_devices
, device_list
, lengths
, binaries
, binary_status
, errcode_ret
);
107 OPENCL_CALL( clCreateProgramWithBinary
, ¶ms
);
111 cl_program WINAPI
clCreateProgramWithBuiltInKernels( cl_context context
, cl_uint num_devices
, const cl_device_id
* device_list
, const char* kernel_names
, cl_int
* errcode_ret
)
114 struct clCreateProgramWithBuiltInKernels_params params
= { &__retval
, context
, num_devices
, device_list
, kernel_names
, errcode_ret
};
115 TRACE( "(%p, %u, %p, %p, %p)\n", context
, num_devices
, device_list
, kernel_names
, errcode_ret
);
116 OPENCL_CALL( clCreateProgramWithBuiltInKernels
, ¶ms
);
120 cl_program WINAPI
clCreateProgramWithSource( cl_context context
, cl_uint count
, const char** strings
, const size_t* lengths
, cl_int
* errcode_ret
)
123 struct clCreateProgramWithSource_params params
= { &__retval
, context
, count
, strings
, lengths
, errcode_ret
};
124 TRACE( "(%p, %u, %p, %p, %p)\n", context
, count
, strings
, lengths
, errcode_ret
);
125 OPENCL_CALL( clCreateProgramWithSource
, ¶ms
);
129 cl_sampler WINAPI
clCreateSampler( cl_context context
, cl_bool normalized_coords
, cl_addressing_mode addressing_mode
, cl_filter_mode filter_mode
, cl_int
* errcode_ret
)
132 struct clCreateSampler_params params
= { &__retval
, context
, normalized_coords
, addressing_mode
, filter_mode
, errcode_ret
};
133 TRACE( "(%p, %u, %u, %u, %p)\n", context
, normalized_coords
, addressing_mode
, filter_mode
, errcode_ret
);
134 OPENCL_CALL( clCreateSampler
, ¶ms
);
138 cl_mem WINAPI
clCreateSubBuffer( cl_mem buffer
, cl_mem_flags flags
, cl_buffer_create_type buffer_create_type
, const void* buffer_create_info
, cl_int
* errcode_ret
)
141 struct clCreateSubBuffer_params params
= { &__retval
, buffer
, flags
, buffer_create_type
, buffer_create_info
, errcode_ret
};
142 TRACE( "(%p, %s, %u, %p, %p)\n", buffer
, wine_dbgstr_longlong(flags
), buffer_create_type
, buffer_create_info
, errcode_ret
);
143 OPENCL_CALL( clCreateSubBuffer
, ¶ms
);
147 cl_int WINAPI
clCreateSubDevices( cl_device_id in_device
, const cl_device_partition_property
* properties
, cl_uint num_devices
, cl_device_id
* out_devices
, cl_uint
* num_devices_ret
)
149 struct clCreateSubDevices_params params
= { in_device
, properties
, num_devices
, out_devices
, num_devices_ret
};
150 TRACE( "(%p, %p, %u, %p, %p)\n", in_device
, properties
, num_devices
, out_devices
, num_devices_ret
);
151 return OPENCL_CALL( clCreateSubDevices
, ¶ms
);
154 cl_event WINAPI
clCreateUserEvent( cl_context context
, cl_int
* errcode_ret
)
157 struct clCreateUserEvent_params params
= { &__retval
, context
, errcode_ret
};
158 TRACE( "(%p, %p)\n", context
, errcode_ret
);
159 OPENCL_CALL( clCreateUserEvent
, ¶ms
);
163 cl_int WINAPI
clEnqueueBarrier( cl_command_queue command_queue
)
165 struct clEnqueueBarrier_params params
= { command_queue
};
166 TRACE( "(%p)\n", command_queue
);
167 return OPENCL_CALL( clEnqueueBarrier
, ¶ms
);
170 cl_int WINAPI
clEnqueueBarrierWithWaitList( cl_command_queue command_queue
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
172 struct clEnqueueBarrierWithWaitList_params params
= { command_queue
, num_events_in_wait_list
, event_wait_list
, event
};
173 TRACE( "(%p, %u, %p, %p)\n", command_queue
, num_events_in_wait_list
, event_wait_list
, event
);
174 return OPENCL_CALL( clEnqueueBarrierWithWaitList
, ¶ms
);
177 cl_int WINAPI
clEnqueueCopyBuffer( cl_command_queue command_queue
, cl_mem src_buffer
, cl_mem dst_buffer
, size_t src_offset
, size_t dst_offset
, size_t size
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
179 struct clEnqueueCopyBuffer_params params
= { command_queue
, src_buffer
, dst_buffer
, src_offset
, dst_offset
, size
, num_events_in_wait_list
, event_wait_list
, event
};
180 TRACE( "(%p, %p, %p, %Iu, %Iu, %Iu, %u, %p, %p)\n", command_queue
, src_buffer
, dst_buffer
, src_offset
, dst_offset
, size
, num_events_in_wait_list
, event_wait_list
, event
);
181 return OPENCL_CALL( clEnqueueCopyBuffer
, ¶ms
);
184 cl_int WINAPI
clEnqueueCopyBufferRect( cl_command_queue command_queue
, cl_mem src_buffer
, cl_mem dst_buffer
, const size_t* src_origin
, const size_t* dst_origin
, const size_t* region
, size_t src_row_pitch
, size_t src_slice_pitch
, size_t dst_row_pitch
, size_t dst_slice_pitch
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
186 struct clEnqueueCopyBufferRect_params params
= { command_queue
, src_buffer
, dst_buffer
, src_origin
, dst_origin
, region
, src_row_pitch
, src_slice_pitch
, dst_row_pitch
, dst_slice_pitch
, num_events_in_wait_list
, event_wait_list
, event
};
187 TRACE( "(%p, %p, %p, %p, %p, %p, %Iu, %Iu, %Iu, %Iu, %u, %p, %p)\n", command_queue
, src_buffer
, dst_buffer
, src_origin
, dst_origin
, region
, src_row_pitch
, src_slice_pitch
, dst_row_pitch
, dst_slice_pitch
, num_events_in_wait_list
, event_wait_list
, event
);
188 return OPENCL_CALL( clEnqueueCopyBufferRect
, ¶ms
);
191 cl_int WINAPI
clEnqueueCopyBufferToImage( cl_command_queue command_queue
, cl_mem src_buffer
, cl_mem dst_image
, size_t src_offset
, const size_t* dst_origin
, const size_t* region
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
193 struct clEnqueueCopyBufferToImage_params params
= { command_queue
, src_buffer
, dst_image
, src_offset
, dst_origin
, region
, num_events_in_wait_list
, event_wait_list
, event
};
194 TRACE( "(%p, %p, %p, %Iu, %p, %p, %u, %p, %p)\n", command_queue
, src_buffer
, dst_image
, src_offset
, dst_origin
, region
, num_events_in_wait_list
, event_wait_list
, event
);
195 return OPENCL_CALL( clEnqueueCopyBufferToImage
, ¶ms
);
198 cl_int WINAPI
clEnqueueCopyImage( cl_command_queue command_queue
, cl_mem src_image
, cl_mem dst_image
, const size_t* src_origin
, const size_t* dst_origin
, const size_t* region
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
200 struct clEnqueueCopyImage_params params
= { command_queue
, src_image
, dst_image
, src_origin
, dst_origin
, region
, num_events_in_wait_list
, event_wait_list
, event
};
201 TRACE( "(%p, %p, %p, %p, %p, %p, %u, %p, %p)\n", command_queue
, src_image
, dst_image
, src_origin
, dst_origin
, region
, num_events_in_wait_list
, event_wait_list
, event
);
202 return OPENCL_CALL( clEnqueueCopyImage
, ¶ms
);
205 cl_int WINAPI
clEnqueueCopyImageToBuffer( cl_command_queue command_queue
, cl_mem src_image
, cl_mem dst_buffer
, const size_t* src_origin
, const size_t* region
, size_t dst_offset
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
207 struct clEnqueueCopyImageToBuffer_params params
= { command_queue
, src_image
, dst_buffer
, src_origin
, region
, dst_offset
, num_events_in_wait_list
, event_wait_list
, event
};
208 TRACE( "(%p, %p, %p, %p, %p, %Iu, %u, %p, %p)\n", command_queue
, src_image
, dst_buffer
, src_origin
, region
, dst_offset
, num_events_in_wait_list
, event_wait_list
, event
);
209 return OPENCL_CALL( clEnqueueCopyImageToBuffer
, ¶ms
);
212 cl_int WINAPI
clEnqueueFillBuffer( cl_command_queue command_queue
, cl_mem buffer
, const void* pattern
, size_t pattern_size
, size_t offset
, size_t size
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
214 struct clEnqueueFillBuffer_params params
= { command_queue
, buffer
, pattern
, pattern_size
, offset
, size
, num_events_in_wait_list
, event_wait_list
, event
};
215 TRACE( "(%p, %p, %p, %Iu, %Iu, %Iu, %u, %p, %p)\n", command_queue
, buffer
, pattern
, pattern_size
, offset
, size
, num_events_in_wait_list
, event_wait_list
, event
);
216 return OPENCL_CALL( clEnqueueFillBuffer
, ¶ms
);
219 cl_int WINAPI
clEnqueueFillImage( cl_command_queue command_queue
, cl_mem image
, const void* fill_color
, const size_t* origin
, const size_t* region
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
221 struct clEnqueueFillImage_params params
= { command_queue
, image
, fill_color
, origin
, region
, num_events_in_wait_list
, event_wait_list
, event
};
222 TRACE( "(%p, %p, %p, %p, %p, %u, %p, %p)\n", command_queue
, image
, fill_color
, origin
, region
, num_events_in_wait_list
, event_wait_list
, event
);
223 return OPENCL_CALL( clEnqueueFillImage
, ¶ms
);
226 void* WINAPI
clEnqueueMapBuffer( cl_command_queue command_queue
, cl_mem buffer
, cl_bool blocking_map
, cl_map_flags map_flags
, size_t offset
, size_t size
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
, cl_int
* errcode_ret
)
229 struct clEnqueueMapBuffer_params params
= { &__retval
, command_queue
, buffer
, blocking_map
, map_flags
, offset
, size
, num_events_in_wait_list
, event_wait_list
, event
, errcode_ret
};
230 TRACE( "(%p, %p, %u, %s, %Iu, %Iu, %u, %p, %p, %p)\n", command_queue
, buffer
, blocking_map
, wine_dbgstr_longlong(map_flags
), offset
, size
, num_events_in_wait_list
, event_wait_list
, event
, errcode_ret
);
231 OPENCL_CALL( clEnqueueMapBuffer
, ¶ms
);
235 void* WINAPI
clEnqueueMapImage( cl_command_queue command_queue
, cl_mem image
, cl_bool blocking_map
, cl_map_flags map_flags
, const size_t* origin
, const size_t* region
, size_t* image_row_pitch
, size_t* image_slice_pitch
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
, cl_int
* errcode_ret
)
238 struct clEnqueueMapImage_params params
= { &__retval
, command_queue
, image
, blocking_map
, map_flags
, origin
, region
, image_row_pitch
, image_slice_pitch
, num_events_in_wait_list
, event_wait_list
, event
, errcode_ret
};
239 TRACE( "(%p, %p, %u, %s, %p, %p, %p, %p, %u, %p, %p, %p)\n", command_queue
, image
, blocking_map
, wine_dbgstr_longlong(map_flags
), origin
, region
, image_row_pitch
, image_slice_pitch
, num_events_in_wait_list
, event_wait_list
, event
, errcode_ret
);
240 OPENCL_CALL( clEnqueueMapImage
, ¶ms
);
244 cl_int WINAPI
clEnqueueMarker( cl_command_queue command_queue
, cl_event
* event
)
246 struct clEnqueueMarker_params params
= { command_queue
, event
};
247 TRACE( "(%p, %p)\n", command_queue
, event
);
248 return OPENCL_CALL( clEnqueueMarker
, ¶ms
);
251 cl_int WINAPI
clEnqueueMarkerWithWaitList( cl_command_queue command_queue
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
253 struct clEnqueueMarkerWithWaitList_params params
= { command_queue
, num_events_in_wait_list
, event_wait_list
, event
};
254 TRACE( "(%p, %u, %p, %p)\n", command_queue
, num_events_in_wait_list
, event_wait_list
, event
);
255 return OPENCL_CALL( clEnqueueMarkerWithWaitList
, ¶ms
);
258 cl_int WINAPI
clEnqueueMigrateMemObjects( cl_command_queue command_queue
, cl_uint num_mem_objects
, const cl_mem
* mem_objects
, cl_mem_migration_flags flags
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
260 struct clEnqueueMigrateMemObjects_params params
= { command_queue
, num_mem_objects
, mem_objects
, flags
, num_events_in_wait_list
, event_wait_list
, event
};
261 TRACE( "(%p, %u, %p, %s, %u, %p, %p)\n", command_queue
, num_mem_objects
, mem_objects
, wine_dbgstr_longlong(flags
), num_events_in_wait_list
, event_wait_list
, event
);
262 return OPENCL_CALL( clEnqueueMigrateMemObjects
, ¶ms
);
265 cl_int WINAPI
clEnqueueNDRangeKernel( cl_command_queue command_queue
, cl_kernel kernel
, cl_uint work_dim
, const size_t* global_work_offset
, const size_t* global_work_size
, const size_t* local_work_size
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
267 struct clEnqueueNDRangeKernel_params params
= { command_queue
, kernel
, work_dim
, global_work_offset
, global_work_size
, local_work_size
, num_events_in_wait_list
, event_wait_list
, event
};
268 TRACE( "(%p, %p, %u, %p, %p, %p, %u, %p, %p)\n", command_queue
, kernel
, work_dim
, global_work_offset
, global_work_size
, local_work_size
, num_events_in_wait_list
, event_wait_list
, event
);
269 return OPENCL_CALL( clEnqueueNDRangeKernel
, ¶ms
);
272 cl_int WINAPI
clEnqueueNativeKernel( cl_command_queue command_queue
, void (WINAPI
* user_func
)(void*), void* args
, size_t cb_args
, cl_uint num_mem_objects
, const cl_mem
* mem_list
, const void** args_mem_loc
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
274 struct clEnqueueNativeKernel_params params
= { command_queue
, user_func
, args
, cb_args
, num_mem_objects
, mem_list
, args_mem_loc
, num_events_in_wait_list
, event_wait_list
, event
};
275 TRACE( "(%p, %p, %p, %Iu, %u, %p, %p, %u, %p, %p)\n", command_queue
, user_func
, args
, cb_args
, num_mem_objects
, mem_list
, args_mem_loc
, num_events_in_wait_list
, event_wait_list
, event
);
276 return OPENCL_CALL( clEnqueueNativeKernel
, ¶ms
);
279 cl_int WINAPI
clEnqueueReadBuffer( cl_command_queue command_queue
, cl_mem buffer
, cl_bool blocking_read
, size_t offset
, size_t size
, void* ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
281 struct clEnqueueReadBuffer_params params
= { command_queue
, buffer
, blocking_read
, offset
, size
, ptr
, num_events_in_wait_list
, event_wait_list
, event
};
282 TRACE( "(%p, %p, %u, %Iu, %Iu, %p, %u, %p, %p)\n", command_queue
, buffer
, blocking_read
, offset
, size
, ptr
, num_events_in_wait_list
, event_wait_list
, event
);
283 return OPENCL_CALL( clEnqueueReadBuffer
, ¶ms
);
286 cl_int WINAPI
clEnqueueReadBufferRect( cl_command_queue command_queue
, cl_mem buffer
, cl_bool blocking_read
, const size_t* buffer_origin
, const size_t* host_origin
, const size_t* region
, size_t buffer_row_pitch
, size_t buffer_slice_pitch
, size_t host_row_pitch
, size_t host_slice_pitch
, void* ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
288 struct clEnqueueReadBufferRect_params params
= { command_queue
, buffer
, blocking_read
, buffer_origin
, host_origin
, region
, buffer_row_pitch
, buffer_slice_pitch
, host_row_pitch
, host_slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
};
289 TRACE( "(%p, %p, %u, %p, %p, %p, %Iu, %Iu, %Iu, %Iu, %p, %u, %p, %p)\n", command_queue
, buffer
, blocking_read
, buffer_origin
, host_origin
, region
, buffer_row_pitch
, buffer_slice_pitch
, host_row_pitch
, host_slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
);
290 return OPENCL_CALL( clEnqueueReadBufferRect
, ¶ms
);
293 cl_int WINAPI
clEnqueueReadImage( cl_command_queue command_queue
, cl_mem image
, cl_bool blocking_read
, const size_t* origin
, const size_t* region
, size_t row_pitch
, size_t slice_pitch
, void* ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
295 struct clEnqueueReadImage_params params
= { command_queue
, image
, blocking_read
, origin
, region
, row_pitch
, slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
};
296 TRACE( "(%p, %p, %u, %p, %p, %Iu, %Iu, %p, %u, %p, %p)\n", command_queue
, image
, blocking_read
, origin
, region
, row_pitch
, slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
);
297 return OPENCL_CALL( clEnqueueReadImage
, ¶ms
);
300 cl_int WINAPI
clEnqueueTask( cl_command_queue command_queue
, cl_kernel kernel
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
302 struct clEnqueueTask_params params
= { command_queue
, kernel
, num_events_in_wait_list
, event_wait_list
, event
};
303 TRACE( "(%p, %p, %u, %p, %p)\n", command_queue
, kernel
, num_events_in_wait_list
, event_wait_list
, event
);
304 return OPENCL_CALL( clEnqueueTask
, ¶ms
);
307 cl_int WINAPI
clEnqueueUnmapMemObject( cl_command_queue command_queue
, cl_mem memobj
, void* mapped_ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
309 struct clEnqueueUnmapMemObject_params params
= { command_queue
, memobj
, mapped_ptr
, num_events_in_wait_list
, event_wait_list
, event
};
310 TRACE( "(%p, %p, %p, %u, %p, %p)\n", command_queue
, memobj
, mapped_ptr
, num_events_in_wait_list
, event_wait_list
, event
);
311 return OPENCL_CALL( clEnqueueUnmapMemObject
, ¶ms
);
314 cl_int WINAPI
clEnqueueWaitForEvents( cl_command_queue command_queue
, cl_uint num_events
, const cl_event
* event_list
)
316 struct clEnqueueWaitForEvents_params params
= { command_queue
, num_events
, event_list
};
317 TRACE( "(%p, %u, %p)\n", command_queue
, num_events
, event_list
);
318 return OPENCL_CALL( clEnqueueWaitForEvents
, ¶ms
);
321 cl_int WINAPI
clEnqueueWriteBuffer( cl_command_queue command_queue
, cl_mem buffer
, cl_bool blocking_write
, size_t offset
, size_t size
, const void* ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
323 struct clEnqueueWriteBuffer_params params
= { command_queue
, buffer
, blocking_write
, offset
, size
, ptr
, num_events_in_wait_list
, event_wait_list
, event
};
324 TRACE( "(%p, %p, %u, %Iu, %Iu, %p, %u, %p, %p)\n", command_queue
, buffer
, blocking_write
, offset
, size
, ptr
, num_events_in_wait_list
, event_wait_list
, event
);
325 return OPENCL_CALL( clEnqueueWriteBuffer
, ¶ms
);
328 cl_int WINAPI
clEnqueueWriteBufferRect( cl_command_queue command_queue
, cl_mem buffer
, cl_bool blocking_write
, const size_t* buffer_origin
, const size_t* host_origin
, const size_t* region
, size_t buffer_row_pitch
, size_t buffer_slice_pitch
, size_t host_row_pitch
, size_t host_slice_pitch
, const void* ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
330 struct clEnqueueWriteBufferRect_params params
= { command_queue
, buffer
, blocking_write
, buffer_origin
, host_origin
, region
, buffer_row_pitch
, buffer_slice_pitch
, host_row_pitch
, host_slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
};
331 TRACE( "(%p, %p, %u, %p, %p, %p, %Iu, %Iu, %Iu, %Iu, %p, %u, %p, %p)\n", command_queue
, buffer
, blocking_write
, buffer_origin
, host_origin
, region
, buffer_row_pitch
, buffer_slice_pitch
, host_row_pitch
, host_slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
);
332 return OPENCL_CALL( clEnqueueWriteBufferRect
, ¶ms
);
335 cl_int WINAPI
clEnqueueWriteImage( cl_command_queue command_queue
, cl_mem image
, cl_bool blocking_write
, const size_t* origin
, const size_t* region
, size_t input_row_pitch
, size_t input_slice_pitch
, const void* ptr
, cl_uint num_events_in_wait_list
, const cl_event
* event_wait_list
, cl_event
* event
)
337 struct clEnqueueWriteImage_params params
= { command_queue
, image
, blocking_write
, origin
, region
, input_row_pitch
, input_slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
};
338 TRACE( "(%p, %p, %u, %p, %p, %Iu, %Iu, %p, %u, %p, %p)\n", command_queue
, image
, blocking_write
, origin
, region
, input_row_pitch
, input_slice_pitch
, ptr
, num_events_in_wait_list
, event_wait_list
, event
);
339 return OPENCL_CALL( clEnqueueWriteImage
, ¶ms
);
342 cl_int WINAPI
clFinish( cl_command_queue command_queue
)
344 struct clFinish_params params
= { command_queue
};
345 TRACE( "(%p)\n", command_queue
);
346 return OPENCL_CALL( clFinish
, ¶ms
);
349 cl_int WINAPI
clFlush( cl_command_queue command_queue
)
351 struct clFlush_params params
= { command_queue
};
352 TRACE( "(%p)\n", command_queue
);
353 return OPENCL_CALL( clFlush
, ¶ms
);
356 cl_int WINAPI
clGetCommandQueueInfo( cl_command_queue command_queue
, cl_command_queue_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
358 struct clGetCommandQueueInfo_params params
= { command_queue
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
359 TRACE( "(%p, %u, %Iu, %p, %p)\n", command_queue
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
360 return OPENCL_CALL( clGetCommandQueueInfo
, ¶ms
);
363 cl_int WINAPI
clGetContextInfo( cl_context context
, cl_context_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
365 struct clGetContextInfo_params params
= { context
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
366 TRACE( "(%p, %u, %Iu, %p, %p)\n", context
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
367 return OPENCL_CALL( clGetContextInfo
, ¶ms
);
370 cl_int WINAPI
clGetDeviceIDs( cl_platform_id platform
, cl_device_type device_type
, cl_uint num_entries
, cl_device_id
* devices
, cl_uint
* num_devices
)
372 struct clGetDeviceIDs_params params
= { platform
, device_type
, num_entries
, devices
, num_devices
};
373 TRACE( "(%p, %s, %u, %p, %p)\n", platform
, wine_dbgstr_longlong(device_type
), num_entries
, devices
, num_devices
);
374 return OPENCL_CALL( clGetDeviceIDs
, ¶ms
);
377 cl_int WINAPI
clGetEventInfo( cl_event event
, cl_event_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
379 struct clGetEventInfo_params params
= { event
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
380 TRACE( "(%p, %u, %Iu, %p, %p)\n", event
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
381 return OPENCL_CALL( clGetEventInfo
, ¶ms
);
384 cl_int WINAPI
clGetEventProfilingInfo( cl_event event
, cl_profiling_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
386 struct clGetEventProfilingInfo_params params
= { event
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
387 TRACE( "(%p, %u, %Iu, %p, %p)\n", event
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
388 return OPENCL_CALL( clGetEventProfilingInfo
, ¶ms
);
391 cl_int WINAPI
clGetImageInfo( cl_mem image
, cl_image_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
393 struct clGetImageInfo_params params
= { image
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
394 TRACE( "(%p, %u, %Iu, %p, %p)\n", image
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
395 return OPENCL_CALL( clGetImageInfo
, ¶ms
);
398 cl_int WINAPI
clGetKernelArgInfo( cl_kernel kernel
, cl_uint arg_index
, cl_kernel_arg_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
400 struct clGetKernelArgInfo_params params
= { kernel
, arg_index
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
401 TRACE( "(%p, %u, %u, %Iu, %p, %p)\n", kernel
, arg_index
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
402 return OPENCL_CALL( clGetKernelArgInfo
, ¶ms
);
405 cl_int WINAPI
clGetKernelInfo( cl_kernel kernel
, cl_kernel_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
407 struct clGetKernelInfo_params params
= { kernel
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
408 TRACE( "(%p, %u, %Iu, %p, %p)\n", kernel
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
409 return OPENCL_CALL( clGetKernelInfo
, ¶ms
);
412 cl_int WINAPI
clGetKernelWorkGroupInfo( cl_kernel kernel
, cl_device_id device
, cl_kernel_work_group_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
414 struct clGetKernelWorkGroupInfo_params params
= { kernel
, device
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
415 TRACE( "(%p, %p, %u, %Iu, %p, %p)\n", kernel
, device
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
416 return OPENCL_CALL( clGetKernelWorkGroupInfo
, ¶ms
);
419 cl_int WINAPI
clGetMemObjectInfo( cl_mem memobj
, cl_mem_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
421 struct clGetMemObjectInfo_params params
= { memobj
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
422 TRACE( "(%p, %u, %Iu, %p, %p)\n", memobj
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
423 return OPENCL_CALL( clGetMemObjectInfo
, ¶ms
);
426 cl_int WINAPI
clGetPlatformIDs( cl_uint num_entries
, cl_platform_id
* platforms
, cl_uint
* num_platforms
)
428 struct clGetPlatformIDs_params params
= { num_entries
, platforms
, num_platforms
};
429 TRACE( "(%u, %p, %p)\n", num_entries
, platforms
, num_platforms
);
430 return OPENCL_CALL( clGetPlatformIDs
, ¶ms
);
433 cl_int WINAPI
clGetProgramBuildInfo( cl_program program
, cl_device_id device
, cl_program_build_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
435 struct clGetProgramBuildInfo_params params
= { program
, device
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
436 TRACE( "(%p, %p, %u, %Iu, %p, %p)\n", program
, device
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
437 return OPENCL_CALL( clGetProgramBuildInfo
, ¶ms
);
440 cl_int WINAPI
clGetProgramInfo( cl_program program
, cl_program_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
442 struct clGetProgramInfo_params params
= { program
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
443 TRACE( "(%p, %u, %Iu, %p, %p)\n", program
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
444 return OPENCL_CALL( clGetProgramInfo
, ¶ms
);
447 cl_int WINAPI
clGetSamplerInfo( cl_sampler sampler
, cl_sampler_info param_name
, size_t param_value_size
, void* param_value
, size_t* param_value_size_ret
)
449 struct clGetSamplerInfo_params params
= { sampler
, param_name
, param_value_size
, param_value
, param_value_size_ret
};
450 TRACE( "(%p, %u, %Iu, %p, %p)\n", sampler
, param_name
, param_value_size
, param_value
, param_value_size_ret
);
451 return OPENCL_CALL( clGetSamplerInfo
, ¶ms
);
454 cl_int WINAPI
clGetSupportedImageFormats( cl_context context
, cl_mem_flags flags
, cl_mem_object_type image_type
, cl_uint num_entries
, cl_image_format
* image_formats
, cl_uint
* num_image_formats
)
456 struct clGetSupportedImageFormats_params params
= { context
, flags
, image_type
, num_entries
, image_formats
, num_image_formats
};
457 TRACE( "(%p, %s, %u, %u, %p, %p)\n", context
, wine_dbgstr_longlong(flags
), image_type
, num_entries
, image_formats
, num_image_formats
);
458 return OPENCL_CALL( clGetSupportedImageFormats
, ¶ms
);
461 cl_program WINAPI
clLinkProgram( cl_context context
, cl_uint num_devices
, const cl_device_id
* device_list
, const char* options
, cl_uint num_input_programs
, const cl_program
* input_programs
, void (WINAPI
* pfn_notify
)(cl_program program
, void* user_data
), void* user_data
, cl_int
* errcode_ret
)
464 struct clLinkProgram_params params
= { &__retval
, context
, num_devices
, device_list
, options
, num_input_programs
, input_programs
, pfn_notify
, user_data
, errcode_ret
};
465 TRACE( "(%p, %u, %p, %p, %u, %p, %p, %p, %p)\n", context
, num_devices
, device_list
, options
, num_input_programs
, input_programs
, pfn_notify
, user_data
, errcode_ret
);
466 OPENCL_CALL( clLinkProgram
, ¶ms
);
470 cl_int WINAPI
clReleaseCommandQueue( cl_command_queue command_queue
)
472 struct clReleaseCommandQueue_params params
= { command_queue
};
473 TRACE( "(%p)\n", command_queue
);
474 return OPENCL_CALL( clReleaseCommandQueue
, ¶ms
);
477 cl_int WINAPI
clReleaseContext( cl_context context
)
479 struct clReleaseContext_params params
= { context
};
480 TRACE( "(%p)\n", context
);
481 return OPENCL_CALL( clReleaseContext
, ¶ms
);
484 cl_int WINAPI
clReleaseDevice( cl_device_id device
)
486 struct clReleaseDevice_params params
= { device
};
487 TRACE( "(%p)\n", device
);
488 return OPENCL_CALL( clReleaseDevice
, ¶ms
);
491 cl_int WINAPI
clReleaseEvent( cl_event event
)
493 struct clReleaseEvent_params params
= { event
};
494 TRACE( "(%p)\n", event
);
495 return OPENCL_CALL( clReleaseEvent
, ¶ms
);
498 cl_int WINAPI
clReleaseKernel( cl_kernel kernel
)
500 struct clReleaseKernel_params params
= { kernel
};
501 TRACE( "(%p)\n", kernel
);
502 return OPENCL_CALL( clReleaseKernel
, ¶ms
);
505 cl_int WINAPI
clReleaseMemObject( cl_mem memobj
)
507 struct clReleaseMemObject_params params
= { memobj
};
508 TRACE( "(%p)\n", memobj
);
509 return OPENCL_CALL( clReleaseMemObject
, ¶ms
);
512 cl_int WINAPI
clReleaseProgram( cl_program program
)
514 struct clReleaseProgram_params params
= { program
};
515 TRACE( "(%p)\n", program
);
516 return OPENCL_CALL( clReleaseProgram
, ¶ms
);
519 cl_int WINAPI
clReleaseSampler( cl_sampler sampler
)
521 struct clReleaseSampler_params params
= { sampler
};
522 TRACE( "(%p)\n", sampler
);
523 return OPENCL_CALL( clReleaseSampler
, ¶ms
);
526 cl_int WINAPI
clRetainCommandQueue( cl_command_queue command_queue
)
528 struct clRetainCommandQueue_params params
= { command_queue
};
529 TRACE( "(%p)\n", command_queue
);
530 return OPENCL_CALL( clRetainCommandQueue
, ¶ms
);
533 cl_int WINAPI
clRetainContext( cl_context context
)
535 struct clRetainContext_params params
= { context
};
536 TRACE( "(%p)\n", context
);
537 return OPENCL_CALL( clRetainContext
, ¶ms
);
540 cl_int WINAPI
clRetainDevice( cl_device_id device
)
542 struct clRetainDevice_params params
= { device
};
543 TRACE( "(%p)\n", device
);
544 return OPENCL_CALL( clRetainDevice
, ¶ms
);
547 cl_int WINAPI
clRetainEvent( cl_event event
)
549 struct clRetainEvent_params params
= { event
};
550 TRACE( "(%p)\n", event
);
551 return OPENCL_CALL( clRetainEvent
, ¶ms
);
554 cl_int WINAPI
clRetainKernel( cl_kernel kernel
)
556 struct clRetainKernel_params params
= { kernel
};
557 TRACE( "(%p)\n", kernel
);
558 return OPENCL_CALL( clRetainKernel
, ¶ms
);
561 cl_int WINAPI
clRetainMemObject( cl_mem memobj
)
563 struct clRetainMemObject_params params
= { memobj
};
564 TRACE( "(%p)\n", memobj
);
565 return OPENCL_CALL( clRetainMemObject
, ¶ms
);
568 cl_int WINAPI
clRetainProgram( cl_program program
)
570 struct clRetainProgram_params params
= { program
};
571 TRACE( "(%p)\n", program
);
572 return OPENCL_CALL( clRetainProgram
, ¶ms
);
575 cl_int WINAPI
clRetainSampler( cl_sampler sampler
)
577 struct clRetainSampler_params params
= { sampler
};
578 TRACE( "(%p)\n", sampler
);
579 return OPENCL_CALL( clRetainSampler
, ¶ms
);
582 cl_int WINAPI
clSetEventCallback( cl_event event
, cl_int command_exec_callback_type
, void (WINAPI
* pfn_notify
)(cl_event event
, cl_int event_command_status
, void *user_data
), void* user_data
)
584 struct clSetEventCallback_params params
= { event
, command_exec_callback_type
, pfn_notify
, user_data
};
585 TRACE( "(%p, %d, %p, %p)\n", event
, command_exec_callback_type
, pfn_notify
, user_data
);
586 return OPENCL_CALL( clSetEventCallback
, ¶ms
);
589 cl_int WINAPI
clSetKernelArg( cl_kernel kernel
, cl_uint arg_index
, size_t arg_size
, const void* arg_value
)
591 struct clSetKernelArg_params params
= { kernel
, arg_index
, arg_size
, arg_value
};
592 TRACE( "(%p, %u, %Iu, %p)\n", kernel
, arg_index
, arg_size
, arg_value
);
593 return OPENCL_CALL( clSetKernelArg
, ¶ms
);
596 cl_int WINAPI
clSetMemObjectDestructorCallback( cl_mem memobj
, void (WINAPI
* pfn_notify
)(cl_mem memobj
, void* user_data
), void* user_data
)
598 struct clSetMemObjectDestructorCallback_params params
= { memobj
, pfn_notify
, user_data
};
599 TRACE( "(%p, %p, %p)\n", memobj
, pfn_notify
, user_data
);
600 return OPENCL_CALL( clSetMemObjectDestructorCallback
, ¶ms
);
603 cl_int WINAPI
clSetUserEventStatus( cl_event event
, cl_int execution_status
)
605 struct clSetUserEventStatus_params params
= { event
, execution_status
};
606 TRACE( "(%p, %d)\n", event
, execution_status
);
607 return OPENCL_CALL( clSetUserEventStatus
, ¶ms
);
610 cl_int WINAPI
clUnloadCompiler( void )
612 struct clUnloadCompiler_params params
= {};
614 return OPENCL_CALL( clUnloadCompiler
, ¶ms
);
617 cl_int WINAPI
clUnloadPlatformCompiler( cl_platform_id platform
)
619 struct clUnloadPlatformCompiler_params params
= { platform
};
620 TRACE( "(%p)\n", platform
);
621 return OPENCL_CALL( clUnloadPlatformCompiler
, ¶ms
);
624 cl_int WINAPI
clWaitForEvents( cl_uint num_events
, const cl_event
* event_list
)
626 struct clWaitForEvents_params params
= { num_events
, event_list
};
627 TRACE( "(%u, %p)\n", num_events
, event_list
);
628 return OPENCL_CALL( clWaitForEvents
, ¶ms
);
631 BOOL
extension_is_supported( const char *name
, size_t len
)
635 static const char *const unsupported
[] =
637 "cl_apple_contextloggingfunctions",
638 "cl_apple_setmemobjectdestructor",
639 "cl_arm_import_memory",
640 "cl_arm_shared_virtual_memory",
641 "cl_ext_device_fission",
642 "cl_ext_migrate_memobject",
643 "cl_img_generate_mipmap",
644 "cl_img_use_gralloc_ptr",
645 "cl_intel_accelerator",
646 "cl_intel_create_buffer_with_properties",
647 "cl_intel_d3d11_nv12_media_sharing",
648 "cl_intel_dx9_media_sharing",
649 "cl_intel_unified_shared_memory",
650 "cl_intel_va_api_media_sharing",
651 "cl_khr_create_command_queue",
652 "cl_khr_d3d10_sharing",
653 "cl_khr_d3d11_sharing",
654 "cl_khr_dx9_media_sharing",
662 "cl_khr_terminate_context",
664 "cl_nv_d3d10_sharing",
665 "cl_nv_d3d11_sharing",
666 "cl_nv_d3d9_sharing",
667 "cl_qcom_ext_host_ptr",
670 for (i
= 0; i
< ARRAY_SIZE(unsupported
); ++i
)
672 if (!strncasecmp( name
, unsupported
[i
], len
))