clspv
OpenCLOn12
Our great sponsors
clspv | OpenCLOn12 | |
---|---|---|
8 | 3 | |
574 | 100 | |
2.3% | - | |
9.0 | 6.6 | |
8 days ago | 23 days ago | |
LLVM | C++ | |
Apache License 2.0 | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
clspv
-
Vcc – The Vulkan Clang Compiler
See https://github.com/google/clspv for an OpenCL implementation on Vulkan Compute. There are plenty of quirks involved because the two standards use different varieties of SPIR-V ("kernels" vs. "shaders") and provide different guarantees (Vulkan Compute doesn't care much about numerical accuracy). The Mesa folks are also looking into this as part of their RustiCL (a modern OpenCL implementation) and Zink (implementing OpenGL and perhaps OpenCL itself on Vulkan) projects.
-
AMD's CDNA 3 Compute Architecture
Vulkan Compute backends for numerical compute (as typified by both OpenCL and SYCL) are challenging, you can look at Google's cspv https://github.com/google/clspv project for the nitty gritty details. The lowest-effort path is actually via some combination of Rocm (for hardware that AMD bothers to support themselves) and the Mesa project's Rusticl backend (for everything else).
-
WSL with CUDA Support
D3D12 has more compute features than Vulkan has. It works out for DXVK because games often don’t use those, but it’ll cause much more issues with CLon12.
By the way, if you are ready to have a _limited_ implementation without a full feature set because of Vulkan API limitations, clvk is a thing. The list of limitations of that approach is at https://github.com/google/clspv/blob/master/docs/OpenCLCOnVu...
tldr: Vulkan and OpenCL SPIR-V dialects are different, and the former has significant limitations affecting this use case
- Resources for Vulkan GPGPU searched
-
Low overhead C++ interface for Apple's Metal API
For OpenCL on DX12, the test suite doesn't pass yet. Every Khronos OpenCL 1.2 CTS test passes on at least one hardware driver, but there's none that pass them all. That is why CLon12 isn't submitted to Khronos's compliant products list yet.
The pointer semantics that Vulkan has aren't very amenable to implementing a compliant OpenCL implementation on top of. There are also some other limitatons: https://github.com/google/clspv/blob/master/docs/OpenCLCOnVu....
-
[Hardware Unboxed] - Apple M1 Pro Review - Is It Really Faster than Intel/AMD?
Vulkan is much more limited, notably because of Vulkan's SPIR-V dialect limitations. That makes a compliant OpenCL 1.2 impl on top of Vulkan impossible. (see: https://github.com/google/clspv/blob/master/docs/OpenCLCOnVulkan.md)
-
Cross Platform GPU-Capable Framework?
OpenCL really is your best bet for a cross-platform GPU-capable framework. OpenCL 3.0 cleared out a lot of the cruft from OpenCL 2.x so it's seeing a lot more adoption. The most cross-platform solution is still OpenCL 1.2, largely for MacOS, but OpenCL 3.0 is becoming more and more common for Windows and Linux and multiple devices. Even on platforms without native OpenCL support there are compatibility layers that implement OpenCL on top of DirectX (OpenCLOn12) or Vulkan (clvk and clspv).
OpenCLOn12
-
A Review of Shader Languages
The SPIR-V OpenCL profile is suitable, the Vulkan one is much less suitable. (In the you can’t even transpile OpenCL C 1.2 to it fully, with quite heavily limited pointers…)
Metal has the best GPGPU story of the compute APIs, with D3D12 coming second after that. Both at least can have OpenCL C transpiled without catches to them…
Microsoft is writing CLon12 on that front: https://github.com/microsoft/OpenCLOn12
-
WSL with CUDA Support
> OpenCL does not work. There's some bits about intel [& amd] GPUs, but nada on nvidia
This is planned to be fixed. WSL2’s GPU support currently doesn’t provide a path to provide an alternate OpenCL loader ICD location. (And not for OpenGL either)
Microsoft is developing CLon12 at https://github.com/microsoft/OpenCLOn12 as the option to provide OpenCL out of the box.
-
Cross Platform GPU-Capable Framework?
OpenCL really is your best bet for a cross-platform GPU-capable framework. OpenCL 3.0 cleared out a lot of the cruft from OpenCL 2.x so it's seeing a lot more adoption. The most cross-platform solution is still OpenCL 1.2, largely for MacOS, but OpenCL 3.0 is becoming more and more common for Windows and Linux and multiple devices. Even on platforms without native OpenCL support there are compatibility layers that implement OpenCL on top of DirectX (OpenCLOn12) or Vulkan (clvk and clspv).
What are some alternatives?
kompute - General purpose GPU compute framework built on Vulkan to support 1000s of cross vendor graphics cards (AMD, Qualcomm, NVIDIA & friends). Blazing fast, mobile-enabled, asynchronous and optimized for advanced GPU data processing usecases. Backed by the Linux Foundation.
GLSL - GLSL Shading Language Issue Tracker
alpaka - Abstraction Library for Parallel Kernel Acceleration :llama:
MoltenVK - MoltenVK is a Vulkan Portability implementation. It layers a subset of the high-performance, industry-standard Vulkan graphics and compute API over Apple's Metal graphics framework, enabling Vulkan applications to run on macOS, iOS and tvOS.
SHADERed - Lightweight, cross-platform & full-featured shader IDE
SPIRV-VM - Virtual machine for executing SPIR-V
clvk - Implementation of OpenCL 3.0 on Vulkan
metal-cpp - Metal-cpp is a low-overhead C++ interface for Metal that helps developers add Metal functionality to graphics apps, games, and game engines that are written in C++.