Skip to content

[DO NOT MERGE][DO NOT REVIEW] Specialization constant #1084

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

Closed
wants to merge 2 commits into from

Conversation

AlexeySotkin
Copy link
Contributor

This is cherry-pick of specialization constant patches from https://github.com/KhronosGroup/SPIRV-LLVM-Translator

Add support for OpSpecConstantTrue, OpSpecConstantFalse, OpSpecConstant and
OpSpecConstantComposite instructions.

Add -spec-const command line option which allows to overwrite the default
values of specialization constants while translating SPIRV to LLVM.

Add getSpecConstInfo API. This API returns specialization sonstant IDs
available in the SPIR-V module and their size. This information also can be
printed out with -spec-const-info command line option.

Signed-off-by: Alexey Sotkin <[email protected]>
Translate SPIRV-friendly LLVM IR builtins represnting specialization constants
`__spirv_SpecConstant` to corresponding SPIR-V instructions.

This approach works only for scalar constants, so support for
`OpSpecConstantComposite` and `OpSpecConstantOp` is not implemented in this
patch.

Signed-off-by: Alexey Sotkin <[email protected]>
@bader bader closed this Feb 3, 2020
aelovikov-intel pushed a commit to aelovikov-intel/llvm that referenced this pull request Feb 23, 2023
…uld have it included (intel#1084)

The purpose of this PR is support the changes made in PR intel#6469 , which gets rid of #include <iostream> from sycl headers and is assumed to be included in the "sycl/sycl.hpp" header for some of the tests present in this repository
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants