Skip to content

[SYCL] Predefine SYCL macros with vendor strings #4498

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
Sep 8, 2021
Merged

[SYCL] Predefine SYCL macros with vendor strings #4498

merged 2 commits into from
Sep 8, 2021

Conversation

dsawfer
Copy link
Contributor

@dsawfer dsawfer commented Sep 7, 2021

The SYCL 2020 specification requires at least one macro of the form SYCL_IMPLEMENTATION_"vendorstring" to be predefined, which allows applications to check if they compile with this provider's implementation.

Our vendorstrings are SYCL_IMPLEMENTATION_ONEAPI and SYCL_IMPLEMENTATION_INTEL. The SYCL_FEATURE_SET_FULL macro is mandated by section 5.6. "Preprocessor directives and macros" of the SYCL 2020 specification.

@dsawfer dsawfer requested a review from a team as a code owner September 7, 2021 05:47
@dsawfer dsawfer requested a review from alexbatashev September 7, 2021 05:47
@alexbatashev alexbatashev requested a review from gmlueck September 7, 2021 05:51
Co-authored-by: Alexander Batashev <[email protected]>
@dm-vodopyanov
Copy link
Contributor

@dsawfer, can you please add a description for this PR?

@dm-vodopyanov
Copy link
Contributor

@dsawfer @alexbatashev Should tests need to be added?

@alexbatashev
Copy link
Contributor

alexbatashev commented Sep 7, 2021

@dsawfer @alexbatashev Should tests need to be added?

There's a test in the tests folder. What other kind of testing are you thinking of?

@dm-vodopyanov
Copy link
Contributor

@dsawfer @alexbatashev Should tests need to be added?

There's a test in the tests folder. What other kind of testing are you thinking of?

Sorry, missed that somehow.

@dm-vodopyanov
Copy link
Contributor

@dsawfer, can you please add a description for this PR?

Thanks!

@dm-vodopyanov dm-vodopyanov merged commit 6d34ebf into intel:sycl Sep 8, 2021
DoyleLi pushed a commit to DoyleLi/intel_llvm that referenced this pull request Sep 13, 2021
The SYCL 2020 specification requires at least one macro of the form SYCL_IMPLEMENTATION_"vendorstring" to be predefined, which allows applications to check if they compile with this provider's implementation.

Our vendorstrings are SYCL_IMPLEMENTATION_ONEAPI and SYCL_IMPLEMENTATION_INTEL. The SYCL_FEATURE_SET_FULL macro is mandated by section 5.6. "Preprocessor directives and macros" of the SYCL 2020 specification.
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.

5 participants