AISpot

llama.cpp SYCL 後端修復 CONV_2D 錯誤結果並支援 CWHN 佈局

llama.cpp releases版本更新地端推論開源

llama.cpp 的 SYCL 後端修復了 CONV_2D 在非連續輸入下靜默算錯的問題,並新增對 CWHN 通道序佈局的支援。此前 supports_op 聲稱支援任意佈局,但卷積 kernel 按連續的 [W, H, C, N] 索引,CWHN 等排列的輸入會被用錯誤偏移讀取;現在改為與 CUDA 後端約定一致,對輸入和卷積核的連續性做校驗。

原標題:b11815
閱讀原文

評分32 / 40(平均 36,門檻 60)
狀態未入選

原文

sycl: fix CONV_2D wrong results for non-contiguous input ( #30363 ) sycl: fix CONV_2D wrong results for non-contiguous input The kernel indexes the input as a contiguous [W, H, C, N] tensor, but supports_op claimed the op for any layout. A non-contiguous (e.g. CWHN permuted) input was read with the wrong element offsets, silently producing wrong results. Gate the CONV_2D op on input and kernel contiguity, matching the CUDA backend contract, and assert input contiguity in the op. test-backend-ops -b SYCL0 -o CONV_2D : goes from 16 failures to 0, none. 2006/2006 tests passed Backend SYCL0: OK Backend 2/2: CPU Skipping 2/2 backends passed OK Assisted-by: pi (unsloth/Qwen3.8-27B-GGUF:Q4_K_M via llama.cpp) sycl : CONV_2D cwhn=1 support Make the SYCL backend compute GGML_OP_CONV_2D correctly for cwhn=1 (CWHN channel-order) inputs and kernels, so the previously failing test- backend-ops CONV_2D cases pass on SYCL instead of being skipped or miscomputed. Implement CWHN layout support in ggml/src/ggml-sycl/conv2d.cpp ( ggml_sycl_op_conv2d ). Update SYCL supports_op for GGML_OP_CONV_2D in ggml/src/ggml-sycl/ggml-sycl.cpp to accept both layouts. Assisted-by: pi (Greatjedi/Qwen3.8-27B-Intel-Arc-Tuned-GGUF via llama.cpp) sycl docs : update ops for SYCL Website: https://llama.app Attestations: https://github.com/ggml-org/llama.cpp/attestations/58574646 macOS/iOS: macOS Apple Silicon (arm64) macOS Apple Silicon (arm64, KleidiAI enabled) DISABLED macOS Intel (x64) iOS XCFramework Linux: Ubuntu x64 (CPU) Ubuntu arm64 (CPU) Ubuntu s390x (CPU) Ubuntu x64 (Vulkan) Ubuntu arm64 (Vulkan) Ubuntu x64 (CUDA 12) - CUDA 12.8 libraries Ubuntu x64 (CUDA 13) - CUDA 13.4 libraries Ubuntu arm64 (CUDA 13) - CUDA 13.4 libraries Ubuntu x64 (ROCm 10.0) Ubuntu x64 (OpenVINO) Ubuntu x64 (SYCL FP32) Ubuntu x64 (SYCL FP16) Linux arm64 (Snapdragon: CPU, Adreno GPU, Hexagon NPU) - setup guide Android: Android arm64 (CPU) Android arm64 (Snapdragon: CPU, Adreno GPU, Hexagon NPU) - setup guide Windows: Windows x64 (CPU) Windows arm64 (CPU) Windows arm64 (OpenCL Adreno) Windows x64 (CUDA 12) - CUDA 12.4 DLLs Windows x64 (CUDA 13) - CUDA 13.4 DLLs Windows arm64 (CUDA 13) - CUDA 13.4 DLLs Windows x64 (Vulkan) Windows arm64 (Vulkan) Windows x64 (OpenVINO) Windows x64 (SYCL) Windows x64 (ROCm 10.0) openEuler: DISABLED openEuler x86 (310p) openEuler x86 (910b, ACL Graph) openEuler aarch64 (310p) openEuler aarch64 (910b, ACL Graph) UI: UI

相關報導

llama.cpp releasesAI 評分42

llama.cpp 修復 SYCL 混用不同型號 GPU 的 FA 問題

llama.cpp 合併 PR #29071,修復 SYCL 後端在 Flash Attention(FA)中混用不同型號 GPU 時出現的問題。改動位於 ggml/src/ggml-sycl/ggml-sycl.cpp,提交由 Georgi Gerganov 共同署名。該修復包含在版本 b11464 中,此版本同時提供 Ubuntu x64(SYCL FP32、FP16)與 Windows x64(SYCL)等建置。

llama.cpp releasesAI 評分43

llama.cpp 修復 ggml conv_1d 批次輸入轉置錯誤

llama.cpp 修復了 ggml conv_1d 在批次輸入下輸出通道與批次維度錯位的問題。conv_1d 背後的 GEMM 把 batch 折進行,結果在記憶體中是 [OL, N, OC],reshape 卻宣告為 [OL, OC, N],形狀正確但內容被轉置,因此不報錯、通道與批次交錯;N==1 時兩種讀法等價,倉庫裡三個 vocoder 都沒觸發。

llama.cpp releasesAI 評分37

llama.cpp 修復 OpenCL 非連續檢視 CLAMP 計算錯誤

llama.cpp 為 OpenCL 後端新增跨步核心 kernel_clamp_nc,修復輸入為非連續(strided)檢視時 CLAMP 讀錯元素的問題。原 clamp 核心把源與目標當作一維連續陣列索引,遇到新增的 CLAMP v=1 情形會取錯資料;現在源不連續時自動改用新的 strided 核心,與其他一元運算元的做法保持一致。

llama.cpp releasesAI 評分40

llama.cpp b11693 修復 SYCL 後端 mul_mat 記憶體錯誤

llama.cpp 發布建置 b11693,核心改動是修復 SYCL 後端在 mul_mat、split buffer 和 host pool 中的記憶體錯誤(PR #29889)。該版本同時更新了預編譯產物清單,覆蓋 macOS/iOS、Linux、Windows、Android,包含 CUDA 12/13、Vulkan、ROCm 10.0、OpenVINO 以及 SYCL FP32/FP16 等後端。

llama.cpp releasesAI 評分40

llama.cpp 發布 b11750,修復 SYCL 編譯警告

llama.cpp 發布 b11750 建置,主要變更是修復 SYCL 後端程式碼的編譯警告,包括缺失的函式原型、死程式碼與多餘分號(#30271)。同時照例提供全平台預編譯包,覆蓋 macOS Apple Silicon、iOS XCFramework、Ubuntu 的 CPU/Vulkan/CUDA 12 與 CUDA 13/ROCm 10.0/OpenVINO/SYCL FP32 與 FP16 建置,以及 Android、Windows 的 CPU、CUDA、Vulkan…