Copy Memory objects

Hi,

Does openCL have any methods in which data can be copied from one memory object to
another memory object?

Regards

Does openCL have any methods in which data can be copied from one memory object to
another memory object?

Yes. Look for clEnqueueCopyBuffer(), clEnqueueCopyImage(), clEnqueueCopyBufferToImage() and clEnqueueCopyImageToBuffer().

I too had been wondering lately whether there were any methods in Open CL by which we could copy data to a memory object from another one. I am glad to learn we can. I guess we need to look for these codes so as to apply the transference.

The problem is, that clEnqueueCopyBuffer() was only specified in the OpenCL 1.1 specification and is not listed in the online reference manual (http://www.khronos.org/registry/cl/sdk/ … man/xhtml/) until 1.2. On the other hand this function is explicitly specified on the OpenCL 1.0 reference card…

clEnqueueCopyBuffer appears in the OpenCL 1.0 specification in section 5.5.2.

It also appears in the OpenCL 1.0 man pages as well as the OpenCL 1.1. man pages.

But, then how can I actually go to these pages when the only things in the side bar are the following?

OpenCL 1.0:

Memory Objects
clCreateBuffer
clEnqueueReadBuffer
clEnqueueWriteBuffer
clRetainMemObject
clReleaseMemObject
clCreateImage2D
clCreateImage3D
clGetSupportedImageFormats
clEnqueueReadImage
clEnqueueWriteImage
clEnqueueCopyImage
clEnqueueCopyImageToBuffer
clEnqueueCopyBufferToImage
clEnqueueMapBuffer
clEnqueueMapImage
clEnqueueUnmapMemObject
clGetMemObjectInfo
clGetImageInfo
cl_image_format

OpenCL 1.1:

Memory Objects
clCreateBuffer
clCreateSubBuffer
clEnqueueReadBuffer
clEnqueueWriteBuffer
clEnqueueReadBufferRect
clEnqueueWriteBufferRect
clRetainMemObject
clReleaseMemObject
clSetMemObjectDestructorCallback
clCreateImage2D
clCreateImage3D
clGetSupportedImageFormats
clEnqueueReadImage
clEnqueueWriteImage
clEnqueueCopyImage
clEnqueueCopyImageToBuffer
clEnqueueCopyBufferToImage
clEnqueueCopyBufferRect
clEnqueueMapBuffer
clEnqueueMapImage
clEnqueueUnmapMemObject
clGetMemObjectInfo
clGetImageInfo
cl_image_format

Thanks, Matthias. This was apparently a known bug. See http://www.khronos.org/bugzilla/show_bug.cgi?id=527

I will try to get some attention into it.

Thanks David, I didn’t really know there was a bug tracker for such things.

Regards,
Matthias