mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[PR #1472] [CLOSED] Intel Arc A770 (DG2, 16 GB) support in the SYCL port #3478
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#3478
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Niko1221/Strata/pull/1472
Author: @samsonnguyen
Created: 10/8/2026
Status: ❌ Closed
Base:
main← Head:a770-upstream-pr📝 Commits (10+)
4e4d8e9sycl: STRATA_SYCL_NO_XMX option for GPUs without a working joint_matrix pathb7c8407sycl: read free VRAM from Level Zero Sysman when the SYCL aspect is missing4ac1d7bsycl: allocate the pinned expert mirror in chunks748e949sycl: STRATA_SYCL_LARGE_BUFFERS: compile for buffers over 4 GiB8069c20sycl: publish a GGUF ring slot only after its read has finishedcd42647sycl: mirror the resident experts too when adaptive swaps are on454d799sycl: expert cache laid out in reverse; prompt loans capped under 4 GiB07bbd61sycl: a device wait that gives up is an error, and says which flag54300f7sycl: count the routed experts on the GPU so the adaptive tier runs in GPU-only mode44c53aasycl: serve Q6_K from blocks padded to 224 bytes: GPU-only decode 9.77 -> 10.37 tok/s📊 Changes
35 files changed (+1453 additions, -197 deletions)
View changed files
📝
docs/INTEL.md(+6 -0)➕
docs/INTEL_A770.md(+276 -0)➕
docs/INTEL_A770_ISSUES.md(+126 -0)📝
include/strata/core/expert_cache.hpp(+24 -3)➕
include/strata/core/expert_cache_layout.hpp(+51 -0)📝
sycl/CMakeLists.txt(+14 -1)📝
sycl/include/dpct/device.hpp(+29 -2)📝
sycl/include/strata/core/gguf_expert_source.hpp(+3 -3)📝
sycl/include/strata/core/session.hpp(+2 -1)📝
sycl/include/strata/core/verify.hpp(+1 -0)➕
sycl/include/strata/kernels/cache_hit.hpp(+18 -0)📝
sycl/include/strata/kernels/native_mmvq.hpp(+6 -0)📝
sycl/include/strata/kernels/resident_plan_mirror.hpp(+6 -0)📝
sycl/include/strata/sycl_queue.hpp(+7 -2)➕
sycl/include/strata/sycl_wait_timeouts.hpp(+24 -0)➕
sycl/include/strata/wait_timeout_registry.hpp(+46 -0)📝
sycl/src/core/expert_cache.cpp(+41 -5)📝
sycl/src/core/expert_source.cpp(+4 -2)📝
sycl/src/core/gguf_expert_source.cpp(+61 -38)📝
sycl/src/core/native_dense.cpp(+14 -4)...and 15 more files
📄 Description
Title
Intel Arc A770 (DG2, 16 GB) support in the SYCL port
Issue: Resolves #692
The Alchemist cards on
xedrivers have some weird bugs, which unfortunately need to be worked around. I've tried to ensure that these flags don't affect builds for other cards, and documented the issues i ran into.Summary
The SYCL port was written for the Arc Pro B70. This makes it build and run correctly on an Arc A770 (Alchemist,
xedriver, 16 GB) with the Qwen3.8-Flash-Next IQ3_XXS model, plus a few engine fixes the A770 exposed. Everything is additive or gated to the cases that need it (a build option, an env switch, or a memory size above 4 GiB).Measured on an A770 (xe driver, forced probe), Xeon E5 v4 host (PCIe 3.0 x16, AVX2 only), Ubuntu 26.04, kernel 7.0, oneAPI 2026.1, engine 0.1.40.3, Qwen3.8-Flash-Next IQ3_XXS,
--stream-experts --expert-cache 5000 --vram-reserve-mib 1280 --kv int8 --spec 4 --mtp,STRATA_VERIFY_DEVICE_PLAN=1 STRATA_VERIFY_NO_HOST=1, greedy, 128 new tokens:Not measured here: the B70 or any other card, the parity tests (built with
STRATA_SYCL_PARITY=OFF), models other than IQ3_XXS (and, earlier, the Coder IQ1_M).What changed
-DSTRATA_SYCL_NO_XMX=ON: compiles thejoint_matrixkernels out. IGC for dg2 dies with a floating point exception on them.dpct::get_memory_infoasks Level Zero Sysman when the SYCL aspect is missing (xe reports nothing, so--expert-cache autosaw 0 bytes).-DSTRATA_SYCL_LARGE_BUFFERS=ON(-ze-opt-greater-than-4GB-buffer-required): without it, a kernel reading an expert more than 4 GiB into the cache read garbage.STRATA_CACHE_REVERSE, automatic when the arena is over 4 GiB): oneMKL's bf16/f16 GEMM returns zeros when an input matrix starts 4 GiB or more into an allocation, so a prompt of about 1.5k tokens or more decoded to token 0 when the prompt path borrowed cache slots. The coldest slots now sit at the lowest addresses, the loan is the tail of the cache and capped at 3.9 GiB, and the kernels reading slots take per-slot device offsets. Reproducer:sycl/tests/repro/mkl_gemm_4gib.cpp; host test:sycl/tests/expert_cache_reverse_test.cpp.STRATA_WAIT_TIMEOUT=warnonly reports,STRATA_SPIN_MAXsets the bound). Before, the window went on with data the host had not written and the recurrent state kept the garbage.resident_plancounts routed experts on the device, so the adaptive swaps run withSTRATA_VERIFY_NO_HOST(hit rate 33% to 87% on the Coder IQ1_M), and a swap victim is only taken if it can be re-read from a pinned mirror.STRATA_Q6K_REPACK=1, off by default): aligned weight loads in the decode mmvq kernel. +6% GPU-only decode on the Coder IQ1_M (9.77 to 10.37 tok/s); no measurable change on IQ3_XXS (17.5 against 17.2).mmvq_bench --selftestchecks it against the GGUF layout.STRATA_VERIFY_NO_HOSTis set: nothing waits on a host store in that mode, and the uncached allocation cost 42 ms per decode window on the A770 (13.1 against 17.5 tok/s). Uncached allocation is unchanged in every other mode, andSTRATA_HOST_UNCACHED=0still turns it off.docs/INTEL_A770.md(bring-up, what differs from the B70, measurements) anddocs/INTEL_A770_ISSUES.md(the driver, runtime and compiler problems found, with workarounds), and a pointer indocs/INTEL.md.Extra Notes
IGC_EnableDPEmulation=1 OverrideDefaultFP64Settings=1at build time (no fp64 in hardware; the engine uses double on purpose) andUR_L0_ENABLE_RELAXED_ALLOCATION_LIMITS=1 ZES_ENABLE_SYSMAN=1at run time. Details are indocs/INTEL_A770.md.-DSTRATA_SYCL_SPIN_MAX=20000; the default for a non-B-series AOT build (2,000,000 polls) is what a plain build gets.🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.