intel / intel-graphics-compiler

Other
606 stars 158 forks source link

Intel HD Graphics and WSL/WSL2 #158

Closed vrpascuzzi closed 3 years ago

vrpascuzzi commented 3 years ago

Sorry in advance if here is the incorrect place to report this.

System

Problem Intel HD Graphics setup/configuration in WSL/WSL2. Related to intel/compute-runtime #300.

Process Installed NVIDIA CUDA Quadro for WSL drivers for Windows 10 and followed instructions for CUDA on WSL to configure an Ubuntu distro. Built and ran a simple CUDA app -- everything works fine. Instructions from NVIDIA are very clear. Intel is a different story. Installed Intel beta drivers and followed Intel's GPGPU setup instructions for Ubuntu 20.04. Built a simple app with oneAPI went smoothly but ran into a runtime error when selecting Intel iGPU:

$ ./test_sycl
terminate called after throwing an instance of 'cl::sycl::runtime_error'
  what():  No device of requested type available. Please check https://software.intel.com/en-us/articles/intel-oneapi-dpcpp-compiler-system-requirements-beta -1 (CL_DEVICE_NOT_FOUND)
Aborted

Selecting default/CPU device things are fine:

$ ./test_sycl
Running on: Intel(R) Core(TM) i7-10875H CPU @ 2.30GHz
<...>

I get the same result when using WSL and WSL2.

Anyone able to get Intel HD Graphics (iGPU) working in WSL/WSL2? Do I need to build intel-graphics-compiler and compute-runtime from their respective repos?

PiotrRozenfeld commented 3 years ago

Intel® Graphics BETA WSL Windows® 10 DCH Drivers that you reference above provide DirectML functionality. OpenCL and Level Zero support for WSL is coming soon - stay tuned.

paigeale commented 3 years ago

Duplicate of https://github.com/intel/compute-runtime/issues/391

Closing as to have one issue

fedecompa commented 1 month ago

I have a similar problem. I installed all the packages from Intel OneAPI link. On Windows 11 all works fine and the VideoProcessor Intel(R) UHD Graphics can be used from OpenVINO libraries. On the contrary on WSL2 with the Ubuntu 22.04 distro I see no GPU:

clinfo clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU) No devices found in platform

sycl-ls [opencl:cpu][opencl:0] Intel(R) OpenCL, Intel(R) Core(TM) i7-10850H CPU @ 2.70GHz OpenCL 3.0 (Build 0) [2024.18.7.0.11_160000]

https://www.intel.com/content/www/us/en/docs/oneapi/installation-guide-linux/2023-0/configure-wsl-2-for-gpu-workflows.html