mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #4547] [Engine] Arc Pro B70: the int8 prompt-expert default (STRATA_PREFILL_MMQ unset = auto) reads a 6.3k prompt 15 % slower than the FP16 chain, and its per-start crossover (32 to 154 rows) changes the greedy answer between starts #2055
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#2055
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?
Originally created by @otaliptus on GitHub (Oct 28, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/4547
Area
[Engine]
Desktop app, Terminal or source?
Source
What happened
Updating a B70 install from the v0.1.45 source build to the v0.2.6 one (engine 0.1.51), I compared the two engines on the same server config with
tools/ab_engine.py(greedy, 256 new tokens, alternating fresh engines; per round the tool's three chats of 27-34 tokens plus one 6,345-token prompt; then a 21,102-token prompt). Decode was unchanged. Prompt reading with the new Battlemage default (STRATA_PREFILL_MMQunset = auto) was slower than the old engine, and its greedy answers changed from start to start.6,345-token prompt, Qwen3.8-Flash-Next IQ3_S,
--prefill 4096, one row per engine start:STRATA_PREFILL_MMQ=off(FP16 chain)STRATA_PREFILL_MMQ=121,102-token prompt: 0.1.45 1394, 1397;
off1400, 1405;=11431, 1431 (its answer differs from FP16 but is the same at both starts);=1with--prefill 81921322, 1145, with decode afterwards 3-7 % lower. Decode after the 6.3k prompt: FP16 46.7-46.8, auto 46.2-47.6,=149.2 tok/s.So on this card the auto default is the slowest of the three at these prompt sizes (15 % behind FP16 at 6.3k) and the only one whose greedy output is not repeatable.
=1is the fastest (+4.5 % at 6.3k, +2.5 % at 21k) and repeatable; the FP16 chain is byte-identical to 0.1.45, and again to itself on the v0.2.7.1 build (32 of 32 requests). I did not measure 1K or 4K prompts, where the 0.2.0 release notes measured the gain.Why the answers vary: the crossover is measured at every start, and the measurement is not stable. The engine line over 11 starts on this card, same device string:
Crossovers seen: 32, 40, 40, 40, 41, 72, 149, 151 rows (and 139, 151, 154 on three starts whose device string ends
|22|20|640x2560). The FP16 timings are steady (36.4-36.6 us at 64 rows); the int8 timing at 64 rows swings between 31 and 45 us. Which groups take int8 therefore differs per start, and with it the rounding and the greedy answer.The cache that should make this a one-time measurement (
~/.cache/strata/i8-crossover.txt,STRATA_CACHE_DIRmoves it, docs/INTEL_INT8_EXPERTS.md) is written inside the container thatstrata-sycl.shstarts with--rm -u $(id -u). That home is not a mounted volume (the only mounts are the repo's parent as/workand/dev/shm), so nothing persists and every start measures again.The engine's advice line
STRATA_PREFILL_MMQ=0 turns them offcannot be followed through the launcher, which drops a value of 0 (#4546);offworks.Suggestions, in the order I would try them: (1) let the launcher set
STRATA_CACHE_DIRto a folder under/workso the crossover persists and starts are repeatable; (2) measure the crossover more robustly (repeats, median: the int8 timings at 64 rows are the unstable ones); (3) on this card either the FP16 chain or=1would be a better default than auto at prompts of this size: both are repeatable and both were faster than auto here.Smallest steps or command that reproduce it
grep crossoverin the engine log gives different numbers.prompt_per_secondabout 1,110 and answers of different length. The same with"env": {"STRATA_PREFILL_MMQ": "off"}: about 1,315 and the same answer at every start.Reproduction status
Reproduced locally
Strata version
Measured on the v0.2.6 source build (engine 0.1.51) on 2026-10-26;
sycl/src/prefill/prefill.cpp,sycl/include/strata/prefill/esimd_moe.hppand the launcher are unchanged in v0.2.7.1 (46c152a1) and on main today. On v0.2.7.1 (engine 0.1.53) I ran the FP16 chain only.Graphics card, memory and system
Intel Arc Pro B70 32 GB · 62 GB RAM · Debian 13 (kernel 7.2.6, xe driver) · engine in the strata-sycl-dev container (oneAPI 2026.1; compute runtime 1.17.39758+10 as the engine prints it)
Model, size and settings
Qwen3.8-Flash-Next GSQ-RCO IQ3_S native pack,
--stream-experts,--prefill 4096,--kv int8 --kv-resident 32768, 262144 context,--spec 4with the MTP drafter, pictures off. Greedy, 256 new tokens.Logs
The crossover lines above come from the engine logs of the auto starts; I can attach the full logs of the four auto starts and the
ab_engine.pyjsonl if useful.@Niko1221 commented on GitHub (Nov 5, 2026):
Thanks for taking the time to report this.
Strata has changed a lot since this was opened, and 0.2.11 is out now, so many older reports no longer apply. We're closing issues older than a week that have had no new reports in the last week. Closed here does not mean rejected.
To reopen it takes about two minutes:
/reopen. A check runs and either reopens the issue or lists what is still missing.The rules are in CONTRIBUTING.md.
@otaliptus commented on GitHub (Nov 6, 2026):
Re-tested on 2026-11-05 after the 0.2.11 release. The SYCL prompt path (
sycl/src/prefill/prefill.cpp,sycl/src/prefill/gemm.dp.cpp,sycl/include/strata/prefill/esimd_moe.hpp) andsycl/serve/strata-sycl.share byte-identical between v0.2.10 and v0.2.11, so I ran this on the engine built from v0.2.10 (0.1.56) on the same B70 (32 GB, 62 GB RAM, Debian 13, strata-sycl-dev container). Not asking to reopen: the two main points of the report no longer reproduce here.strata-sycl.shsetsSTRATA_CACHE_DIR=/work/.strata-cachesince commit8dcda377(2026-10-31, from PR #3248), so the crossover now outlives the--rmcontainer. The cache file here holds six keys for this card (one per|a|b|shape in the key: crossovers 85.7 to 232.7 rows, three of the six flagged "not clear"), so each new config shape is measured once and then read back ("crossover 233 rows per expert (not clear) from the cache").tools/ab_engine.py, the same config minus its env block (Qwen3.8-Flash-Next IQ3_S,--prefill 4096, DFlash2 drafter, greedy, 256 new tokens, 2 rounds, a fresh engine per start, alternating): the 6,345-token prompt read at 1254.7 tok/s on the auto start that measured the crossover (the measurement is inside that prompt's time) and 1728.0 tok/s on the auto start that read it from the cache;STRATA_PREFILL_MMQ=offread it at 1614.7 and 1604.2. Decode after the prompt: auto 50.3 / 50.3, off 49.3 / 49.2 tok/s; the three short chats were identical in both arms (68.4, 54.8, 52.7 tok/s). So with a warm cache, auto was about 7 % faster than the FP16 chain at 6.3k here (one start each). The -15 % above was measured on 0.1.51, where every start measured again.offgave 149 tokens both times (the answer the FP16 chain has given since 0.1.45). What remains of point 2: the answer still depends on the crossover value, so a cache miss (new driver, new shape) can change it once, and the "not clear" flag on half of the cached keys says the measurement itself is still noisy (suggestion (2)).Thanks for the cache directory.