Implement tree states & hierarchical state DB

This commit is contained in:
Michael Sproul
2023-06-19 10:14:47 +10:00
parent 2bb62b7f7d
commit 23db089a7a
193 changed files with 6093 additions and 5925 deletions

View File

@@ -1,5 +1,6 @@
#![deny(clippy::wildcard_imports)]
use crate::metrics;
pub use epoch_processing_summary::EpochProcessingSummary;
use errors::EpochProcessingError as Error;
pub use justification_and_finalization_state::JustificationAndFinalizationState;
@@ -32,6 +33,8 @@ pub fn process_epoch<T: EthSpec>(
state: &mut BeaconState<T>,
spec: &ChainSpec,
) -> Result<EpochProcessingSummary<T>, Error> {
let _timer = metrics::start_timer(&metrics::PROCESS_EPOCH_TIME);
// Verify that the `BeaconState` instantiation matches the fork at `state.slot()`.
state
.fork_name(spec)