Governing correction: cached 35B baseline before fusion
Drake's correction, 2026-10-24. The serving target is Qwen3.6-35B-A3B: 40 layers, 256 routed experts, and vocabulary 248,320. Pin the actual serving source, binary/archive, checkpoint, row count, sampling mode and runtime flags before deriving bytes or launch counts.
Serving-speed order: (1) measure and qualify cached scratch on the live 35B path, (2) measure fusion against that qualified baseline, (3) implement and qualify the 8-bit output head. Omega #704/#705 are a parallel planning-tool lane and do not block these direct measurements.
This issue consumes the qualified cached-scratch measurement from #604's baseline arm; it does not wait for completion of #604's later persistent-execution experiment. Recompute the selected 35B chain's bytes, launches and resource demands from its actual execution path. The older 30B/48-layer calculation in CUDApp#18 is historical and must not be reused for 35B.
Preserve already-enabled 35B optimizations and numerical behavior in the comparison. Implement and qualify the owned successor and owned tests in seeded .om; retained comparison algorithms must also meet the current replacement policy.
Problem
Workflow fusion is not arithmetic kernel fusion. src/runtime/rx_fusion.h combines verified action fragments; it does not prove intermediate tensors stay on-chip. Eliminate a demonstrated write/read boundary within one inference computation.
Dependencies and boundaries
Depends on #602. Reuse src/omega_blackwell_codegen.c, src/omega_gpu_matmul_api.c and the current model's execution path. #580 retains ownership of general engine scheduling; #555 retains attention tiling; #569 retains arena allocation. Existing q/k/v and gate/up fusion documented in #328 must not be reimplemented.
Deliver
- Pick one hot producer-consumer chain from the baseline (for example a supported activation epilogue), after checking current kernels for existing fusion. Document the exact eliminated intermediate and all consumers.
- Emit an opt-in fused native kernel that retains the intermediate in registers/shared memory. Preserve dependency order and the incumbent rounding/reduction contract; do not silently introduce FMA or reassociation.
- Keep the original kernel path as a differential reference. Preserve completion, error, bounds and output-validation behavior; coordinate recorded-buffer lifetimes with #562/#569.
- Compare unfused and fused versions at identical shapes, weights and precision. Measure actual or explicitly estimated external traffic, registers, shared memory, spills, launch count and end-to-end latency. Include cases near resource limits.
Acceptance
- Correctness passes the existing numerical gate, including representative tails and boundary shapes.
- Receipt demonstrates which store/load boundary disappeared; fewer launches alone is insufficient evidence of less DRAM traffic.
- Resource growth and occupancy tradeoffs are reported; spill regressions are visible.
- Repeated whole-workload comparison determines whether the candidate improves the intended regime. Freeze promotion criteria before scored runs; keep incumbent if it loses.
- No claim that fewer workflow nodes guarantees on-chip residency.
Scope and evidence
Use Omega's existing native GB10 codegen/session/engine; no replacement executor or CUDA dependency is implied. Recheck current source, active PRs, repository instructions and execution plan before implementation. Coordinate shared-file ownership. Existing model precision, arithmetic contracts and qualification thresholds remain fixed for the comparison; any changed numerical contract is a separately qualified candidate. Use the existing GPU lock and scheduling protocol; do not interrupt live workloads. Pin source, model, hardware, workload and commands in receipts. Hardware results remain NOT_RUN until actually measured.
Specialization before fusion (2026-10-20)
For the selected chain, split inputs into static facts (model/version, dimensions, dtype/layout, hardware target, numerical contract) and dynamic values (current activations and variable context). Use existing native code generation and preparation/cache facilities to resolve static dispatch, address/layout calculations and reusable packing once where valid. Do not bake dynamic values into the program or claim fixed weights eliminate activation-dependent arithmetic.
- Compare incumbent, specialization-only, and specialization-plus-fusion arms so eliminated setup work is distinguished from eliminated intermediate traffic.
- Cache identity includes all specialization assumptions; changed assumptions force regeneration or the existing qualified generic path. Exercise at least one invalidation case.
- Report cold generation/packing cost, code/cache footprint, warm savings and measured reuse break-even. Bound variant growth.
- Reuse only deterministic, validated artifacts; include lookup and validation cost in #583's ledger.
Background: CMU staged computation / partial evaluation, https://www.cs.cmu.edu/~fox/staged.html .
TURING integration
Feed qualified candidates and measurements into #522's numerical execution-method selection and #583's cost ledger. No LLM deliberation is required for ranking the finite eligible set. Include selection/preparation/transfer/validation overhead and uncertainty; compare CPU or cached selection with GPU scoring only when worthwhile. Preserve #522's offline-first qualification gate. This changes execution strategy, not the model's underlying semantic inference.