opencl介绍

OpenCL3.0是一个开放的、免费的标准,用于跨平台并行编程,涵盖各种设备。新版本增强了功能部署灵活性,支持更多硬件,推动了边缘计算和移动设备中的GPU编程语言应用。OpenCL3.0的发布有助于加速器的广泛使用和软件堆栈的优化。
摘要由CSDN通过智能技术生成

OPEN STANDARD FOR PARALLEL PROGRAMMING OF HETEROGENEOUS SYSTEMS

异构系统并行编程的开放标准

OpenCL™ (Open Computing Language) is an open, royalty-free standard for cross-platform, parallel programming of diverse accelerators found in supercomputers, cloud servers, personal computers, mobile devices and embedded platforms. OpenCL greatly improves the speed and responsiveness of a wide spectrum of applications in numerous market categories including professional creative tools, scientific and medical software, vision processing, and neural network training and inferencing.

OpenCL™ (开放计算语言)是一种开放的、免版税的标准,用于超级计算机、云服务器、个人计算机、移动设备和嵌入式平台中各种加速器的跨平台并行编程。OpenCL极大地提高了众多市场类别中广泛应用程序的速度和响应能力,包括专业创意工具、科学和医学软件、视觉处理以及神经网络训练和推理。

OpenCL 3.0 Final is Here!

OpenCL 3.0来了!

The OpenCL 3.0 Finalized Specification was released on September 30th 2020

OpenCL 3.0最终规范于2020年9月30日发布

Read the Blog about the final release of OpenCL 3.0 Provisional Press Release Provisional Launch Presentation

OpenCL 3.0 realigns the OpenCL roadmap to enable developer-requested functionality to be broadly deployed by hardware vendors, and it significantly increases deployment flexibility by empowering conformant OpenCL implementations to focus on functionality relevant to their target markets. OpenCL 3.0 also integrates subgroup functionality into the core specification, ships with a new unified API and OpenCL C 3.0 language specifications and introduces extensions for asynchronous data copies to enable a new class of embedded processors.

OpenCL 3.0重新调整了OpenCL路线图,使硬件供应商能够广泛部署开发人员要求的功能,并通过使符合要求的OpenCL实现能够专注于与其目标市场相关的功能,显著提高了部署灵活性。OpenCL 3.0还将子组功能集成到核心规范中,附带了新的统一API和OpenCL C 3.0语言规范,并引入了异步数据副本的扩展,以实现新的嵌入式处理器类别。

OpenCL 3.0 Materials

OpenCL 3.0材料

Specification SDK OpenCL Guide OpenCL Blogs Issues Discussions Resources Reference Guide

Industry Support for OpenCL

OpenCL的行业支持

“Many of our customers want a GPU programming language that runs on all devices, and with growing deployment in edge computing and mobile, this need is increasing. OpenCL is the only solution for accessing diverse silicon acceleration and many key software stacks use OpenCL/SPIR-V as a backend. We are very happy that OpenCL 3.0 will drive even wider industry adoption, as it reassures our customers that their past and future investments in OpenCL are justified.”

“我们的许多客户都想要一种在所有设备上运行的GPU编程语言,随着边缘计算和移动设备的部署不断增加,这种需求也在增加。OpenCL是访问各种硅加速的唯一解决方案,许多关键软件堆栈都使用OpenCL/SPIR-V作为后端。我们很高兴OpenCL 3.0将推动更广泛的行业采用,因为它保证了我们的自定义他们过去和未来对OpenCL的投资是合理的。”

Vincent Hindriksen

Founder and CEO of Stream HPC

OpenCL is Widely Deployed and Used

Accelerated Implementations

加速实施

OpenCL for Low-level Parallel Programing

用于低级并行编程的OpenCL

OpenCL speeds applications by offloading their most computationally intensive code onto accelerator processors - or devices. OpenCL developers use C or C++-based kernel languages to code programs that are passed through a device compiler for parallel execution on accelerator devices.

OpenCL通过将计算量最大的代码卸载到加速器处理器或设备上来加速应用程序。OpenCL开发人员使用基于C或C++的内核语言来编写程序,这些程序通过设备编译器在加速器设备上并行执行。

How OpenCL Relates to Other Khronos Parallel Acceleration Standards

OpenCL与其他Khronos并行加速标准的关系

OpenCL provides the industry with the lowest 'close-to-metal' processor-agile execution layer for accelerating applications, libraries and engines, and also providing a code generation target for compilers. Unlike 'GPU-only' APIs, such as Vulkan, OpenCL enables use of a diverse range of accelerators including multi-core CPUs, GPUs, DSPs, FPGAs and dedicated hardware such as inferencing engines.

OpenCL为业界提供了最低的“接近金属”处理器敏捷执行层,用于加速应用程序、库和引擎,还为编译器提供了代码生成目标。与Vulkan等“仅GPU”API不同,OpenCL支持使用各种加速器,包括多核CPU、GPU、DSP、FPGA和推理引擎等专用硬件。

How OpenCL relates to the family of Khronos acceleration standards

OpenCL Deployment Flexibility

OpenCL部署灵活性

As the industry landscape of platforms and devices grows more complex, tools are evolving the enable OpenCL applications to be deployed onto platforms that do not have available native OpenCL drivers. For example, the open source clspv compiler and clvk API translator enable OpenCL applications to be run over a Vulkan run-time. This gives OpenCL developers significant flexibility on where and how they can deploy their OpenCL applications.

​随着平台和设备的行业格局变得越来越复杂,工具正在发展,使OpenCL应用程序能够部署到没有可用的本地OpenCL驱动程序的平台上。例如,开源clspv编译器和clvk API转换器使OpenCL应用程序能够在Vulkan运行时上运行。这为OpenCL开发人员提供了很大的灵活性,可以在哪里以及如何部署他们的OpenCL应用程序。

Open source software tools enable OpenCL kernels to be executed over multiple target APIs

Open source software tools enable OpenCL kernels to be executed over multiple target APIs

开源软件工具使OpenCL内核能够在多个目标API上执行

OpenCL Programming Model

OpenCL编程模型

An OpenCL application is split into host and device parts with host code written using a general programming language such as C or C++ and compiled by a conventional compiler for execution on a host CPU.

OpenCL应用程序分为主机和设备两部分,主机代码使用通用编程语言(如C或C++)编写,并由传统编译器编译以在主机CPU上执行。

The device compilation phase can be done online, i.e. during execution of an application using special API calls. It can alternatively be compiled before executing the application into the machine binary or special portable intermediate representation defined by Khronos called SPIR-V. There are also domain specific languages and frameworks that can compile to OpenCL either using source-to-source translations or generating binary/SPIR-V, for example Halide.

​设备编译阶段可以在线完成,即在使用特殊API调用执行应用程序期间。也可以在执行应用程序之前将其编译为机器二进制或Khronos定义的特殊可移植中间表示SPIR-V。还有一些特定于领域的语言和框架可以使用源到源的翻译或生成二进制/SPIR-V编译到OpenCL,例如Halide。

Traditional vs OpenCL programming paradigm

Traditional vs OpenCL programming paradigm

传统编程范式与OpenCL编程范式

Application host code is frequently written in C or C++ but bindings for other languages are also available, such as Python. Kernel programs can be written in a dialect of C (OpenCL C) or C++ (C++ for OpenCL) that enables a developer to program computationally intensive parts of their application in a kernel program. All versions of the OpenCL C language are based on C99. The community driven C++ for OpenCL language brings together capabilities of OpenCL and C++17.

应用程序主机代码通常是用C或C++编写的,但也可以使用其他语言的绑定,如Python。内核程序可以用C(OpenCL C)或C++(OpenCL的C++)的方言编写,使开发人员能够在内核程序中对其应用程序的计算密集型部分进行编程。OpenCL C语言的所有版本都基于C99。社区驱动的C++for OpenCL语言汇集了OpenCL和C++17的功能。

C++ for OpenCL Kernel Language

用于OpenCL内核语言的C++

The OpenCL working group has transitioned from the original OpenCL C++ kernel language first defined in OpenCL 2.0 to C++ for OpenCL developed by the open source community to provide improved features and compatibility with OpenCL C. C++ for OpenCL is supported by Clang and its documentation can be found here. It enables developers to use most C++17 features in OpenCL kernels. It is largely backwards compatible with OpenCL C 2.0 enabling it to be used to program accelerators with OpenCL 2.0 or above with conformant drivers that support SPIR-V. Its implementation in Clang can be tracked via the OpenCL Support Page.

​OpenCL工作组已经从最初在OpenCL 2.0中定义的OpenCL C++内核语言过渡到由开源社区开发的用于OpenCL的C++,以提供改进的功能和与OpenCL的兼容性。它使开发人员能够在OpenCL内核中使用大多数C++17功能。它在很大程度上与OpenCL C 2.0向后兼容,使其能够用于使用支持SPIR-V的一致驱动程序对OpenCL 2.0或更高版本的加速器进行编程。它在Clang中的实现可以通过OpenCL支持页面进行跟踪。

Kernel Language Extensions

内核语言扩展

Some extensions are available to the existing published kernel language standards. The full list of such extensions is documented here . Conformant compilers and drivers may optionally support the extensions and so there is a mechanism to detect their support at the compile time. Developers should be aware that not all extensions may be supported across all devices.

​一些扩展可用于现有已发布的内核语言标准。这里记录了此类扩展的完整列表。一致的编译器和驱动程序可以选择性地支持扩展,因此有一种机制可以在编译时检测它们的支持。开发人员应该意识到,并非所有扩展都可以在所有设备上得到支持。

Conformant OpenCL Implementations

一致的OpenCL实现

Here you can view a list of hardware vendors with openConformant OpenCL Implementations

​在这里,可以查看具有openConformant OpenCL实现的硬件供应商列表

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值