global: big snapshot

This commit is contained in:
nym21
2026-03-13 12:47:01 +01:00
parent c83955eea7
commit 2b31c7f6b7
158 changed files with 4961 additions and 6939 deletions
@@ -5,13 +5,10 @@ use vecdb::Exit;
use super::Vecs;
use crate::blocks::lookback;
impl Vecs {
pub(crate) fn compute(
&mut self,
indexer: &Indexer,
lookback: &lookback::Vecs,
starting_indexes: &Indexes,
exit: &Exit,
) -> Result<()> {
@@ -22,20 +19,7 @@ impl Vecs {
|h| (h, StoredU32::from(1_u32)),
exit,
)?;
self.total.cumulative.height.compute_cumulative(
starting_indexes.height,
&self.total.raw.height,
exit,
)?;
// Rolling window block counts
let ws = lookback.window_starts();
self.total.sum.compute_rolling_sum(
starting_indexes.height,
&ws,
&self.total.raw.height,
exit,
)?;
self.total.compute_rest(starting_indexes.height, exit)?;
Ok(())
}