Skip to content

Intel GPU: Enable SYCL building system #1671

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

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

fengyuan14
Copy link

@fengyuan14 fengyuan14 commented Jun 5, 2025

SYCL is the programming solution dominated by Intel. SYCL has been adopted widely to enable compute kernels for Intel GPUs, such as PyTorch. CUDA has been a supported language in CMAKE, e.g. enable_langauge(CUDA). Unlike CUDA, SYCL requires more CMAKE codes to enable building system. The SYCL building system in the commit is the general part ported from PyTorch.

Usage:

  1. mkdir build && cd build
  2. cmake -DCOMPUTE_BACKEND=xpu [-DBUILD_TEST_SYCL=1] .. && make

BUILD_TEST_SYCL is an option for testing SYCL building system.

@fengyuan14 fengyuan14 marked this pull request as draft June 5, 2025 07:00
SYCL is the programming solution dominated by Intel. SYCL has been adopted widely to enable compute kernels for Intel GPUs, such as PyTorch.
CUDA has been a supported language in CMAKE, e.g. enable_langauge(CUDA). Unlike CUDA, SYCL requires more CMAKE codes to enable building system.
The SYCL building system in the commit is the general part ported from PyTorch.

Usage:
1. mkdir build && cd build
2. cmake -DCOMPUTE_BACKEND=xpu [-DBUILD_TEST_SYCL=1] .. && make
BUILD_TEST_SYCL is an option for testing SYCL building system.

Signed-off-by: Feng Yuan <[email protected]>
@matthewdouglas
Copy link
Member

Are there any particular kernels we expect to implement in SYCL directly in this repo? I haven't been expecting that we'd build SYCL code for XPU here, and instead would use ops exposed in IPEX, kernels in Triton, or plain PyTorch.

@matthewdouglas matthewdouglas added Low Priority (will be worked on after all priority issues) Waiting for Info Build labels Jun 5, 2025
@gujinghui
Copy link

Are there any particular kernels we expect to implement in SYCL directly in this repo? I haven't been expecting that we'd build SYCL code for XPU here, and instead would use ops exposed in IPEX, kernels in Triton, or plain PyTorch.

Hi @matthewdouglas ,

Thanks for comments.
We are going to remove IPEX dep from BnB for Intel GPU. The triton and pytorch ops will be options for non-gemm kernels.
But for gemm related kernels, we are going to provide SYCL path to provide better performance and reduced memory footprint.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Intel Low Priority (will be worked on after all priority issues) Waiting for Info
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants