Beispiel #1
0
func (k *Kernel) release() error {
	if k.id != nil {
		if err := C.clReleaseKernel(k.id); err != C.CL_SUCCESS {
			return Cl_error(err)
		}
		k.id = nil
	}
	return nil
}
Beispiel #2
0
func CLReleaseKernel(kernel CL_kernel) CL_int {
	return CL_int(C.clReleaseKernel(kernel.cl_kernel))
}
Beispiel #3
0
// see https://www.khronos.org/registry/cl/sdk/1.1/docs/man/xhtml/clReleaseKernel.html
func ReleaseKernel(ker Kernel) ErrorCode {
	return ErrorCode(C.clReleaseKernel(ker))
}
Beispiel #4
0
func releaseKernel(k *Kernel) {
	if k.clKernel != nil {
		C.clReleaseKernel(k.clKernel)
		k.clKernel = nil
	}
}