Crate revm
Expand description
Revm is a Rust EVM implementation.
Modules§
- db
- Database implementations.
- handler
- inspectors
- Inspector implementations.
- interpreter
- revm-interpreter
- optimism
- Optimism-specific constants, types, and helpers.
- precompile
- revm-precompile
Structs§
- Cache
State - Cache state contains both modified and original values.
- Call
Frame - Call CallStackFrame.
- Context
- Main Context structure that contains both EvmContext and External context.
- Context
Precompiles - Precompiles context.
- Context
With Handler Cfg - Context with handler configuration.
- Create
Frame - Evm
- EVM instance containing both internal EVM context and external context and the handler that dictates the logic of EVM (or hardfork specification).
- EvmBuilder
- Evm Builder allows building or modifying EVM. Note that some of the methods that changes underlying structures will reset the registered handler to default mainnet.
- EvmContext
- EVM context that contains the inner EVM context and precompiles.
- Frame
Data - Handler
- Handler acts as a proxy and allow to define different behavior for different sections of the code. This allows nice integration of different chains or to disable some mainnet behavior.
- Inner
EvmContext - EVM contexts contains data that EVM needs for execution.
- Journal
Checkpoint - SubRoutine checkpoint that will help us to go back from this
- Journaled
State - A journal of state changes internal to the EVM.
- L1Block
Info - L1 block info
- State
- State of blockchain.
- State
Builder - Allows building of State and initializing it with different options.
- Transition
Account - Account Created when EVM state is merged to cache state. And it is sent to Block state.
- Transition
State
Enums§
- Context
Precompile - A single precompile handler.
- Frame
- Call stack frame.
- Frame
OrResult - Contains either a frame or a result.
- Frame
Result - Journal
Entry - Journal entries that are used to track changes to the state and are used to revert it.
Constants§
- BASE_
FEE_ RECIPIENT - The address of the base fee recipient.
- CALL_
STACK_ LIMIT - EVM call stack limit.
- L1_
BLOCK_ CONTRACT - The address of the L1Block contract.
- L1_
FEE_ RECIPIENT - The address of L1 fee recipient.
Traits§
- Context
Stateful Precompile - Context aware stateful precompile trait. It is used to create
a arc precompile in
ContextPrecompile
. - Context
Stateful Precompile Mut - Context aware mutable stateful precompile trait. It is used to create
a boxed precompile in
ContextPrecompile
. - Database
- EVM database interface.
- Database
Commit - EVM database commit interface.
- Database
Ref - EVM database interface.
- GetInspector
- Provides access to an
Inspector
instance. - Inspector
- EVM Interpreter callbacks.
Functions§
- inspector_
handle_ register - Register Inspector handles that interact with Inspector instance.
Type Aliases§
- Context
Stateful Precompile Arc - Arc over context stateful precompile.
- Context
Stateful Precompile Box - Box over context mutable stateful precompile
- DBBox
- Database boxed with a lifetime and Send.
- InMemoryDB
- A Database implementation that stores all state changes in memory.
- StateDB
Box - More constrained version of State that uses Boxed database with a lifetime.