Skip to content

[SYCL] Fix type traits used for shuffle operations #17055

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 2 commits into from
Feb 24, 2025

Conversation

againull
Copy link
Contributor

@againull againull commented Feb 19, 2025

  • Pointer type was incorrectly treated as arithmetic type, so the case when user passed, for example, int* variable to sycl::select_from_group ended up mapping to non-existent built-in SubgroupShuffleINTEL(i32*, ...). This is fixed in this PR and now it is mapped to SubgroupShuffleINTEL(i64, ...)

  • Rename type trait VecTypeIsProhibitedForShuffleEmulation->VecTypeIsProhibitedForNativeShuffle. Old name was confusing. Basically trait is used to determine vec types for which we cannot use native built-ins.

  • enable_ifs for shuffle overloads were not completely mutually exclusive leading to compilation error with ambiguous definitions for some types. For example, marray<bfloat16, 4> used to satisfy both NonScalar and Bitcast traits. So, refactoring was done to make them mutually exclusive and more clear.

* Pointer type was incorretly treated as arithemetic type, so the case
  when user passed, for example, int* varible sycl::select_from_group it
  ended up mapping to non-existent builtin SubgroupShuffleINTEL(i32*, ...).
  This is fixed in this PR and now it is mapped to SubgroupShuffleINTEL(i64, ...)

* Rename type trait VecTypeIsProhibitedForShuffleEmulation->VecTypeIsProhibitedForNativeShuffle.
  Old name was confusing. Basically trait is used to determine vec types for which we cannot use native builtins.

* Type traits were not completely mutually exclusive leading to
  compilation error with ambigous definitions for some types. For
  example, marray<bfloat16, 4> used to satisfy both NonScalar and bitcast traits.
  So, refactoring was done to make them mutually exclusive and more clear.
@againull
Copy link
Contributor Author

@sergey-semenov Could you please take a look.

@againull againull merged commit 7f5da80 into intel:sycl Feb 24, 2025
20 checks passed
@colleeneb
Copy link

Hello! We ran into this issue with oneAPI 2025.0.5. Is there a workaround for this by any chance, or is the only fix from a newer version of SYCL? Thanks a lot!

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