Package net.haesleinhuepf.clij.clearcl
Class ClearCLCompiledProgram
- java.lang.Object
-
- net.haesleinhuepf.clij.clearcl.abs.ClearCLBase
-
- net.haesleinhuepf.clij.clearcl.ClearCLCompiledProgram
-
- All Implemented Interfaces:
AutoCloseable,net.haesleinhuepf.clij.coremem.rgc.Cleanable
public class ClearCLCompiledProgram extends ClearCLBase implements net.haesleinhuepf.clij.coremem.rgc.Cleanable
ClearCLCompiledProgram is an internal abstraction for compiled programs.Note: This object did not exist in the early versions of ClearCL. This was introduced to fix the RGC bug that caused ressource leakage. This object better matches the lifecycle of the compiled OpenCL program and thus is better suited for properly supporting ressource cleanup at GC time.
- Author:
- royer
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()ClearCLKernelcreateKernel(String pKernelName)Creates kernel of given name from this program.StringgetBuildLog()Returns last build logs for this program.BuildStatusgetBuildStatus()Returns last build status for this program.net.haesleinhuepf.clij.coremem.rgc.CleanergetCleaner()ClearCLContextgetContext()Returns the context for this program.ClearCLDevicegetDevice()Returns the device for this program.ClearCLKernelgetKernel(String pKernelName)Returns the kernel of a given name.StringtoString()-
Methods inherited from class net.haesleinhuepf.clij.clearcl.abs.ClearCLBase
getBackend, getPeerPointer, setPeerPointer
-
-
-
-
Method Detail
-
getDevice
public ClearCLDevice getDevice()
Returns the device for this program.- Returns:
- device
-
getContext
public ClearCLContext getContext()
Returns the context for this program.- Returns:
- context
-
getBuildStatus
public BuildStatus getBuildStatus()
Returns last build status for this program.- Returns:
- last build status
-
getBuildLog
public String getBuildLog()
Returns last build logs for this program.- Returns:
- build logs
-
getKernel
public ClearCLKernel getKernel(String pKernelName)
Returns the kernel of a given name. If the kernel is not yet created, it is then created on-demand. Note: this will not recreate a kernel that already exists.- Parameters:
pKernelName- kernel name- Returns:
- kernel
-
createKernel
public ClearCLKernel createKernel(String pKernelName)
Creates kernel of given name from this program.- Parameters:
pKernelName- kernel name (function name)- Returns:
- kernel
-
toString
public String toString()
- Overrides:
toStringin classClearCLBase
-
close
public void close()
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein classClearCLBase
-
getCleaner
public net.haesleinhuepf.clij.coremem.rgc.Cleaner getCleaner()
- Specified by:
getCleanerin interfacenet.haesleinhuepf.clij.coremem.rgc.Cleanable
-
-