diff --git a/crates/revm/src/handler/mainnet/pre_execution.rs b/crates/revm/src/handler/mainnet/pre_execution.rs index 64b41e7045..c0f4fe7bde 100644 --- a/crates/revm/src/handler/mainnet/pre_execution.rs +++ b/crates/revm/src/handler/mainnet/pre_execution.rs @@ -7,8 +7,8 @@ use crate::{ primitives::{ db::Database, Account, EVMError, Env, Spec, - SpecId::{CANCUN, SHANGHAI}, - TransactTo, U256, + SpecId::{CANCUN, PRAGUE, SHANGHAI}, + TransactTo, BLOCKHASH_STORAGE_ADDRESS, U256, }, Context, ContextPrecompiles, }; @@ -39,6 +39,16 @@ pub fn load_accounts( )?; } + // Load blockhash storage address + // EIP-2935: Serve historical block hashes from state + if SPEC::enabled(PRAGUE) { + context.evm.inner.journaled_state.initial_account_load( + BLOCKHASH_STORAGE_ADDRESS, + &[], + &mut context.evm.inner.db, + )?; + } + context.evm.load_access_list()?; Ok(()) }