Returns an uninitialized buffer of Element
on device.
Returns an uninitialized buffer of Element
on device.
Returns a buffer of Element
on device whose content is copied from hostBuffer
.
Returns a buffer of Element
on device whose content is copied from hostBuffer
.
Creates single kernel from this Program.
HandleEventInExecutionContext should be unnecessary because only OpenCL calls to create contexts or command-queues, or blocking OpenCL operations are undefined behavior, according to https://www.khronos.org/registry/OpenCL/sdk/1.2/docs/man/xhtml/clSetEventCallback.html and we don't use those forbidden functions. Our usage should be fine according to the OpenCL specification. However, AMD SDK always crashes for any reentry calls (e.g. https://travis-ci.org/Atry/DeepLearning.scala/jobs/318466522), no matter if they are blocking or not. There is also similar bug in Intel's OpenCL implementation As a workaround, always enable this HandleEventInExecutionContext for Intel's and AMD's OpenCL implementation.