Repository navigation
WHIR no-epoch (prove-and-retire) prover: block 25368371 — work in progress - #1014
Draft
MauroToscano wants to merge 2546 commits into
Draft
MauroToscano wants to merge 2546 commits into
MauroToscano wants to merge 2546 commits into
Conversation
|
Benchmark Results for modified programs 🚀
|
|
Benchmark Results for unmodified programs 🚀
|
MauroToscano
force-pushed
the
noepoch/whir
branch
from
October 1, 2026 14:57
e9107c6 to
97ba486
Compare
MauroToscano
added a commit
that referenced
this pull request
Oct 2, 2026
… leaves The builder kept every walked window until finish, so at the run's end all of its op lists were resident, about 300 B per cycle (0.28 GiB per M cycles: 8.6 GiB on block 25368371 and about 100 GiB on a median mainnet block). WindowedTraceBuilder::drop_streamed_ops keeps only the ops not yet in a handed-out chunk for each of the 8 streamed tables (Tail: the windows' lists moved in whole and freed once used up). As a chunk leaves, the builder takes what the table phase would have read from its ops. It counts BITWISE's lookups from LT, SHIFT, STORE, MEMW_A and MEMW_R, plus DECODE's lookups and the last ECALL from CPU. It derives and keeps the phase-3 LT ops of MEMW and MEMW_A, unless stream_memw_lt already put them in the windows' LT lists. The other walk lists are appended window by window instead of being concatenated at finish. The in-walk BITWISE lookups are counted and dropped. finish runs the table phase over the tails (StreamSkip::tails), padding the dropped CPU chunks and placing the kept LT ops where phase 3 would have derived them. The tables are the same. The new tests compare every table with the whole-run build, and with stream_memw_lt every table with the builder that keeps its windows, plus LT's multiplicities. Both go through push and the split, at window lengths 1 to the whole run, and with chunks small enough that all 8 tables drop. The same comparison runs with KECCAK_RND streamed. Another test checks that after each window each table holds less than a chunk of ops. Removing any one accounting step (LT, MEMW_R or DECODE counts, the CPU padding, either LT prefix) fails the first test. Off by default. Cherry-picked from mem/m1 74e1df1 onto #1014, with the streamed finish's build marks kept.
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
…es are laid out #1014 now lays the streamed chunks out on three workers (0498480), and phase A waits on the groups the rest closes, which close only once the whole rest is laid out. With b1's waves the AIR order's prefix is laid out first, so pack_rest_as_laid_out (the rest's sink, groups identical by test) is now on in production: each wave's tables go to the packer as the wave ends, and a group closes once its own tables are laid out. Laid out all at once, the first table in AIR order was ready only with the last, which is why packing as laid out read +0.21 s before (FAST 422). The real-block tests' BLOCK_WHIR_PACK_REST=0|1 now overrides the production choice instead of replacing it with off. Readouts for the finish's place in phase A: each group's commit start (from@, beside done@), and every rest table's layout end and group in AIR order (BLOCK REST TABLES).
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
…s its tables, the block memory log) into nw2/r2ii No conflicts. multilinear_block.rs: the memory log's phase-B marks and the group observer sit side by side at the end of each group (the observer first, then the group's columns are released and the mark taken). block_whir.rs and the W3 harness: the new BlockOptions fields and the memory log's plumbing next to the group observer's.
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
… proof to an observer; the block tree's first leaf executes during phase B) into m4b/b2 No conflict. R2-ii's two full BlockOptions literals in lfm/whir_block_tests.rs already carry b2's pack_finished: true, so its hand-over tests run with the finish's tables packed, as production does.
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
…14fea1 crypto/stark/src/narrow.rs and crypto/stark/src/spill.rs are #1013's files, byte-identical to mem/stark-f1 @ e5214fea1 (i-mem3's F1: the page-backed Bytes, the streaming Digester, the fused writer, over the S1/S2 store). #1013 is their one source of truth: #1014 never edits them, re-imports any change from there, and they merge as one when both PRs reach main. Wiring only: the two modules in lib.rs (dead code allowed there, since some parts serve #1013's prover alone), math's page-bytes feature, and libc unconditional as the store needs it (it was behind disk-spill). #1013's prover glue (TraceTable::spill_main) and its spill tests are not imported; #1014's adapter and tests follow.
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
… reserve LAMBDA_VM_BLOCK_SPILL now reads as #1013's (prover/src/block.rs SpillPolicy … spill_decision @ edddc68): auto (and unset) | off | always | <GiB> resident budget. auto spills a committed table once the host's bytes (the larger of VmHWM and the cgroup's memory.current), the reserve and the table would pass the target (LAMBDA_VM_BLOCK_SPILL_TARGET_GIB, else the cgroup's memory.max less 10 GiB, else MemTotal less 10 GiB). Phase A decides per table and never past the writers' queue; groups 0 and 1 count but never spill. The reserve is #1014's own, inferred from the median block (BIG 565): the finish's p5 transient (25.5 GiB) and the tree's leaf programs alive through phase B (16.3 GiB), about 1.25 GiB per total G cells or 1.65 per G cells committed so far, plus 6 GiB for phase B's bump and the read-back window. BlockSpill carries the policy's choice (SpillWanted) and the kept bytes and committed cells it reads. A block that fits spills nothing; the store opens for every policy but off. Tests: the knob and the decision (unit), a budget the block fits in spills nothing and one of zero spills (block).
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
…@ 278e6a8 The rule #1014 copies from #1013 read only cgroup v2's memory.max and memory.current. On a v1 host (FAST) the target fell through to MemTotal less 10 GiB, and the host's charge was not read at all. #1013 fixed both in 278e6a8; this re-copies spill_target_bytes, spill_target_from, cgroup_memory and host_bytes_now from that sha, with its two tests (the cgroup files from fake trees, and the target rule), cited as before. The only changes from #1013's text are the citations and the tests' temporary directory, which gets a name of its own so the two copies of the test never share one if they ever run in one process.
MauroToscano
added a commit
that referenced
this pull request
Oct 3, 2026
…cf253d2) The host measure #1014 copies from #1013 took max(VmHWM, the cgroup's charge), and the charge counts page cache. FAST charged 40.58 GB at 17:28Z with 15.18 GB of it inactive file pages, which would have made auto spill the last groups of a 1x block that fits. This re-copies #1013's measure from its landed head 035aef5 (commit cf253d2): HostReading reads VmHWM, the charge and memory.stat's inactive file pages (v2 inactive_file, v1 total_inactive_file, by their exact key), and the host's bytes are max(VmHWM, charge - inactive_file). CgroupValue lets cgroup_memory read a whole-file number or one memory.stat key. The BLOCK SPILL line ends with the largest reading auto decided on, as #1013's does. With #1013's two tests; the text differs only in citations and the test's temporary directory. The rest of #1013's train (lazy queue budgets, the allocator purge) is not copied: #1014 has no queue budgets.
MauroToscano
added a commit
that referenced
this pull request
Oct 4, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 4, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 4, 2026
The spill code (stark, multilinear, block_whir) and the streamed top (executor, proof, the W3 tree) touch disjoint code; the one shared file, whir_block_tests.rs, merges without conflict (the spill side adds BlockSpillPolicy::Off to two test fixtures).
MauroToscano
added a commit
that referenced
this pull request
Oct 5, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 5, 2026
MauroToscano
added a commit
that referenced
this pull request
Oct 5, 2026
…114; min proven bits unchanged at 130.393) The default flip of LAMBDA_VM_ZF_WHIR_GRIND_BITS: the port of #1010's 5364aa2 and its pin follow-up 2687e48. PRODUCTION_WHIR_GRIND_BITS is 18; LEGACY_WHIR_GRIND_BITS = 20 keeps the legacy format and is the opt-out (LAMBDA_VM_ZF_WHIR_GRIND_BITS=20). It reaches #1014's WHIR proofs: the block's group chains and prepared openings, verify_block_whir, and the W3 leaves' in-guest verifier. The W3 tree's own STARK LFM proofs do not read it. The binding WHIR phase is unchanged (the unground fold at 27 variables, 130.393 bits); the query phases move 130.926 -> 130.907. Measured behind the knob on c55dec4: ULTRA 019 1x phase B -0.344 s (t -12.9), whole -0.270 s, recursion -0.010 s; BIG 628 median whole -3.42 s, both arms verified. The opt-out reproduces the previous 1x proof byte for byte (top digest 0da6fea9 under fixed hash keys and deterministic grind); the new default's is b9b4826d. The W-leg sizing pins follow the process's grind bits, as 2687e48 did on #1010.
MauroToscano
added a commit
that referenced
this pull request
Oct 6, 2026
…all, commit pairs off the pool) ULTRA 096 (median 25475471, #1014 + cap 256, one binary, 3 + 3 runs plus 2 + 2 single-lever arms) read LEVER EFFECTIVE on every pre-registered row: phase-A end -6.66 s with every run of the pair below every run without it, whole block -6.86 s (154.67 -> 147.81 s), finish 15.8 -> 9.3 s at most, KECCAK_RND's span 12.0 -> 5.4 s at most, the largest phase-A commit 2.93 -> 0.68 s, the card's wait for the rest 6.65 -> 1.77 s, max RSS -0.97 GiB. The wave alone gave -5.92 s whole, the commit pairs alone -0.47 s. At 1x (ULTRA 095) the pair is neutral (whole -0.016 s, t -0.4) and the top digest is unchanged. Both become the defaults; the knobs stay as opt-outs: LAMBDA_VM_KR_PACKED_WAVE=4 builds the chunks four at a time again, and LAMBDA_VM_BLOCK_COMMIT_OFF_POOL=0 puts the commit pairs back on the global pool. The proof bytes are the same either way.
MauroToscano
added a commit
that referenced
this pull request
Oct 6, 2026
…W_WINDOW=1) A #1014 block leaf's LFM_BALU is 70,692 rows a full group, so a 4-group leaf holds 282,768 rows and pads to 2^19. 34,200 of a group's rows are the lean fold's point x0^-1 = prod g^(-2^i b_i): one Select and one Mul a bit through edsl::pow_bits. pow_bits_windowed drops the identity multiply (the first factor read is the accumulator) and reads each of the first two bit pairs through a 4-way Select mux over the constants {1, f0, f1, f0 f1}. A fold then pays three fewer Muls and two more Selects at four or more index bits, two and one below. A full group goes -6,498 LFM_BALU and +4,104 LFM_SELECT, so a 4-group leaf's LFM_BALU drops to 256,776 (under 2^18) while its LFM_SELECT stays under 2^19 at 480,168. The value is the same and so is the Select semantics. The knob is read at program emission like LAMBDA_VM_WHIR_FOLD_CLASSIC and defaults off, so today's programs and ids are unchanged. pow_bits itself is untouched, so the STARK paths keep their programs. The lean fold's row and constant closed forms follow the setting.
MauroToscano
added a commit
that referenced
this pull request
Oct 10, 2026
…E_DOWNLOAD (default off) The port to #1014 of #1013's 6d25865: the same changed lines in device.rs, lde.rs, stark's gpu_lde.rs and the new device test, applied to functions that were identical on both PRs. On a precomputed-tree cache miss the preprocessed commit downloads the full node buffer into a zeroed pageable Vec<u8> and stark copies it once more into Vec<[u8; 32]>. #1014's median recursion pulls about 14.7 GB this way at 2.75 GB/s (I-PROF4 B.5.1). LAMBDA_VM_TREE_DOWNLOAD=staged sends it through a staging pair straight into the node vector and queues the multiplicity tree behind the last chunk; the device peak stays one tree and the nodes are the same bytes.
MauroToscano
added a commit
that referenced
this pull request
Oct 10, 2026
The port to #1014 of #1013's 814a4b6. LAMBDA_VM_TREE_DOWNLOAD unset (or any unknown value) now selects the staged download; `legacy` or `pageable` keeps the old pageable copy as an opt-out. The nodes are the same bytes on both paths. A unit test pins the default. On #1013, legacy vs staged on the median 25475471, one binary per job: recursion -2.94 s (t -15.9, ULTRA 094) and -6.26 s (t -27.6, RYZEN 002), with the base digest and the top program id unchanged (ULTRA 093, 100). #1014's own gate is I-COPIES §10.
… off)
A block can now argue the lookups into verifier-fixed tables group by
group, under each group's own LogUp challenges, instead of under the
block's shared ones. Without the new option every byte is today's.
- The batched argue's phase G is one function over a class of a group's
tables (prove_ladders / verify_ladders); the class is a pure function of
the bus id (ClassTables::split). Today's argue is the one class of every
table and every interaction, byte for byte.
- A group's local transcript continues its commit-time out-of-domain
transcript: its answers, a label and one digest per table, then
(z_g, alpha_g) (local_challenges, table_digest). The local ladders run on
it (prove_local / verify_local); the local outputs must sum to zero per
group; the transcript's state is absorbed first into the group's fork.
- The C phase takes each table's local claim pair as two more rules at
lambda^3, lambda^4, the tables weighted lambda^{5t} in a local group;
front_loaded::TableRounds takes its eq weights as a slice.
- The verifier refuses any receiver on a local bus that reads committed
columns (the static check the format's soundness rests on), checks each
group's local balance, and the global balance once, as today.
- BlockProved carries the local argues; block_verify_with takes the
verifier's local buses and digests with the proof's local argues.
Tests: a small block with local senders and a fixed receiver in two
groups round-trips under every packing; a group with no local interaction
argues today's bytes; the local transcript is pinned by hand and moves
with every root, answer and digest byte; each forgery (a false lookup, a
dynamic receiver, a wrong fixed column, counts or constants chosen after
the local challenges, a forged local output, a receiver in another group,
swapped or tampered local claims, a wrong weight, format confusion, shape
tampering) is refused, and where a check refuses it, the verifier with
that check off accepts it.
(cherry picked from commit 741cd56)
- Two bus ids, LocalAreBytes (46) and LocalByteAlu (47), for lookups argued per group. - KeccakRndForm::LeanLocal: the lean form's interactions with its 1,008 byte lookups moved to the local buses in place (same tuples, multiplicities and columns). BITWISE no longer receives them: the finish's side count skips the rounds' lookups and the padding rows' AreBytes under this form. - tables::local_bytes: the 2^16-row LOCAL_BYTES table (X, Y, X and Y, X xor Y preprocessed; three committed multiplicities) receiving those tuples, its AIR, and its counts: from a KECCAK_RND table's records by replaying the rounds a row range covers (emit_keccak_rnd_rounds), or from any table's columns through its interactions (the reference). Tests: the local form moves exactly the 1,008 byte lookups; the counts from records equal the counts from the table's columns for whole tables, chunks that start and end inside permutations and a padded last chunk, and the chunks sum to the whole; a false tuple is counted nowhere; the fixed columns and receivers. (cherry picked from commit 26e6fc4)
…form A block whose KECCAK_RND sends its byte lookups on the local buses (KeccakRndForm::LeanLocal, LAMBDA_VM_B3_BASE_LOCAL=keccak on the BLAKE3 base, off by default) argues them per group: every group that holds a local sender ends with its LOCAL_BYTES table, and the block prover and verifier run the stark crate's local lookups over the groups. - Format: BlockFormat::local_lookups reads the KECCAK_RND form; the tag gains /LL1; the knob is the BLAKE3 base's alone. - Prover (streamed): each laid-out table's local sends are counted on the thread that laid it out (records by replaying rounds, else through the interactions); the packer adds them to the group the table joins and closes that group with its LOCAL_BYTES table, the j-th such table at index N + j after every other table. Phase B takes the local buses and every local group's table digests. - Statement and frame: the LOCAL_BYTES count is derived from the stated heights; no table before N receives a local bus; tables from N on are LOCAL_BYTES at 2^16 rows; each group with a local sender ends with exactly one, in order, and no other group holds one. A group's LOCAL_BYTES is outside its stack budget. - Proof: BlockWhirProof gains a type parameter and a last field `local`; today's proof carries `()`, which archives as nothing, so its bytes are unchanged. A local proof carries every group's local argue and comes from prove_block_whir_local; each format's verifier refuses the other kind. The recursion's plan refuses a base under local lookups. Tests: a block with KECCAK_RND proves and verifies under local lookups with its LOCAL_BYTES tables in place; format confusion both ways; today's proof archives byte for byte as the layout before the field; the frame refuses LOCAL_BYTES moved, misplaced, doubled, missing, traded or at another height; the knob and the tag; the recursion's refusal. (cherry picked from commit 4f17784)
…eview label (cherry picked from commit d34183d)
… box-tier Comments and docs name each step of a group's local transcript by what it absorbs or draws, not by a design document's step labels, and drop the star markers from the new code. The prover crate's tests that prove a real block are ignored by default (run them with --ignored --test-threads=1); the knob and tag tests stay. (cherry picked from commit 6581c03)
A table whose interactions are argued in two classes (its global buses and its local lookups, each claimed at its own GKR point) has five rules in the batched argue's constraint phase. The fused card session declined anything but three, so such a table ran its rounds on host factors. - math-cuda: FusedZerocheck takes an optional second bus column: its coefficients, constant and weight table; its column sits after the first bus's in the folded slab and is folded with the factors. The grid pass sums its four U' values with zc_bus_u; each later round sums B'(0) and B'(1) with zc_round_gruen launched with no node (its two bus rows alone) into the sums after the first bus's. No kernel changes. - multilinear: FusedInput carries an optional second bus (interactions and claim point); FusedStepper accepts five lambdas with it, adds the second bus's term to every message (fused::with_bus), takes its share off the claim when recovering A(1) (fused::bus_sum), and hands the host tail its third weight. - stark: the batched argue gives a table with both pairs to the fused session with its second bus, instead of the host. Tests: the message and claim algebra with a second bus against a brute-force round polynomial (laptop); a card test (ignored, box tier) that runs KECCAK_RND and CPU at 2^10 and 2^12 through TableRounds on the card and on the host with five rules and compares every message, the point and the factor values, with a faulted bus as the negative control. (cherry picked from commit 1468aab)
(cherry picked from commit 70288b8)
The batched argue's per-bin body is now its own function over a ladder state (outputs, claims, ladders, bin seconds), and the ladders loop it. A local argue's prover keeps its plan, members and interactions lowered under the group's challenges, and runs the next bin on each step on the transcript the caller holds: stopped after any bin and resumed later, on any thread, it sends the bytes the whole argue sends. prove_local is the prover made and stepped to its end, byte for byte as before. ProverFaults::is_none names every field, so a faulted argue can be told from an honest one. (cherry picked from commit 1f13143)
Under local lookups phase A now takes each table's digest from its own layout (the AIR's preprocessed count is carried by the layout, set where both sides build it) and, right after a local group's commit has its roots and answers, draws the group's local challenges with the one function the verifier calls. The lane beside phase A runs those groups' local argues one bin a unit, under its existing commit gates and memory rules; a job stopped for any reason hands its prover and transcript to phase B, which runs the bins left at the group's turn. A unit that fails drops its job, and phase B argues the group from fresh challenges. The proof is the same byte for byte wherever the bins run. LAMBDA_VM_LOCAL_LANE: unset or 1 lets the lane run them, 0 leaves every bin to phase B; anything else is refused. The streamed prove refuses commit-time digests that differ from the verifier's, taken from the AIRs. BLOCK LOCAL LANE lines report each local group's bins by phase. (cherry picked from commit 2911890)
prove-block-base now proves and verifies a format that argues KECCAK_RND's byte lookups per group (a proof type of its own). The tree config takes the production format's KECCAK_RND form when BLOCK_WHIR_KECCAK_RND is unset (lean, unless the BLAKE3 base's local knob asks for local lookups; the two knobs together are refused), so that knob reaches the command. The local lane's readout counts the bins of a job refused before it started from the bins phase B ran. (cherry picked from commit 5c91048)
The block leaf verifies a base under local lookups: a group with a local interaction continues its commit-time transcript with its answers, the label and its tables' digests, draws its own challenges, checks its local ladders and asserts its local balance in the leaf, absorbs the local state into its fork first, and argues its global class with each table's local pair (weights lambda^5t). LOCAL_BYTES' fixed columns are checked by their closed form. The plan runs the static receiver check and takes the digests from its own AIRs. The levels driver and the tree pipeline prove either kind of base. Tests not yet run. (cherry picked from commit a74dfb9)
Tests of the leaf over a base under local lookups: the leaves execute and close the bus, the local challenges are the host's, every leaf mutant refuses the honest base, a false local lookup and a wrong LOCAL_BYTES column are refused by the checks that drop them, faulted, tampered and misshapen local argues and the other format's base are refused, the levels driver proves a small local base to its last level, and the plan's static receiver check refuses a dynamic local receiver. A prover's wrong LOCAL_BYTES tables for them (Deviations::local_bytes). A group handed over by phase B with no local argue reads as one that argues none. (cherry picked from commit 6107286)
… no local argue Clippy fixes (a named claim type, the fork's state order behind one function, needless borrows). The arena takes a group with no local lookup handed over by phase B without a local argue, as the levels driver hands it (its test proved a local base to its last level). (cherry picked from commit 636bb04)
…knob The leaf's local balance takes each local tree's share as p times the inverse of q under every share setting, so a zero denominator has no satisfying assignment (a quotient leaves the share free at p = q = 0). (cherry picked from commit daf90c4)
… on their inputs Default-tier tests of check_local_groups and check_local_airs on hand-written groups and AIRs, each refusal by its message, among them two sending groups' LOCAL_BYTES traded (the base + j rule, which the real-block frame test cannot reach with one sending group). local_digests reused a digest by the interaction list's address, height and width alone; every table with no interaction shares one empty list, so two such tables of one shape and different preprocessed counts got one digest. The cache now keys on every input of the digest, with a test. (cherry picked from commit 3b321f8)
…tants The plan's static receiver check now runs once the plan's routes exist, over every group: a local receiver may read only the columns its table's route checks. Mutant tests: the local transcript reads the front's root and answer cells (a leaf reading hinted copies needs a longer arena), the local balance divides p by q whatever the share knob (a leaf following the knob emits one product fewer a local tree), and the format confusion tests read the frame's own refusal. (cherry picked from commit cbc500d)
…ined column
The static check of local lookups holds receivers to fixed columns and
says nothing of a sender: a local sender whose multiplicity could be -1
would receive committed values and cancel a false tuple. A default-tier
test pins every form's local sends to multiplicity One (200) or MU (808),
and MU to {0, 1} by KECCAK_RND's own constraints.
(cherry picked from commit 6ac399a)
…ult tier Two digest pins of a leaf under local lookups over a hand-built statement (Poseidon1, one group a leaf; BLAKE3, one leaf), no proof: deleting the leaf's local-balance assert, a quotient local share or another closed-form bit order moves them, as does each local test fault. A test hook builds the frame's LOCAL_BYTES with other interactions, and a test derives a plan over a receiver reading a committed column: refused by the plan's static check, and derived with the check off. The hand-built statements close each local group with its LOCAL_BYTES. One test fault's comment corrected. (cherry picked from commit e61a250)
A default-tier allowlist over the whole AIR set the frame builds under local lookups: every local sender is a KECCAK_RND table, whose multiplicities its own test pins, and every local receiver a LOCAL_BYTES table. The static check holds receivers only, so a local sender anywhere else (one with a free multiplicity receives committed values) was visible to no test; with such a sender added to LOCAL_BYTES the test names it. (cherry picked from commit 6d34b1a)
The plan derived a local group's two class splits four times (the cost, the chip-load probes, the emission and the arena words), routed every table for the static receiver check, and built statements to tell a local group, which put level 1's program 0.6 to 0.7 s later under local lookups and its prepared stacks after the base. The plan now splits each local group once at derive, shared by groups of one definition (keyed by the tables' digests, families and constraint shapes), and reads it everywhere; the receiver check routes only the tables with a local receiver (a table with none passes it whatever its route); and a local group is told from its AIRs' interactions. No proof byte, leaf or verifier rule changes: the leaf and digest pins are unchanged. A test checks each shared split equals the group's own; a timing probe compares the derivation and the walk with today's format. (cherry picked from commit 8ee0194)
(cherry picked from commit 38ce099)
…o heights The split each local group takes at derive is shared by groups with one key, and the key's table digests are what keep groups of one family list at different heights apart. The test's statement had every KECCAK_RND table at one height, so a key of family names alone passed it. The statement now puts KECCAK_RND tables at 2^16 and 2^15 rows, each in a group of its own (mix_statement_split), so two pairs of groups share a key and groups of one family list differ by height. A test fault leaves the digests out of the key; under it the plan no longer derives (its probe of the shared split refuses), and the test asserts that. ClassKey's doc says what the key leaves out (the shifted flag) and why the digests are real for every local group. (cherry picked from commit 0ffeefc)
…roup by default LAMBDA_VM_B3_BASE_LOCAL unset now means on for the BLAKE3 base (B3_BASE_LOCAL_DEFAULT; B3_BASE_KECCAK_RND is LeanLocal); `off` or `0` keeps the lookups in the global bus, and `keccak` still names them. Another base stays lean when the knob is unset, and asking it for local lookups is still a configuration error. b3_base_local_setting now returns None for an unset knob. The levels verifier pins the same form: pin_family sets KECCAK_RND's form to B3_BASE_KECCAK_RND on the BLAKE3 base, so verify_block_levels checks the default proof. check_process_format reads the knob through its own refusing parser and refuses, by name, local lookups off under BLAKE3 and local lookups asked for under Poseidon1; a malformed word is an Err under either. Readers swept: the production format (block_whir.rs); the tree config's BLOCK_WHIR_KECCAK_RND refusal beside local lookups (its message says how to turn them off); the round-form level test over a real block, which now proves either kind of base; the BLAKE3 tree test's comment. The CLI's base command, the levels driver and the BLAKE3 tree test already prove either kind. The pinned (Poseidon1) presets and every leaf and digest pin are unchanged: the test process keeps the Poseidon1 base, whose production format argues none. Tests: the knob test reads the new default; the family pin asserts the local form on BLAKE3 and the lean form on Poseidon1; the format-knob test refuses local lookups off (BLAKE3) and on (Poseidon1) by name; two new child-process scenarios (`off`, a malformed word). (cherry picked from commit b2d855e)
…one narrow commit The narrow commit (LAMBDA_VM_LEVELS_NARROW_COMMIT, off by default) packed each prepared stack at its commit, on the path after the base. Now the level's host part packs the stacks on two threads of their own beside the base's phase B (WlfmPrebuild::hold_narrow_packs, GroupStack::pack_narrow), and the commit sends those bytes when they fit its columns, else packs as before. Word 2 copies each packed run through the card's double-buffered pinned staging (upload_packed_store_staged, upload_store_tables_staged, widen_col_major_into_staged) instead of one pageable copy a run. The same words at the same places, so the same roots and proofs. The retired stack's packed bytes still serve the opening's narrow store, and the store's promise at admission is unchanged. The harness's NARROW COMMIT line counts the stacks packed ahead. The same-bytes test covers packed at the commit, packed ahead and staged, in every place, with the narrow store on and off, under the overlap planner's defaults. (cherry picked from commit a36d246)
Under RTA_L1_GROUPS the harness proved its base with today's prover, so on the BLAKE3 base, whose default is now local lookups, it proved a whole base and then refused it. It now proves through the local prover when the format argues local lookups and holds either kind as AnyBlockWhirProof; level 1's first-groups run, the arena and the host's bus sum already take either kind. (cherry picked from commit 3faa652)
The local-lookups block format made verify_block_whir and
verify_block_whir_with generic over the proof's kind (`<L: LocalPart>`), so
the scan's anchors for them, written for the plain signatures, no longer
matched and the scan refused the real sources. The anchors now name the
generic signatures; the scan still requires both to survive the test-gate
skipper. A planted `#[cfg(test)]` before verify_block_whir is refused
("does not reach"), so dropping the anchor turns the planted-regression
test red.
(cherry picked from commit d2239c9)
…le copy a run LAMBDA_VM_LEVELS_NARROW_COMMIT now reads as on when unset, in the form NARROW_COMMIT_DEFAULT (1: each packed run sent with one pageable copy); 0 turns it off, 1 and 2 pick a form. The same words at the same places, so the same roots and proofs. (cherry picked from commit 6649ae6)
the_public_levels_verifier_accepts_at_the_pinned_format proved test_commit_4, a program with no keccak call, so the public entry only met local lookups with an empty local plan. It now proves test_keccak, whose KECCAK_RND group is closed by its LOCAL_BYTES table, and asserts the pinned format argues local lookups and the base carries a local group before verify_block_levels accepts it. (cherry picked from commit f6fb79a)
The two local leaf pins derive from the test process's production format, which argues the one-layer GKR ladder. A third pin derives the hand-built local statement's leaf under pin_family(pinned_with(Indexed), B3, Fri): local lookups, the two-layer ladder and the base's group size, the leaf a public entry derives. Every local fault moves its digest. (cherry picked from commit 3fca95a)
Every negative test of local lookups ran under the one-layer ladder, while the BLAKE3 base's default and its levels verifier argue the two-layer one. The stark crate's false local lookup and forged local output now also run under GkrLadder::Double: the first refused by the local balance (and accepted with the balance off), the second by its ladder. The leaf's false local lookup case becomes a helper with a two-layer twin: the host refuses it for the local balance, the leaf refuses it, and the leaf without its balance assert executes it. (cherry picked from commit 67f23c8)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
One WHIR (multilinear) proof per block, with no epochs (the prove-and-retire / VADCOP shape). This is a second prover next to #1010's epoch-based one. #1010 stays the reference and this branch does not touch it. The branch starts from #1010's head
f3d359998; compare againstf3d359998to see only this work.What it is
prover::block_whir::prove_block_whir/verify_block_whir. The whole block is oneMultiProof:(z, α, β)are drawn once.S_post ‖ g: upload again, argue (LogUp-GKR), re-encode with the NTT alone, open. The dropped tree levels are rebuilt from the queried cosets and checked against the kept nodes.WindowedTraceBuilder(noepoch/windowed-builder, also used by STARK no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1013). Every full chunk of CPU, MEMW_R, MEMW_A, MEMW, LOAD, LT, SHIFT and STORE is laid out and committed as soon as it exists.⚠ Format changes (all approved by Mauro, 10-02 (§7 on 10-05), but §6, the port of #1013's S0a; for the cryptography team's end review; ledger rows W-0…W-6, W-8, W-9 in CRYPTO-REVIEW.md)
The block is one WHIR proof (
BlockWhirProof, oneMultiProof) over all of the block's tables.z, α, β.S_post ‖ g).Every parameter below is a verifier-side constant. None is read from the proof.
BLOCK_GROUP_POLYSBLOCK_MAX_GROUPSBLOCK_MAX_TABLE_VARSBLOCK_MAX_KECCAK_RNDBLOCK_KECCAK_RND_MAX_VARSBLOCK_MAX_ECDASBLOCK_ECDAS_MAX_VARSBLOCK_MAX_KECCAKBLOCK_KECCAK_MAX_VARSBLOCK_MAX_ECSMBLOCK_ECSM_MAX_VARSArgueFormat::BATCHEDPRODUCTION_WHIR_GRIND_BITSLEAF_PERMS_CAP,BLOCK_FAN_IN1. The group partition is in the statement
What. The streamed prover packs tables into groups in the order their chunks complete. It writes the partition (per group, its tables' indices) into the statement. The transcript absorbs it before any root.
Verifier. The verifier checks:
It then rebuilds every group's stack layout itself.
Security. Proven bits are unchanged.
BLOCK_MAX_TABLE_VARS(change 3), so no partition can make a chain taller than 2^27.Proof bytes vary from run to run. Arrival order depends on thread timing, and the hash-ordered tables' row order (LT, EQ, BYTEWISE, BRANCH, MUL, DVRM) follows a hash state that is random per process. Mauro, 10-02: "the proof not having the same bytes it's fine, they never had the same bytes anyways".
LAMBDA_VM_FIXED_TRACE_HASH=1(fixed hash keys) andLAMBDA_VM_DETERMINISTIC_GRIND=1. Under both, two processes prove the same bytes (FAST 423).2. Prepared openings, one stack per group (approved by Mauro, 10-02: "it's a standard technique, go ahead")
In short. This is #1010's existing prepared DECODE opening, carried into the block format. It is extended to the dense genesis pages and stacked per group.
What. The recursion guest cannot evaluate DECODE's five 2^20 preprocessed columns, nor the dense genesis pages (millions of rows), on its own. So each group's prepared tables (DECODE and the dense genesis pages chosen by
genesis_stack_plan) have their leading preprocessed columns stacked into one commitment.verify_block_whir, andverify_block_tree's plan. The prover's own roots only shortcut the prover's side.z.Negatives, on a guest with two dense genesis pages. Each is refused by the host verifier and by the recursion leaf, and admitted when the openings are skipped (the mutation):
Wrongly committed stacks are refused at the roots block: two pages swapped, a page holding another page's columns, another program's DECODE.
Cost. One stack per group costs +0.14 s of base (FAST 419; one commitment per table cost +0.49 s) and saves 0.57 s of recursion, by taking 90 k permutations out of the leaves.
BlockFormat::prepared = falseturns the openings off, for measurement only.3. ECDAS split; table heights capped
What.
split_ecdas).(round, op).Why. At a median block, one ECDAS table (2^19) argues on a 12 GiB tree. At p90 (2^20) it stacks into five polynomials on a 24 GiB tree.
Gates. FAST 534 and 535: the negatives, 3 mutations caught.
4. Recursion leaf: the leaf cap (G3) and the inverse share (W1)
LEAF_PERMS_CAP. With no fixed leaf count, it adds leaves while the heaviest leaf is over the cap. The block's own partition is unchanged.p · ediv(1, q), which has no satisfying assignment for q = 0 whatever p is. The formerediv(p, q)left the share free at p = q = 0 (≈ 2^-160 under GKR soundness).LFM_WHIR_SHARE_INVERSE=0keeps the former form.5. Batched argue, on by default since d9d0ac5 (
BlockFormat::argue = ArgueFormat::BATCHED; Mauro, 10-02: "batch the constraints")What. Each group's tables are argued together on the group's fork:
Verifier side. The verifier derives the bins from the statement's shapes and its own cap; the variant is never read from the proof. The proof carries one
BatchedArgueper group inBlockWhirProof.argues, andproof.tablesis empty under this format. The recursion leaves verify the same format (lane i-batch2, N-4).Security at the block's measured inputs (D-BATCH §3.2's formulas; re-checked at FAST 424's inputs: |T| ≤ 60 tables a group, ≤ 51 trees a bin, ≤ 2^28.87 input cells, bus messages ≤ 204 elements, N_C ≤ 413, D_max 4, n ≤ 21; L = 300):
Every term is above the WHIR phase, so the proof minimum is unchanged: 128.946 under the campaign accounting (130.393 for the WHIR fold under the calculator of record).
Measured.
The knob.
ArgueFormat::PerTable(one argument per table, the format before) stays measurable, withBLOCK_WHIR_ARGUE=per-tablein the real-block tests. At the per-table format, the MultiProof, the prepared openings and the partition are digest-equal to the head before the batched merge (BIG 393).6. KECCAK and ECSM split; their heights capped (the port of #1013's S0a; landed at 3cfffe2; approved by the lead under Mauro's any-block target, Mauro to confirm)
What.
split_keccak,split_ecsm), as ECDAS is at 2^17.Why. A keccak-heavy block at the gas limit makes about 2^21 permutation calls. One KECCAK table that tall stacks into eight polynomials of 2^27, against a group budget of three. At its cap each table fits one polynomial.
Bytes. Every block measured so far has KECCAK ≤ 2^17 rows and ECSM ≤ 2^11, so it builds the same tables and the same proof (FAST 830: digest 07d1bd43… unchanged on block 25368371).
Gates. FAST 830: KECCAK and ECSM forced into 4 tables each on block 25368371 prove and verify, base and tree; the count and height negatives; mutation C caught.
7. WHIR grinding 20 → 18 bits, queries 112 → 114 (landed at cbfa7d7; approved by Mauro, 10-05)
What.
Each WHIR chain grinds 18 bits instead of 20 before each round's queries, and opens 114 queries instead of 112 to buy the two bits back. At every block height (15 to 27 variables) Q =
num_queries(2, rounds, 128, 18).One site,
multilinear_prove::chain_config_under. Every side of the block reaches it throughBlockFormat::chain_config:verify_block_whir;The statement absorbs Q and the grind bits.
Scope: the block's WHIR proofs only. The recursion tree's own leaf, node and top proofs are STARK proofs (FRI) and keep their own grind.
It ports WHIR recursion on GPU (RPX) with ZisK-style proof formats: block 25368371 in 32.62 s #1010's grind 18 (landed there at 2687e48). Opt-out:
LAMBDA_VM_ZF_WHIR_GRIND_BITS=20, which reproduces the previous proofs byte for byte.Security. The calculator of record: Johnson bound, η = 1/300, the fold proof of work unground.
Measured behind the knob, on c55dec4, one binary per box:
Bytes. The proof bytes change. Under the fixed trace hash and deterministic grind, the 1× top proof's digest is b9b4826d… at the default and 0da6fea9… under
=20. Both trees are accepted (ULTRA 015, at this head).Known limit. The leaf cap (279,000 permutations) sits above 2^18 LFM_HASH rows, and 18 bits moves every leaf about 1.7 % closer to that doubling.
Gates.
zf_format::; the chain refusals and the legacy-bytes KAT; the pins the flip moved; the host block refusal.One-binary A/B: the block tree vs #1010's epoch tree (FAST 416, noepoch/whir @ 454dad6)
Eight arms E B B E E B B E on the same binary (md5 checked after every arm):
Base, block 25368371 on FAST (each run against #1010's epoch base on the same binary)
Recursion (W3): proved and verified on block 25368371 (FAST 413)
lfm::whir_block::WhirBlockPlan) runs the host verifier's own statement checks, derives every shape from the AIR and every prepared root from the program, and never reads a proof. It prices each group in permutations and partitions the groups over the leaves (heaviest first, onto the least-loaded leaf).block_node, shared byte for byte with STARK no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1013). They check the id, the state and the output equal across children, add the shares, and the top asserts zero.verify_block_tree(elf, statement, top)derives the top program and checks the top proof against it. Every preset is pinned inside: the base's options, the block format, the tree's options, the leaf rule and the fan-in.Every proof was verified by the harness off the clock. The base is unchanged by the emission running beside phase B (20.98 s vs 21.18 s in the arms without the change).
Next:
Base levers after the A/B (FAST 417–422, each S/P on one binary)
Memory (D-MEMORY, with i-mem / i-mem2)
drop_streamed_ops)layout_ahead, D-EXEC)Narrow trace storage (M4, lane i-m4)
Prover-only; the proof bytes are the same. The proof digest equals the head's before M4 (07d1bd43…) under the fixed trace hash + deterministic grind (FAST 820).
BlockOptions::narrow, productionNarrowing::CARD).Max RSS, wide → narrow (BIG 560; the traces themselves shrink about 4×, e.g. 24.89 → 6.20 GiB at 1×):
Before M4, #1014 ran out of memory at 3.03× (i-m4); the narrow line puts the 120.7 GiB edge near 5.5–6×.
Phase A uploads the next group beside the commit (3′, lane i-noepoch-w2)
Prover-only; the proof bytes are the same (digest 07d1bd43… at the default, FAST 832; the commits, their order and their bytes are unchanged).
BlockOptions::upload_ahead, on by default;BLOCK_WHIR_UPLOAD_AHEAD=0is the control).Streamed chunks laid out on three threads (E3 on by default, lane i-noepoch-w2)
Prover-only; the proof bytes are the same (digest 07d1bd43… at the default, FAST 838 and 835; the groups, their order and the packing are unchanged).
layout_workers0 → 3 inBlockOptions::production(59e9890). The streamed chunks are laid out on three threads, with at most K + 1 = 3 of them unpacked at a time (layout_ahead, E3), instead of on the builder's one layout thread.BLOCK_WHIR_LAYOUT_WORKERS=0(the inline layout, 01da99f's) is the control.Phase B's kept-top paths re-hashed in parallel (lever 1, lane i-noepoch-w2)
Prover-only; the proof bytes are the same (digest 07d1bd43… at the default, FAST 840 at 733557a — 82f9046 adds only the knob; the paths, their order and the refusal are unchanged).
BLOCK_WHIR_REHASH_SERIAL=1restores the serial re-hash (a measurement knob).BLOCK OPEN SPLIT(withLAMBDA_VM_BASE_SPLIT=1), phase B's openings by host stage and the kept-top gather and re-hash seconds.The tree's leaves execute while their artifacts are built (R2-i, lane i-noepoch-w2)
Prover-only; the proofs are the same (the top proof's digest equal with and without it, 0da6fea9…, under the fixed trace hash + deterministic grind, FAST 841).
prove_tree_pipelined, the way a prover would run it; there is no production tree driver yet). Its level 0 built all three leaves' artifacts first (three serial card holds, 0.24 s at 1×) and only then let the leaves execute and fill their traces (0.46 s until the first was ready) while the card sat idle (nsys timeline, FAST 839). Execution and fill do not read the artifacts; only the prove does.lfm_proveis now cut into its host half (lfm_execute_and_fill) and its card half (LfmFilled::prove, which asserts the artifacts' hasher is the one the traces were filled for), in the same order; the harness builds the artifacts on a thread of their own and each leaf executes and fills beside them, waiting for its artifacts only to prove.W3_EXEC_BESIDE_ARTIFACTS=0is the control (the order before).A second whole-block field. The W3 readout prints, on the clock between the base and the tree, the block report, a second block frame for the LT heights and the group tables: 0.13–0.14 s at 1× that a prover would not spend. "Whole block" keeps its meaning (every number above includes them); from d169edd on,
W3 RECURSIONalso prints "whole excl. harness readouts" beside it (at d169edd, FAST 841 + 842 pooled: whole 18.54 s, whole excl. harness readouts 18.40 s).The rest laid out in waves; KECCAK_RND built as its tables (W, lane i-m4b)
Prover-only; the proof bytes are the same (digest 07d1bd43… under the fixed trace hash + deterministic grind: FAST 854 at 0bcc1fc, and FAST 855's W arm on this head's code).
BlockOptions::rest_layout_bytes). The tables, their order and the groups are the same (test).split_keccak_rndthen copied into its 2^16-row tables. At 4.13× that copy was a second peak of the same height. The finish now builds the 2^16-row tables directly (BlockOptions::finish_keccak_rnd_chunks), the same tables as the split's (test), and hands none out during the windows, which would change the groups.BLOCK_WHIR_REST_LAYOUT=allandBLOCK_WHIR_KR_FINISH_CHUNKS=0restore the old behaviour.pack_rest_as_laid_out) was re-measured with the waves: no gain (+0.01 s), so it stays off.LAMBDA_VM_BLOCK_MEMLOG=1(off by default). It prints the host memory term by term every half second and at each phase mark, with the line at jemalloc's active peak and each arena's bytes (those two in the lib tests, which install jemalloc).BLOCK REST TABLES(each rest table's layout end and group) and each group's commit start (from@).The tree's first finished leaf executes during phase B (R2-ii, lane i-noepoch-w2)
Prover-only; the proofs are the same (base digest 07d1bd43… and the top proof's digest equal with and without it, 0da6fea9… — FAST 841's — under the fixed trace hash + deterministic grind: FAST 845, and FAST 847 again on fac261f, the merge with W).
block_prove_on_forks_observed; the old entry point passes a no-op, and the proof is the same with any observer). A leaf's arena is built from its groups' words alone (group_arena_words+leaf_arena;block_leaf_arenais built from them). The W3 harness turns the groups into words as they arrive; the first leaf whose groups are all opened while another group is still to come (leaf 0 = groups 1, 5, 6 at 1×, done after group 6) executes and fills its traces on a thread of its own, about 1.5 s before the base ends, and the tree picks it up. Off the clock its arena is checked against the finished proof's.W3_LEAF_DURING_PHASE_B=0is the control.The finish's tables packed as they are built (b2, lane i-m4b)
Prover-only; the proof bytes are the same (digest 07d1bd43… under the fixed trace hash + deterministic grind at both arms: FAST 855 at 0cebe16, and FAST 857 again on 365e3ab, the merge with R2-ii).
BlockOptions::pack_finished). KECCAK_RND is packed in waves of four 2^16-row tables. Phase A takes those tables as narrow columns and uploads them as they are, so the card packs only the groups' other tables. Nothing packed is transposed.BLOCK REST PACKEDcounts the rest: 187 of 191 tables at 4.13×).BLOCK_WHIR_PACK_FINISHED=0restores W.Measurement posture: the card's pool now retains freed memory (baseline shift)
Not a prover change; the proofs are the same (the top proof's digest 0da6fea9… under both postures, fixed trace hash + deterministic grind, FAST 848; 351a773 adds only a test readout).
LAMBDA_VM_MEMPOOL_RELEASE_MB=0. The card's stream-ordered memory pool then hands its freed blocks back to the driver at each synchronize, so a VRAM sampler's total − free reads the live working set. The code default is to retain every freed block (DEFAULT_MEMPOOL_RELEASE_THRESHOLD_BYTES = u64::MAXin math-cuda), and that is what a prover runs.cuStreamSynchronizeandcuMemAllocAsyncwhile the card was idle was ≈ 0.25 s in phase A, 0.42 s in phase B (0.26 s of it in the encode: one 18–33 ms gap per group) and 0.34 s in the tree.W3 DEVICEline).The prover refuses a partition over the group maximum (lane i-m4b)
Prover-only; the proof bytes are the same (digest 07d1bd43…, FAST 858). The prover now refuses a block over
BlockFormat::max_groupsas its groups close, with the verifier's ownInvalidTableCountserror, instead of proving a block the verifier refuses. The median block (90 groups against the cap of 64) spent its whole ≈ 190 s base on such a proof (BIG 564). A test covers both prover paths, with a mutation for each check.The tree's nodes built beside it, each level proving as its nodes arrive (A, lane i-noepoch-w2)
Prover-only (the W3 harness); the proofs are the same (the top proof's digest 0da6fea9… — FAST 841's — with and without it, under the fixed trace hash + deterministic grind: FAST 889, and FAST 891 again after the permit fix below).
prove_tree_pipelined) built every node program and its artifacts on one thread, level after level, and level 0 joined that thread before any node proved, so level 1 waited for the whole tree's builds. At the median block, 32 s of serial node builds after the leaves' artifacts held level 0 open 10.7 s past its last leaf proof, and the card sat idle 11.4 s before level 1 (BIG 565 / 568's card trace). At 2.66× the wait was 1.5–2.1 s (FAST 888).W3_EMIT_THREADSthreads (default 4, the builder's own: on the global pool a prover's join can steal an emission and leave the card idle, STARK no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1013's FAST 454), and the builder's thread builds each one's artifacts as it arrives. Each node proves once its children are proved and its slot is filled. A builder that stops fails every empty slot.W3_NODE_PIPE=0is the control.Published<T>serves as the slot; there is no per-group early emission (W3 builds every leaf's artifacts up front, so a level's programs are emitted together); and there is no host-only thread marking (WHIR no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1014 has none).build_levels, an emit on the pool and a finish on the builder's thread). A toy tree at the median's shape puts the serial builder's programs in their slots whatever order a pool finishes them in, and finishes every node off the rayon workers (test; finishing on a worker, or publishing in arrival order, fails it). A failed build fails every slot above it without a hang (test).WhirBlockPlan::programsbuilds as rayon jobs.W3_NODE_TIMES=1(off by default). It prints, per program, when it was built, taken and proved; its prove's split (execute, fill, the prove net of the card wait, the wait); and each node level's start against the level below. The stamps are taken either way and cost a handful ofInstantreads.prove_tree_pipelinedis its de-facto driver. With the slots it now has a driver's shape: leaves from phase B, nodes from slots, levels as their nodes and children arrive. Moving it out of the test harness is a landing item for STARK no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1013 and WHIR no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1014 both.Each node proved as soon as its own children are (C, lane i-noepoch-w2)
Prover-only (the W3 harness); the proofs are the same (the 1× top proof's digest with and without it, under the fixed trace hash + deterministic grind, both trees accepted: 0da6fea9…, BIG 614 — the digest FAST 841 / 889 / 891 printed).
siblingsworkers proves every program of the tree, leaves and nodes, taking them in topological order (the leaves, then each node level) and publishing each proof into a slot of its own. A node waits only for its own children's slots, so it executes, fills and proves while the rest of the level below still proves.W3_DATAFLOW=0is the control: each node waits for its whole level below (tested never to start early).W3 LEVELwall now runs from the level below's last proof to its own.The held tables spill to disk, by default only when memory is short (lane i-m4b)
Prover-only; the proof bytes are the same: one shape and one proof digest (07d1bd43…) across the base and all four policies, under the fixed trace hash + deterministic grind (BIG 616). The 1× top proof's digest (0da6fea9…) and the tree verify at the landed merge (ULTRA 006).
crypto/stark/src/spill.rs) is imported byte-identical; it digests each slot and writes it with O_DIRECT on a writer thread, off the committer's path. A table moves only when the writer's queue has room at that moment, so the committer never waits.SpillFailed). After a group's opening its packed columns are let go.LAMBDA_VM_BLOCK_SPILL=auto(the default) |off|always|<GiB>(a resident budget).autospills a table when the host's bytes plus a reserve plus the table would pass the target.LAMBDA_VM_BLOCK_SPILL_TARGET_GIB, else min(the cgroup's limit, v2 or v1;MemTotal) − 10 GiB.BLOCK SPILLprints the policy, the slots and bytes, the writer's split, the read-back, and the largest host readingautodecided on.always(BIG 566, single runs): 22.74 GiB spilled, max RSS 52.53 → 40.12 GiB, whole block +1.15 s, drivers waited 0 s.auto(BIG 567): by default nothing spills (target 110.7 GiB). Under a 35 GiB target it spills 21.21 GiB, max RSS 41.04 GiB, +2.91 s.autospilled 26.98 GiB from group 44 of 90, and the tree verified.auto, O =off, S =always, T =autoat a 47.5 GiB target):autorun spilled 0 in both jobs, at 110.7 GiB and under the 47.5 GiB target (FAST's limit, kept as a real test on BIG's 128 GiB; the host read 25.3–26.8 GiB across those runs);alwaysandautoat 0 spilled within noise.autospilled 0 (host at most 27.65 GiB).Phase 4 counts the BITWISE lookups in slices (#1013's c369843, lane i-m4b)
Prover-only; the bytes are the same:
What changes:
LAMBDA_VM_P4_SLICED=0keeps the whole-source collectors. The knob is WHIR no-epoch (prove-and-retire) prover: block 25368371 — work in progress #1014's only, for the A/B.Measured: the median, BIG 619. One binary on the cap-128 exploration head, N P P N,
autospill on. N runs the whole-source path, P the slices.auto)autospills only once memory is short.The top executes each child's share as that child is proved, while a child is still unproved (B and B′, lane i-noepoch-w2)
Prover-only (the W3 harness and the LFM executor); the proofs are the same. The 1× top digest is 0da6fea9… with the streamed top on and off, under the fixed trace hash + deterministic grind, and both trees are accepted (BIG 617; ULTRA 008 and 009; ULTRA 011 at c55dec4 itself).
executor::StreamedExecutionruns an execution as its arena groups land: each instruction runs in the wave in which the last group it reads lands (each instruction's group set comes from one forward pass), in the level schedule's order, into the slot the schedule gives it. So the witness isexecute's, word for word.finishchecks that every instruction ran once. Dropping the group propagation (ReadBeforeWrite) or re-running instructions across waves (DoubleWrite) fails them.W3_STREAM_TOP, on by default), so only the last child's share and the fill remain after the last child.W3 TOP EXECUTEprints which. A test covers a program ready before the last child (streamed), after it (whole), and a failed child (whole, which then reports the failure). Inverting the predicate fails the test.A node executes from its program; only its prove waits for its artifacts (b′, lane i-noepoch-w2)
Prover-only (the W3 harness); the proofs are the same: the 1× top digest is 0da6fea9… with
W3_EXEC_EARLYon and off, under the fixed trace hash + deterministic grind, and both trees are accepted (ULTRA 012; ULTRA 013 at 806c211 itself).node_flow). The traces are filled under the block hasher, which the node artifacts are built for. The top's streaming choice (B′) is taken when the top can execute.W3_EXEC_EARLY=0is the control.LfmProveError::HasherMismatch, naming both) instead of failing a release assert, and the streamed execution's finish returns an error instead of asserting its public words' capacity. Each has a test and a mutation.