Commit Graph
5 Commits
Author SHA1 Message Date
Deadcode 140987fa7b radiance 1.0.8
- Qwen3.8-Flash-Next serves at --tp 4, contributed by goodman-b (PR 9). Rank pairs share each of
  the model's two KV heads, every rank computes a slice of every expert's width, and four ranks
  run the unfused all-reduce plus a new four-rank all-gather for the vocab-parallel sampler. Two
  ranks declare and compute exactly as before. The README has a four-rank flag row; it pins
  --host-pool-mib on every card, 48 GiB in all. At four ranks the expert shares are not equal:
  ranks 0 and 1 compute three blocks of every even/odd pair of experts and ranks 2 and 3 two
  (docs/ARCHITECTURES.md).
- The four- and eight-rank all-gathers require peer access between the cards, as every other
  collective does since 1.0.7, and the kernel library's selftest now refuses any multi-rank kernel
  that does not.
2026-10-04 21:59:28 +02:00
picoder 8f795c1022 plain bf16 experts: the model's width, and an uneven share of the tiles
radiance: 'layer 34's plain experts are 384 wide, which 4 ranks cannot share in
64-wide tiles' -- on ranks 1 and 2 only. The protected experts are declared by a
second grouped GEMM over their own slice of the expert's width, and that width
was read off THIS RANK's parity slices (max ff_hi). At two ranks that is the
model's width; at four it is 384, 512, 640 depending on who asks. Ranks 0 and 3
passed the check, ranks 1 and 2 refused, so the all-reduce's rendezvous got two
of four ranks and the launch died -- the AR error was the cascade, not a bug.

The width is g.n_ff_all. And an even share of it is not available here: 640
columns are ten 64-wide output tiles, which four ranks take as 3, 3, 2, 2. An
uneven share is still whole tiles and every tile still has exactly one owner, so
the rank takes a span -- uniform across a layer's protected experts, because
their GEMM takes ONE table and every entry of a table has one geometry (unlike
the quantised experts, which alternate by parity precisely because they have two).

A rank count that divides the width keeps the old declaration verbatim, span
included: no span at all, the loader dividing the entry itself.
2026-10-04 21:47:44 +02:00
picoder b8fab2c871 test: pin the four-rank expert WIDTH split, and that it tiles exactly
The old assertions pinned expert parallelism -- n_expert = 128, expert_base =
r*128 -- which is the design this replaces. What the four ranks divide is each
expert's width, so what the test pins is a span on every expert's down
projection, per parity, plus the property that actually matters: the four
ranks' slices of one parity TILE the width, each block claimed exactly once.
Neither unserved (a rank quietly dropping a fifth of every expert) nor twice
(the all-reduce then double-counts that block).

Read off the declared spans, not off the plugin's formula -- recomputing them
would only prove the test agrees with the code.
2026-10-04 21:47:44 +02:00
picoder 7cf4c005e1 TP4 for Qwen3.8-Flash-Next: unfused chain, four refusals answered
World 4 refused at declare on two counts and at boot on a third the audit
found; the fourth is unchanged by design.

- rad_arch.h: a world above the KV head count replicates the heads in rank
  pairs instead of dividing them. Geom gains kv_off; each rank declares
  n_head_kv 1 and gqa 6. A world that is not a multiple of the head count
  is still refused, by name.
- rad_block_attn_gated_fp8.h: k/v pass the row span LinearFP8 already
  takes, gated on world > n_head_kv_all so an even shard is untouched and
  TP2 declares byte-identically.
- qwen4exp_fp8.cpp: above two ranks the ranks own whole experts (5 blocks
  of 128 do not cut four ways); the parity tables stay two-rank and the
  router stays replicated.
- libr4d: attn_{prefill,decode}_h256_gqa6_bs4 rows and their TU -- the
  gqa8 body at ratio 6, page 4. No fused form is instantiated at this
  geometry; the unfused pair is what resolves.
- libr4d: r4d_ar_gather_Nrank.hip. The vocab-parallel sampler declares an
  all_gather at any world > 1 and libr4d shipped only the 2-rank row, so a
  TP4 boot was refused by the reference-kernel gate rather than served
  wrong. The wide one-shot all-reduce with the reduction removed.
- rad_block_attn_gated.h / rad_block_attn_fp8.h: refuse a world above the
  KV head count. They read n_head_kv and declare no span, so they would
  have booted and read half a KV head -- fluent wrong text.
- tests/arch_test.cpp: the four-rank declare test, and the fake records
  the shard span the real builder stores.
- README, ARCHITECTURES: TP4 in the present tense, with the costs named
  and the rate against TP2 left unmeasured.
2026-10-04 21:47:44 +02:00
Deadcode ae74a8aebf radiance 1.0.0 2026-10-04 12:02:41 +02:00