Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Part 1: Foundations of OpenCL programming > General coding principles

10. General coding principles

This chapter covers

  • Determining values for global size and local size

  • Implementing the reduction algorithm in OpenCL

  • Synchronizing work-items in different work-groups


In the preceding chapters, the example host applications have executed kernels using a single work-item. This is fine when you’re learning OpenCL or testing a new application, but for production code, this is unacceptable. OpenCL’s great strength is that you can execute kernels using millions or even billions of work-items, and if you’re not going to put them to use, you might as well program in regular C.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint