oneapi-src / level-zero

oneAPI Level Zero Specification Headers and Loader
https://spec.oneapi.com/versions/latest/elements/l0/source/index.html
MIT License
208 stars 90 forks source link

Level-zero loader & dev packages missing from major distributions #73

Closed eero-t closed 1 year ago

eero-t commented 2 years ago

If something needs extra repositories and "wget'ing" package signing keys, "it does not exist".

IMHO Level-Zero (L0) loader should be present in the major distributions, so that applications using L0 can be developed and distributed by distributions, and those distributions can be used to containerize L0 apps, similarly to OpenCL. Please discuss this with the persons in major distributions who manage their compute / GPU related SW packaging.

For example if L0 misses next Ubuntu 22.04 LTS, it's going be further 2 years until it will be generally available for Ubuntu distributions and distros derived from it. To be part of an LTS, package needs to be there several months before it is released, for 22.04 LTS this means several months before April 2022.

PS. Distros like Debian & Ubuntu are already packaging Intel compute-runtime, so once L0 loader is in them too, I can file distro specific bugs to enable L0 support for compute-runtime builds, for L0 GPU backend.

bmyates commented 2 years ago

We don't have any immediate plans to get the loader in distro but are considering it.

We do have Intel repositories that contains all the relevant packages: https://dgpu-docs.intel.com/installation-guides/index.html

eero-t commented 2 years ago

Having the loader packages in the actual distribution repositories is blocker for getting applications using Level-Zero to the distributions, which can also be a blocker in getting Level-Zero support to upstream projects. Why they would feel any "urgency" to approve support for something "marginal enough" that it cannot be enabled in major distros?

As to the backend, once the frontend is in distros, the backend updates can be covered by distribution's HW enabling for long-term-support versions, where they backport package versions from newer distribution versions to older LTS versions, few months after each new distro version is released. Here's how it works: https://wiki.ubuntu.com/Kernel/RollingLTSEnablementStack

eero-t commented 2 years ago

We don't have any immediate plans to get the loader in distro but are considering it.

@bmyates 2 months have passed, any updates on this?

eero-t commented 2 years ago

Having the loader packages in the actual distribution repositories is blocker for getting applications using Level-Zero to the distributions,

I.e. customers would need to rebuild also the compute applications / libraries, in addition to installing newer driver packages from Intel repositories. Whereas with L0 being already in distro, distro version of e.g. Gromacs, could have L0 support enabled right out of the box.

(Now that OpenCL support is deprecated in Gromacs, and the new 2022 version OpenCL backend does not support acceleration for everything that Gromacs CUDA and SYCL backends do, this is getting a bit more urgent.)

which can also be a blocker in getting Level-Zero support to upstream projects

bmyates commented 2 years ago

We are continuing to discuss this internally. No update yet, but hopefully I will have some more details to share soon.

tjaalton commented 1 year ago

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1025760 https://salsa.debian.org/debian/level-zero

eero-t commented 1 year ago

@tjaalton Thanks!

compute-runtime seems to be missing it as a build dependency still: https://salsa.debian.org/opencl-team/intel-compute-runtime/-/blob/master/debian/control

After level-zero (frontend) headers are present, compute-runtime will automatically build level-zero backend, which provides implementation for the OneAPI APIs (exposed by the frontend): https://spec.oneapi.io/level-zero/latest/

Current compute-runtime project packaging puts it into a separate package, Debian should do the same.

tjaalton commented 1 year ago

well, the package is not reviewed yet, so it's on the NEW queue for now

eero-t commented 1 year ago

Fedora seems to have level-zero package now: https://src.fedoraproject.org/rpms/oneapi-level-zero

But it's compute package is also still missing level-zero dep: https://src.fedoraproject.org/rpms/intel-compute-runtime/blob/rawhide/f/intel-compute-runtime.spec

tjaalton commented 1 year ago

level-zero is now in Debian sid and Ubuntu lunar, and enabled in latest compute-runtime uploaded to sid earlier today

eero-t commented 1 year ago

level-zero is now in Debian sid and Ubuntu lunar, and enabled in latest compute-runtime uploaded to sid earlier today

@tjaalton Looking at what compute-runtime source package produces: https://salsa.debian.org/opencl-team/intel-compute-runtime/-/blob/master/debian/control

I noticed that it does not split level zero backend to another package package from the OpenCL package, like compute-runtime project's own packaging files do: https://github.com/intel/compute-runtime/blob/master/scripts/packaging/l0_gpu_driver/ubuntu_20.04/control

As L0 and OpenCL are both separate large APIs, with their own, separate frontends and backends, maybe same should be done also for upstream Debian / Ubuntu packaging?

PS. I was also wondering why L0 frontend binary package was amd64 only, until I realized that there might not be official Intel (discrete) GPU kernel driver support yet for anything anything else, which would be needed for backends to work on non-Intel platforms. On quick googling, I found only preliminary patches for such support.

eero-t commented 1 year ago

According to @frantisekz, Level Zero is now enabled in Fedora 38 and 39 for compute-runtime, meaning the backend is finally there also for Fedora.

PS. I was also wondering why Debian L0 frontend binary package was amd64 only, until I realized that there might not be official Intel (discrete) GPU kernel driver support yet for anything anything else, which would be needed for backends to work on non-Intel platforms.

Support for other architectures comes with the Xe kernel driver: https://patchwork.freedesktop.org/series/112188/

eero-t commented 1 year ago

I'm closing this now that L0 support is in already released Fedora, Ubuntu (23.04) and (new) Debian stable releases.

(IMHO it would have been better if Debian & Ubuntu would have had the L0 backend in its own package like Fedora did, so that programs depending just on L0, would not redundantly bring in also OpenCL, and vice verse. They both are going to grown when support for new HW & APIs are added to them.)

tjaalton commented 1 year ago

I'm closing this now that L0 support is in already released Fedora, Ubuntu (23.04) and (new) Debian stable releases.

(IMHO it would have been better if Debian & Ubuntu would have had the L0 backend in its own package like Fedora did, so that programs depending just on L0, would not redundantly bring in also OpenCL, and vice verse. They both are going to grown when support for new HW & APIs are added to them.)

fixing it now, but pending on compute-runtime build getting fixed with gcc13 https://github.com/intel/compute-runtime/issues/669