-
Notifications
You must be signed in to change notification settings - Fork 788
[UR] Enable hwloc in UMF linux build #15261
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
Conversation
d8a76ff
to
94c1a73
Compare
7aa9690
to
dcc6761
Compare
dcc6761
to
2891f1e
Compare
2891f1e
to
c647376
Compare
Drafted until the UMF fix is pulled down to llvm via UMF update in UR. |
c647376
to
c6e5f06
Compare
Fix is now pulled down, ready for review. |
You should probably also update https://github.com/intel/llvm/blob/sycl/sycl/doc/GetStartedGuide.md (remove hwloc as a dependency that needs to be installed by the user) |
c6e5f06
to
f1fa58b
Compare
Right, now it will automatically be downloaded - deleted user requirement. |
sycl/doc/GetStartedGuide.md
Outdated
* `hwloc` version 2.3 or later (Linux only) | ||
* libhwloc-dev or hwloc-devel package on linux |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update UR to statically link hwloc v2.9.3 both on linux and Windows.
If I get the change right, the dependency on hwloc
still exists. The change removed the runtime dependency, but not the compile time dependency. Am I right?
This document describes the environment for DPC++ compiler developers, not DPC++ compiler users.
Your change seems to raise the version requirement. Please, update the hwloc
version to 2.9.3.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The hwloc
library will always be fetched from sources. Regardless of hwloc-dev
packages user has installed, the fetched version will be linked with the UMF library. That's why I remove hwloc
from this dependencies list, as the user-installed hwloc-dev
package will not be used by UMF.
If
llvm/.github/workflows/sycl-docs.yml Line 36 in 7cc9e80
|
f1fa58b
to
d54b9d2
Compare
The UMF library is required for allocation handling by default in UR, the user cannot opt-out, UR can't be built without UMF. There are two ways that UR gets UMF now. UMF is either fetched by UR or the user can force CMake to search for the installed UMF with
We don't release UMF prebuilt libraries as a part of open-source releases and there are no plans to do so. Users using UMF have to fetch it.
I don't fetch On the second hand, currently on Linux hwloc is a requirement of intel/llvm and CI seems to be ready for enabling hwloc in UMF Linux builds, I could verify that. So I propose to stick with having hwloc as a requirement in intel/llvm and not fetch it. |
AS @PatKamin said today UMF project does not distribute binaries. We can prioritize this discussion and estimate what should be done to distribute UMF in binary form. I agree that it might be a best option. Regarding why UMF is not optional, @PatKamin said that UR uses UMF to support memory pooling. Another reason is the interop between runtimes. UMF provides observability for other runtimes. For example, MPI uses UMF to get the memory properties of the memory allocated by SYCL applications. |
Does it mean that we need to redistribute our own version of |
8820401
to
3c4c41c
Compare
No, it's just one of the options. The other is to require the user to have hwloc installed. |
Reverted back changes with fetching hwloc. Leaving hwloc as a required dependency. Failing CI jobs also fail on other PRs, looks like these failures are not caused by changes in this PR. |
Thanks for educating me on the topic, @vinser52, @PatKamin.
What is the point of patching Do I understand correctly that we don't fetch |
The patch is needed to satisfy Coverity requirements in case hwloc is fetched and built as a static library.
In Windows we have to do the fetch and link statically with hwloc always: https://github.com/intel/llvm/blob/sycl/sycl/cmake/modules/FetchUnifiedRuntime.cmake#L129-L130 Please, note that I've minimized the changes in this PR recently. On current sycl branch, hwloc already is a required llvm dependency and is installed in intel/llvm CI environment. I've removed the fetching for Linux builds in favor of using the installed hwloc library to reduce the unnecessary overhead of hwloc fetch and build during llvm build. This will, however, require changes in the downstream CI environment, so I put this PR on draft until it's ready there. |
Changes wait for #17551 to be merged. |
3c4c41c
to
b9e9269
Compare
b9e9269
to
4effcff
Compare
@intel/unified-runtime-reviewers, please take a look - all tests passed. Changes are now minimal. |
@intel/llvm-gatekeepers, I think this PR is ready to merge |
It doesn't look like Alexey's concerns have been addressed so I'm going to hold off merge until he's confirmed he's okay with this. As a side note: the PR description doesn't do what it says |
I am getting the following error locally. Can it be related to this change?
|
The hwloc is required on Linux ( llvm/sycl/doc/GetStartedGuide.md Lines 47 to 48 in 0886791
|
This flag will be removed from UMF. Either `hwloc` installed in the system is used or it's fetched if not found. Ref.: #15261
Update UR to statically link UMF with hwloc on Linux.This will enable hwloc support in UMF on Linux.
Also, always use the v2.9.3 hwloc version for hwloc builds.