Repository navigation
Run YuE2 on the SYCL backend - #1243
Merged
Merged
Conversation
This was referenced Nov 9, 2026
Owner
|
@newjordan Will review tomorrow. Could you rebase? |
- NAR: add the timestep vector with ADD broadcasting on SYCL instead of materializing it with REPEAT first. Other backends keep repeat + add. - NAR attention: SYCL flash attention reads Q through its strides, so skip the Q ggml_cont there. Other backends are unchanged. - DepthwiseConv1dModule: SYCL has no CONV_2D_DW kernel. A pre-padded stride-1 depthwise conv is the same per-channel correlation as SSM_CONV, so use that on SYCL. - AR: F16 KV storage on SYCL, as on CUDA, HIP and Vulkan. - Unit tests for the NAR conditioning and attention layout helpers. Every change is gated to BackendType::Sycl; CUDA output is byte-identical before and after. The cuda_perf preset is not backend-gated and applies on SYCL unchanged.
Attention over a whole song is what makes NAR slow, and the prompt state is recomputed for every chunk. These controls bring YuE2 on SYCL to the speed of its best measured configuration: - yue2.nar_window_frames / yue2.nar_overlap_frames cap the NAR chunk length and crossfade consecutive chunks in latent space. - yue2.nar_prefix_cache computes the AR state of the prompt once and reuses it, unrounded, for every chunk. - yue2.compact_kv starts with a KV capacity that fits the stage instead of 5120 tokens, since decode attention scans the whole capacity. - yue2.perf_mode=sycl_perf enables them together and is the SYCL default. Other backends keep their existing defaults.
newjordan
force-pushed
the
pr/yue2-sycl-champion
branch
from
November 9, 2026 14:11
dc48bb0 to
3d2227c
Compare
Contributor
Author
|
Rebased onto |
Owner
|
@newjordan PR merged. Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
YuE2 at 2.98x realtime on an Arc Pro B70, up from 1.75x with enablement alone, with no flags or environment variables. 3.02x with the opt-in weight cache.
Runs YuE2 on
--backend sycl. On SYCL, YuE2 defaults to a newsycl_perfpreset. Other backends keep their existing defaults.yue2.nar_window_framesandyue2.nar_overlap_framescap the NAR chunk length, since attention cost grows with its square, and crossfade consecutive chunks in latent space. Windowing changes the output.yue2.nar_prefix_cachecomputes the AR state of the prompt once instead of once per chunk.yue2.compact_kvsizes the AR KV to the stage instead of 5120 tokens, because decode attention scans the whole capacity. Longer songs refill.yue2.perf_mode=sycl_perfenables them together.yue2.perf_mode=offruns without it, and each control can be set on its own.Measurements
Arc Pro B70, oneAPI 2026.1, Linux,
yue2-3b-q8_0.ggufandyue2-vae-f16.gguf. city_lights, seed 831001, 8 NAR steps,cot=full, one warmup then 3 measured takes. All rows are built withGGML_SYCL_F16=ON.cuda_perf, without the ggml-sycl kernels or this tuningperf_mode=offperf_mode=cuda_perfsycl_perf)GGML_SYCL_WEIGHT_F16_CACHE=1Each row is the median of 3 takes after one warmup, on an otherwise idle machine.
Validation
perf_mode=off,perf_mode=cuda_perf, and the graph, oneDNN attention and weight-cache opt-outs.ctest: passes exceptkaldi_fbank_sparse_testandmel_spectrogram_frontend_test, which fail the same way on unmodifiedmainbuilt with icx and pass with gcc.mainwith perf off and withcuda_perf. The full model set builds andctestis 108/108 with 1 skip (torch_random_cuda_multi_device_test).Limitations
Tested on one Intel GPU, the Arc Pro B70, on Linux. Peak VRAM is 8.6 GiB there by default.