# eevm v0.1.0 - Table of Contents Ethereum Virtual Machine implementation in Elixir. ## Pages - [README](readme.md) - [LICENSE](license.md) ## Modules - [EEVM](EEVM.md): EEVM — Ethereum Virtual Machine implementation in Elixir. - [EEVM.Config](EEVM.Config.md): Runtime configuration for EEVM execution. - [EEVM.Delegation](EEVM.Delegation.md): EIP-7702 delegation designators. - [EEVM.Error](EEVM.Error.md): Reference for all error atoms used across the EEVM codebase. - [EEVM.Handler](EEVM.Handler.md): End-to-end transaction handler. - [EEVM.Handler.Execution](EEVM.Handler.Execution.md): Step 8 of the transaction pipeline — actually run the EVM. - [EEVM.Handler.PostExecution](EEVM.Handler.PostExecution.md): Steps 9-11 of the transaction pipeline - [EEVM.Handler.PreExecution](EEVM.Handler.PreExecution.md): Steps 4-7 of the transaction pipeline (Yellow Paper §6) - [EEVM.Handler.Validation](EEVM.Handler.Validation.md): Pre-flight checks on a wire transaction. - [EEVM.Tracer](EEVM.Tracer.md): Opt-in opcode-level execution tracer. - [EEVM.Tracer.TraceStep](EEVM.Tracer.TraceStep.md): A single recorded step: one opcode execution in the trace. - [EEVM.TransactionResult](EEVM.TransactionResult.md): Result of running a single transaction through the end-to-end execution pipeline. - Interpreter - [EEVM.Interpreter](EEVM.Interpreter.md): The EVM interpreter — fetches, decodes, and dispatches opcodes in a loop. - [EEVM.Interpreter.Instructions.Arithmetic](EEVM.Interpreter.Instructions.Arithmetic.md): EVM arithmetic opcodes: ADD, MUL, SUB, DIV, SDIV, MOD, SMOD, ADDMOD, MULMOD, EXP, SIGNEXTEND. - [EEVM.Interpreter.Instructions.Bitwise](EEVM.Interpreter.Instructions.Bitwise.md): EVM bitwise opcodes: AND, OR, XOR, NOT, BYTE, SHL, SHR, SAR, CLZ. - [EEVM.Interpreter.Instructions.Comparison](EEVM.Interpreter.Instructions.Comparison.md): EVM comparison opcodes: LT, GT, SLT, SGT, EQ, ISZERO. - [EEVM.Interpreter.Instructions.ControlFlow](EEVM.Interpreter.Instructions.ControlFlow.md): Opcodes for program counter manipulation and stack data loading. - [EEVM.Interpreter.Instructions.Crypto](EEVM.Interpreter.Instructions.Crypto.md): EVM cryptographic opcode: KECCAK256 (0x20). - [EEVM.Interpreter.Instructions.Environment.Data](EEVM.Interpreter.Instructions.Environment.Data.md): Data-copying environment opcodes that read from calldata, code, or return data. - [EEVM.Interpreter.Instructions.Environment.External](EEVM.Interpreter.Instructions.Environment.External.md): External account inspection opcodes with EIP-2929 access cost tracking. - [EEVM.Interpreter.Instructions.Environment.Simple](EEVM.Interpreter.Instructions.Environment.Simple.md): Simple environment opcodes that read a single value from the execution context. - [EEVM.Interpreter.Instructions.Helpers](EEVM.Interpreter.Instructions.Helpers.md): Shared utilities for opcode implementations. - [EEVM.Interpreter.Instructions.Logging](EEVM.Interpreter.Instructions.Logging.md): EVM logging opcodes — LOG0 through LOG4. - [EEVM.Interpreter.Instructions.Registry](EEVM.Interpreter.Instructions.Registry.md): Opcode metadata registry — single source of truth for every opcode's name, stack I/O signature, implementing module, and static-context flag. - [EEVM.Interpreter.Instructions.StackMemoryStorage.MemoryOps](EEVM.Interpreter.Instructions.StackMemoryStorage.MemoryOps.md): Memory access opcodes: MLOAD, MSTORE, MSTORE8, MSIZE, and MCOPY. - [EEVM.Interpreter.Instructions.StackMemoryStorage.StackOps](EEVM.Interpreter.Instructions.StackMemoryStorage.StackOps.md): Stack manipulation opcode: POP (0x50). - [EEVM.Interpreter.Instructions.StackMemoryStorage.StorageOps](EEVM.Interpreter.Instructions.StackMemoryStorage.StorageOps.md): Persistent and transient storage opcodes: SLOAD, SSTORE, TLOAD, and TSTORE. - [EEVM.Interpreter.Instructions.System.Calls](EEVM.Interpreter.Instructions.System.Calls.md): Cross-contract call opcodes. - [EEVM.Interpreter.Instructions.System.Creation](EEVM.Interpreter.Instructions.System.Creation.md): Contract creation opcodes. - [EEVM.Interpreter.Instructions.System.Termination](EEVM.Interpreter.Instructions.System.Termination.md): Execution-terminating opcodes: STOP, RETURN, REVERT, INVALID, and SELFDESTRUCT. - [EEVM.Interpreter.Journal](EEVM.Interpreter.Journal.md): Snapshot/commit semantics for nested EVM call frames. - [EEVM.Interpreter.MachineState](EEVM.Interpreter.MachineState.md): The EVM machine state — the envelope that holds everything that survives a single opcode step. - [EEVM.Interpreter.MachineState.Env](EEVM.Interpreter.MachineState.Env.md): Per-call read-only execution environment. - [EEVM.Interpreter.MachineState.Frame](EEVM.Interpreter.MachineState.Frame.md): Per-call execution frame. - [EEVM.Interpreter.MachineState.Substate](EEVM.Interpreter.MachineState.Substate.md): Transaction-scoped accumulators that survive nested call frames. - [EEVM.Interpreter.Memory](EEVM.Interpreter.Memory.md): EVM memory — a byte-addressable, dynamically expanding linear memory. - [EEVM.Interpreter.Stack](EEVM.Interpreter.Stack.md): The EVM stack — a LIFO data structure with a max depth of 1024. - Precompiles - [EEVM.Precompile](EEVM.Precompile.md): Behaviour for EVM precompile implementations. - [EEVM.Precompiles](EEVM.Precompiles.md): Dispatcher for EVM precompiled contracts. - [EEVM.Precompiles.BLS12G1Add](EEVM.Precompiles.BLS12G1Add.md): Precompile 0x0B — BLS12-381 G1 point addition. Delegates to `Bls12381.execute_g1_add/2`. - [EEVM.Precompiles.BLS12G1MSM](EEVM.Precompiles.BLS12G1MSM.md): Precompile 0x0C — BLS12-381 G1 multiscalar multiplication. Delegates to `Bls12381.execute_g1_msm/2`. - [EEVM.Precompiles.BLS12G2Add](EEVM.Precompiles.BLS12G2Add.md): Precompile 0x0D — BLS12-381 G2 point addition. Delegates to `Bls12381.execute_g2_add/2`. - [EEVM.Precompiles.BLS12G2MSM](EEVM.Precompiles.BLS12G2MSM.md): Precompile 0x0E — BLS12-381 G2 multiscalar multiplication. Delegates to `Bls12381.execute_g2_msm/2`. - [EEVM.Precompiles.BLS12MapFp2ToG2](EEVM.Precompiles.BLS12MapFp2ToG2.md): Precompile 0x11 — BLS12-381 Fp2-to-G2 map. Delegates to `Bls12381.execute_map_fp2_to_g2/2`. - [EEVM.Precompiles.BLS12MapFpToG1](EEVM.Precompiles.BLS12MapFpToG1.md): Precompile 0x10 — BLS12-381 Fp-to-G1 map. Delegates to `Bls12381.execute_map_fp_to_g1/2`. - [EEVM.Precompiles.BLS12Pairing](EEVM.Precompiles.BLS12Pairing.md): Precompile 0x0F — BLS12-381 pairing check. Delegates to `Bls12381.execute_pairing/2`. - [EEVM.Precompiles.BN256](EEVM.Precompiles.BN256.md): BN256 (alt_bn128) curve precompiles — addresses `0x06`, `0x07`, `0x08` (EIP-196, EIP-197). - [EEVM.Precompiles.BN256Add](EEVM.Precompiles.BN256Add.md): Precompile 0x06 — BN256 point addition. Delegates to `BN256.execute_add/2`. - [EEVM.Precompiles.BN256Mul](EEVM.Precompiles.BN256Mul.md): Precompile 0x07 — BN256 scalar multiplication. Delegates to `BN256.execute_mul/2`. - [EEVM.Precompiles.BN256Pairing](EEVM.Precompiles.BN256Pairing.md): Precompile 0x08 — BN256 pairing check. Delegates to `BN256.execute_pairing/2`. - [EEVM.Precompiles.Blake2F](EEVM.Precompiles.Blake2F.md): Blake2f precompile — address `0x09` (EIP-152). - [EEVM.Precompiles.Bls12381](EEVM.Precompiles.Bls12381.md): BLS12-381 precompiles — addresses `0x0B` through `0x11` (EIP-2537). - [EEVM.Precompiles.ECRecover](EEVM.Precompiles.ECRecover.md): ECRecover precompile — address `0x01`. - [EEVM.Precompiles.Identity](EEVM.Precompiles.Identity.md): Identity precompile — address `0x04`. Returns its input bytes unchanged. - [EEVM.Precompiles.KZGPointEval](EEVM.Precompiles.KZGPointEval.md): KZG point evaluation precompile — address `0x0A` (EIP-4844). - [EEVM.Precompiles.ModExp](EEVM.Precompiles.ModExp.md): Modular exponentiation precompile — address `0x05` (EIP-198). - [EEVM.Precompiles.ModExpEIP7883](EEVM.Precompiles.ModExpEIP7883.md): Precompile 0x05 from Osaka — ModExp with EIP-7883 pricing. Delegates to `ModExp.execute/3`. - [EEVM.Precompiles.P256Verify](EEVM.Precompiles.P256Verify.md): P256VERIFY precompile — address `0x100` (EIP-7951, Osaka onward). - [EEVM.Precompiles.RIPEMD160](EEVM.Precompiles.RIPEMD160.md): RIPEMD-160 precompile — address `0x03`. - [EEVM.Precompiles.SHA256](EEVM.Precompiles.SHA256.md): SHA-256 precompile — address `0x02`. - Block - [EEVM.Block.Bloom](EEVM.Block.Bloom.md): Ethereum logs bloom filter — 256-byte (2048-bit) probabilistic filter summarising the addresses and indexed topics of every log in a receipt or block. Each item is added via 3 hash probes derived from Keccak-256 (Yellow Paper §4.3.1). The `data` field of a log is not included. - [EEVM.Block.Header](EEVM.Block.Header.md): Ethereum block header — the consensus-critical metadata for a block. A pure data carrier; validation lives in `EEVM.Block.Processor`. - [EEVM.Block.HeaderValidator](EEVM.Block.HeaderValidator.md): Validates a child `EEVM.Block.Header` against its parent. - [EEVM.Block.Processor](EEVM.Block.Processor.md): Execute a block end-to-end: system calls, then transactions in order, then beacon-chain withdrawals, then the commitments a consensus-level verifier will check. - [EEVM.Block.Receipt](EEVM.Block.Receipt.md): Per-transaction receipt emitted after execution (Byzantium-and-later layout). - [EEVM.Block.Result](EEVM.Block.Result.md): The outcome of executing a block — the post-state database plus every commitment derived from it. Returned by `EEVM.Block.Processor.process_block/4`. - [EEVM.Block.Withdrawal](EEVM.Block.Withdrawal.md): EIP-4895 beacon-chain withdrawal: a credit applied to an execution-layer account at the start of a block. - Transaction - [EEVM.Transaction](EEVM.Transaction.md): Ethereum transaction wire-format structs. - [EEVM.Transaction.AccessList](EEVM.Transaction.AccessList.md): EIP-2930 access list transaction (type 1). - [EEVM.Transaction.Authorization](EEVM.Transaction.Authorization.md): EIP-7702 authorization tuple. - [EEVM.Transaction.Blob](EEVM.Transaction.Blob.md): EIP-4844 blob transaction (type 3). - [EEVM.Transaction.Envelope](EEVM.Transaction.Envelope.md): Transaction envelope encoding/decoding for legacy and typed transactions. - [EEVM.Transaction.FeeMarket](EEVM.Transaction.FeeMarket.md): EIP-1559 fee market transaction (type 2). - [EEVM.Transaction.IntrinsicGas](EEVM.Transaction.IntrinsicGas.md): Intrinsic transaction gas calculation. - [EEVM.Transaction.Legacy](EEVM.Transaction.Legacy.md): Legacy transaction (type 0). - [EEVM.Transaction.SetCode](EEVM.Transaction.SetCode.md): EIP-7702 set-code transaction (type 4). - [EEVM.Transaction.Signer](EEVM.Transaction.Signer.md): Transaction signing-hash computation and sender recovery. - [EEVM.Transaction.Validator](EEVM.Transaction.Validator.md): Transaction pre-execution validation. - Context - [EEVM.Context.Block](EEVM.Context.Block.md): Block-level context — information about the block being executed, exposed to the EVM via environment opcodes. - [EEVM.Context.Contract](EEVM.Context.Contract.md): Contract/message-level context — the current call frame's environment. Each CALL / DELEGATECALL / STATICCALL / CREATE frame has its own. - [EEVM.Context.Transaction](EEVM.Context.Transaction.md): Transaction-level context — information about the original transaction exposed to the EVM via environment opcodes. - System Contracts - [EEVM.SystemContracts.BeaconRoots](EEVM.SystemContracts.BeaconRoots.md): EIP-4788 beacon block root contract (activated in Cancun). - [EEVM.SystemContracts.BlockHashes](EEVM.SystemContracts.BlockHashes.md): EIP-2935 historical block hashes contract (activated in Prague). - State & Storage - [EEVM.Database](EEVM.Database.md): Behaviour defining the external state interface for the EVM — account state (balances, nonces, code) plus per-contract storage — abstracted behind a single interface so different backends (in-memory, Merkle-backed, disk) can be plugged in without changing opcode implementations. - [EEVM.Database.InMemory](EEVM.Database.InMemory.md): In-memory `EEVM.Database` backend backed by plain maps. - [EEVM.MPT.HexPrefix](EEVM.MPT.HexPrefix.md): Hex-prefix (aka compact) encoding used by Ethereum's Merkle Patricia Trie. - [EEVM.MPT.Trie](EEVM.MPT.Trie.md): Ethereum Merkle Patricia Trie (MPT) root computation. - [EEVM.StateRoot](EEVM.StateRoot.md): Computes Ethereum storage roots and state roots from the current `EEVM.Database`. - [EEVM.Storage](EEVM.Storage.md): Persistent key-value storage for a single contract account: a mapping from 256-bit slot keys to 256-bit values. - [EEVM.WorldState](EEVM.WorldState.md): Minimal world/account state used for external account lookups (`EXTCODESIZE`, `EXTCODECOPY`, `EXTCODEHASH`). - Gas - [EEVM.Gas.Access](EEVM.Gas.Access.md): Cold/warm storage access cost tracking per EIP-2929. - [EEVM.Gas.Blob](EEVM.Gas.Blob.md): Blob gas pricing (EIP-4844) and its later adjustments. - [EEVM.Gas.Dynamic](EEVM.Gas.Dynamic.md): Dynamic gas costs that depend on opcode operands at runtime. - [EEVM.Gas.Intrinsic](EEVM.Gas.Intrinsic.md): Intrinsic gas costs for transactions — costs that apply before execution begins. - [EEVM.Gas.Memory](EEVM.Gas.Memory.md): Memory expansion gas cost calculation. - [EEVM.Gas.Static](EEVM.Gas.Static.md): Static gas costs for each EVM opcode. - [EEVM.HardforkConfig](EEVM.HardforkConfig.md): Hardfork configuration controlling which EIP rules are active during execution.