mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[PR #3153] [Engine] [SYCL] Qwen3.8-Flash-Next IQ2_XS single-B70 E2E preview #4482
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#4482
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/3153
Author: @xiangyuT
Created: 10/19/2026
Status: 🔄 Open
Base:
main← Head:preview/sycl-bmg-iq2xs-100tps-20261019📝 Commits (1)
cb43685sycl: preview integrated Battlemage IQ2_XS inference optimizations📊 Changes
35 files changed (+9890 additions, -202 deletions)
View changed files
📝
sycl/CMakeLists.txt(+43 -0)➕
sycl/include/b60_layout_host.hpp(+139 -0)➕
sycl/include/b60_layout_state.hpp(+29 -0)➕
sycl/include/b60_mtp_q8_cache.hpp(+14 -0)➕
sycl/include/b60_weight_cache.hpp(+12 -0)➕
sycl/include/private_mtp_demand.hpp(+38 -0)📝
sycl/include/strata/core/gguf_expert_source.hpp(+6 -1)📝
sycl/include/strata/core/verify.hpp(+6 -0)➕
sycl/include/strata/kernels/expert_staging.hpp(+16 -0)➕
sycl/include/strata/kernels/iq4_lut.hpp(+47 -0)➕
sycl/include/strata/kernels/iq_dequant.hpp(+20 -0)➕
sycl/include/strata/kernels/iq_signed_grid.hpp(+24 -0)➕
sycl/include/strata/kernels/q2_0_decode.hpp(+18 -0)➕
sycl/include/strata/kernels/qsa_decode_attn.hpp(+91 -0)➕
sycl/include/strata/kernels/qsa_prompt_attn_tla.hpp(+13 -0)➕
sycl/include/strata/kernels/verify_kernels.hpp(+9 -0)➕
sycl/include/strata/prefill/f16_expert_pair.hpp(+95 -0)➕
sycl/include/strata/prefill_copy_queue.hpp(+13 -0)➕
sycl/include/strata/workload_trace.hpp(+127 -0)📝
sycl/src/core/gguf_expert_source.cpp(+63 -1)...and 15 more files
📄 Description
3d1fb48090e8f2cefc22d7b5845fb7f5b71f33fa, measured previewc3ed1d047768d94f43d7384ccf740a214f5a53dd. Published PR headcb436853ab2ee238fa579a3a4f42a0412b46c439has identical engine/server source to that measured preview. Ubuntu 24.04.2 LTS, kernel 6.17.0-1007-intel; one Intel Arc Pro B70, 32 GB VRAM; Xeon w5-3435X, 16 CPU quota / 15 workers. Host RAM is 503.36 GiB usable; the example uses a 128 GiB container limit. Original Qwen3.8-Flash-Next GSQ/RCO IQ2_XS, quantization revisioned59f92082b1e93c0e96d60a8b11aab089b52f09; oneAPI 2026.1 / AOT bmg-g31; INT8 KV, 32K resident window, max context 131584, spec4/min-p0.5/suffix3, thinking off and vision disabled.--prefill auto --prompt-cache 0 --spec 4 --spec-min-p 0.5 --suffix-draft 3 --max-context 131584 --kv int8 --kv-resident 32768 --pcie-frac 0.30; for this B70 example upstream uses--expert-cache auto, preview--expert-cache 16000(B60 uses auto on both). Keep the documented model/profile, sampler and environment controls, including upstream's default ESIMD INT8autopath. Execute one short warmup and three fresh full-length warmups, followed by three fresh 32,768-input-token requests with a 256-token output cap, greedy/seed42 and no prompt-prefix reuse. Compare the same request sequence across arms using the client TTFT/TPOT definitions below. Full independent reproduction is pending publication of the sanitized prompt corpus and measurement harness.Current beta E2E comparison (2026-10-20)
B70 collection is complete: 32/64/128 GiB × five prompt lengths, 15 upstream/preview pairs, plus two 32K stability blocks; 96 measured requests in 32 blocks. All paired text and token-ID sequences match, including warmups. The 1K TTFT regression is retained. B60 collection is also complete: 128/32 GiB × five lengths, 10 pairs / 60 measured requests. Combined total: 25 paired configurations and 156 measured requests across 52 blocks.
Baseline: unmodified 0.2.0-beta / engine 0.1.45.3,
3d1fb48090e8f2cefc22d7b5845fb7f5b71f33fa. Measured preview:c3ed1d047768d94f43d7384ccf740a214f5a53dd; published PR headcb436853ab2ee238fa579a3a4f42a0412b46c439has identical engine/server source. Main observed during this retest (e88ee39d1d6be6e3364183af3b39b62a7ed6f211) has identical baseline engine/server source; it was not separately rebuilt.One B70, 32 GB VRAM, 16 CPU quota / 15 workers, fresh prompts, thinking off, greedy/seed42, spec4/min-p0.5/suffix3, 256 output tokens. Each cell is the mean of three measured requests, excluding one short and three full-length warmups. TTFT is dispatch to first nonempty answer delta; TPOT is first-to-last nonempty answer-delta interval divided by 255. Client tok/s = 1000 / mean(TPOT ms), distinct from engine decode throughput. Reductions use unrounded means; negative means a regression. Actual speculative work is recorded rather than forced equal.
B70, 128 GiB container RAM limit — complete five-length comparison
B70, 64 GiB container RAM limit — complete five-length comparison
B70, 32 GiB container RAM limit — complete five-length comparison
At 32K/128 GiB, baseline-after and an independent preview repeat also passed: baseline TPOT drift -0.0048%, TTFT drift -0.0083%; all three paired samples improved for both latency metrics in both preview blocks. Preview repeats measured 94.85 and 94.86 client tok/s.
B60, 128 GiB container RAM limit — complete five-length comparison
B60, 32 GiB container RAM limit — complete five-length comparison
B60 uses one 24 GB Arc Pro B60, AOT bmg-g21, TLA off, Xeon w9-3595X; a subsequent read-only host capture found 16×32 GiB DDR5, 8 populated channels / 2 DIMMs per channel, SMBIOS configured 4400 MT/s (DIMM rating 4800 MT/s). This hardware capture was made after the benchmark. B60 retains a 16-CPU quota / 15 workers,
--expert-cache autoon both arms, and a 32 GiB host-mirror budget. B70 uses the configuration above, including preview expert-cache 16000; these are per-host engine comparisons, not an isolated GPU comparison. All ten B60 paired text and token-ID sequences match, including warmups. The B60 1K TTFT regressions are retained: +12.12% at 128 GiB and +11.87% at 32 GiB. Both test containers were removed after exporting evidence.All 52 beta block startup logs (B70: 32; B60: 20) report
strata mtp: draft head over 106299 tokens (137.9 MiB). Both baseline and preview therefore used the standard draft-vocabulary subset; these results do not measure the full 248,320-token head or the 40,525-token English subset.RAM tiers above are container limits in GiB with shared model page cache retained; they do not establish minimum installed RAM. This is custom development characterization, not formal acceptance or an approved standard benchmark.
All 96 measured requests, median/range summaries and validation excerpts
Three samples per block; warmups are excluded from summaries. Engine decode rates here are the engine's reported rates, separate from client TPOT-based tok/s.
Sanitized per-request measurement fields (CSV):
Selected regression output, actually executed at
c3ed1d047768d94f43d7384ccf740a214f5a53dd:Observed upstream log excerpts at the 1K checkpoint:
Original complete request/stream records and warmups are retained. The complete sanitized prompt corpus, outputs and engine logs are not yet attached publicly; the fields and excerpts here are not a complete independent reproduction package.
All 60 B60 measured requests, median/range summaries and startup evidence
Three measured requests per block; warmups excluded. Client and engine throughput use the distinct definitions above.
Sanitized startup excerpt, present in both B60 arms at both RAM limits:
Current beta build, engine configuration and replay commands
Build/ctest executed. Launch/replay is reconstructed and source-checked only. Original timing/IPC helpers and frozen inputs await public attachment; independent reproduction is pending.
Use the pinned revisions and beta baseline frontend. Build:oneAPI2026.1; ggml headers:llama.cpp
3cf03257f219afbe7334045ff7c6a06ac68c627d:For B70 preview, add
-DSTRATA_SYCL_TLA_ATTN=ON -DSTRATA_SYCL_TLA_DIR=<SYCL_TLA>to configure. B60 uses AOTbmg-g21with TLA off. Existing selected checks (B70 preview):B70 preview JSON; resolve paths. Expose one GPU (logical0); share
<CALIBRATION_CACHE>across arms.B70 upstream: expert-cache auto; remove all STRATA_SYCL_* / STRATA_PRIVATE_* env keys, retaining the other ten. B60: both arms use expert-cache auto, STRATA_MIRROR_MIB=32768, gpu_order="as_given"; preview STRATA_SYCL_TLA_ATTN=0. Other fields match. Draft vocab106299. Container:16CPU/cpuset0–15; RAM tiers as tabulated, swap unrestricted, shared page cache retained.
Launch:
Restart per arm/RAM/length block; clear inherited STRATA_* before launch. After readiness, replay from the frozen payload directory:
Use N=1024/4096/8192/32768/131072. Exclude1–4, measure5–7; verify input/output counts, reuse0, length finish, text/token IDs. Timing definitions are above; curl alone does not measure them. Actual instrumented launcher:
python -I -B run_block.py --root <BLOCK_ROOT> --arm <N>-single --readiness-timeout 1200 --request-timeout 1200. Harness/corpus publication pending.Current source and validation (2026-10-20)
The source branch for this draft was rebased onto upstream
mainatf57c0adcb31c00f3f216550c004dac4e713a9f70; current PR head iscb436853ab2ee238fa579a3a4f42a0412b46c439. The rebase conflicts in prompt initialization and serving setup were resolved by retaining both upstream's ESIMD INT8 prompt/PCIe-auto setup and the preview's copy/pair headers and usage-counter binding.The new performance comparator is unmodified 0.2.0-beta / engine 0.1.45.3, commit
3d1fb48090e8f2cefc22d7b5845fb7f5b71f33fa. Latest observed upstreammain,e88ee39d1d6be6e3364183af3b39b62a7ed6f211, has identicalsycl/,src/,include/,serve/,data/and rootCMakeLists.txttrees; later differences concern documentation and release-matrix tests. This is source equality, not a claim that a separate latest-main binary was built.The upstream Battlemage ESIMD INT8 prompt-expert
autopath remains enabled in both arms. It uses the measured per-format crossover and FP16 fallback; INT8 activation quantization is upstream behavior, not a new optimization claimed by this preview. The comparator is a pure upstream source build with the documented custom serving settings, rather than a claim about untouched installer defaults. Baseline uses--expert-cache auto; preview uses--expert-cache 16000. UnderSTRATA_VERIFY_NO_HOST=1, the upstream log disables adaptive swaps; the preview explicitly enables its mirror-exchange path. Both retain fixed--pcie-frac 0.30rather than enabling PCIe-auto.Passed
c3ed1d047768d94f43d7384ccf740a214f5a53dd. The current head has byte-identical engine and server source trees;git range-diffshows the same preview patch after moving its base tof57c0adcb31c00f3f216550c004dac4e713a9f70. They are retained validation evidence, not a fresh CI run on the new commit.Failed
No failures were observed in the two clean engine builds or nine selected regression cases. This is not a full-suite pass claim.
Not run / pending
Contribution scope and limits
This remains a draft integration for E2E discussion, with the original performance issue at https://github.com/Niko1221/Strata/issues/3150. Maintainer agreement to merge this combined patch has not been obtained. It is not ready for normal merge review under the updated contribution rules.
In particular, although the packed single-actor path and mirror adaptation are opt-in, some older integrated controls (including IQ4 lookup and Q2 word expansion) still default on. An all-controls-off byte-identical default path has not been established. These must be reconciled with the opt-in/default-preservation rule in focused submissions, rather than claiming this whole preview already meets it.
If upstream agrees with the scope, the remaining work will be split into focused optimization PRs. A results-only benchmark submission and its sanitized raw evidence would be separate from engine changes. Existing measurements are custom community characterization with thinking off, greedy sampling and a 256-token cap; they do not implement the draft standard benchmark protocol and are not approved standard results.
Model used
ed59f92082b1e93c0e96d60a8b11aab089b52f09. This is the GSQ/RCO mixed-precision GGUF release, with per-tensor quantization types; IQ2_XS is the release name, not a claim that every tensor uses one uniform two-bit format.de4b8e4d43b917e7706784d8bb445c9af86a3540; speculation uses spec4 / min-p0.5 / suffix3. The benchmark is text-only, with thinking off and vision disabled.This measurement uses the original full-expert IQ2_XS release, rather than the pruned Coder model or the Swift/Unsloth alternatives.
Optimizations in the preview and existing upstream PRs
The first five rows map to our existing focused upstream submissions. The remaining rows describe additional work present in the preview; they do not claim that an earlier PR already contains those extensions. All five linked focused upstream PRs were confirmed open on 2026-10-20; status is not evidence that their changes were merged. The E2E table measures the combined configuration; individual PR percentages are not added together.
A control being enabled does not mean every shape-specific branch executes. These rows are an implementation inventory, not independent claims that every variant contributes to the measured gain.
Historical engine 0.1.45 tables, configuration and related-work notes (superseded)
Historical engine 0.1.45 summary and measurements
E2E report and discussion: https://github.com/Niko1221/Strata/issues/3150
This issue and the linked draft PR demonstrate end-to-end performance of the combined optimizations on the measured single-GPU workloads. The preview branch is a runnable integration snapshot for reproducing and discussing the result. It is not proposed as one patch to merge in full.
If upstream is interested in these results, the work will be split into individual optimization PRs, following the same approach as the focused submissions listed below. Each such PR can then be reviewed and validated independently, including its dispatch, fallback, correctness and performance scope.
The historical engine 0.1.45 run used one Intel Arc Pro B70 (32 GB VRAM), original Qwen3.8-Flash-Next IQ2_XS, 128 GiB container RAM limit. That preview measured 94.11–106.12 client tok/s across fresh 1K/4K/8K/32K/128K prompts. The 32K result is 98.13 tok/s, independently repeated at 98.11 tok/s. “~100 tok/s” describes the measured range; 32K and 128K remain below 100 tok/s.
K=1024. Each full request generates 256 tokens. Each configuration/length has three measured requests after one short and three full-length warmups. Thinking is off, seed42, no prompt-prefix reuse. TTFT is request submission to the first nonempty answer-text SSE delta; TPOT is the first-to-last nonempty delta interval divided by 255. Client tok/s is
1000 / mean(TPOT_ms). Reduction percentages use unrounded means:(upstream - preview) / upstream * 100; positive means lower latency.The pure upstream comparator is engine 0.1.45 at
477ac13cbe8e582c20484871ce459d20d82df09d, and the preview is based on the same commit. Both use identical inputs, sampler and fixed MTP parameters. Actual speculative work is allowed to vary and is not presented as equal-work kernel timing. All 35 paired requests in the completed 128 GiB series, including warmups, match text and token IDs. These are warmed E2E characterization results; model load and profiled requests are excluded. Shared model page cache was not flushed, so a container RAM limit is not a minimum installed-RAM claim.Related work and submission scope
This is a combined E2E demonstration for one Arc Pro B70, not a proposal to merge the whole preview as one change. If upstream is interested, we would split the remaining changes into focused PRs, following the earlier submissions, and coordinate with existing work first. The combined gain is not the sum of individual PR gains.
A 2026-10-19 review of upstream found related work below. We did not find another report with this same single-B70 IQ2_XS preview and the 1K–128K upstream/optimized TTFT/TPOT comparison. Existing single-B70 reports #2922 and #2867 use IQ3_S and IQ3_XXS respectively; #1054 includes older single-card IQ2_XS results within a two-card bug report. Their hardware, workloads and measurement boundaries differ, so their TPS are not direct comparators.
Our five linked focused upstream PRs were confirmed open on 2026-10-20. “No separate submission” refers only to this preview's remaining delta, not to an absence of related work. The scheduling proposal in issue #2416 is another complementary direction, not part of this preview.
Existing upstream foundations are not claimed as new preview work: Q6_K SWAR/planar/aligned loads from #2340 are already in the historical baseline. PR #2340 is now closed; its state does not change that source ancestry. IQ3_S wide #1774, grouped XMX #1711, and GR foundations #2193 / #2203 are also already present. The optional GR SOA, MTP Q8 SOA and IQ4 head SOA caches are disabled in the reported B70 configuration.
Historical engine 0.1.45 measured configuration
preview/sycl-bmg-iq2xs-100tps-20261019.3440db820d77cc7e71b4a30cc82e966290de1f2d, based on477ac13cbe8e582c20484871ce459d20d82df09d.bmg-g31, normal tracing disabled, optional TLA prompt attention enabled.Build and reproduce the preview
Use the Intel build environment described in
docs/INTEL.md, with oneAPI 2026.1 and local ggml headers at llama.cpp3cf03257f219afbe7334045ff7c6a06ac68c627d. For the optional TLA prompt path, provide a local sycl-tla header checkout; CMake requiresinclude/cute/tensor.hppandinclude/cute/atom/copy_traits_xe_2d.hppand does not fetch them automatically.Use the following engine arguments/environment and sampler, replacing angle-bracket paths with the existing model/checkpoint paths. The engine must run through the same single-client serving/SSE measurement path; plain
strata generateis not an equivalent reproducer for the guarded single-actor layout.The comparison uses fresh prompts, three measured requests per cell and four excluded warmups. Both sides use the same input and sampler settings; the pure upstream executable runs with its original dispatch and adaptation behavior.
Historical measurement scope
Additional B60 and B70 32/64 GiB results may be added after collection and review are complete. The historical performance claim covers the completed single-B70, 128 GiB matrix and its stated runtime configuration. Other models, Windows, multi-GPU and concurrent serving are outside that measurement scope.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.