A Hands-On Introduction
Simon McIntosh-Smith, University of Bristol
OpenCL is an open standard for programming heterogeneous parallel computers composed of CPUs, GPUs and other processors. OpenCL consists of a framework to manipulate the host CPU and one or more compute devices plus a C-based programming language for writing programs for the compute devices. Using OpenCL, a programmer can write parallel programs that harness all of the resources of a heterogeneous computer.
In this advanced, hands-on tutorial, we assume the attendee is already familiar with OpenCL, and has probably written at least one OpenCL program. The tutorial will focus on more advanced OpenCL concepts, such as:
- Shipping kernel code,
- Portable binaries with SPIR
- OpenCL kernel compiler options
- Kernel metaprogramming
- Optimised host-device communications
- Using multiple OpenCL devices
- Performance portability
- Coalesced memory accesses
- Tuning work-group sizes
- OpenCL / OpenGL interoperability
- The OpenCL ecosystem:
- OpenCL 2.0 and future versions
- OpenCL SPIR
- OpenCL SYCL
- OpenCL libraries
- Other OpenCL resources
The tutorial will use a mix of OpenCL’s C and C++ host APIs. The format will be a 50/50 split between lectures and exercises. Attendees will need to use their own laptops (Windows, Linux or OS/X) and log into a remote server running an OpenCL platform. Alternatively, students can load OpenCL onto their own laptops prior to the course (Intel, AMD and NVIDIA provide OpenCL SDKs. Apple laptops with X-code include OpenCL by default. Be sure to configure X-code to use the command line interface).
Attendees at the tutorial will have access to the University of Bristol’s “OpenCL zoo”; a diverse collection of OpenCL conformant devices. Tutorial attendees will be able to run their own programs on devices in the zoo to explore the performance portability of OpenCL. The zoo includes a mix of CPUs, GPUs and APUs from all the major vendors.
Simon McIntosh-Smith is a leading OpenCL trainer, having taught the subject since 2009. He has run many OpenCL training courses at conferences such as SuperComputing and HiPEAC, and has provided OpenCL training for the UK’s national supercomputing service and for the Barcelona Supercomputing Center. With OpenCL training experience ranging from half day on-site introductions within companies, to three-day intensive hands-on workshops, Simon provides standard and customized OpenCL training courses. The tutorial will also be supported by members of Simon’s research team, all of whom are experienced OpenCL software developers.