[llvm] [SPIR-V] Support for C++ for OpenCL source language (PR #188791)
Arseniy Obolenskiy via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 27 03:46:09 PDT 2026
aobolensk wrote:
> Thanks for the PR. This question is mainly for me to learn about OpenCL and SPIRV.
>
> Can the SPRIV backend process the LLVM IR that comes from OpenCL? Are there other missing functionalities? My bad if the question doesn't actually make much sense.
Yes, SPIR-V backend can perform that. If you use clang you can perform OpenCL -> LLVM IR -> SPIR-V this way:
```
clang --target=spirv64 -cl-std=CL2.0 -c test.cl -o test.spv
```
https://github.com/llvm/llvm-project/pull/188791
More information about the llvm-commits
mailing list