Hacker News new | past | comments | ask | show | jobs | submit login
OpenCL on Metal – what if clvk works? (threedots.ovh)
25 points by my123 on April 1, 2022 | hide | past | favorite | 9 comments



Quite close to saturating memory bandwidth, but compute utilization looks like it needs some work.


Now all we need is a way to run CUDA code on OpenCL


Good luck with all the languages supported by CUDA.


On some OpenCL implementations (as in, the ones supporting the SPIR-V OpenCL profile instead of just OpenCL C), this is possible.

Intel has a cleaned up variant of OpenCL for the purpose of running SPIR-V binaries called oneAPI L0, and Zluda can run on top of it. https://github.com/vosen/ZLUDA

AMD used to support SPIR in their driver, but they removed support for that in 2018. As such, you won’t get anything useful out of that one on AMD GPUs.


One reason why OpenCL 3.0 is basically OpenCL 1.2 rebranded, is because no one cared about SPIR profile.

OneAPI is focused on SYSCL, which is targeted at C++ and backend agnostic, it does nothing for Fortran, .NET, Java, Haskell, Rust, or any other language targeting PTX.

CUDA won thanks to embracing GPU polyglot programming and best in quality development tooling.

It is more a failure of the competition to uplevel their game than NVidia's own efforts.


> OneAPI is focused on [SYCL], which is targeted at C++ and backend agnostic, it does nothing for Fortran

oneAPI L0 supports SPIR-V's OpenCL profile, which is a language agnostic IR.

oneAPI Fortran offload to GPUs is supported with the OpenMP programming model. (https://www.intel.com/content/www/us/en/developer/tools/onea...)

SYCL is one of the programming models supported with oneAPI, OpenMP is also a first-class programming model. You can mix both OpenMP and oneAPI code in the same program too. (https://www.intel.com/content/www/us/en/develop/documentatio...)

The clearly defined oneAPI L0/OpenCL w/ SPIR-V API boundary also allows for custom programming models w/ 3rd-party compilers.


Yeah, all of that goes beyond the OpenCL standard as defined by Khronos, specially since OpenCL 3.0 dropped SPIR-V, and OpenMP was never part of OpenCL.


> specially since OpenCL 3.0 dropped SPIR-

It's not dropped, it's optional. An OpenCL 3.0 impl with SPIR-V support would be able to run such binaries on top - but Intel are the ones who care.


An euphemism for dropped.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: