Repository navigation
Flash Next: config-driven top-k and shared expert width - #3523
Conversation
|
Thanks @BadAd84. The design is clean: the kernels already take top-k and slots as launch arguments, so the shape is plain data. On main the three commits conflict in one source file, We added one small commit on top, with no change in behaviour. It drops Must fix: none in the code. Requested before landing: numbers for the top-5 shape at the current head. The top-5 run in the description was taken on
Optional:
Device checks, which we will run on our side:
|
|
Thanks for the extra commit. I fetched it and built on it, so the code below is your commit plus one small one ( The two optional fixes:
Numbers for the top-5 shape on
The top-5 boot's own lines:
Main still refuses this checkpoint by name, so there is no main reply for the top-5 shape. The two-rank check is yours as offered; this head has not run On the CPU side, on a clean host of its own: whole-tree fmt clean on both sides; lean 221 problems on the base and 221 on A first run of that suite on this head failed two timing tests the base did not (the GLM warm-peer bounds and the server's |
|
Thank you @BadAd84. The top-5 numbers you posted cover every equality we asked for: concurrent against solo at one, two and four streams, drafted against plain, and resumed against fresh, all equal with no failures. The mutants and host suite are noted too. We will run our GB10 device check on our side and post the result here. Nothing else is needed from you.
|
10da73f to
b350eff
Compare
|
I reran the host checks on One landing detail for when you pick this up after the GB10 check. Igor Lessio - AIFLOW LABS |
b350eff to
e84fdf7
Compare
|
I rechecked In scratch I kept main's notes and the PR's width notes for those rows and recomputed their hashes from the merged source bytes. No source edits were needed. On M5 Max with Zig 0.17.0, That isolates the textual merge blocker to the fixture refresh. This was a host check. The GB10 device gate remains separate. Igor Lessio - AIFLOW LABS |
e84fdf7 to
37d99a8
Compare
|
The refreshed head I also tested the order #3512 ( zig build test-environment-host test-gradient-serving test-flashnext-compose-host \
test-flashnext-mtp-plan-host test-flashnext-loader-host check-native-cuda-host \
-Dcpu=apple_m1 -j4 --summary allAll 27 build steps passed, with 118 fresh tests and four reused results, including the serving-pin check. The Linux ARM64 CUDA native build check passed. The GB10 device gate is still separate. Igor Lessio - AIFLOW LABS |
37d99a8 to
bbb526c
Compare
|
Thanks @BadAd84. One small tidy-up, not a blocker: the MTP head's byte estimate still sizes its shared expert at 640 wide, so a 1280-wide one is undercounted by about 3 MB. Placement for these checkpoints already adds a 1 GiB allowance, so this should not change what gets admitted. If you touch this code again, reading the width from the loaded tensor would keep the estimate exact.
|
ashhart#3523 was rebased onto main's ce02643 and re-pins the serving sources main moved under it, so this branch's five commits keep their content and only the stack's base moves. Two files conflicted. The scratch keeps this change's tail bytes beside the base's own terms. In the serving pins the base's rows and notes are kept, this change's six note sentences and its new cuda_projection_tail_test.zig row are applied, and every row's hash is recomputed from the merged bytes.
|
Thanks, taken: the MTP head's byte estimate now reads its shared expert's width from the loaded tensor. The old const experts = wt.experts_n * routed + 3 * shared * dims / 2 * 5 / 4;and
The test is at
The 1280 case must price exactly the 640 estimate plus 3,072,000. On this head Checks on this head, on paperclip, under the host lock:
All host steps, no GPU used. The head is |
|
Thank you for the thorough follow-up. The one-row comment now names the width it uses, the MTP head takes the engine’s widths, and the byte estimate reads the shared expert’s loaded rows. The default path also keeps the same routing values and launch order in the source I reviewed. One small loader edge still needs a fix. Please apply the learned-neuron bounds rule on every width-selection path, or use checked addition and refuse that field on overflow. A direct test with an extreme learned count would cover the standalone path. There is also one remaining byte-accounting issue. The two current merge conflicts are mechanical: the MTP byte estimate needs both the existing split-scratch accounting and your shared-width term, and the serving rows then need fresh hashes. We can handle that integration here; no rebase is requested from you. The source defaults look unchanged. The remaining runtime checks should cover the default and top-5 shapes on one GPU, six-slot FP8 routing, and two-rank default and top-5 paths.
|
|
Both are fixed, in two commits on the branch: The learned-neuron count. The rule was already stated in the full config reader ( The shared expert's bytes. Receipts: on linux x86-64 with Zig 0.17.0, the filtered host run over the touched tests passes 51/51 and |
|
Thanks @BadAd84. Both fixes are present: every width selection checks the learned count before addition, and shared-head pricing reads each projection's stored form. The new tests cover the extreme count and affine, BF16 and MXFP8 costs. The earlier top-5 equality results are credited too. No further source fix is requested. We can handle the MTP merge and final serving-pin refresh; two raw pins still describe the earlier source. Current integrated default/top-5, six-slot FP8 and two-rank qualification remain open, with exact checkpoint identities recorded for each.
|
9b77fbe to
20829c3
Compare
20829c3 to
779b959
Compare
…a_mtp.zig keeps to 600 lines Main's cuda_mtp.zig grew since ashhart#3523 was last rebased, and the merged file came to 649 lines. The head's byte pricing moves whole to cuda_mtp_bytes.zig with its three tests: split_bytes, the shared projection's Format, Shared, sharedBytes and headBytes. cuda_mtp.zig re-exports split_bytes, Format, Shared and headBytes, so every caller is unchanged. No behaviour change. Re-pins cuda_mtp.zig.
The CUDA path took the routing width (top-10, 11 slots) and the shared expert's width (640) from constants. config.json now selects one of two supported shapes, top-10 with a 640-wide shared expert or top-5 with a 1280-wide one, and refuses any other value by the field's name. The pass reads the slots from its scratch, which is sized by the shape; the shared expert's width is its gate_proj's rows. The MTP layer routes at the main layers' top-k. A captured kernel set serves the default shape only. The default shape's launches take the same integers as before. Refs ashhart#3368
…ment names the width it reads Head.init read config.json a second time through widthsIn, after Engine.init had already selected the same shape into e.widths, so a change to one read could leave the other stale. It now takes the engine's widths as an argument, and the MTP rule is unchanged: the head's shared expert may be the main layers' width or the routed width (640), and any other row count stops the load naming mtp.layers.0.mlp.shared_expert.gate_proj. The lanes load, the drafted check and the device parity test pass e.widths. The one-row split path gathers [2, 1, width] blocks into the row the down projection reads, and that row's width is native.shared_width, not the halved per-rank width; the comment now names it. A host test pins the single reader: cuda_mtp.zig holds no widthsIn, its init takes the engine's widths, and both callers pass them. Re-pins cuda_mtp.zig, cuda_lanes_load.zig and cuda_mtp_check.zig in the serving fixture.
headBytes priced the shared expert at the 640-wide constant, so a 1280-wide one was undercounted by its three projections' 3,072,000 bytes: gate, up and down at 5/8 of a byte a weight over 640 rows. The estimate now takes the width as an argument. headSharedWidth reads it from the head's own gate_proj rows: whole routed experts beside it are the modelopt load, which holds every row, while the legacy path keeps the first 640 rows of a taught folder's wider expert, and a checkpoint with no head prices the 640 constants. deviceWeightBytes degrades as before, pricing the 640 width when only the width probe fails; placement propagates the error and refuses admission. A host test pins the 1280 case: the head's bytes grow by exactly 3,072,000 at either routed format, and a fixture checkpoint with a 1280-wide shared expert prices that tensor's rows, while 640-wide, 768-row legacy and head-less checkpoints price the default. Re-pins cuda_mtp.zig in gradient-serving.tsv.
…umming it config.json's tensorfold_learned_neurons went straight into the supported shared width's sum, so the standalone engine's read (cuda_config.zig's widthsIn, which cuda_prompt.zig's initialization takes) overflowed on a count near the signed maximum instead of refusing the checkpoint by field name; the server's read checked the count before its selection, so the two paths disagreed. cuda_widths.zig now owns the rule (whole 32-neuron groups, 128 at most) as learnedOk, and select applies it before the sum. cuda_config.zig's geometry calls the same rule, and the field name comes from cuda_widths.zig rather than being spelled again there. Tests: select on the signed maximum, the signed minimum, 129 and 40, and the taught 704-row shape; the standalone widthsIn on a 64-neuron folder's config.json plus the same fields with the signed maximum, which the selection refuses by field.
…ed in headBytes priced every shared projection at 5/8 of a byte a weight, the affine pair's cost, so a whole head whose shared expert is kept BF16 or MXFP8 was estimated short. For a 1280-wide expert the 640 rows past the 640 constants cost 9,830,400 bytes BF16 and 5,068,800 MXFP8, against the 3,072,000 the width correction priced: 6,758,400 and 1,996,800 short. headBytes now takes a Shared: the intermediate width and each of the gate, up and down projections' stored form, priced 5/8 a weight affine, two bytes BF16, a code and a scale byte a 32 MXFP8. headShared reads each form from the tensor the checkpoint holds: F8_E4M3 codes are MXFP8, BF16 is kept, anything else is the affine pair. Tests: the whole 1280-wide expert against no shared rows, 6,144,000 affine, 19,660,800 BF16 and 10,137,600 MXFP8; the 640-row correction's 6,758,400 and 1,996,800 shortfalls; one projection at another form; headShared's forms over affine, BF16 and MXFP8 checkpoints.
…a_mtp.zig keeps to 600 lines Main's cuda_mtp.zig grew since ashhart#3523 was last rebased, and the merged file came to 649 lines. The head's byte pricing moves whole to cuda_mtp_bytes.zig with its three tests: split_bytes, the shared projection's Format, Shared, sharedBytes and headBytes. cuda_mtp.zig re-exports split_bytes, Format, Shared and headBytes, so every caller is unchanged. No behaviour change. Re-pins cuda_mtp.zig.
58a036f to
4dbfaa3
Compare
…a_mtp.zig keeps to 600 lines Main's cuda_mtp.zig grew since #3523 was last rebased, and the merged file came to 649 lines. The head's byte pricing moves whole to cuda_mtp_bytes.zig with its three tests: split_bytes, the shared projection's Format, Shared, sharedBytes and headBytes. cuda_mtp.zig re-exports split_bytes, Format, Shared and headBytes, so every caller is unchanged. No behaviour change. Re-pins cuda_mtp.zig.
|
Thank you @BadAd84. This is merged into main with your commits under your own name, so you're listed as a TensorFold contributor. It ships in the next release, credited to you in the changelog and the release notes. |
Terms used below: "main" is upstream TensorFold at
077998f7d9b14adebec3a2acc2caa47ff7ae6ec7(its tip of 2026-11-16T15:26:10Z), and "the branch" is that main plus the one change this pull request adds, whose head is the commit named below.What this changes
Flash Next on CUDA took its routing width (top-10, so 11 slots a row with the shared expert) and its shared expert's width (640) from constants. With this change the checkpoint's
config.jsonselects one of two supported shapes: top-10 with a 640-wide shared expert, the only shape main loads, or top-5 with a 1280-wide shared expert. Any othernum_experts_per_tokorshared_expert_intermediate_sizeis refused at load by the field's name, ascuda_config.zigrefuses other fields today. No weight format changes: a checkpoint main loads gets the default shape and the same launches, so its tokens are unchanged. The top-5 checkpoint behind #3368 is GPTQ int4, which this step does not load.077998f7d9b14adebec3a2acc2caa47ff7ae6ec7. The branch is one change commit (5cc8b6ace6, on main41a72fd257), one merge commit of964174ea05(5105449d50), one commit that re-pins, inzig/tests/fixtures/gradient-serving.tsv, the ten serving sources the change edits (ea11e31570), which is what the workflow'stest-gradient-servingstep asks for, one merge commit of4bed140a1e(c660f4a0de), one merge commit ofe7e24243(fe753c947), one commit that names this pull request in the CHANGELOG entry (93e3b4056), and one merge commit of077998f7d9b1(6291b4526). The first three merges had no conflict and the last had two,cuda_shared_split.zig(main's Flash Next TP=2 on CUDA: head and rollback graphs replay, and one-row split lanes skip the interleave copies #2837 one-row split lanes and this change's width plumbing, both kept) and the pin file (main'scuda_launch.zigrow and this change's, resolved as the merged file's hash carrying both notes); every merge was predicted bygit merge-tree --write-treebefore it ran. Of the 166 files main changed between964174ea05ande7e24243, onlyCHANGELOG.mdis a file this change changes (the same single shared file out of 62 in4bed140a1etoe7e24243, and out of 114 in964174ea05to4bed140a1e), and there main's bullets sit above this change's one Unreleased bullet. Of the 352 files main changed betweene7e24243and077998f7d9b1, five are files this change changes (CHANGELOG.md,cuda_launch.zig,cuda_shared_split.zig,cuda_split_lane_test.zigand the pin file): the two conflicts above and three that merged without one. Main did move the lane scheduler in the earlier span (15 commits underzig/src/core/lanes/, lanes: shared rounds price plain overhead apart from drafted rows (refs #2605) #2687), which is the path the receipt measures, so the receipt below was retaken onfe753c9470.atc overlap --json: incomplete (complete: false, with its own four limits,otherPullRequestsLimit,pullFilesUnavailable,pullRequestsLimitandtimeLimit), run on this head withup/mainat077998f7d9b1, 19:06 to 19:08 UTC, and once more at 17:27 to 17:28 UTC with the same counts: 25 changed files, and 30 open pull requests listed against this working tree, 4conflicts(Ling-3.1-flash on CUDA, on one or two GB10s #2340, GLM on CUDA: the latent split's per-rank page book and owner (TF_GLM_KV_SPLIT, #1431 part 1; stacked on #1411) #2415, Nemotron 3.5 Bolt (nemotron_h_puzzle) on Metal — serves end to end #1038, ocr: PDF documents and pages on /v1/ocr, one page at a time (#2440 step 2) #2571), 5clean(qwen27: serve the 27B pair, refuse what a pair cannot keep, and die with the peer #1434, lfm3 CUDA: serve the block FP8 export weight-only and the MLX 4-bit export as stored (stacked on #1508) #1634, lfm3: serve LFM3-1.7B on CUDA: NVFP4 and FP8 weight-only, MLX 4-bit (stacked on #1513, #1492 and #1503) #1508, nvfp4 experts cuda: decode up to 24% faster (GLM-5.3 83.8 -> 104.1 tok/s), same bits, via a per-warp cp.async ring #2266, docs: dots.mocr's images on native CUDA #2773) and 21unknown; the report's other 30 rows list pull request 2044, this fork's trunk, against that pull request rather than this tree. Each of the 30 was then fetched from its head and merged bygit merge-treewith this head and, separately, with main alone: all 30 give the same conflict files either way (4 of them share no history with main and merge into neither, hip: ModelOpt NVFP4 and FP8 checkpoints keep their codes and decode in flight #2490, moss image: serve pictures on CUDA (encoder, decoder and host for #1573) #2281, ricursive: speed up Ripple-65B on two GB10s #2523, ricursive: serve Ripple-65B on two GB10s with up to 1M tokens of context #2522), so no conflict the gate names is this change's. The Flash Next TP=2 on CUDA: head and rollback graphs replay, and one-row split lanes skip the interleave copies #2837 pin-file conflict the earlier run reported is gone because main now contains Flash Next TP=2 on CUDA: head and rollback graphs replay, and one-row split lanes skip the interleave copies #2837.How the widths reach the code:
cuda_widths.zig(new, 100 lines) holds the supported list and the selection. The kernels already take top-k and slots as launch arguments (route_rowstop-k,fn_moe_sum,fn_hc_writeback, the expert tiles), so the shape lives in data: the pass reads a row's slots from its scratch, which is allocated for the shape (Sizes.slots,Sizes.shared), and the shared expert's width from the layer (itsgate_projrows). A default-shape checkpoint gets the same integers it got from the constants, so its launches, sums and their order are unchanged. This is option (a) of the issue; the receipt below is its evidence on the default path.10, 11at the write-backs (cuda_batch.zig,cuda_batch_hc.zig) now come from the scratch.cuda_prompt_step.zig's row path, which serves the MLX checkpoint only, names the default slot count instead.config.jsonhas no routing width for it, its router has the same 512 experts, and the shared verify and draft passes lay a row out at one slot count. Since a draft is only a proposal, this width moves acceptance, never a reply. Its shared expert's width is its own tensor's: the main layers' width or the routed width (640); anything else stops the head's load namingmtp.layers.0.mlp.shared_expert.gate_projand its rows.cuda_mixed_experts.zig), and a layer whose rows differ fromshared_expert_intermediate_sizestops it naming the layer and both numbers (cuda_prompt.zig)._topk_rowsis built withTOPK 10andSLOTS 11(cuda_launch.zig). A checkpoint of another shape with a captured set is refused at load, namingnum_experts_per_tok(FlashNextWidthsOnCapturedGlue), andTri.topkManyrefuses another width (CapturedSetTopK) when a captured set owns that launch rather than the family's own glue.cuda_moe.zigand the legacy experts) stays at the default shape; an MLX config of another shape is refused namingnum_experts_per_tok.cuda_moe_exchange.zig): its reduce-scatter size ish * s.slots * dimsinstead ofh * slots * dims. Incuda_moe_native.zigthe rows cleared before the expert launches and the up projections' row layout read the same count, and the shared split's column copies take the layer's width. For the default shape these are the same integers, so the exchange is unchanged; I have not run two ranks, which you offered to check on your side.flashnext_exchange_tests.zig,flashnext_fp8_experts_tests.zig) and two host-test fakes pass the default slot count and width.cuda_launch.zigis 565 lines after adding five lines and removing four (git diff --numstat), one more than before the merge because Flash Next TP=2 on CUDA: head and rollback graphs replay, and one-row split lanes skip the interleave copies #2837 adds a test import; the width plumbing is in its own file, and no Zig file in the change is over 600 lines.Checks on this head
Head commit:
6291b4526767240b68997d8c8f6d00563c4ab676(the change commit5cc8b6ace6on main41a72fd257, a merge of964174ea05(5105449d50), the serving re-pin (ea11e31570), a merge of4bed140a1e(c660f4a0de), a merge ofe7e24243(fe753c9470), the CHANGELOG commit and a merge of077998f7d9b1(6291b4526); its tree isa1be9c739796de928478dc596c43c3a32cb5dc45, and against077998f7d9b1it changes 25 files, 292 insertions and 94 deletions). The receipt and its two images ran on maine7e24243and onfe753c9470; the checks below ran on this head and on main077998f7d9b1, and the receipt bullet says why the merge changes nothing the receipt measured.Lean checker,
python3 tools/zig/lean_check.py, one tree at a time from its own root, with the head's checker in both (byte-identical, sha256 prefixa08d2a424e01b16a): base077998f7d9b16,575 files, 221 problems; this head 6,576 files, 221 problems;lean_new.py:lean: 221 problems, 221 on the base, 0 new. The problems are inherited (for examplezig/src/server/vision_inputs.zig:331), and the two file counts differ, so the two runs really were two trees.python3 tools/pr_check.py --basemain at077998f7d9b1on this head:merge base 077998f7d9b14adebec3a2acc2caa47ff7ae6ec7; 25 changed files; lean 221 vs 221, 0 new; 0 errors and 0 warnings with--pr 3523, the Unreleased bullet naming this pull request.zig fmt --check build.zig zig: clean.git diff --check 077998f7d9b1..HEAD: clean.zig build compile-config-server -Dtarget=aarch64-linux-gnu: passes on this head (rc 0, 7 of 7 steps, 180 s, natively on the aarch64 machine below).zig build compile-cuda-tests -Dtarget=aarch64-linux-gnu: passes on this head (rc 0, 10 of 10 steps, 170 s).Kernels: the shared header
common/fp_pairs.cuhchanged between the pre-merge headea11e31570andfe753c9470, so every.cuthat reaches it was rebuilt at sm_121 with the build's own flags at both commits and compared: 59 of 65 byte-identical, 6 different, 0 that would not build. Five of the six (ck_lane,exl3_block/lin2,qmm,qmm_group,qmmf) differ only in their internals' symbol names (INTERNAL_<hash>, which follow the translation unit's text) andcuobjdump -sassis identical for each; the sixth isnvfp4_experts32(445,936 to 933,560 bytes, SASS differs), which is not among the 24 images Flash Next launches. On those 24, 21 are byte-identical and the 3 that differ are the symbol-name-only cases, so no instruction this family runs changed. The merge itself edits two kernel sources, main'sgdn.cuandqwen35.cuh, each in a comment only; the four bodies that build from them (gdn,qwen35,qwen35_keep,qwen35_kv8) were rebuilt at sm_121 at the old head and at this head and all four are byte-identical (255,432, 828,856, 31,960 and 713,808 bytes), and none of the four is an image Flash Next launches or reaches one.Tests run as the no-GPU workflow runs them, natively on an aarch64 Ubuntu 24.04.5 machine (NVIDIA GB10, 20 CPUs, Zig 0.17.0,
-j8 --maxrss 6000000000except-j4where noted, umask 022, no GPU visible to the tests), on a freshgit archivetree of6291b4526and, separately, of main077998f7d9b1, each checked blob by blob against its commit (11,833 and 11,832 blobs: 0 missing, 0 extra, 0 different).zig build -Dfixed-cpu test-host --test-timeout 20mat-j4gives rc 1 on both:6291b45262,125 of 2,132 steps and 18,382 of 18,508 tests passed, 125 skipped, 1 failed; main077998f7d9b12,125 of 2,132 steps and 21,094 of 21,233 tests passed, 138 skipped, 1 failed. Head's run reused 89 test steps that its own earlier steps in the same cache had already run (98 cachedrun teststeps against main's 9), so the two totals are not comparable across the runs while the failing sets are, because a step is cached only when it succeeded. The failing set is identical on both sides, one test,listener.zig'saccepted IPv4 and IPv6 TCP streams disable Nagle for incremental responses, which needs IPv6 that this machine boots without (ipv6.disable=1): tests that fail on6291b4526only, 0; on main only, 0.New tests, each shown failing on a mutant of this change: the mutant applied to its own fresh copy of this head, then
zig build -Dfixed-cpu test-cuda-host -j4(natively on the aarch64 Ubuntu 24.04.5 machine above, Zig 0.17.0, umask 022). Every mutant fails:cuda_widths.zig's tests index the top-5 entrya top-5 config with a 1280-wide shared expert selects that shape, and the MLX path refuses it by name,a width outside the supported list is refused by its field's name,the default shape is the constants' and a top-5 checkpoint selects a 1280-wide shared experta top-5 config with a 1280-wide shared expert selects that shape, and the MLX path refuses it by namethe scratch is sized by the shape: a wider shared expert's three buffers, fewer slots' pairsthe MTP layer routes at the main layers' top-k with its own shared width, and another width is refuseda captured kernel set serves the default shape onlyMeasured on this head: each mutant runs on its own fresh copy of this head (a
cp -aof the tree the control ran in, its cache pruned withtools/zig/zig_cache_restat.zig --prune), the six anchors checked to occur exactly once on this head before the run, and the control runs first,zig build -Dfixed-cpu test-cuda-host -j4: rc 1, 408 of 410 steps, 6,926 of 6,960 tests passed, 33 skipped, 1 failed, that failure beinglistener.zig's IPv4 and IPv6 test, because the machine boots without IPv6. Every mutant fails it too, and the table names the tests each mutant fails beyond it.CI on
6291b4526(this head), run on this pull request:fmt,zig,zig-b,zig-windows,pytest,benchmark-clients(ubuntu and windows),release-pathsandzig-macos-dev-toolsall completed successfully;host-nightly-linuxandhost-nightly-macosare skipped by their own conditions.Not run, and why: two ranks (no second GPU here; you offered the device check for this step) and the MLX 4-bit checkpoint (there is no MLX checkpoint on this box; the MLX path is exercised through its refusal in the host tests). The receipt below measured the default shape main loads, which is the shape this diff's launches are on; the top-5 shape's device run stays on the base it was taken on and its bullet says so.
Receipt
tools/bench_openai.py --tokens 256 --reps 3 --temperatures 0at one stream andtools/bench_concurrent.py --tokens 256 --reps 3 --levels 1,2,4,6,8 --alone --serial --temperatures 0, both from main'stools/. A cell counts as slower when both branch runs are under both main runs and the mean gap is over 1%. No cell is slower:/metricsbefore and after each probe:bench_concurrent --alone --serialandserved_exactness.pyagainst"draft": false:M1 cache on concurrent: concurrent equals solo 156 equal / 0 unequal; drafted equals "draft": false 56 equal / 0 unequal
M1 cache on golden: concurrent equals solo 13 equal / 0 unequal; drafted equals "draft": false 24 equal / 0 unequal
M1 cache on drafts: 8 of 8 equal to "draft": false (basis ['token_ids'])
B1 cache on concurrent: concurrent equals solo 156 equal / 0 unequal; drafted equals "draft": false 56 equal / 0 unequal
B1 cache on golden: concurrent equals solo 13 equal / 0 unequal; drafted equals "draft": false 24 equal / 0 unequal
B1 cache on drafts: 8 of 8 equal to "draft": false (basis ['token_ids'])
M1 cache off drafts: 8 of 8 equal to "draft": false (basis ['token_ids'])
M1 cache off fresh: 7 of 7 resumed replies equal the fresh ones
B1 cache off drafts: 8 of 8 equal to "draft": false (basis ['token_ids'])
B1 cache off fresh: 7 of 7 resumed replies equal the fresh ones
Branch replies equal main's (pass A greedy token_sha, every stream and rep): 528 equal, 0 unequal
--prompt-cache-gib 0at a 131,072-token window with 4 slots; cold prompts of 2k, 8k, 32k and 64k tokens (a fresh salt first, thinking off, median of 3), thentools/bench_cache.py --require-cold. Same noise rule, with slower meaning longer. No cell is slower:bench_cache --require-cold, firstttft_se7e24243astensorfold-qwen38:wr-m-e7e24243and the branchfe753c94astensorfold-qwen38:wr-b-fe753c94, each built bybuild.shfrom a verifiedgit archivetree of its own commit (e7e24243d63e232b05d4892df4fa01c9a2d6c70b,fe753c9470fb04c2c4a1bb09ac0d6e08b7c00775; image ids and labelssha256:94ef45cd6a1c432e0e39a8a6468ac15741e1857a041d013de3edcb17b893e888 created=2026-11-16T07:25:56.999388196Z kernels=embeddedandsha256:43be8280bdcf3d21c5829969400675947d07a3dda30852266f2a38097eb0f176 created=2026-11-16T07:16:54.426273349Z kernels=embedded), nothing of ours patched into either; 7.0.0-1019-nvidia-64k; Ubuntu 24.04.5 LTS; NVIDIA GB10, 580.178.04, [N/A]; RAM 123 GiB; NVCC Cuda compilation tools, release 13.3, V13.3.73 Build cuda_13.3.r13.3/compiler.38244171_0; ZIG 0.17.0 (GB10's unified memory: nvidia-smi reports the memory total as [N/A] and the box reports its RAM); checkpointnvidia/Qwen3.8-Flash-Next-FP4-Localat revisionb9ce18a6887e18c089fdea8509a33e63429a3300; bf16 KV, decode and exactness at a 32,768-token window with 8 slots, the cold pass at 131,072 with 4 slots.e7e24243and on the branch of it (fe753c94), the Environment bullet's two images, so the comparison is this change and nothing else, and the merge of077998f7d9b1adds no work to the cells it measured. Flash Next TP=2 on CUDA: head and rollback graphs replay, and one-row split lanes skip the interleave copies #2837's runtime change runs only at two ranks: its two statements incuda_shared_split.zigsit insideif (native.split_shared), its one incuda_split_lane.zigafterlw.dense_cut orelse return self.lane(...), andcuda_dense_split.appliesreturns false unlessworld == 2, so on the one GPU every row was taken on neither executes; itscuda_launch.zigchange is a test import. At the default shape this change's integers are main's,cuda_widths.zig'sdefaultbeingwt.slots - 1slots andwt.moe_wrows (11 and 640) andSizesdefaulting to the same two, so main-at-T and branch-at-T issue the same launches with the same arguments and run the same kernel files, and no cell of the receipt can differ. What does not transfer is the absolute figures, which are what those two images produced; main's own commits betweene7e24243and077998f7d9b1are on both arms. As context only, and not part of this receipt: maincf4555373againste7e24243is level in all 22 cells it was measured in, -0.77% to +0.07%, on the same machine and checkpoint.964174ea05and not retaken here (this window served the default shape only): from the FP4-Local snapshot I built a top-5 checkpoint whose 48 main layers' shared expert carries 640 zero-padded rows (they contribute exactly zero), with the MTP layer's shared expert left at 640, which the MTP rule allows. The branch loaded and served it (model 72.88 GiB, 4 streams at 4.11 GiB each, 27.9 GiB left after the 9.0 GiB reserve):bench_concurrent --alone --serial1, 2 and 4 streams at 68.5, 58.8 and 52.7 tok/s a stream on code and 55.7, 52.9 and 47.9 on chat; drafts 8 of 8 equal to"draft": falsewith 173 to 234 accepted a reply;bench_openai67.98 and 55.71 tok/s; 2,805 accepted of 4,593 drafted over 1,824 rounds in the concurrent bench; and a plain question answered coherently. Main refused the same checkpoint by name:config.json's num_experts_per_tok differs from the supported Flash Next CUDA layout.Checklist
e7e24243and on the branch of it (fe753c94) in one window."draft": false, a resumed prompt equals a fresh one, and concurrent equals solo, measured onfe753c9470in this window; the receipt bullet says why the merge adds no work to those paths.