Class OpenCLContext
- java.lang.Object
-
- de.mirkosertic.bytecoder.core.backend.opencl.OpenCLContext
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static class
OpenCLContext.CachedKernel
private static class
OpenCLContext.DataRef
-
Field Summary
Fields Modifier and Type Field Description private static java.util.Map<java.lang.Class,OpenCLCompileResult>
ALREADY_COMPILED
private OpenCLCompileBackend
backend
private java.util.Map<java.lang.Class,OpenCLContext.CachedKernel>
cachedKernels
private org.jocl.cl_command_queue
commandQueue
private CompileOptions
compileOptions
private org.jocl.cl_context
context
private Logger
logger
private OpenCLPlatform
platform
-
Constructor Summary
Constructors Constructor Description OpenCLContext(OpenCLPlatform platform, Logger logger)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
compute(int numberOfStreams, Kernel kernel)
private OpenCLContext.CachedKernel
kernelFor(Kernel kernel, AnalysisStack analysisStack)
private static OpenCLContext.DataRef
toDataRef(java.lang.Object[] array, java.lang.Class dataType)
-
-
-
Field Detail
-
ALREADY_COMPILED
private static final java.util.Map<java.lang.Class,OpenCLCompileResult> ALREADY_COMPILED
-
backend
private final OpenCLCompileBackend backend
-
compileOptions
private final CompileOptions compileOptions
-
context
private final org.jocl.cl_context context
-
commandQueue
private final org.jocl.cl_command_queue commandQueue
-
cachedKernels
private final java.util.Map<java.lang.Class,OpenCLContext.CachedKernel> cachedKernels
-
logger
private final Logger logger
-
platform
private final OpenCLPlatform platform
-
-
Constructor Detail
-
OpenCLContext
OpenCLContext(OpenCLPlatform platform, Logger logger)
-
-
Method Detail
-
kernelFor
private OpenCLContext.CachedKernel kernelFor(Kernel kernel, AnalysisStack analysisStack) throws java.io.IOException
- Throws:
java.io.IOException
-
compute
public void compute(int numberOfStreams, Kernel kernel) throws java.io.IOException
-
toDataRef
private static OpenCLContext.DataRef toDataRef(java.lang.Object[] array, java.lang.Class dataType)
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
-
-