Commit 8dd66ebe authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

opencl: Update to OpenCL 1.1.

parent 540e627a
...@@ -30,6 +30,7 @@ my $gen_traces = 1; ...@@ -30,6 +30,7 @@ my $gen_traces = 1;
# List of categories to put in the 'opengl_core.c' file # List of categories to put in the 'opengl_core.c' file
my %cat_1_0 = ( "CL_VERSION_1_0" => 1 ); my %cat_1_0 = ( "CL_VERSION_1_0" => 1 );
my %cat_1_1 = ( %cat_1_0, "CL_VERSION_1_1" => 1 );
my %core_categories = (); my %core_categories = ();
...@@ -183,11 +184,15 @@ if (@ARGV > 1) ...@@ -183,11 +184,15 @@ if (@ARGV > 1)
$name0 =~ s%^.*/%%; $name0 =~ s%^.*/%%;
die "Usage: $name0 [version]\n"; die "Usage: $name0 [version]\n";
} }
my $version = $ARGV[0] || "1.0"; my $version = $ARGV[0] || "1.1";
if ($version eq "1.0") if ($version eq "1.0")
{ {
%core_categories = %cat_1_0; %core_categories = %cat_1_0;
} }
elsif ($version eq "1.1")
{
%core_categories = %cat_1_1;
}
else else
{ {
die "Incorrect OpenCL version.\n"; die "Incorrect OpenCL version.\n";
...@@ -256,6 +261,8 @@ sub needs_unix_wrapper($) ...@@ -256,6 +261,8 @@ sub needs_unix_wrapper($)
"clCreateContext" => 1, "clCreateContext" => 1,
"clCreateContextFromType" => 1, "clCreateContextFromType" => 1,
"clEnqueueNativeKernel" => 1, "clEnqueueNativeKernel" => 1,
"clSetEventCallback" => 1,
"clSetMemObjectDestructorCallback" => 1,
); );
my $name = shift; my $name = shift;
......
...@@ -10,8 +10,11 @@ ...@@ -10,8 +10,11 @@
@ stdcall clCreateProgramWithBinary(ptr long ptr ptr ptr ptr ptr) @ stdcall clCreateProgramWithBinary(ptr long ptr ptr ptr ptr ptr)
@ stdcall clCreateProgramWithSource(ptr long ptr ptr ptr) @ stdcall clCreateProgramWithSource(ptr long ptr ptr ptr)
@ stdcall clCreateSampler(ptr long long long ptr) @ stdcall clCreateSampler(ptr long long long ptr)
@ stdcall clCreateSubBuffer(ptr int64 long ptr ptr)
@ stdcall clCreateUserEvent(ptr ptr)
@ stdcall clEnqueueBarrier(ptr) @ stdcall clEnqueueBarrier(ptr)
@ stdcall clEnqueueCopyBuffer(ptr ptr ptr long long long long ptr ptr) @ stdcall clEnqueueCopyBuffer(ptr ptr ptr long long long long ptr ptr)
@ stdcall clEnqueueCopyBufferRect(ptr ptr ptr ptr ptr ptr long long long long long ptr ptr)
@ stdcall clEnqueueCopyBufferToImage(ptr ptr ptr long ptr ptr long ptr ptr) @ stdcall clEnqueueCopyBufferToImage(ptr ptr ptr long ptr ptr long ptr ptr)
@ stdcall clEnqueueCopyImage(ptr ptr ptr ptr ptr ptr long ptr ptr) @ stdcall clEnqueueCopyImage(ptr ptr ptr ptr ptr ptr long ptr ptr)
@ stdcall clEnqueueCopyImageToBuffer(ptr ptr ptr ptr ptr long long ptr ptr) @ stdcall clEnqueueCopyImageToBuffer(ptr ptr ptr ptr ptr long long ptr ptr)
...@@ -21,11 +24,13 @@ ...@@ -21,11 +24,13 @@
@ stdcall clEnqueueNDRangeKernel(ptr ptr long ptr ptr ptr long ptr ptr) @ stdcall clEnqueueNDRangeKernel(ptr ptr long ptr ptr ptr long ptr ptr)
@ stdcall clEnqueueNativeKernel(ptr ptr ptr long long ptr ptr long ptr ptr) @ stdcall clEnqueueNativeKernel(ptr ptr ptr long long ptr ptr long ptr ptr)
@ stdcall clEnqueueReadBuffer(ptr ptr long long long ptr long ptr ptr) @ stdcall clEnqueueReadBuffer(ptr ptr long long long ptr long ptr ptr)
@ stdcall clEnqueueReadBufferRect(ptr ptr long ptr ptr ptr long long long long ptr long ptr ptr)
@ stdcall clEnqueueReadImage(ptr ptr long ptr ptr long long ptr long ptr ptr) @ stdcall clEnqueueReadImage(ptr ptr long ptr ptr long long ptr long ptr ptr)
@ stdcall clEnqueueTask(ptr ptr long ptr ptr) @ stdcall clEnqueueTask(ptr ptr long ptr ptr)
@ stdcall clEnqueueUnmapMemObject(ptr ptr ptr long ptr ptr) @ stdcall clEnqueueUnmapMemObject(ptr ptr ptr long ptr ptr)
@ stdcall clEnqueueWaitForEvents(ptr long ptr) @ stdcall clEnqueueWaitForEvents(ptr long ptr)
@ stdcall clEnqueueWriteBuffer(ptr ptr long long long ptr long ptr ptr) @ stdcall clEnqueueWriteBuffer(ptr ptr long long long ptr long ptr ptr)
@ stdcall clEnqueueWriteBufferRect(ptr ptr long ptr ptr ptr long long long long ptr long ptr ptr)
@ stdcall clEnqueueWriteImage(ptr ptr long ptr ptr long long ptr long ptr ptr) @ stdcall clEnqueueWriteImage(ptr ptr long ptr ptr long long ptr long ptr ptr)
@ stdcall clFinish(ptr) @ stdcall clFinish(ptr)
@ stdcall clFlush(ptr) @ stdcall clFlush(ptr)
...@@ -61,6 +66,9 @@ ...@@ -61,6 +66,9 @@
@ stdcall clRetainProgram(ptr) @ stdcall clRetainProgram(ptr)
@ stdcall clRetainSampler(ptr) @ stdcall clRetainSampler(ptr)
@ stdcall clSetCommandQueueProperty(ptr int64 long ptr) @ stdcall clSetCommandQueueProperty(ptr int64 long ptr)
@ stdcall clSetEventCallback(ptr long ptr ptr)
@ stdcall clSetKernelArg(ptr long long ptr) @ stdcall clSetKernelArg(ptr long long ptr)
@ stdcall clSetMemObjectDestructorCallback(ptr ptr ptr)
@ stdcall clSetUserEventStatus(ptr long)
@ stdcall clUnloadCompiler() @ stdcall clUnloadCompiler()
@ stdcall clWaitForEvents(long ptr) @ stdcall clWaitForEvents(long ptr)
...@@ -54,14 +54,17 @@ typedef struct _cl_buffer_region ...@@ -54,14 +54,17 @@ typedef struct _cl_buffer_region
size_t origin; size_t origin;
size_t size; size_t size;
} cl_buffer_region; } cl_buffer_region;
typedef cl_uint cl_buffer_create_type;
#define CL_A 0x10B1 #define CL_A 0x10B1
#define CL_ADDRESS_CLAMP 0x1132 #define CL_ADDRESS_CLAMP 0x1132
#define CL_ADDRESS_CLAMP_TO_EDGE 0x1131 #define CL_ADDRESS_CLAMP_TO_EDGE 0x1131
#define CL_ADDRESS_MIRRORED_REPEAT 0x1134
#define CL_ADDRESS_NONE 0x1130 #define CL_ADDRESS_NONE 0x1130
#define CL_ADDRESS_REPEAT 0x1133 #define CL_ADDRESS_REPEAT 0x1133
#define CL_ARGB 0x10B7 #define CL_ARGB 0x10B7
#define CL_BGRA 0x10B6 #define CL_BGRA 0x10B6
#define CL_BUFFER_CREATE_TYPE_REGION 0x1220
#define CL_BUILD_ERROR -2 #define CL_BUILD_ERROR -2
#define CL_BUILD_IN_PROGRESS -3 #define CL_BUILD_IN_PROGRESS -3
#define CL_BUILD_NONE -1 #define CL_BUILD_NONE -1
...@@ -72,6 +75,7 @@ typedef struct _cl_buffer_region ...@@ -72,6 +75,7 @@ typedef struct _cl_buffer_region
#define CL_CHAR_MIN CL_SCHAR_MIN #define CL_CHAR_MIN CL_SCHAR_MIN
#define CL_COMMAND_ACQUIRE_GL_OBJECTS 0x11FF #define CL_COMMAND_ACQUIRE_GL_OBJECTS 0x11FF
#define CL_COMMAND_COPY_BUFFER 0x11F5 #define CL_COMMAND_COPY_BUFFER 0x11F5
#define CL_COMMAND_COPY_BUFFER_RECT 0x1203
#define CL_COMMAND_COPY_BUFFER_TO_IMAGE 0x11FA #define CL_COMMAND_COPY_BUFFER_TO_IMAGE 0x11FA
#define CL_COMMAND_COPY_IMAGE 0x11F8 #define CL_COMMAND_COPY_IMAGE 0x11F8
#define CL_COMMAND_COPY_IMAGE_TO_BUFFER 0x11F9 #define CL_COMMAND_COPY_IMAGE_TO_BUFFER 0x11F9
...@@ -81,15 +85,19 @@ typedef struct _cl_buffer_region ...@@ -81,15 +85,19 @@ typedef struct _cl_buffer_region
#define CL_COMMAND_NATIVE_KERNEL 0x11F2 #define CL_COMMAND_NATIVE_KERNEL 0x11F2
#define CL_COMMAND_NDRANGE_KERNEL 0x11F0 #define CL_COMMAND_NDRANGE_KERNEL 0x11F0
#define CL_COMMAND_READ_BUFFER 0x11F3 #define CL_COMMAND_READ_BUFFER 0x11F3
#define CL_COMMAND_READ_BUFFER_RECT 0x1201
#define CL_COMMAND_READ_IMAGE 0x11F6 #define CL_COMMAND_READ_IMAGE 0x11F6
#define CL_COMMAND_RELEASE_GL_OBJECTS 0x1200 #define CL_COMMAND_RELEASE_GL_OBJECTS 0x1200
#define CL_COMMAND_TASK 0x11F1 #define CL_COMMAND_TASK 0x11F1
#define CL_COMMAND_UNMAP_MEM_OBJECT 0x11FD #define CL_COMMAND_UNMAP_MEM_OBJECT 0x11FD
#define CL_COMMAND_USER 0x1204
#define CL_COMMAND_WRITE_BUFFER 0x11F4 #define CL_COMMAND_WRITE_BUFFER 0x11F4
#define CL_COMMAND_WRITE_BUFFER_RECT 0x1202
#define CL_COMMAND_WRITE_IMAGE 0x11F7 #define CL_COMMAND_WRITE_IMAGE 0x11F7
#define CL_COMPILER_NOT_AVAILABLE -3 #define CL_COMPILER_NOT_AVAILABLE -3
#define CL_COMPLETE 0x0 #define CL_COMPLETE 0x0
#define CL_CONTEXT_DEVICES 0x1081 #define CL_CONTEXT_DEVICES 0x1081
#define CL_CONTEXT_NUM_DEVICES 0x1083
#define CL_CONTEXT_PLATFORM 0x1084 #define CL_CONTEXT_PLATFORM 0x1084
#define CL_CONTEXT_PROPERTIES 0x1082 #define CL_CONTEXT_PROPERTIES 0x1082
#define CL_CONTEXT_REFERENCE_COUNT 0x1080 #define CL_CONTEXT_REFERENCE_COUNT 0x1080
...@@ -114,6 +122,7 @@ typedef struct _cl_buffer_region ...@@ -114,6 +122,7 @@ typedef struct _cl_buffer_region
#define CL_DEVICE_GLOBAL_MEM_CACHE_SIZE 0x101E #define CL_DEVICE_GLOBAL_MEM_CACHE_SIZE 0x101E
#define CL_DEVICE_GLOBAL_MEM_CACHE_TYPE 0x101C #define CL_DEVICE_GLOBAL_MEM_CACHE_TYPE 0x101C
#define CL_DEVICE_GLOBAL_MEM_SIZE 0x101F #define CL_DEVICE_GLOBAL_MEM_SIZE 0x101F
#define CL_DEVICE_HOST_UNIFIED_MEMORY 0x1035
#define CL_DEVICE_IMAGE2D_MAX_HEIGHT 0x1012 #define CL_DEVICE_IMAGE2D_MAX_HEIGHT 0x1012
#define CL_DEVICE_IMAGE2D_MAX_WIDTH 0x1011 #define CL_DEVICE_IMAGE2D_MAX_WIDTH 0x1011
#define CL_DEVICE_IMAGE3D_MAX_DEPTH 0x1015 #define CL_DEVICE_IMAGE3D_MAX_DEPTH 0x1015
...@@ -137,12 +146,21 @@ typedef struct _cl_buffer_region ...@@ -137,12 +146,21 @@ typedef struct _cl_buffer_region
#define CL_DEVICE_MEM_BASE_ADDR_ALIGN 0x1019 #define CL_DEVICE_MEM_BASE_ADDR_ALIGN 0x1019
#define CL_DEVICE_MIN_DATA_TYPE_ALIGN_SIZE 0x101A #define CL_DEVICE_MIN_DATA_TYPE_ALIGN_SIZE 0x101A
#define CL_DEVICE_NAME 0x102B #define CL_DEVICE_NAME 0x102B
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_CHAR 0x1036
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE 0x103B
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_FLOAT 0x103A
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_HALF 0x103C
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_INT 0x1038
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_LONG 0x1039
#define CL_DEVICE_NATIVE_VECTOR_WIDTH_SHORT 0x1037
#define CL_DEVICE_NOT_AVAILABLE -2 #define CL_DEVICE_NOT_AVAILABLE -2
#define CL_DEVICE_NOT_FOUND -1 #define CL_DEVICE_NOT_FOUND -1
#define CL_DEVICE_OPENCL_C_VERSION 0x103D
#define CL_DEVICE_PLATFORM 0x1031 #define CL_DEVICE_PLATFORM 0x1031
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_CHAR 0x1006 #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_CHAR 0x1006
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_DOUBLE 0x100B #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_DOUBLE 0x100B
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_FLOAT 0x100A #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_FLOAT 0x100A
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_HALF 0x1034
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT 0x1008 #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT 0x1008
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_LONG 0x1009 #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_LONG 0x1009
#define CL_DEVICE_PREFERRED_VECTOR_WIDTH_SHORT 0x1007 #define CL_DEVICE_PREFERRED_VECTOR_WIDTH_SHORT 0x1007
...@@ -163,9 +181,11 @@ typedef struct _cl_buffer_region ...@@ -163,9 +181,11 @@ typedef struct _cl_buffer_region
#define CL_EVENT_COMMAND_EXECUTION_STATUS 0x11D3 #define CL_EVENT_COMMAND_EXECUTION_STATUS 0x11D3
#define CL_EVENT_COMMAND_QUEUE 0x11D0 #define CL_EVENT_COMMAND_QUEUE 0x11D0
#define CL_EVENT_COMMAND_TYPE 0x11D1 #define CL_EVENT_COMMAND_TYPE 0x11D1
#define CL_EVENT_CONTEXT 0x11D4
#define CL_EVENT_REFERENCE_COUNT 0x11D2 #define CL_EVENT_REFERENCE_COUNT 0x11D2
#define CL_EXEC_KERNEL (1 << 0) #define CL_EXEC_KERNEL (1 << 0)
#define CL_EXEC_NATIVE_KERNEL (1 << 1) #define CL_EXEC_NATIVE_KERNEL (1 << 1)
#define CL_EXEC_STATUS_ERROR_FOR_EVENTS_IN_WAIT_LIST -14
#define CL_FALSE 0 #define CL_FALSE 0
#define CL_FILTER_LINEAR 0x1141 #define CL_FILTER_LINEAR 0x1141
#define CL_FILTER_NEAREST 0x1140 #define CL_FILTER_NEAREST 0x1140
...@@ -186,6 +206,7 @@ typedef struct _cl_buffer_region ...@@ -186,6 +206,7 @@ typedef struct _cl_buffer_region
#define CL_FP_ROUND_TO_INF (1 << 4) #define CL_FP_ROUND_TO_INF (1 << 4)
#define CL_FP_ROUND_TO_NEAREST (1 << 2) #define CL_FP_ROUND_TO_NEAREST (1 << 2)
#define CL_FP_ROUND_TO_ZERO (1 << 3) #define CL_FP_ROUND_TO_ZERO (1 << 3)
#define CL_FP_SOFT_FLOAT (1 << 6)
#define CL_GLOBAL 0x2 #define CL_GLOBAL 0x2
#define CL_HALF_FLOAT 0x10DD #define CL_HALF_FLOAT 0x10DD
#define CL_HUGE_VAL ((cl_double) 1e500) #define CL_HUGE_VAL ((cl_double) 1e500)
...@@ -231,6 +252,7 @@ typedef struct _cl_buffer_region ...@@ -231,6 +252,7 @@ typedef struct _cl_buffer_region
#define CL_INVALID_PLATFORM -32 #define CL_INVALID_PLATFORM -32
#define CL_INVALID_PROGRAM -44 #define CL_INVALID_PROGRAM -44
#define CL_INVALID_PROGRAM_EXECUTABLE -45 #define CL_INVALID_PROGRAM_EXECUTABLE -45
#define CL_INVALID_PROPERTY -64
#define CL_INVALID_QUEUE_PROPERTIES -35 #define CL_INVALID_QUEUE_PROPERTIES -35
#define CL_INVALID_SAMPLER -41 #define CL_INVALID_SAMPLER -41
#define CL_INVALID_VALUE -30 #define CL_INVALID_VALUE -30
...@@ -256,6 +278,7 @@ typedef struct _cl_buffer_region ...@@ -256,6 +278,7 @@ typedef struct _cl_buffer_region
#define CL_MAP_WRITE (1 << 1) #define CL_MAP_WRITE (1 << 1)
#define CL_MAXFLOAT CL_FLT_MAX #define CL_MAXFLOAT CL_FLT_MAX
#define CL_MEM_ALLOC_HOST_PTR (1 << 4) #define CL_MEM_ALLOC_HOST_PTR (1 << 4)
#define CL_MEM_ASSOCIATED_MEMOBJECT 0x1107
#define CL_MEM_CONTEXT 0x1106 #define CL_MEM_CONTEXT 0x1106
#define CL_MEM_COPY_HOST_PTR (1 << 5) #define CL_MEM_COPY_HOST_PTR (1 << 5)
#define CL_MEM_COPY_OVERLAP -8 #define CL_MEM_COPY_OVERLAP -8
...@@ -266,6 +289,7 @@ typedef struct _cl_buffer_region ...@@ -266,6 +289,7 @@ typedef struct _cl_buffer_region
#define CL_MEM_OBJECT_BUFFER 0x10F0 #define CL_MEM_OBJECT_BUFFER 0x10F0
#define CL_MEM_OBJECT_IMAGE2D 0x10F1 #define CL_MEM_OBJECT_IMAGE2D 0x10F1
#define CL_MEM_OBJECT_IMAGE3D 0x10F2 #define CL_MEM_OBJECT_IMAGE3D 0x10F2
#define CL_MEM_OFFSET 0x1108
#define CL_MEM_READ_ONLY (1 << 2) #define CL_MEM_READ_ONLY (1 << 2)
#define CL_MEM_READ_WRITE (1 << 0) #define CL_MEM_READ_WRITE (1 << 0)
#define CL_MEM_REFERENCE_COUNT 0x1105 #define CL_MEM_REFERENCE_COUNT 0x1105
...@@ -273,6 +297,7 @@ typedef struct _cl_buffer_region ...@@ -273,6 +297,7 @@ typedef struct _cl_buffer_region
#define CL_MEM_TYPE 0x1100 #define CL_MEM_TYPE 0x1100
#define CL_MEM_USE_HOST_PTR (1 << 3) #define CL_MEM_USE_HOST_PTR (1 << 3)
#define CL_MEM_WRITE_ONLY (1 << 1) #define CL_MEM_WRITE_ONLY (1 << 1)
#define CL_MISALIGNED_SUB_BUFFER_OFFSET -13
#define CL_NAN (CL_INFINITY - CL_INFINITY) #define CL_NAN (CL_INFINITY - CL_INFINITY)
#define CL_NONE 0x0 #define CL_NONE 0x0
#define CL_OUT_OF_HOST_MEMORY -6 #define CL_OUT_OF_HOST_MEMORY -6
...@@ -311,7 +336,10 @@ typedef struct _cl_buffer_region ...@@ -311,7 +336,10 @@ typedef struct _cl_buffer_region
#define CL_RG 0x10B2 #define CL_RG 0x10B2
#define CL_RGB 0x10B4 #define CL_RGB 0x10B4
#define CL_RGBA 0x10B5 #define CL_RGBA 0x10B5
#define CL_RGBx 0x10BC
#define CL_RGx 0x10BB
#define CL_RUNNING 0x1 #define CL_RUNNING 0x1
#define CL_Rx 0x10BA
#define CL_SAMPLER_ADDRESSING_MODE 0x1153 #define CL_SAMPLER_ADDRESSING_MODE 0x1153
#define CL_SAMPLER_CONTEXT 0x1151 #define CL_SAMPLER_CONTEXT 0x1151
#define CL_SAMPLER_FILTER_MODE 0x1154 #define CL_SAMPLER_FILTER_MODE 0x1154
......
...@@ -78,6 +78,18 @@ cl_sampler WINAPI clCreateSampler( cl_context context, cl_bool normalized_coords ...@@ -78,6 +78,18 @@ cl_sampler WINAPI clCreateSampler( cl_context context, cl_bool normalized_coords
return opencl_funcs->pclCreateSampler( context, normalized_coords, addressing_mode, filter_mode, errcode_ret ); return opencl_funcs->pclCreateSampler( context, normalized_coords, addressing_mode, filter_mode, errcode_ret );
} }
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 )
{
TRACE( "(%p, %s, %u, %p, %p)\n", buffer, wine_dbgstr_longlong(flags), buffer_create_type, buffer_create_info, errcode_ret );
return opencl_funcs->pclCreateSubBuffer( buffer, flags, buffer_create_type, buffer_create_info, errcode_ret );
}
cl_event WINAPI clCreateUserEvent( cl_context context, cl_int* errcode_ret )
{
TRACE( "(%p, %p)\n", context, errcode_ret );
return opencl_funcs->pclCreateUserEvent( context, errcode_ret );
}
cl_int WINAPI clEnqueueBarrier( cl_command_queue command_queue ) cl_int WINAPI clEnqueueBarrier( cl_command_queue command_queue )
{ {
TRACE( "(%p)\n", command_queue ); TRACE( "(%p)\n", command_queue );
...@@ -90,6 +102,12 @@ cl_int WINAPI clEnqueueCopyBuffer( cl_command_queue command_queue, cl_mem src_bu ...@@ -90,6 +102,12 @@ cl_int WINAPI clEnqueueCopyBuffer( cl_command_queue command_queue, cl_mem src_bu
return opencl_funcs->pclEnqueueCopyBuffer( command_queue, src_buffer, dst_buffer, src_offset, dst_offset, size, num_events_in_wait_list, event_wait_list, event ); return opencl_funcs->pclEnqueueCopyBuffer( command_queue, src_buffer, dst_buffer, src_offset, dst_offset, size, num_events_in_wait_list, event_wait_list, event );
} }
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 )
{
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 );
return opencl_funcs->pclEnqueueCopyBufferRect( 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 );
}
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 ) 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 )
{ {
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 ); 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 );
...@@ -144,6 +162,12 @@ cl_int WINAPI clEnqueueReadBuffer( cl_command_queue command_queue, cl_mem buffer ...@@ -144,6 +162,12 @@ cl_int WINAPI clEnqueueReadBuffer( cl_command_queue command_queue, cl_mem buffer
return opencl_funcs->pclEnqueueReadBuffer( command_queue, buffer, blocking_read, offset, size, ptr, num_events_in_wait_list, event_wait_list, event ); return opencl_funcs->pclEnqueueReadBuffer( command_queue, buffer, blocking_read, offset, size, ptr, num_events_in_wait_list, event_wait_list, event );
} }
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 )
{
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 );
return opencl_funcs->pclEnqueueReadBufferRect( 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 );
}
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 ) 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 )
{ {
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 ); 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 );
...@@ -174,6 +198,12 @@ cl_int WINAPI clEnqueueWriteBuffer( cl_command_queue command_queue, cl_mem buffe ...@@ -174,6 +198,12 @@ cl_int WINAPI clEnqueueWriteBuffer( cl_command_queue command_queue, cl_mem buffe
return opencl_funcs->pclEnqueueWriteBuffer( command_queue, buffer, blocking_write, offset, size, ptr, num_events_in_wait_list, event_wait_list, event ); return opencl_funcs->pclEnqueueWriteBuffer( command_queue, buffer, blocking_write, offset, size, ptr, num_events_in_wait_list, event_wait_list, event );
} }
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 )
{
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 );
return opencl_funcs->pclEnqueueWriteBufferRect( 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 );
}
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 ) 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 )
{ {
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 ); 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 );
...@@ -360,12 +390,30 @@ cl_int WINAPI clRetainSampler( cl_sampler sampler ) ...@@ -360,12 +390,30 @@ cl_int WINAPI clRetainSampler( cl_sampler sampler )
return opencl_funcs->pclRetainSampler( sampler ); return opencl_funcs->pclRetainSampler( sampler );
} }
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 )
{
TRACE( "(%p, %d, %p, %p)\n", event, command_exec_callback_type, pfn_notify, user_data );
return opencl_funcs->pclSetEventCallback( event, command_exec_callback_type, pfn_notify, user_data );
}
cl_int WINAPI clSetKernelArg( cl_kernel kernel, cl_uint arg_index, size_t arg_size, const void* arg_value ) cl_int WINAPI clSetKernelArg( cl_kernel kernel, cl_uint arg_index, size_t arg_size, const void* arg_value )
{ {
TRACE( "(%p, %u, %Iu, %p)\n", kernel, arg_index, arg_size, arg_value ); TRACE( "(%p, %u, %Iu, %p)\n", kernel, arg_index, arg_size, arg_value );
return opencl_funcs->pclSetKernelArg( kernel, arg_index, arg_size, arg_value ); return opencl_funcs->pclSetKernelArg( kernel, arg_index, arg_size, arg_value );
} }
cl_int WINAPI clSetMemObjectDestructorCallback( cl_mem memobj, void (WINAPI* pfn_notify)(cl_mem memobj, void* user_data), void* user_data )
{
TRACE( "(%p, %p, %p)\n", memobj, pfn_notify, user_data );
return opencl_funcs->pclSetMemObjectDestructorCallback( memobj, pfn_notify, user_data );
}
cl_int WINAPI clSetUserEventStatus( cl_event event, cl_int execution_status )
{
TRACE( "(%p, %d)\n", event, execution_status );
return opencl_funcs->pclSetUserEventStatus( event, execution_status );
}
cl_int WINAPI clUnloadCompiler( void ) cl_int WINAPI clUnloadCompiler( void )
{ {
TRACE( "()\n" ); TRACE( "()\n" );
......
...@@ -63,6 +63,14 @@ cl_int WINAPI wrap_clEnqueueNativeKernel( cl_command_queue command_queue, ...@@ -63,6 +63,14 @@ cl_int WINAPI wrap_clEnqueueNativeKernel( cl_command_queue command_queue,
void *args, size_t cb_args, cl_uint num_mem_objects, const cl_mem *mem_list, const void **args_mem_loc, 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 ) DECLSPEC_HIDDEN; cl_uint num_events_in_wait_list, const cl_event *event_wait_list, cl_event *event ) DECLSPEC_HIDDEN;
cl_int WINAPI wrap_clSetEventCallback( cl_event event, cl_int type,
void (WINAPI *pfn_notify)(cl_event, cl_int, void *),
void *user_data) DECLSPEC_HIDDEN;
cl_int WINAPI wrap_clSetMemObjectDestructorCallback(cl_mem memobj,
void (WINAPI *pfn_notify)(cl_mem, void *),
void *user_data) DECLSPEC_HIDDEN;
extern const struct opencl_funcs funcs; extern const struct opencl_funcs funcs;
#endif #endif
...@@ -52,6 +52,16 @@ static cl_sampler WINAPI wrap_clCreateSampler( cl_context context, cl_bool norma ...@@ -52,6 +52,16 @@ static cl_sampler WINAPI wrap_clCreateSampler( cl_context context, cl_bool norma
return clCreateSampler( context, normalized_coords, addressing_mode, filter_mode, errcode_ret ); return clCreateSampler( context, normalized_coords, addressing_mode, filter_mode, errcode_ret );
} }
static cl_mem WINAPI wrap_clCreateSubBuffer( cl_mem buffer, cl_mem_flags flags, cl_buffer_create_type buffer_create_type, const void* buffer_create_info, cl_int* errcode_ret )
{
return clCreateSubBuffer( buffer, flags, buffer_create_type, buffer_create_info, errcode_ret );
}
static cl_event WINAPI wrap_clCreateUserEvent( cl_context context, cl_int* errcode_ret )
{
return clCreateUserEvent( context, errcode_ret );
}
static cl_int WINAPI wrap_clEnqueueBarrier( cl_command_queue command_queue ) static cl_int WINAPI wrap_clEnqueueBarrier( cl_command_queue command_queue )
{ {
return clEnqueueBarrier( command_queue ); return clEnqueueBarrier( command_queue );
...@@ -62,6 +72,11 @@ static cl_int WINAPI wrap_clEnqueueCopyBuffer( cl_command_queue command_queue, c ...@@ -62,6 +72,11 @@ static cl_int WINAPI wrap_clEnqueueCopyBuffer( cl_command_queue command_queue, c
return clEnqueueCopyBuffer( command_queue, src_buffer, dst_buffer, src_offset, dst_offset, size, num_events_in_wait_list, event_wait_list, event ); return clEnqueueCopyBuffer( command_queue, src_buffer, dst_buffer, src_offset, dst_offset, size, num_events_in_wait_list, event_wait_list, event );
} }
static cl_int WINAPI wrap_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 )
{
return clEnqueueCopyBufferRect( 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 );
}
static cl_int WINAPI wrap_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 ) static cl_int WINAPI wrap_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 )
{ {
return clEnqueueCopyBufferToImage( command_queue, src_buffer, dst_image, src_offset, dst_origin, region, num_events_in_wait_list, event_wait_list, event ); return clEnqueueCopyBufferToImage( command_queue, src_buffer, dst_image, src_offset, dst_origin, region, num_events_in_wait_list, event_wait_list, event );
...@@ -102,6 +117,11 @@ static cl_int WINAPI wrap_clEnqueueReadBuffer( cl_command_queue command_queue, c ...@@ -102,6 +117,11 @@ static cl_int WINAPI wrap_clEnqueueReadBuffer( cl_command_queue command_queue, c
return clEnqueueReadBuffer( command_queue, buffer, blocking_read, offset, size, ptr, num_events_in_wait_list, event_wait_list, event ); return clEnqueueReadBuffer( command_queue, buffer, blocking_read, offset, size, ptr, num_events_in_wait_list, event_wait_list, event );
} }
static cl_int WINAPI wrap_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 )
{
return clEnqueueReadBufferRect( 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 );
}
static cl_int WINAPI wrap_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 ) static cl_int WINAPI wrap_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 )
{ {
return clEnqueueReadImage( command_queue, image, blocking_read, origin, region, row_pitch, slice_pitch, ptr, num_events_in_wait_list, event_wait_list, event ); return clEnqueueReadImage( command_queue, image, blocking_read, origin, region, row_pitch, slice_pitch, ptr, num_events_in_wait_list, event_wait_list, event );
...@@ -127,6 +147,11 @@ static cl_int WINAPI wrap_clEnqueueWriteBuffer( cl_command_queue command_queue, ...@@ -127,6 +147,11 @@ static cl_int WINAPI wrap_clEnqueueWriteBuffer( cl_command_queue command_queue,
return clEnqueueWriteBuffer( command_queue, buffer, blocking_write, offset, size, ptr, num_events_in_wait_list, event_wait_list, event ); return clEnqueueWriteBuffer( command_queue, buffer, blocking_write, offset, size, ptr, num_events_in_wait_list, event_wait_list, event );
} }
static cl_int WINAPI wrap_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 )
{
return clEnqueueWriteBufferRect( 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 );
}
static cl_int WINAPI wrap_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 ) static cl_int WINAPI wrap_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 )
{ {
return clEnqueueWriteImage( command_queue, image, blocking_write, origin, region, input_row_pitch, input_slice_pitch, ptr, num_events_in_wait_list, event_wait_list, event ); return clEnqueueWriteImage( command_queue, image, blocking_write, origin, region, input_row_pitch, input_slice_pitch, ptr, num_events_in_wait_list, event_wait_list, event );
...@@ -297,6 +322,11 @@ static cl_int WINAPI wrap_clSetKernelArg( cl_kernel kernel, cl_uint arg_index, s ...@@ -297,6 +322,11 @@ static cl_int WINAPI wrap_clSetKernelArg( cl_kernel kernel, cl_uint arg_index, s
return clSetKernelArg( kernel, arg_index, arg_size, arg_value ); return clSetKernelArg( kernel, arg_index, arg_size, arg_value );
} }
static cl_int WINAPI wrap_clSetUserEventStatus( cl_event event, cl_int execution_status )
{
return clSetUserEventStatus( event, execution_status );
}
static cl_int WINAPI wrap_clUnloadCompiler( void ) static cl_int WINAPI wrap_clUnloadCompiler( void )
{ {
return clUnloadCompiler(); return clUnloadCompiler();
...@@ -321,8 +351,11 @@ const struct opencl_funcs funcs = ...@@ -321,8 +351,11 @@ const struct opencl_funcs funcs =
wrap_clCreateProgramWithBinary, wrap_clCreateProgramWithBinary,
wrap_clCreateProgramWithSource, wrap_clCreateProgramWithSource,
wrap_clCreateSampler, wrap_clCreateSampler,
wrap_clCreateSubBuffer,
wrap_clCreateUserEvent,
wrap_clEnqueueBarrier, wrap_clEnqueueBarrier,
wrap_clEnqueueCopyBuffer, wrap_clEnqueueCopyBuffer,
wrap_clEnqueueCopyBufferRect,
wrap_clEnqueueCopyBufferToImage, wrap_clEnqueueCopyBufferToImage,
wrap_clEnqueueCopyImage, wrap_clEnqueueCopyImage,
wrap_clEnqueueCopyImageToBuffer, wrap_clEnqueueCopyImageToBuffer,
...@@ -332,11 +365,13 @@ const struct opencl_funcs funcs = ...@@ -332,11 +365,13 @@ const struct opencl_funcs funcs =
wrap_clEnqueueNDRangeKernel, wrap_clEnqueueNDRangeKernel,
wrap_clEnqueueNativeKernel, wrap_clEnqueueNativeKernel,
wrap_clEnqueueReadBuffer, wrap_clEnqueueReadBuffer,
wrap_clEnqueueReadBufferRect,
wrap_clEnqueueReadImage, wrap_clEnqueueReadImage,
wrap_clEnqueueTask, wrap_clEnqueueTask,
wrap_clEnqueueUnmapMemObject, wrap_clEnqueueUnmapMemObject,
wrap_clEnqueueWaitForEvents, wrap_clEnqueueWaitForEvents,
wrap_clEnqueueWriteBuffer, wrap_clEnqueueWriteBuffer,
wrap_clEnqueueWriteBufferRect,
wrap_clEnqueueWriteImage, wrap_clEnqueueWriteImage,
wrap_clFinish, wrap_clFinish,
wrap_clFlush, wrap_clFlush,
...@@ -370,7 +405,10 @@ const struct opencl_funcs funcs = ...@@ -370,7 +405,10 @@ const struct opencl_funcs funcs =
wrap_clRetainMemObject, wrap_clRetainMemObject,
wrap_clRetainProgram, wrap_clRetainProgram,
wrap_clRetainSampler, wrap_clRetainSampler,
wrap_clSetEventCallback,
wrap_clSetKernelArg, wrap_clSetKernelArg,
wrap_clSetMemObjectDestructorCallback,
wrap_clSetUserEventStatus,
wrap_clUnloadCompiler, wrap_clUnloadCompiler,
wrap_clWaitForEvents, wrap_clWaitForEvents,
}; };
...@@ -138,6 +138,22 @@ cl_int WINAPI wrap_clEnqueueNativeKernel( cl_command_queue command_queue, ...@@ -138,6 +138,22 @@ cl_int WINAPI wrap_clEnqueueNativeKernel( cl_command_queue command_queue,
return CL_INVALID_OPERATION; return CL_INVALID_OPERATION;
} }
cl_int WINAPI wrap_clSetEventCallback( cl_event event, cl_int type,
void (WINAPI *pfn_notify)(cl_event, cl_int, void *),
void *user_data)
{
FIXME( "not yet implemented\n" );
return CL_INVALID_OPERATION;
}
cl_int WINAPI wrap_clSetMemObjectDestructorCallback(cl_mem memobj,
void (WINAPI *pfn_notify)(cl_mem, void *),
void *user_data)
{
FIXME( "not yet implemented\n" );
return CL_INVALID_OPERATION;
}
NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *ptr_in, void *ptr_out ) NTSTATUS CDECL __wine_init_unix_lib( HMODULE module, DWORD reason, const void *ptr_in, void *ptr_out )
{ {
if (reason != DLL_PROCESS_ATTACH) return STATUS_SUCCESS; if (reason != DLL_PROCESS_ATTACH) return STATUS_SUCCESS;
......
...@@ -14,8 +14,11 @@ struct opencl_funcs ...@@ -14,8 +14,11 @@ struct opencl_funcs
cl_program (WINAPI *pclCreateProgramWithBinary)( 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 ); cl_program (WINAPI *pclCreateProgramWithBinary)( 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 );
cl_program (WINAPI *pclCreateProgramWithSource)( cl_context context, cl_uint count, const char** strings, const size_t* lengths, cl_int* errcode_ret ); cl_program (WINAPI *pclCreateProgramWithSource)( cl_context context, cl_uint count, const char** strings, const size_t* lengths, cl_int* errcode_ret );
cl_sampler (WINAPI *pclCreateSampler)( cl_context context, cl_bool normalized_coords, cl_addressing_mode addressing_mode, cl_filter_mode filter_mode, cl_int* errcode_ret ); cl_sampler (WINAPI *pclCreateSampler)( cl_context context, cl_bool normalized_coords, cl_addressing_mode addressing_mode, cl_filter_mode filter_mode, cl_int* errcode_ret );
cl_mem (WINAPI *pclCreateSubBuffer)( cl_mem buffer, cl_mem_flags flags, cl_buffer_create_type buffer_create_type, const void* buffer_create_info, cl_int* errcode_ret );
cl_event (WINAPI *pclCreateUserEvent)( cl_context context, cl_int* errcode_ret );
cl_int (WINAPI *pclEnqueueBarrier)( cl_command_queue command_queue ); cl_int (WINAPI *pclEnqueueBarrier)( cl_command_queue command_queue );
cl_int (WINAPI *pclEnqueueCopyBuffer)( 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 ); cl_int (WINAPI *pclEnqueueCopyBuffer)( 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 );
cl_int (WINAPI *pclEnqueueCopyBufferRect)( 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 );
cl_int (WINAPI *pclEnqueueCopyBufferToImage)( 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 ); cl_int (WINAPI *pclEnqueueCopyBufferToImage)( 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 );
cl_int (WINAPI *pclEnqueueCopyImage)( 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 ); cl_int (WINAPI *pclEnqueueCopyImage)( 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 );
cl_int (WINAPI *pclEnqueueCopyImageToBuffer)( 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 ); cl_int (WINAPI *pclEnqueueCopyImageToBuffer)( 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 );
...@@ -25,11 +28,13 @@ struct opencl_funcs ...@@ -25,11 +28,13 @@ struct opencl_funcs
cl_int (WINAPI *pclEnqueueNDRangeKernel)( 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 ); cl_int (WINAPI *pclEnqueueNDRangeKernel)( 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 );
cl_int (WINAPI *pclEnqueueNativeKernel)( 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 ); cl_int (WINAPI *pclEnqueueNativeKernel)( 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 );
cl_int (WINAPI *pclEnqueueReadBuffer)( 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 ); cl_int (WINAPI *pclEnqueueReadBuffer)( 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 );
cl_int (WINAPI *pclEnqueueReadBufferRect)( 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 );
cl_int (WINAPI *pclEnqueueReadImage)( 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 ); cl_int (WINAPI *pclEnqueueReadImage)( 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 );
cl_int (WINAPI *pclEnqueueTask)( cl_command_queue command_queue, cl_kernel kernel, cl_uint num_events_in_wait_list, const cl_event* event_wait_list, cl_event* event ); cl_int (WINAPI *pclEnqueueTask)( cl_command_queue command_queue, cl_kernel kernel, cl_uint num_events_in_wait_list, const cl_event* event_wait_list, cl_event* event );
cl_int (WINAPI *pclEnqueueUnmapMemObject)( 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 ); cl_int (WINAPI *pclEnqueueUnmapMemObject)( 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 );
cl_int (WINAPI *pclEnqueueWaitForEvents)( cl_command_queue command_queue, cl_uint num_events, const cl_event* event_list ); cl_int (WINAPI *pclEnqueueWaitForEvents)( cl_command_queue command_queue, cl_uint num_events, const cl_event* event_list );
cl_int (WINAPI *pclEnqueueWriteBuffer)( 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 ); cl_int (WINAPI *pclEnqueueWriteBuffer)( 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 );
cl_int (WINAPI *pclEnqueueWriteBufferRect)( 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 );
cl_int (WINAPI *pclEnqueueWriteImage)( 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 ); cl_int (WINAPI *pclEnqueueWriteImage)( 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 );
cl_int (WINAPI *pclFinish)( cl_command_queue command_queue ); cl_int (WINAPI *pclFinish)( cl_command_queue command_queue );
cl_int (WINAPI *pclFlush)( cl_command_queue command_queue ); cl_int (WINAPI *pclFlush)( cl_command_queue command_queue );
...@@ -63,7 +68,10 @@ struct opencl_funcs ...@@ -63,7 +68,10 @@ struct opencl_funcs
cl_int (WINAPI *pclRetainMemObject)( cl_mem memobj ); cl_int (WINAPI *pclRetainMemObject)( cl_mem memobj );
cl_int (WINAPI *pclRetainProgram)( cl_program program ); cl_int (WINAPI *pclRetainProgram)( cl_program program );
cl_int (WINAPI *pclRetainSampler)( cl_sampler sampler ); cl_int (WINAPI *pclRetainSampler)( cl_sampler sampler );
cl_int (WINAPI *pclSetEventCallback)( 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 );
cl_int (WINAPI *pclSetKernelArg)( cl_kernel kernel, cl_uint arg_index, size_t arg_size, const void* arg_value ); cl_int (WINAPI *pclSetKernelArg)( cl_kernel kernel, cl_uint arg_index, size_t arg_size, const void* arg_value );
cl_int (WINAPI *pclSetMemObjectDestructorCallback)( cl_mem memobj, void (WINAPI* pfn_notify)(cl_mem memobj, void* user_data), void* user_data );
cl_int (WINAPI *pclSetUserEventStatus)( cl_event event, cl_int execution_status );
cl_int (WINAPI *pclUnloadCompiler)( void ); cl_int (WINAPI *pclUnloadCompiler)( void );
cl_int (WINAPI *pclWaitForEvents)( cl_uint num_events, const cl_event* event_list ); cl_int (WINAPI *pclWaitForEvents)( cl_uint num_events, const cl_event* event_list );
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment