Commit Graph
583 Commits
Author SHA1 Message Date
Pavlo RatushnyiandClaude Sonnet 5.5 5267c9d538 Ledger: V2 device part at parity, V4b closed by V4a, K11 per layer, S7/D2/D3 rows (FFN phase analysis)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-11 00:41:16 +01:00
Pavlo Ratushnyi 8d73d862c1 Merge branch 'claude/v2-ffn-design' into claude/speed-vs-strata-08143a 2026-11-11 00:40:55 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 d19d08b698 V2 FFN phase: loss analysis and design (offline CUPTI timeline script)
Per kind/T/layer-class timeline of the FFN phase for LEL (CL.2, CT.1, CY.1)
and VANL from the request-29 windows, shift-share of the +0.95 ms into device
chain / arrival of the CPU rows / tail / tier mix, and the device-side options
that remain (sub16 down kernel with PCIe pass rows, add_hits in combine, wait M
folded into copy rows) with a task split. Analysis only: no engine code, no GPU.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-11 00:40:33 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 917289a5e5 Ledger: S11/S9/U5a identity results, probe run 2
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-11 00:04:55 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 137d2899a6 Speed program: ledger counts
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 19:23:34 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 fc1e94ea55 Speed program: window variants CP/CS/CH/CD/CZ, ledger S11/S9/U5a built and queued (probes, identity, CUPTI windows)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 19:23:28 +01:00
Pavlo Ratushnyi 4a1845aedb Merge branch 'claude/u5a-gr-down-fused' into claude/speed-vs-strata-08143a
# Conflicts:
#	crates/cuda-driver/ptx-sm86/MANIFEST.json
#	crates/cuda-driver/src/original_verify_window_sm120.rs
#	scripts/gpu-bringup/extra-seal-plan.json
2026-11-10 19:15:36 +01:00
Pavlo Ratushnyi 1c8c4abac2 Merge branch 'claude/s11-s9-combine-headmix' into claude/speed-vs-strata-08143a 2026-11-10 19:15:14 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 0518311567 verify window: LELEKA_SM120_GR_DOWN_FUSED (hc split + tiled down projection as one launch, step U5a), off by default
New sealed sm_120 asset sm120_gr_down_fused.ptx (nvcc 13.2.86): leleka_gr_down_fused_t2w8 replaces
chain_gr_split + chain_gr_down_t2w8_nb4 (96 launches fewer per verify graph). The block stages R' * w_norm of
its two tokens into shared memory, adds the sum of squares in the split kernel's order, scales with rs and
runs the down kernel's dots; the operations and their order are those of the two kernels (bitwise by
construction; upstream's gr_down_v3 sums in another order). A no-op, said once, without the chain gr pair.
Planner, switch resolution (Sm120Switches, GrConfig.down_fused), unit tests, model-free probe
tools/gr-down-fused (not run: no GPU). Not measured. Microbench harness: the NaN outputs were a stream race
between the poison memsets and the kernels, fixed; inputs are checked finite.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 19:14:46 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 b8a74d01dd Verify window: LELEKA_SM120_COMBINE_VEC4 (float4 routed-expert combine) and LELEKA_SM120_HEAD_MIX_MULTI (one multi-token head mix), both off by default
COMBINE_VEC4: new sealed sm_120 asset sm120_combine_vec4.ptx (nvcc 13.2.86), entry leleka_verify_combine_k10_vec4,
upstream combine_k10_vec4 (non-hits form). Same per-element operations as the sealed mtp_full_combine: first
product rounded, nine fmaf in expert order, one add of the shared row. Falls back to the scalar launch when
k != 10, n % 4 != 0 or a row base is not 16-byte aligned. Same launch count as the scalar path.

HEAD_MIX_MULTI: upstream STRATA_HEAD_MIX_MULTI. The final mixer as one multi-token hc read over output_hc_* (the
layer read kernels, apply = false, no inject), 3 launches instead of 5 per token. No new PTX.

Switch DTO CombineHeadKernels (original_verify_window_combine_head.rs) travels beside the GDN policy; the shared
switch file gets two fields. Unit tests (asset seal, PTX arithmetic shape, launch plans, whole-window launch order with
both switches). Model-free byte-compare probe tools/combine-head written, compiled, not run (no GPU). Design and
CUPTI names: docs/experiments/verify-combine-and-head-mix.md

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 19:08:30 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 456f5336b1 Speed program: ledger V5/V7 analysis of the flag waits (no kernel overhead to remove; the loss is the CPU leg's arrival), cupti_flag_waits.py
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 18:55:34 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 b56e5afb58 Speed program: fused commit graph ON in the three 5090 profiles (identity P2/P3 PASS, section 509 -> 125 us); ledger closes S6/O11
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 17:46:11 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 9b9f736bff Speed program: ledger, A/B rules of 2026-11-10; second half of the tie-spread A/B withdrawn; S6 closes without its own paired A/B
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 17:34:44 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 deb0d73489 Speed program: ledger, QSA prelude set A/B (no regression) closes K6/K1/S10; fused commit window 509 -> 125 us (S6/O11 wait for identity)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 17:04:56 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 818c604ab2 Speed program: ledger, set A/B of the side branches (M against U): decode +2.11 %, no regression; V3a/V3b/V4a stay fixed
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 14:44:42 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 c7920322f3 Speed program: ledger C2v, correct four kernel-time cells
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 12:24:11 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 e4c9208570 Speed program: ledger section C2v, the CUPTI windows of the new verify switches against CL.2 and VANL
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 12:23:58 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 edad5e7737 Speed program: QSA prelude on in the 5090 profiles (identity P2/P3/P8, section delta per T); ledger K6/K1/K7/K7a/S10/U3/O7 with the window results; PB/ZQ variants for the set A/B
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 12:13:58 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 c499df4141 Speed program: ledger U5 measured on the 5090 (upstream hc down faster by 3-6 us a launch), new row U5a
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 10:17:10 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 f080ae522b Speed program: ledger Q7 device part merged
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 00:26:30 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 0e84729686 docs/experiments: driver side of the decode graph reuse (DeviceRef handles, park, rearm, reseed), ledger Q7
What changed, the reset checklist with the code location of each item, what is not covered, how to test it
on a GPU and the risks. No measurement: nothing was run on a device.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 00:24:02 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 a2f5854d72 Speed program: ledger rows of the merged verify switches -> fixing with job names
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:47:31 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 16dea5cb90 Speed program: ledger V3b, A/B ab-sqn (no regression, not significant alone)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:43:43 +01:00
Pavlo Ratushnyi 182e1ca07e Merge branch 'claude/verify-gdn-fused-kernels' into claude/speed-vs-strata-08143a
# Conflicts:
#	crates/cuda-driver/ptx-sm86/MANIFEST.json
#	crates/cuda-driver/src/original_verify.rs
#	crates/cuda-driver/src/original_verify_window_sm120.rs
#	scripts/gpu-bringup/extra-seal-plan.json
2026-11-09 23:39:52 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 62fd0f88a8 verify window: LELEKA_SM120_FUSED_GDN (GDN conv + gates + step in one launch) and LELEKA_SM120_GDN_AB_UNROLL (upstream SMALL_UNR bit 1), both off by default
New sealed sm_120 asset sm120_gdn_fused.ptx (nvcc 13.2.86): leleka_verify_gdn_fused_step
(the Original's step loop over shared memory, conv prologue, gates in two warps or joined from the
SIDE_MIXER branch, split-window replay) and leleka_gdn_ab_unrolled_t1..t8. Written with the Original's
plain expressions on purpose: ptxas contracts a plain mul+sub into one FFMA, so __f*_rn intrinsics
would not be bitwise equal after the driver JIT. PTX shape compared with original_verify.ptx in unit
tests; model-free probe tools/gdn-fused written, not run (no GPU). Design: docs/experiments/verify-gdn-fused-kernels.md

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:38:50 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 aaf14df80b Speed program: ledger U5, microbench queued
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:27:05 +01:00
Pavlo Ratushnyi 6bcc4742b1 Merge branch 'claude/verify-hc-down-microbench' into claude/speed-vs-strata-08143a 2026-11-09 23:26:48 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 aa2f237590 speed: kernel micro-benchmark of upstream gr_down_v3 (masks 0/5/133) against chain_gr_down_t2w8_nb4 (ledger U5)
Harness (one TU including upstream fused_gr.cu whole, ours from the sealed PTX through the driver API plus an nvcc cubin),
GPU queue stub, and the method note with input sha256. Not run on the GPU yet.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:26:26 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 f252aa162c Speed program: ledger Q7 owner and plan (shared handle + re-arm API)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:22:05 +01:00
Pavlo Ratushnyi 009585f285 Merge branch 'claude/verify-qsa-fused-prelude' into claude/speed-vs-strata-08143a
# Conflicts:
#	crates/cuda-driver/src/original_verify_window_ops/original_verifier.rs
#	crates/cuda-driver/src/original_verify_window_sm120.rs
2026-11-09 23:13:12 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 595e34feb4 Docs: name the resolve function of the fused QSA prelude
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:12:29 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 506527bb9e Verify window: LELEKA_SM120_FUSED_QSA_PRELUDE (K/V rows and tail snapshot + indexer rows of a QSA layer as two launches, opt-in, off by default)
Replaces 12 x (2n+1) per-row launches of a window graph by 24: leleka_verify_qsa_kv_rows (n x mtp_original_append, precise math) and
leleka_verify_qsa_index_rows (tail snapshot + n x verify_qsa_append_analytic, fast math). Both PTX built with nvcc 13.2.86 (compile only)
and pinned; model-free probe tools/verify-qsa-fused-prelude/prelude_probe.cpp not yet run. No GPU number.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:12:25 +01:00
Pavlo Ratushnyi 6b2a69f1d9 Merge branch 'claude/verify-accept-on-device' into claude/speed-vs-strata-08143a 2026-11-09 23:06:30 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 3887d777d6 Speed program O7: LELEKA_SM120_ACCEPT_ON_DEVICE, the finite verdict of the head logits in the verify graph
Off by default. With the switch the verify graph ends with verify_clear_status, verify_scan_logits and a
one-word store of the status into a host-mapped verdict word (vanilla's logits_nonfinite_rows order); the
post-drain check reads that word instead of launching the scan, synchronising the stream, copying the status
back and synchronising the context. Same error at the same place, before complete_window and any commit.
Sealed PTX unchanged. Unit tests for the switch, the graph tail commands, the verdict decode and the post-drain
dispatch. Note updated with the corrected O7 ledger wording.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 23:05:51 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 91a130da6a Speed program: ledger U5, retract the cross-kernel grid-y comparison (different row mapping)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 22:52:45 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 00d90124a9 Speed program: ledger U5, chain down kernel by window rows against vanilla
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 22:52:35 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 6d61656177 Speed program: ledger section C2u (upstream cc 12.0 defaults: PDL, SMALL_UNR, GR_V3_PF) and the O7 correction
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 22:52:00 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 23f0ecb97d Speed program O7: trace of verify end to first draft kernel (ours and vanilla)
Vanilla's greedy accept is host-side (generate.cpp:15255); the difference to ours is the
post-drain finite-verdict scan (three syncs against one) and the host chain before the draft
launch. A device-side accept needs draft-chain edits; options and recommendation in the note.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 22:51:15 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 5b8c0eba0e Speed program: readable job names (queued stubs and dirs renamed, old->new table in the ledger), content labels on the touched ledger rows
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 21:54:38 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 a199b3ad11 Speed program: S6/O11 plan (fused commit graph exists, to be measured and enabled), LELEKA_DRAFT_* allowed in profile engine_env, CF/CU CUPTI variants
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 21:16:33 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 a838d0abe7 Speed program: SIDE_QSA and SIDE_SHARED on by default in the 5090 profiles; ledger V3a/V3b/V4a/V4/S3 fixed (section delta + identity)
Owner method: a step closes on a measured section delta plus identity; the set A/B (spd-sqa, M against M+QSA+shared) checks the set for regression.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 21:14:37 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 35040ea9a6 Speed program: ledger V4a A/B (ab-sqe n=10, not significant, stays off), variant U for the set A/B
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 21:10:51 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 4c8919610a Speed program: ledger V3b/V4a/V4 section deltas from the CE/CN/CT windows (spd-sqw)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 20:13:02 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 4f310457ce Speed program: SIDE_MIXER on by default in the three 5090 profiles (identity PASS, decode +1.39 % paired); ledger V3a/V3b/V4a identity
Teacher-forced gate spd-sqid1: P2 (SIDE_MIXER), P3 (SIDE_QSA), P4 (SIDE_SHARED) against P1: 2057 top-16 logprob rows bit-identical, 0 argmax flips, draft trace 518/518 identical. The A/A arm did not open (InputAllocation) in any process, so no A/A floor.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 18:37:48 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 015b98ec43 Speed program: ledger V3a, A/B SIDE_MIXER (ab-sm, n=10): decode +1.39 %, identity pending
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 17:32:20 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 3faad53b60 Speed program: step ledger reordered along the request pipeline (request, prefill, decode round)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 15:07:08 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 d5fd270f81 Speed program: step ledger (every gap to vanilla per step of round and request), counts tool
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 15:05:58 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 a310533186 Speed program: CUPTI kernel-level comparison LEL against VANL (67k window): the gap is the missing parallel branches in the verify graph
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 14:36:19 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 4a633f70df Speed program: lever 3 variant H clean paired result (e2e +1.06 %, not significant)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-09 01:15:06 +01:00
Pavlo RatushnyiandClaude Sonnet 5.5 d2108576a8 Speed program: lever 5 variant R clean paired result (e2e +0.56 %, not significant)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-08 23:43:25 +01:00