Skip to content

[SYCL] Ignore vec_type_hint attribute in SYCL 2020 #10619

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

Merged
merged 3 commits into from
Aug 8, 2023

Conversation

elizabethandrews
Copy link
Contributor

@elizabethandrews elizabethandrews commented Jul 28, 2023

According to the SYCL 2020 spec, [[sycl::vec_type_hint()]] attribute should accept arguments of the type sycl::vec type. The attribute should also be accepted with non conforming lambda syntax.

The current implementation in SYCL corresponds to the openCL version of this argument (with an additional spelling for SYCL), i.e. the attribute accepts extended vector type, floating point types and integral type. An error diagnostic is thrown for sycl:vec type.

Since the attribute is deprecated and is not handled by any SYCL backend, and will be removed in a future version of the spec, to be minimally conformant with SYCL 2020 spec, this PR just ignores the attribute instead of adding support for sycl::vec type. Support was also added for non conforming lambda syntax

According to the SYCL 2020 spec, [[sycl::vec_type_hint()]]
attribute should accept arguments of the type sycl::vec
type. This customization/support however has never been
implemented. The current implementation in SYCL corresponds
to the openCL version of this argument (with an additional
spelling for SYCL), i.e. the attribute accepts extended vector
type, floating point types and integral type. An error diagnostic
is thrown for sycl:vec type. Since the attribute is deprecated
and is not handled by any SYCL backend, and will be removed in
a future version of the spec, to be minimally conformant with SYCL
2020 spec, this PR just ignores the attribute instead of adding
support for sycl::vec type.
@elizabethandrews elizabethandrews requested a review from a team as a code owner July 28, 2023 21:07
@elizabethandrews elizabethandrews temporarily deployed to aws July 28, 2023 21:27 — with GitHub Actions Inactive
@elizabethandrews elizabethandrews marked this pull request as draft July 28, 2023 21:34
@elizabethandrews
Copy link
Contributor Author

elizabethandrews commented Jul 28, 2023

Just realized that this attribute also needs to be accepted on lambda syntax like other kernel attributes are accepted. I will update PR with a new commit

@elizabethandrews elizabethandrews temporarily deployed to aws July 28, 2023 22:06 — with GitHub Actions Inactive
@elizabethandrews elizabethandrews marked this pull request as ready for review July 31, 2023 22:20
@elizabethandrews elizabethandrews temporarily deployed to aws July 31, 2023 22:32 — with GitHub Actions Inactive
@elizabethandrews elizabethandrews temporarily deployed to aws July 31, 2023 23:11 — with GitHub Actions Inactive
@elizabethandrews
Copy link
Contributor Author

ping @premanandrao

@elizabethandrews
Copy link
Contributor Author

ping @premanandrao @Fznamznon

Copy link
Contributor

@Fznamznon Fznamznon left a comment

Choose a reason for hiding this comment

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

A couple of NITs, otherwise LGTM.

@elizabethandrews elizabethandrews temporarily deployed to aws August 4, 2023 15:05 — with GitHub Actions Inactive
@elizabethandrews elizabethandrews temporarily deployed to aws August 4, 2023 15:47 — with GitHub Actions Inactive
@elizabethandrews
Copy link
Contributor Author

@intel/llvm-gatekeepers PR is ready for merge

@dm-vodopyanov dm-vodopyanov merged commit e020f69 into intel:sycl Aug 8, 2023
mdtoguchi pushed a commit to mdtoguchi/llvm that referenced this pull request Oct 18, 2023
According to the SYCL 2020 spec, [[sycl::vec_type_hint()]] attribute
should accept arguments of the type sycl::vec type. The attribute should
also be accepted with non conforming lambda syntax.

The current implementation in SYCL corresponds to the openCL version of
this argument (with an additional spelling for SYCL), i.e. the attribute
accepts extended vector type, floating point types and integral type. An
error diagnostic is thrown for sycl:vec type.

Since the attribute is deprecated and is not handled by any SYCL
backend, and will be removed in a future version of the spec, to be
minimally conformant with SYCL 2020 spec, this PR just ignores the
attribute instead of adding support for sycl::vec type. Support was also
added for non conforming lambda syntax
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.

3 participants