Skip to content

[SYCL] Include backend-specific header if exists #4783

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
Oct 20, 2021

Conversation

vladimirlaz
Copy link
Contributor

https://www.khronos.org/registry/SYCL/specs/sycl-2020/html/sycl-2020.html#sec:headers-and-namespaces
introduces the backend specific headers "sycl/backend/<backend_name>.hpp"
CTS tests assume that if backend macro is defined (e.g. SYCL_BACKEND_OPENCL)
it is fully functional without extra includes. So the patch adds
include of the backend specific header when the backend is enabled.

The change should fix the recent massive failure of CTS tests with the error:
implicit instantiation of undefined template 'sycl::interop<sycl::backend::opencl, sycl::platform>'

https://www.khronos.org/registry/SYCL/specs/sycl-2020/html/sycl-2020.html#sec:headers-and-namespaces
introduces backend specific headers "sycl/backend/<backend_name>.hpp"
CTS tests assume that if backend macro is defined (e.g. SYCL_BACKEND_OPENCL)
it is fully functional without extra includes. So the patch adds
include of backend specific header when the backend is enabled.
@vladimirlaz vladimirlaz requested a review from a team as a code owner October 19, 2021 08:41
@vladimirlaz vladimirlaz requested a review from s-kanaev October 19, 2021 08:41
@vladimirlaz
Copy link
Contributor Author

/summary:run

@bader bader changed the title [SYCL] include BE specific header if exists [SYCL] Include backend-specific header if exists Oct 19, 2021
@vladimirlaz
Copy link
Contributor Author

/summary:run

@vladimirlaz
Copy link
Contributor Author

@s-kanaev, could you please review? SYCL-CTS tests have passed expectedly.

Co-authored-by: Mikhail Lychkov <mikhail.lychkov@intel.com>
@vladimirlaz vladimirlaz requested a review from mlychkov October 20, 2021 10:10
Copy link
Contributor

@s-kanaev s-kanaev left a comment

Choose a reason for hiding this comment

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

lgtm

@vladimirlaz vladimirlaz merged commit bc8a00a into intel:sycl Oct 20, 2021
@vladimirlaz vladimirlaz deleted the fix_interop_tests branch October 20, 2021 15:25
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