Commit 0594893
committed
feat(aggregation): score interval-2 jobs like the block builder
The interval-2 session aggregated current-slot gossip groups in arbitrary
order and ignored existing proofs, so it could not prioritize the groups
whose aggregation most advances consensus. Rework snapshot_aggregation_inputs
into a tiered greedy selector modeled on select_attestations: an up-front
store pass resolves each candidate's material once (raw-first + trim), then a
loop scores candidates by (current-slot-first, Finalize > Justify > Build)
against an optimistically-projected state, emitting at most
MAX_AGGREGATION_JOBS jobs.
Candidates are filtered by the block builder's entry_passes_filters against a
chain view covering [0, head_slot] (head root pushed onto the state's
historical_block_hashes, which omits the head's own root), so prover time is
spent only on aggregations a block could actually pack.
Reuses the shared ProjectedState (from_head_state + advance) and
Tier/EntryScore/entry_passes_filters via a coverage-based score_from_coverage
core, so proposer and aggregator can never drift on either the
justify/finalize projection or the tiering. Deletes
snapshot_current_slot_aggregation_inputs and build_raw_signature_job
(subsumed).
Builds on the block_builder ProjectedState extraction refactor.1 parent 2bb7ac7 commit 0594893
5 files changed
Lines changed: 957 additions & 151 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
| 44 | + | |
43 | 45 | | |
44 | 46 | | |
45 | 47 | | |
| |||
0 commit comments