summaryrefslogtreecommitdiffstats
path: root/make/config/cl-impl-11.cfg
diff options
context:
space:
mode:
authorWade Walker <[email protected]>2015-09-12 14:28:16 -0500
committerWade Walker <[email protected]>2015-11-08 14:05:29 -0600
commit9a90181ed1fb596275fee9ebca0f3d1093722ca9 (patch)
treed9fbcc4fbb6c54bae64e5c0160f3a28a2ca0e934 /make/config/cl-impl-11.cfg
parente56a17d6d7780b8597c78ce50808c8da68d094b5 (diff)
Add explicit version number to original CL impl classes.
This makes all three versions (1.1, 1.2, and 2.0) use the same naming convention, and sets me up to use the unversioned name to factor out code common to all three.
Diffstat (limited to 'make/config/cl-impl-11.cfg')
-rw-r--r--make/config/cl-impl-11.cfg99
1 files changed, 99 insertions, 0 deletions
diff --git a/make/config/cl-impl-11.cfg b/make/config/cl-impl-11.cfg
new file mode 100644
index 00000000..9a49ea64
--- /dev/null
+++ b/make/config/cl-impl-11.cfg
@@ -0,0 +1,99 @@
+Include cl-common.cfg
+NativeOutputDir gensrc/native/jocl11
+
+Style ImplOnly
+
+#imports for all generated java files
+Import com.jogamp.opencl.llb.gl.CLGL
+Import java.security.AccessController
+Import java.security.PrivilegedAction
+
+ClassJavadoc CLAbstractImpl11 /**
+ClassJavadoc CLAbstractImpl11 * Java bindings to OpenCL, the Open Computing Language (generated).
+ClassJavadoc CLAbstractImpl11 * @author Michael Bien, GlueGen, et al.
+ClassJavadoc CLAbstractImpl11 */
+
+ImplJavaClass CLAbstractImpl11
+AccessControl CLAbstractImpl11 PUBLIC_ABSTRACT
+Implements CLAbstractImpl11 CLGL
+
+LocalProcAddressCallingConvention __ALL__ CL_API_CALL
+
+EmitProcAddressTable true
+ProcAddressTableClassName CLProcAddressTable11
+GetProcAddressTableExpr addressTable
+ProcAddressNameExpr $UpperCase(arg)
+ForceProcAddressGen __ALL__
+
+#dynamic binding for OpenGL specific functions...
+#ForceProcAddressGen clGetGLContextInfoKHR
+#ForceProcAddressGen clCreateFromGLBuffer
+#ForceProcAddressGen clCreateFromGLRenderbuffer
+#ForceProcAddressGen clCreateFromGLTexture2D
+#ForceProcAddressGen clCreateFromGLTexture3D
+#ForceProcAddressGen clEnqueueAcquireGLObjects
+#ForceProcAddressGen clEnqueueReleaseGLObjects
+#ForceProcAddressGen clGetGLObjectInfo
+#ForceProcAddressGen clGetGLTextureInfo
+#ForceProcAddressGen clCreateEventFromGLsyncKHR
+#ForceProcAddressGen clIcdGetPlatformIDsKHR
+#ForceProcAddressGen clCreateSubBuffer
+#ForceProcAddressGen clCreateSubDevicesEXT
+#ForceProcAddressGen clCreateUserEvent
+#ForceProcAddressGen clEnqueueCopyBufferRect
+#ForceProcAddressGen clEnqueueReadBufferRect
+#ForceProcAddressGen clEnqueueWriteBufferRect
+#ForceProcAddressGen clReleaseDeviceEXT
+#ForceProcAddressGen clRetainDeviceEXT
+#ForceProcAddressGen clSetUserEventStatus
+
+#...or force all
+ForceProcAddressGen __ALL__
+
+#
+# extern CL_API_ENTRY void * CL_API_CALL clGetExtensionFunctionAddress(const char * /* func_name */) CL_API_SUFFIX__VERSION_1_0;
+#
+Ignore clGetExtensionFunctionAddress
+ForceProcAddressGen clGetExtensionFunctionAddress
+
+#append to generated c files
+CustomCCode #include <inttypes.h>
+CustomCCode #include <GL/glcorearb.h>
+CustomCCode #include <CL/cl.h>
+CustomCCode #include <CL/cl_ext.h>
+CustomCCode #include <CL/cl_gl.h>
+
+# implement manually via custom code
+Ignore clCreateContext
+ForceProcAddressGen clCreateContext
+
+Ignore clCreateContextFromType
+ForceProcAddressGen clCreateContextFromType
+
+Ignore clBuildProgram
+ForceProcAddressGen clBuildProgram
+
+Ignore clEnqueueNativeKernel
+ForceProcAddressGen clEnqueueNativeKernel
+
+Ignore clReleaseContext
+ForceProcAddressGen clReleaseContext
+
+Ignore clSetEventCallback
+ForceProcAddressGen clSetEventCallback
+
+Ignore clSetMemObjectDestructorCallback
+ForceProcAddressGen clSetMemObjectDestructorCallback
+
+#take buffer capacity from input param 5
+ReturnValueCapacity clEnqueueMapBuffer {5}
+
+#this one is more complicated, we have to calculate the capacity with custom code
+ManuallyImplement clEnqueueMapImage
+ForceProcAddressGen clEnqueueMapImage
+
+#include custom code
+IncludeAs CustomJavaCode CLAbstractImpl11 clImplCustomCode11.java
+ManualStaticInitCall CLAbstractImpl11
+IncludeAs CustomCCode clImplCustomCode11.c
+