Class SingletonGpuManagerCL

java.lang.Object
cz.fidentis.analyst.opencl.impl.SingletonGpuManagerCL

public final class SingletonGpuManagerCL extends Object
A singleton object managing with OpenCL contexts and their CL programs. Stores binaries to allow for faster compilation of already compiled programs for new contexts
  • Method Details

    • getOrCompile

      public CLProgram getOrCompile(com.jogamp.opencl.CLContext clContext, CLProgramDef program)
      Compiles the CL program, re-uses already compiled programs or re-compiles program binaries for desired context.
      Parameters:
      clContext - OpenCL context. Must not be null.
      program - CL program
      Returns:
      The reference object to the compiled CL program
    • release

      public void release(com.jogamp.opencl.CLContext clContext)
      Should be called before the OpenCL context is erased.
      Parameters:
      clContext - OpenCL context. Must not be null.
    • getInstance

      public static SingletonGpuManagerCL getInstance()
      Returns the single instance
      Returns:
      the single instance