Skip to content

Conversation

AlexeySachkov
Copy link
Contributor

This PR implements runtime support for composite specialization constants. The test is disabled at the moment, because we need to merge #2779 first + enable SPIR-V support for composite spec constants

@AlexeySachkov
Copy link
Contributor Author

@kbobrovs, @smaslov-intel, please review this PR

Copy link
Contributor

@smaslov-intel smaslov-intel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you going to fix the style check failure?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// encode scalar specialization constants, that form a composite one.
/// encode scalar specialization constants, that form the composite one.

What if it is a nested structural type? Can you maybe give an example here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The whole structure will be flattened. Sure, I will add an example

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed and added an example in 0800c2bc8278c364eeee5951d0be180df228dcef

@AlexeySachkov
Copy link
Contributor Author

Are you going to fix the style check failure?

Sure, applied it in 0800c2bc8278c364eeee5951d0be180df228dcef. I was just waiting for some review comments to bundle clang-format change together with them to avoid wasting CI run

sergey-semenov
sergey-semenov previously approved these changes Nov 30, 2020
Copy link
Contributor

@sergey-semenov sergey-semenov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor typo aside, LGTM

Added an example of composite constant descriptor. Fixed a few typos.
Applied clang-format
Added a padding field to device representation of spec_constant class in
order to align its size with size of it on host. If sizes are not the
same it could lead to memory corruptions in SYCL RT when it tries to
access arguments of SYCL Kernel function.
Moved them into on-device directory as they are E2E tests required
low-level runtimes and HW. Added one more test for composite spec
constants.
@AlexeySachkov AlexeySachkov force-pushed the private/asachkov/support-for-composite-spec-constants-in-runtime branch from a37e679 to c8b42fd Compare December 2, 2020 15:41
@AlexeySachkov
Copy link
Contributor Author

Enabled E2E tests as we have the rest of functionality in the repo already. Fixed an issue I found with different size of spec_constant class on host and device

@AlexeySachkov AlexeySachkov changed the title [SYCL RT] Add support for POD specialization constants [SYCL RT] Add support for composite specialization constants Dec 3, 2020
@AlexeySachkov
Copy link
Contributor Author

@kbobrovs, please take a look as well

Copy link
Contributor

@kbobrovs kbobrovs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New fix in spec_constant.hpp LGTM

@AlexeySachkov
Copy link
Contributor Author

@sergey-semenov, @smaslov-intel, please take a look at the update version

@romanovvlad romanovvlad merged commit c62860f into intel:sycl Dec 8, 2020
@AlexeySachkov AlexeySachkov deleted the private/asachkov/support-for-composite-spec-constants-in-runtime branch February 25, 2021 12:27
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.

6 participants