Analysis (docs/experiments/verify-tail-and-gaps.md, CUPTI windows CP.1 / CL.2 / CY.1 against VANL): R6 is the
single-stream control (2035 gaps, 211 us) against VANL (1194, 119 us); with the side streams LEL has 1124 / 123.7 us,
residual +0.006 ms. R7 has no gap. R8 (+86.5 us at LEL's T mix) is the hyper-connection chain 31.2, the head matmul at
T >= 3 38.4 and the greedy pick 18.0.
The switch batches the 6 T launches of the tail (mtp_full_native_write plus the five lm_head_mix kernels a row) into
6: new sealed sm120_head_chain.cu/.ptx (final write, head norm, pre-final mix with the row as grid.y, compiled with the
--use_fast_math flags of the originals), the existing multi-column bf16 gemv, mtp_full_down_silu over the contiguous
rows. Bitwise by construction (same bodies, same per-column fma chain). Flag in GrConfig::head_chain_batch like U5a;
HEAD_MIX_MULTI untouched. Model-free probe tools/decode-sm120/sm120_probe_head_chain.cpp (built, not run), report
script scripts/e2e/codex/speed/verify_tail_report.py, 15 unit tests (288 original_verify tests pass).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
D1 of docs/experiments/ffn-phase-loss-design.md. New sealed sm_120 asset sm120_down_sub16.ptx
(nvcc 13.2.86), entries sm120_moe_down_20 (IQ4_NL, 8 lanes a row, 32 rows a block) and
sm120_moe_down_42 (Q2_0, 16 lanes a row, 16 rows a block): upstream's
native_down_multi_kernel<TD, SUB_DOWN> hb == 20 branches, with the row-dot reduction tree of the
literal window_moe_down_<T> (row_dot_multi) reproduced in 8 / 16 lanes. grid.y strides over the
groups, so the PCIe pass launches kPcieGroupRows = 4 block rows (the fused GU_SWIGLU gate/up of
that pass too) instead of one per possible group. Only n_ff == 640 and the two formats; any other
layer keeps window_moe_down_<T>. Switch off: the recorded graph is unchanged.
Planner: group_kernels / GroupKernels / DownKernel in plan_expert_groups.rs. Asset, formats and
the PCIe block rows in original_verify_window_down.rs; asset pinned in extra-seal-plan.json and
ptx-sm86/MANIFEST.json ("not built for sm_86 by design"). Probe: sm120_probe `down` compares the
whole output buffer of both kernels byte for byte (T 1-8, 0-16 groups, grid.y cap and 4,
n_embd 2560 and 2552); built, not run (no GPU).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
LELEKA_SM120_HITS_IN_COMBINE: one leleka_verify_combine_k10_vec4_hits launch per layer
replaces moe_hit_add + the combine (mtp_full_combine or the COMBINE_VEC4 kernel), -48
launches per graph. New sealed asset sm120_combine_hits.cu/.ptx (nvcc 13.2.86, sm_120,
--fmad=true --ftz=false; pinned in extra-seal-plan.json and ptx-sm86/MANIFEST.json),
planner and ffn_hits_combine in original_verify_window_ops/hits_combine*, asset preloaded
via required_assets. Shapes the kernel does not fit record add_hits + the scalar combine.
Model-free probe tools/decode-sm120/sm120_probe_hits.cpp (+ build_hits.sh): add_hits +
combine against the folded kernel byte for byte, T 1-8; built, not run (no GPU).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
LELEKA_SM120_WAIT_M_ROWS (off by default): wait_cpu defers the ring, copy_cpu_rows records one
leleka_verify_wait_copy_rows launch (grid tokens x k, 128 threads) instead of verify_wait_flag_ge +
the rows copy. Thread 0 of each block polls, fences, block barrier, then the copy of
chain_copy_rows_from_mapped_kernel. PTX built with nvcc 13.2.86 and pinned (extra-seal-plan,
ptx-sm86 MANIFEST note). Model-free probe tools/decode-sm120/sm120_probe_waitrows.cpp (late flag,
T 1-8) built, not run (no GPU).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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>
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>
Merge of the speed session's driver part (DeviceRef handles, OriginalVerifier park/rearm, OriginalVerifyCanonicalGdn reseed; ptx manifest and seal plan entries of both sides kept, ledger rows of both sides kept) with the owner loan: the journal's owners are Option behind accessors, lend() uses the same idle precondition as the speed session's require_idle.
DecodeResources implements HeldAssembly for real (park, rearm from the session priors, lend and take_back through the journal loan; every refusal retires the set). OriginalServeStack holds a GraphReuse; decode assemble asks begin first (re-arm, refill queue; or the owners back to record), teardown keeps the assembly for a clean request (drafter end_request_keep_bank, shared-expert pin, park, lend, adopt) or runs the old teardown; retirement releases the drafter before the bank closes, in begin, close and reset_expert_tier. The MoE cache pins the shared experts while a set is held and counts freed window entries (weights epoch). Switch off: begin is not called and teardown runs the old body unchanged.
Tests: GraphReuse policy with a logging probe (switch off touches nothing, key change, moved owners, refused re-arm, lost owners, order release before drop), keepable outcomes, the lifecycle fake scenarios, the GPU-free loan state machine. Not run on a GPU. No speedup claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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>
Port of Strata upstream gdn_tc.cuh (strata-upstream/main 504b1433; history 8c2a84694, 06f212aef 99-KB split plan, 51567de1a two value tiles
per head from 96 SMs) as a new standalone sealed asset gdn_prefill_tc.cu/.ptx (sm_120, precise recipe of prefill_stage, extra-seal-plan group
gdn-prefill-tc, ptx-sm86 manifest: not built, the plan refuses cc < 12). Kernels: leleka_gdn_tc_prep (chunk algebra A, T = (I + A)^-1, P, f16
hi/lo images), leleka_gdn_tc_scan_t1 (48 blocks x 256) and _t2 (96 blocks x 128, the RTX 5090 plan, 170 SMs), 97,808 B of dynamic shared
memory, 254 registers, no spill. Same interface as leleka_prefill_gdn_rec_kh: state_in -> state_out, readout y, the non-finite state
witness from the final state. The fused norm, the 124-KB plan and the NP experiments are not ported; our out-norm kernel runs after as before.
Switch: typed setting prefill_gdn_tc (LELEKA_PREFILL_GDN_TC=1|on, serve_tests), GdnPromptOptions.tensor_core_scan through
Context::original_gdn_prompt_device_with; no env read in cuda-driver. Dispatch (gdn_prefill_tc::plan/ScanPlan::takes, host tests of the whole
decision table): switch on, cc >= 12, >= 48 SMs, >= 97,808 B opt-in shared memory, a run of >= 128 tokens; else the sequential kernels
unchanged, with one stderr line why. The scratch (942,272 B a chunk, 60,305,408 B at upstream's 64 chunks) is the prompt device's
dequantization scratch, idle during the recurrence on the one stream, so the super-block is 55 chunks (1,760 tokens) and the switch costs no
device memory. KernelModule gets launch_dynamic (cuFuncSetAttribute opt-in above 48 KiB) and device_geometry.
Identity is NOT bitwise, by design: the reduction order changes (WY chunking, f16x3 splits on mma.sync). Upstream first-token KL against the
sequential path: mean 0.0019, max 0.0125. The gates that decide are docs/quality-gate.md (first-token KL, q_tail_gate, logprob envelope) and
the harness gate 1e-4 (ignored GPU test gdn_tensor_core_scan_stays_within_the_gate_of_the_sequential_recurrence). Not run on a GPU here: no
parity, quality or speed result yet, no speedup claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
A draft step launches 48 numerical guards, one kernel per buffer. Runs of guards that are neighbours in the program (no kernel or copy between them) are launched as one mtp_original_check_batch at the position of the run: each entry keeps its own buffer, count, kind and status word, with the predicate and loop of mtp_original_finite / mtp_original_q8_guard, so the status words are the separate launches' words. 3 runs per step (5 prefix guards after the GR block, 5 tail guards after the MLP GR, 2 after the shared gate and up): 12 launches become 3. No guard moves across another command; nothing is removed.
New standalone sealed asset mtp_original_check_batch.cu/.ptx (extra-seal-plan.json entry, compile_assets.py + seal_pins.py with nvcc 13.2.86, sha pinned in mtp_original_full_symbols.rs), loaded only with the switch on; no existing sealed asset is touched. Pure planner and descriptor in cuda-model (draft_check_batch) with a simulated-step proof that a NaN/Inf placed in any checked buffer after any kernel leaves identical status words; driver tests on the real command lists; an ignored GPU test (batched against separate guards). Typed setting draft_check_merge, policy field check_merge, off by default. Identity, section delta and GPU proof pending; no speedup claim.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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>
The remaining refusal is device_poison (sealed PTX pinned at closed_kernels.rs, plan entry has no repin_expect): plan staleness from main, not from the splits.
SmokeInventory failed three tests at a4ceeab69 and 8890db316.
test_gates_values_and_classes_on_known_tests (caused by the S12c/S17 splits, seen after S22): the
fixture helper of actual_expert215_native_resident_gu_and_same_source_down_diagnostic moved from
mmq_native_resident_gpu.rs into mmq_native_resident_gpu/digest_fn.rs, and only `read` there opens
files. The scanner looked for file-reading helpers in the test's own file and one call deep, so a
test that reads a private fixture was classified device instead of assets. The rule is now the
module tree (x.rs with x/*.rs, or x/y.rs with x.rs) and the helper search is transitive. The
test expectation is unchanged: the smoke needs LELEKA_REAL_GU_DIR and is an assets test. Checked
against the merge base with main: every name that exists in both has the same class, gates and
needs.
test_every_smoke_lands_in_a_declared_group_and_dependencies_precede (51 smokes, 45 of them
already ungrouped on main): smoke-groups.json declares them. Unlisted cuda-driver smokes go to
transport (src/tests.rs and device_slab/tests.rs, which were lib.rs inline tests before S17,
mapped_file_dma_stress_gpu, native_head), qsa (late selection, mapped journal), mtp (scalar short
path), dispatch (qwen_dispatch/ children after the split) and runtime-moe (expert tier
residency). New groups: prefill-stage (depends on gr, gdn), pcie-copy, serve-probes (depends on
seal-loads) and cpu-probes, kind cpu: benchmarks, scale simulations and timing probes of
native-cpu-expert, engine-core and engine-qwen35-cuda that need no GPU and stay out of the default
device run. LELEKA_PLE_PROBE_ARCHIVE, LELEKA_PLE_PROBE_ROWS and LELEKA_SYNTH_KAR are asset
variables now, so the smokes that read the 55 GB archive are no longer classed as device.
CRATE_PACKAGE names leleka-engine-core, leleka-model-format and leleka-deploy (the plan used the
directory name as package).
test_doc_table_is_current: docs/gpu-bringup.md regenerated with smoke_inventory.py --update-doc
under WSL; the section on group order mentions the new groups and the cpu kind.
The 2026-10-25 upstream sync moved the Original kernels and the four experimental CUDA ports were not re-synced
(literal_port failed 4 of 6: 1, 5, 20 and 197 Original kernel-body lines missing).
* kv_stream: guarded shared atomicAdd; kv_q4: step_stride / planes; kv_q8: template <bool MULTI>; qsa_attn: attn_chunk_body with
reduce12_gfx906 / reduce12_head_of_lane. Bodies are copied verbatim; the entries keep their ABI and instantiate the Original's
single-token launch, so the sealed entry tables and the Rust facade are unchanged. The thread-emulation harness gives bitwise
identical results on the previous and the re-synced sources (fwht, q4, q8, route, cvec, attention m2/m3/m4).
* tests/literal_port.rs: per-function bodies; a device function of the Original that the port does not carry (SM60-only gather,
pre75 / merge_v2 / v3 / slot / row variants of the same arithmetic) is listed with its reason; the list is checked both ways, an
unlisted new function or a stale entry fails; self-test of the guard.
* experimental.rs: the PTX is not rebuilt (no nvcc on this host), so PINS[..].source_sha256 of the four programs still names the
previous source. admit() gains a source-seal gate (source_is_sealed) and PENDING_RESEAL lists the four programs: they refuse to
open until the server reseals them, and a unit test keeps the list exact. The sealed PTX and their PTX digests are untouched.
* docs/cuda-seal-plan-additions-experimental.json: new cu_pin of the four sources. reseal_own.py: --plan, refreshes seal_sha256 /
seal_length when the plan entry has them.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The accepted-prefix commit graph replayed each of the 36 GDN layers (conv history commit + recurrence replay through the accepted tokens) and each of the 12 QSA layers (tail restore +
8 row appends) as its own kernels. Two sealed kernels do all layers in one launch each: draft_commit_gdn_layers (precise math like original_verify.cu; the replay's output path,
which nothing reads, is not computed; the state-independent loads of all tokens are issued first) and draft_commit_qsa_layers (fast math like the resealed original_verify_qsa.cu;
one block per layer, rows in order). Model-free probe tools/draft-round/commit_probe.cpp: every state byte identical to the Original's kernels on 36 GDN and 60 QSA random
cases (n_keep 0..8, three RoPE settings, positions around block edges, holes); in a graph the GDN part is 346 -> 156 us, the QSA part 72 -> 4.5 us. Replay gate: draft-round-id1
(fused alone, DAILY alone and both): 2057/2057 top-16 logprob rows and 1036/1036 draft traces bit-identical, A/A exact.
Sealed with scripts/gpu-bringup (extra-seal-plan.json group draft-round, nvcc 13.2.86); ptx-sm86/MANIFEST.json records them as not built for sm_86 (record_commit fuses only on cc 12).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Ten files touched by this branch had been rewritten with CRLF line endings
(base versions are LF), inflating the diff against the merge-base to
13685/13039 lines. Content is otherwise unchanged: the diff ignoring line
endings was and remains 661 insertions / 15 deletions.
.gitattributes: crates/**/*.rs and scripts/gpu-bringup/**/*.py are text=auto
eol=lf, so CRLF cannot re-enter these LF files at commit time. text=auto leaves
files that are already CRLF in the index untouched.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
CUDA 13.2.0/13.2.1 miscompile some sm_120 kernels (IQ2_S/IQ3_S products wrong). validate_ptx (used by compile_assets and seal_pins) now reads the nvcc build from the PTX header and rejects those builds. A tree-wide test checks that every sealed PTX names a good build (today: none bad).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Replaces window_moe_gu_<T> + swiglu_entries_kernel + quantize_q8_1_kernel of every routed-expert group launch (VRAM and PCIe tier) by one launch of upstream's
native_gu_swiglu_kernel (16-lane sub-warp rows, gate and up row at once) for the gate/up types 16 17 18 21 22 23 at n_embd 2560, n_ff % 32 == 0; every other
format keeps the three-kernel plan. New sealed asset sm120_gu_swiglu.cu (group sm120-decode) textually includes sm120_iq_prefix.cuh, the pinned
iq_kernels.cu up to the dequant banner (generated and checked by scripts/decode-sm120/make_iq_prefix.py; the whole file would instantiate 24 MB of PTX).
Kernel parameter: upstream's 88-byte NativeExpertLayout (the window's 64 bytes + tail_off, had_block, d_signs = 0).
Switch: policy.gu_swiglu, resolved at window recording from the card (cc 12.0), LELEKA_SM120_PERF=0 and LELEKA_SM120_GU_SWIGLU=0|1.
Model-free probe (tools/decode-sm120/sm120_probe.cpp gu, RTX 5090): the q8_1 blocks the down kernel reads are byte-identical to the old three-kernel path in
30 cases (types 16 17 18 21 22 23, 1-8 rows, 1-40 groups, 1-7 entries a group, random blobs with valid block scales); per layer at 4 rows 20.9 -> 14.2 us (16),
29.8 -> 20.7 us (18), 24.9 -> 19.6 us (21), warm L2. Types 29 and 42 are not probed and not routed to the new kernel. Not yet measured end to end.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Ports engine/strata qsa_decode_attn.cu attn_chunk_kernel_pre75<mode 1, NC 2> and attn_merge_v2_kernel<16> as sm120_attn_daily.cu (new sealed asset,
group sm120-decode) and selects them in QsaWindow::decode_attention when policy.qsa.attn_daily is set. The policy bit is resolved at window recording
from the card (cc 12.0), LELEKA_SM120_PERF=0 (whole set off) and LELEKA_SM120_ATTN_DAILY=0|1 (wins in both directions, any card).
Model-free probe tools/decode-sm120/sm120_probe.cpp on the RTX 5090: chunk partials, merge(old) of both partial sets and merge_v2 are byte-identical to
the sealed Original kernels on 66 cases (T 1,2,4,5,6,8 x n_ids 2051..0, masked pages, two score ranges). Per call at T=4: chunk 29.8 -> 20.3 us,
merge 6.5 -> 2.9 us (warm L2, graph-timed); 12 QSA layers per window. Not yet measured end to end.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
leleka_qsa_topk_wide (also _sample/_wide_failed, measured and not used) in qsa_late.cu; leleka_qsa_topk_cluster in the new sealed asset qsa_cluster.cu (sm_90+,
no sm_86 companion); cuLaunchKernelEx plumbing for KernelModule and the verifier window (Launch.cluster); policy.qsa.cluster_topk. Same ids as qsa_topk_ref in
every model-free case (continuous, heavy tailed, tied, all equal; prompt tiles of 256 rows and decode calls of 1..5 rows up to 261,500 tokens).
LELEKA_QSA_TOPK=wide (prompt, from 10,000 blocks) and LELEKA_QSA_CLUSTER=1 (decode window) switch them on; defaults off until their R gate.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
New precise-recipe asset (extra-seal-plan group prefill-stage, nvcc 13.2.86), sealed with compile_assets.py/seal_pins.py, with its sm_86 companion.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The resolver PTX baked 8192 resident pages (--kv-resident 32768). Port the
Original's KvStreamMap::n_slots: leleka_qsa_resolve and leleka_qsa_stream_reset
take n_slots (resealed with nvcc 13.2.86, sm_120, precise flags; digests in the
window asset, the window seal plan and the ptx_abi test). Every streamed owner
sizes its resident runs and resolver state from the process-wide window
(configure_kv_resident, default 32768 cells = the previous behaviour) and
launches with its own slot count; the verify window carries it in its KV
binding. leleka-context: resident_pages_for (layer.cpp kv_plan rule),
resident_runs, stream_map_bytes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
bf16_f32_mmvf, gr_fixed and gr_batch_preview do mov.u64 R, shared_sym followed by
cvta.to.shared.u64 R, R. sm_120 tolerates it, sm_86 faults (CUDA error 700 in
full_matrix_transport_gpu dense-bf16-gdn-z on the RTX 3080 Laptop). The sm_86
companions omit the cvta; sealed sm_120 files are untouched; verified by the
smoke passing after the change.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Default build unchanged (arch_ptx::image is the identity without the feature,
sm_120 PTX and all pins untouched). With --features sm86 every cuModuleLoadData
site hands its sealed image to arch_ptx::image, which on a device with
8.6 <= cc < 12.0 looks the image up by the SHA-256 of the sealed sm_120 body in
the generated table and admits the companion only through sealed_ptx::pinned.
The four sm_120-only capability gates (MMQ resident, scalar/full/prefill MTP)
accept sm_86-class devices under the feature. leleka-runtime and
strata-desktop-core forward the feature. run_gpu_smokes.sh: SMOKE_SM86=1 adds
it to the test builds.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
scripts/gpu-bringup/sm86_assets.py: survey / infer / build / compare / check.
Default method is retarget (the sealed text with the .target line and two
documented sm_90+ rules edited, accepted only if ptxas -arch=sm_86 accepts it);
recompile from the .cu is the fallback and needs a recipe verified by a round
trip on sm_120. sm86-recipes.json is the round-trip evidence.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Adds the six audited assets (head_native, original_verify_qsa, router, gr_post,
gr_norm, ple_native_batch) as an atomic reseal group built with --use_fast_math,
re-pins their old digests (incl. ple PTX_BYTES) and window-plan hex, and a
generic --flag-override recorded in the manifest and re-applied by the sealer.
compile_assets --isa-inventory/--driver-check and run_gpu_smokes.sh refuse a
driver older than the highest PTX ISA in the tree (9.0 needs >= 580.65.06).
Runbook: mandatory reseal + golden comparison section, step d' (linux-tests).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
smoke_inventory.py scans every real #[ignore] attribute, extracts the enabling
LELEKA_* flags and values, classifies tests (device / assets / mock) and assigns
them to dependency-ordered groups (smoke-groups.json). run_gpu_smokes.sh runs
them in order, stops a group at its first failure, skips dependents, continues
independent groups, treats a filter that matches nothing as a failure, records
nvidia-smi before/after, refuses a busy GPU and never starts a model run
without --allow-model-runs plus caller-supplied env. remote_sync.sh mirrors the
tree (no --delete, refuses to clobber unpulled sealed files) and builds the
three binaries and the test binaries on the host; host_sanity.sh is read-only;
record_env.sh captures hardware/software/model digests for the ledger.
Tested with stub cargo/nvidia-smi, shellcheck and a Linux container.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
compile_assets.py reads docs/cuda-seal-plan*.json (assets and new_sources
formats), an extra plan for assets no plan covers, and the four rope PTX list
of docs/rope-and-memory-plan.md; verifies .cu pins, runs nvcc with the exact
flags (fast-math policy lint, rope flag variants), validates exports and ABI
parameter counts, and writes PTX + build-manifest.json outside the tree.
seal_pins.py installs the PTX in the encoding each consumer expects and patches
every pin form (PtxPin arrays/structs, AssetSpec.sha, Option tuple arrays,
plain len/sha consts, re-pins of regenerated rope PTX, ptx_abi test) with
exactly one replacement per field and a read-back check. fake-nvcc and a
unittest suite exercise the pipeline on macOS; no GPU, no generated PTX.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>