• 2019 Update 4
  • 03/20/2019
  • Public Content
Contents

Minimizing Data Copying

The application should process data “in-place” and minimize copying memory objects. For example, OpenCL™ 1.2 and lower requires the global work dimensions be exact multiples of the local work-group dimensions. For a typical image processing task, require the work-groups to be tiles that exactly cover a frame buffer. If the global size differs from the original image, you might decide to copy and pad the original image buffer, so the kernel does not need to check every work-item to see if it falls outside the image. But this can add several milliseconds of processing time just to create and copy images. Refer to the section "Avoid Handling Edge Conditions in Kernels" for alternatives, including most elegant solution with OpenCL 2.0.
See Also

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.