Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: extend SPIRV-Cross to accept OpenCL dialect of SPIR-V.. #984

Open
oscarbg opened this issue May 17, 2019 · 4 comments
Open

Request: extend SPIRV-Cross to accept OpenCL dialect of SPIR-V.. #984

oscarbg opened this issue May 17, 2019 · 4 comments
Labels
enhancement

Comments

@oscarbg
Copy link

@oscarbg oscarbg commented May 17, 2019

Hi,
just seeing IWOCL 2019 keynote presentation slides:(https://www.khronos.org/assets/uploads/developers/library/2019-iwocl/IWOCL%20Keynote%20May19.pdf)
https://www.khronos.org/developers/library/2019-iwocl
in page 31 we see talks about possible plans for "OpenCL portability initiative on Apple":
image
i.e. a OpenCL->Metal shim as Neil mentions that OpenCL maps to Metal better than to Vulkan (for CL->Vulkan we have clvk in progress) and with Apple deprecated OpenCL support maybe of interest..
for that, the slide mentions "SPIR-V Cross would need to be expanded to handle OpenCL dialect of SPIR-V) so just asking here..
I don't know why he doesn't mention using also clspv project which already maps OpenCL C source to SPIR-V Vulkan dialect..
Maybe because project is not mature enough or because maybe because is not enough as OpenCL 2.1 allows feeding directly SPIR-V OpenCL "binary" kernels for which clspv is of not use..
sorry, just random thoughts.. :-)

@HansKristian-Work HansKristian-Work added the enhancement label May 18, 2019
@HansKristian-Work
Copy link
Contributor

@HansKristian-Work HansKristian-Work commented May 18, 2019

SPIRV-Cross as-is does not support the "Kernel" execution mode as it supports various things which are impossible to express in GLSL/HLSL and I think MSL, non-structured control flow (goto) for one. I don't know what the scope of adding this is, and I have no plans to look into it until something materializes.

@vchuravy
Copy link

@vchuravy vchuravy commented May 11, 2020

Any news on this? We are currently looking at producing SPIR-V Kernel for Intel and were hoping to re-use some of that work by using SPIR-V Cross to compile to MSL. The idea was mentioned in one of the last presentations https://images.anandtech.com/doci/15746/OpenCL%2030%20Press%20Deck_20.png

@HansKristian-Work
Copy link
Contributor

@HansKristian-Work HansKristian-Work commented Jun 8, 2020

Kernel is fundamentally incompatible with high level languages, since it supports unstructured control-flow. A subset of Kernel which uses structured control flow may or may not work, but this is not a priority for me any time soon.

@Trass3r
Copy link

@Trass3r Trass3r commented Dec 16, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement
Projects
None yet
Development

No branches or pull requests

4 participants