Skip to content

[sycl-post-link] Add support of spec constant default values #3513

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

Conversation

AlexeySachkov
Copy link
Contributor

Added handling of the second argument of
__sycl_get*2020SpecConstantValue intrinsic.

Added handling of the second argument of
`__sycl_get*2020SpecConstantValue` intrinsic.
@AlexeySachkov AlexeySachkov requested a review from vmaksimo April 8, 2021 15:19
@AlexeySachkov AlexeySachkov marked this pull request as ready for review April 9, 2021 08:46
@AlexeySachkov AlexeySachkov requested a review from kbobrovs as a code owner April 9, 2021 08:46
@AlexeySachkov
Copy link
Contributor Author

@kbobrovs, could you please take a look?

@bader bader changed the title Add support of spec constant default values [sycl-post-link] Add support of spec constant default values Apr 15, 2021
@bader bader requested a review from vmaksimo April 15, 2021 10:41
@AlexeySachkov
Copy link
Contributor Author

@kbobrovs, ping

@bader bader merged commit 6921608 into intel:sycl Apr 21, 2021
AlexeySachkov added a commit to AlexeySachkov/llvm that referenced this pull request May 13, 2021
Due to changes in `SpecConstatsPass` introduced by intel#3513,
device image properties for specialization constants are now computed in
a bit different way: in particular they are calculated based on metadata
generated by the pass and not by looking at the SPIR-V friendly IR
intrinsics left in the module.

Such change caused a regression: if device code split was used together
with specialization constants, each resulting device image was supplied
with list of *all* specialization constants found in the _original_
undivided module. In combination with some DPC++ RT changes it lead to
setting non-existing specialization constants.

This patch fixed the regression by performing device code split step
*before* handling specialization constants.
bader pushed a commit that referenced this pull request May 15, 2021
Due to changes in `SpecConstatsPass` introduced by #3513,
device image properties for specialization constants are now computed in
a bit different way: in particular they are calculated based on metadata
generated by the pass and not by looking at the SPIR-V friendly IR
intrinsics left in the module.

Such change caused a regression: if device code split was used together
with specialization constants, each resulting device image was supplied
with list of *all* specialization constants found in the _original_
undivided module. In combination with some DPC++ RT changes it lead to
setting non-existing specialization constants.

This patch fixed the regression by performing device code split step
*before* handling specialization constants.
@AlexeySachkov AlexeySachkov deleted the private/asachkov/spec-constants-default-values-support branch May 22, 2024 09:49
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.

4 participants