Khronos Releases OpenCL 2.2 With SPIR-V 1.2
Market feedback incorporated to finalize OpenCL 2.2 release with full OpenCL specifications and conformance tests placed in open source
May 16, 2017 – IWOCL 2017, Toronto, CA – The Khronos™ Group, an open consortium of leading hardware and software companies, announces the immediate availability of the finalized OpenCL™ 2.2 specification, incorporating industry feedback received from developers during the provisional specification review period. In addition to releasing the specification in final form, Khronos has, for the first time, released the full source of the specifications and conformance tests for OpenCL 2.2 onto GitHub to enable deeper community engagement. The conformance tests for OpenCL versions 1.2, 2.0 and 2.1 have also been released on GitHub with more open-source releases to follow.
OpenCL 2.2 brings the most developer-requested feature into core — the new OpenCL C++ kernel language for significantly enhanced parallel programming productivity. OpenCL™ 2.2 has been released in parallel with SPIR-V 1.2 which brings full support for the new OpenCL C++ kernel language into the Khronos-defined intermediate language. OpenCL 2.2 finalization further complements SYCL 2.2, which leverages OpenCL 2.2 to provide the power of single source C++ programming.
“By finalizing OpenCL 2.2, Khronos has delivered on its promise to make C++ a first-class kernel language in the OpenCL standard,” said Neil Trevett, OpenCL chair and Khronos president. “The OpenCL working group is now free to continue its work with SYCL, to converge the power of single source parallel C++ programming with standard ISO C++, and to explore new markets and opportunities for OpenCL — such as embedded vision and inferencing. We are also working to converge with, and leverage, the Khronos Vulkan API — merging advance graphics and compute into a single API.”
Khronos is proud to announce these new features at the IWOCL 2017 Conference, hosted at the University of Toronto and sponsored by the Fields Institute, in Toronto, Canada, where participants have a choice of four tutorials, 19 technical sessions, a Khronos panel discussion, posters, demos, and a conference dinner and networking event. The Khronos Group, alongside other Khronos Group Members, is the primary sponsor of IWOCL.
The new specifications for OpenCL 2.2 and SPIR-V 1.2 can be found at www.khronos.org.
About OpenCL 2.2
OpenCL 2.2 defines the OpenCL C++ kernel language as a static subset of the C++14 standard. OpenCL C++ includes classes, templates, lambda expressions, function overloads and many other constructs to increase parallel programming productivity through generic and meta-programming.
OpenCL library functions can now take advantage of the C++ language to provide increased safety and reduced undefined behavior while accessing features such as atomics, iterators, images, samplers, pipes, and device queue built-in types and address spaces.
Pipe storage is a new device-side type in OpenCL 2.2 that is useful for FPGA implementations by making connectivity size and type known at compile time, enabling efficient device-scope communication between kernels.
OpenCL 2.2 also includes features for enhanced optimization of generated code: applications can provide the value of specialization constants at SPIR-V compilation time, a new query can detect non-trivial constructors and destructors of program scope global objects, and user callbacks can be set at program release time.
About SPIR-V 1.2
SPIR-V (Standard Portable Intermediate Representation) is the first open standard, cross-API intermediate language for natively representing parallel compute and graphics. As well as supporting the OpenCL C++ kernel language, SPIR-V 1.2 adds support for runtime specialization of key tuning parameters in OpenCL 2.2 such as workgroup size.
About SYCL 2.2
SYCL lets developers easily accelerate C++ software on OpenCL devices. SYCL is used in artificial intelligence frameworks because it matches the single-source programming style that enables complex deep learning graphs to use accelerators efficiently. SYCL 2.2 adds the capabilities of OpenCL 2.2 to the SYCL specification.
The open-source C++ 17 Parallel STL for SYCL, hosted by Khronos, will enable the upcoming C++ standard to support OpenCL 2.2 features such as shared virtual memory, generic pointers and device-side enqueue.
OpenCL C++ and SYCL between them now provide developers the choice of two C++ approaches. For developers who want to separate their device-side kernel source code and their host code, the C++ kernel language can be the best option. This is the approach taken with OpenCL C today, as well as the widely-adopted approach taken by shaders in graphics software. The alternative approach, commonly called ‘single-source’ C++, is the approach taken by SYCL, CUDA, OpenMP and the C++ 17 Parallel STL. By specifying both SYCL and the C++ kernel language, Khronos provides developers maximum choice, while aligning the two specifications so that code can be easily shared between these complementary approaches.
Industry Support for OpenCL 2.2
“Imagination Technologies is committed to helping drive standards around heterogeneous processing and GPU compute. It’s critical that the industry continues to improve the GPU compute programming model, and Khronos is playing a key role in these efforts through the continued momentum with OpenCL 2.2 and SPIR-V 1.2. Our customers continue to demand enhanced compute capability on the GPU and our newly announced PowerVR Series8XT cores support OpenCL 2.2 to further the use cases for our GPUs,” said Graham Connor, senior director, Imagination Technologies.
“We are very excited and happy to see OpenCL C++ kernel language being a part of the OpenCL standard,” said Vincent Hindriksen, founder and managing director of StreamHPC. “It’s a great achievement, and it shows that OpenCL keeps progressing. After developing conformance tests for OpenCL 2.2 and helping finalizing OpenCL C++ specification, we are looking forward to work on first projects with OpenCL 2.2 and the new kernel language. My team believes that using OpenCL C++ instead of OpenCL C will result in improved software quality, reduced maintenance effort and faster time to market. We expect SPIR-V to heavily impact the compiler ecosystem and bring several new OpenCL kernel languages.”
“The University of Windsor has been actively involved in utilizing OpenCL in aspects of automotive research and heterogeneous computing and also developing software build and test frameworks that are vital for achieving programming goals. We are committed to continuing our academic membership in Khronos and are proud to lend our organizational support to IWOCL 2017,” said Robert Kent, computer science professor, University of Windsor.
“It is fitting that OpenCL C++ and SPIR-V, two critical technologies for machine learning, are launched here in Toronto, a global focal point for AI. As a Canadian entrepreneur with a technology startup, I am proud of my role in the development of these technologies within Khronos alongside these amazing industry leaders, and bringing the IWOCL event to Toronto. Anyone who is not familiar with OpenCL risks being left behind the technology curve,” said AJ Guillon, founder, YetiWare.
For more information about The Khronos Group visit Khronos.org.