summaryrefslogtreecommitdiff
path: root/src/gallium/state_trackers/clover/api/icd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/state_trackers/clover/api/icd.cpp')
-rw-r--r--src/gallium/state_trackers/clover/api/icd.cpp145
1 files changed, 145 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/clover/api/icd.cpp b/src/gallium/state_trackers/clover/api/icd.cpp
new file mode 100644
index 00000000000..898df224a47
--- /dev/null
+++ b/src/gallium/state_trackers/clover/api/icd.cpp
@@ -0,0 +1,145 @@
+//
+// Copyright 2013 Advanced Micro Devices Inc.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the "Software"),
+// to deal in the Software without restriction, including without limitation
+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
+// and/or sell copies of the Software, and to permit persons to whom the
+// Software is furnished to do so, subject to the following conditions:
+//
+// The above copyright notice and this permission notice shall be included in
+// all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+// OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+// OTHER DEALINGS IN THE SOFTWARE.
+//
+//
+// Author: Tom Stellard <thomas.stellard@amd.com>
+//
+
+#include "api/icd.hpp"
+
+
+const cl_icd_dispatch clover_icd_dispatch =
+#ifndef USE_ICD
+ 0
+#else
+{
+ &CLOVER_API(clGetPlatformIDs),
+ &CLOVER_API(clGetPlatformInfo),
+ &CLOVER_API(clGetDeviceIDs),
+ &CLOVER_API(clGetDeviceInfo),
+ &CLOVER_API(clCreateContext),
+ &CLOVER_API(clCreateContextFromType),
+ &CLOVER_API(clRetainContext),
+ &CLOVER_API(clReleaseContext),
+ &CLOVER_API(clGetContextInfo),
+ &CLOVER_API(clCreateCommandQueue),
+ &CLOVER_API(clRetainCommandQueue),
+ &CLOVER_API(clReleaseCommandQueue),
+ &CLOVER_API(clGetCommandQueueInfo),
+ NULL, // &CLOVER_API(clSetCommandQueueProperty),
+ &CLOVER_API(clCreateBuffer),
+ NULL, // &CLOVER_API(clCreateImage2D),
+ NULL, // &CLOVER_API(clCreateImage3D),
+ &CLOVER_API(clRetainMemObject),
+ &CLOVER_API(clReleaseMemObject),
+ &CLOVER_API(clGetSupportedImageFormats),
+ &CLOVER_API(clGetMemObjectInfo),
+ &CLOVER_API(clGetImageInfo),
+ &CLOVER_API(clCreateSampler),
+ &CLOVER_API(clRetainSampler),
+ &CLOVER_API(clReleaseSampler),
+ &CLOVER_API(clGetSamplerInfo),
+ &CLOVER_API(clCreateProgramWithSource),
+ &CLOVER_API(clCreateProgramWithBinary),
+ &CLOVER_API(clRetainProgram),
+ &CLOVER_API(clReleaseProgram),
+ &CLOVER_API(clBuildProgram),
+ NULL, // &CLOVER_API(clUnloadCompiler),
+ &CLOVER_API(clGetProgramInfo),
+ &CLOVER_API(clGetProgramBuildInfo),
+ &CLOVER_API(clCreateKernel),
+ &CLOVER_API(clCreateKernelsInProgram),
+ &CLOVER_API(clRetainKernel),
+ &CLOVER_API(clReleaseKernel),
+ &CLOVER_API(clSetKernelArg),
+ &CLOVER_API(clGetKernelInfo),
+ &CLOVER_API(clGetKernelWorkGroupInfo),
+ &CLOVER_API(clWaitForEvents),
+ &CLOVER_API(clGetEventInfo),
+ &CLOVER_API(clRetainEvent),
+ &CLOVER_API(clReleaseEvent),
+ &CLOVER_API(clGetEventProfilingInfo),
+ &CLOVER_API(clFlush),
+ &CLOVER_API(clFinish),
+ &CLOVER_API(clEnqueueReadBuffer),
+ &CLOVER_API(clEnqueueWriteBuffer),
+ &CLOVER_API(clEnqueueCopyBuffer),
+ &CLOVER_API(clEnqueueReadImage),
+ &CLOVER_API(clEnqueueWriteImage),
+ &CLOVER_API(clEnqueueCopyImage),
+ &CLOVER_API(clEnqueueCopyImageToBuffer),
+ &CLOVER_API(clEnqueueCopyBufferToImage),
+ &CLOVER_API(clEnqueueMapBuffer),
+ &CLOVER_API(clEnqueueMapImage),
+ &CLOVER_API(clEnqueueUnmapMemObject),
+ &CLOVER_API(clEnqueueNDRangeKernel),
+ &CLOVER_API(clEnqueueTask),
+ &CLOVER_API(clEnqueueNativeKernel),
+ NULL, // &CLOVER_API(clEnqueueMarker),
+ NULL, // &CLOVER_API(clEnqueueWaitForEvents),
+ NULL, // &CLOVER_API(clEnqueueBarrier),
+ clGetExtensionFunctionAddress,
+ NULL, // &CLOVER_API(clCreateFromGLBuffer),
+ NULL, // &CLOVER_API(clCreateFromGLTexture2D),
+ NULL, // &CLOVER_API(clCreateFromGLTexture3D),
+ NULL, // &CLOVER_API(clCreateFromGLRenderbuffer),
+ NULL, // &CLOVER_API(clGetGLObjectInfo),
+ NULL, // &CLOVER_API(clGetGLTextureInfo),
+ NULL, // &CLOVER_API(clEnqueueAcquireGLObjects),
+ NULL, // &CLOVER_API(clEnqueueReleaseGLObjects),
+ NULL, // &CLOVER_API(clGetGLContextInfoKHR),
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ NULL,
+ &CLOVER_API(clSetEventCallback),
+ &CLOVER_API(clCreateSubBuffer),
+ &CLOVER_API(clSetMemObjectDestructorCallback),
+ &CLOVER_API(clCreateUserEvent),
+ &CLOVER_API(clSetUserEventStatus),
+ &CLOVER_API(clEnqueueReadBufferRect),
+ &CLOVER_API(clEnqueueWriteBufferRect),
+ &CLOVER_API(clEnqueueCopyBufferRect),
+ NULL, // &CLOVER_API(clCreateSubDevicesEXT),
+ NULL, // &CLOVER_API(clRetainDeviceEXT),
+ NULL, // &CLOVER_API(clReleaseDeviceEXT),
+ NULL,
+ NULL, // &CLOVER_API(clCreateSubDevices),
+ NULL, // &CLOVER_API(clRetainDevice),
+ NULL, // &CLOVER_API(clReleaseDevice),
+ NULL, // &CLOVER_API(clCreateImage),
+ NULL, // &CLOVER_API(clCreateProgramWithBuiltInKernels),
+ NULL, // &CLOVER_API(clCompileProgram),
+ NULL, // &CLOVER_API(clLinkProgram),
+ NULL, // &CLOVER_API(clUnloadPlatformCompiler),
+ NULL, // &CLOVER_API(clGetKernelArgInfo),
+ NULL, // &CLOVER_API(clEnqueueFillBuffer),
+ NULL, // &CLOVER_API(clEnqueueFillImage),
+ NULL, // &CLOVER_API(clEnqueueMigrateMemObjects),
+ NULL, // &CLOVER_API(clEnqueueMarkerWithWaitList),
+ NULL, // &CLOVER_API(clEnqueueBarrierWithWaitList),
+ NULL, // &CLOVER_API(clGetExtensionFunctionAddressForPlatform),
+ NULL, // &CLOVER_API(clCreateFromGLTexture),
+}
+#endif // USE_ICD
+;