Skip to content

Fix build break with open-source intel/llvm DPC++ #876

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 4 commits into from
Aug 8, 2022

Conversation

oleksandr-pavlyk
Copy link
Contributor

@oleksandr-pavlyk oleksandr-pavlyk commented Aug 6, 2022

Due to change in intel/llvm#6467 the build of SYCLInterface library is failing when using nightly sycl_bundle of intel/llvm DPC++.

This PR uses __SYCL_COMPILER_VERSION to keep both current oneAPI DPC++ and intel/llvm DPC++ working when compiling the library.

Note that sycl::device::info::max_work_item_sizes parameter is no longer in the SYCL 2020 spec rev 5, instead one should use sycl::device::info::max_work_item_sizes<1>, sycl::device::info::max_work_item_sizes<2>, sycl::device::info::max_work_item_sizes<3> and hence dpctl interfaces must be updated at some point.

  • Have you provided a meaningful PR description?

@github-actions
Copy link

github-actions bot commented Aug 6, 2022

@oleksandr-pavlyk oleksandr-pavlyk force-pushed the fix-intel-llvm-build-break branch from ce9e502 to d161ab2 Compare August 6, 2022 21:14
@coveralls
Copy link
Collaborator

coveralls commented Aug 6, 2022

Coverage Status

Coverage decreased (-0.06%) to 81.803% when pulling 81a14dc on fix-intel-llvm-build-break into 09de29b on master.

@oleksandr-pavlyk
Copy link
Contributor Author

I wonder if it makes sense to define dpctl.SyclDevice.max_work_item_sizes1d, dpctl.SyclDevice.max_work_item_sizes2d and dpctl.SyclDevice.max_work_item_sizes3d alongside dpctl.SyclDevice.max_work_item_sizes and deprecate the latter.

For older compilers the 1d, 2d version would simply take the first and the first two entries from the triplet returned by max_work_item_sizes.

@oleksandr-pavlyk oleksandr-pavlyk force-pushed the fix-intel-llvm-build-break branch from d161ab2 to 52254ea Compare August 6, 2022 21:35
dpctl.SyclDevice.max_work_iterm_sizes is deprecated.
Reflactor common duplicated fixtures for device properties checks
out into a common file made available to both `test_sycl_device.py`
and `test_sycl_queue.py` via `conftest.py` per

https://stackoverflow.com/questions/13641973/how-and-where-does-py-test-find-fixtures

MaxWorkItemSizes1d, MaxWorkItemSizes2d and MaxWorkItemSizes3d properties
are added.
@oleksandr-pavlyk
Copy link
Contributor Author

@diptorupd I have implemented dpctl.SyclDevice.max_work_item_sizes1d and high dimensional analogs. The dpctl.SyclDevice.max_work_item_sizes issues Python warning.

The DPCTLDevice_GetMaxWorkItemSizes also carries deprecation warning.

Frankly, I dislike introducing these warnings. I'd say we should just remove them. It is not used in dpnp, numba_dpex so I think it should be safe to do.

@oleksandr-pavlyk oleksandr-pavlyk force-pushed the fix-intel-llvm-build-break branch 2 times, most recently from ed34668 to 81a14dc Compare August 8, 2022 12:24
@oleksandr-pavlyk
Copy link
Contributor Author

oleksandr-pavlyk commented Aug 8, 2022

Ok @diptorupd , I think I am going to merge this to fix build with intel/llvm DPC++ and address your feedback in a separate PR.

@oleksandr-pavlyk oleksandr-pavlyk merged commit d2da805 into master Aug 8, 2022
@oleksandr-pavlyk oleksandr-pavlyk deleted the fix-intel-llvm-build-break branch August 8, 2022 18:56
@github-actions
Copy link

github-actions bot commented Aug 8, 2022

Deleted rendered PR docs from intelpython.github.com/dpctl, latest should be updated shortly. 🤞

@oleksandr-pavlyk oleksandr-pavlyk mentioned this pull request Aug 10, 2022
5 tasks
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.

2 participants