Close Menu

    Subscribe to Updates

    Get the latest creative news from FooBar about art, design and business.

    What's Hot

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025
    Facebook X (Twitter) Instagram
    Ai Crypto TimesAi Crypto Times
    • Altcoins
      • Bitcoin
      • Coinbase
      • Litecoin
    • Blockchain
    • Crypto
    • Ethereum
    • Lithosphere News Releases
    X (Twitter) Instagram YouTube LinkedIn
    Ai Crypto TimesAi Crypto Times
    Home » Ethereum Execution Layer Specification | Ethereum Foundation Blog

    Ethereum Execution Layer Specification | Ethereum Foundation Blog

    Michael JohnsonBy Michael JohnsonApril 24, 2025No Comments4 Mins Read
    Facebook Twitter Pinterest LinkedIn Tumblr Reddit Telegram Email
    Share
    Facebook Twitter LinkedIn Pinterest Email


    tl;dr

    • EELS is an execution layer reference implementation in Python.
    • It’s up to date with mainnet.
    • It fills tests, and passes existing ones.
    • There’s an example of an EIP implemented in EELS below.

    Introduction

    After more than a year in development, we’re pleased to publicly introduce the Ethereum Execution Layer Specification (affectionately known as EELS.) EELS is a Python reference implementation of the core components of an Ethereum execution client focused on readability and clarity. Intended as a spiritual successor to the Yellow Paper that’s more programmer friendly and up-to-date with post-merge forks, EELS can fill and execute state tests, follow mainnet1, and is a great place to prototype new EIPs.

    EELS provides complete snapshots of the protocol at each fork—including upcoming ones—making it much easier to follow than EIPs (which only propose changes) and production clients (which often mix multiple forks in the same codepath.)

    History

    Beginning in 2021, as a project of ConsenSys’ Quilt team and the Ethereum Foundation, the eth1.0-spec (as it was known then) was inspired by the sheer frustration of having to decipher the cryptic notation of the Yellow Paper (Figure 1) to understand the specific behavior of an EVM instruction.

    Screenshot of formulas 2, 3, and 4 from the Yellow Paper
    Figure 1. arcane runes describing the basis of the blockchain paradigm

    Drawing on the successful Consensus Layer Specification, we set out to create a similar executable specification for the execution layer.

    Present

    Today, EELS is consumable as a traditional Python repository and as rendered documentation. It’s still a bit rough around the edges, and doesn’t provide much in the way of annotations or English explanations for what various pieces do, but those will come with time.

    It’s just Python

    Hopefully a side-by-side comparison of the Yellow Paper and the equivalent code from EELS can show why EELS is a valuable complement to it:

    Less-than (LT) opcode

    Figure 2. Less-than (LT) EVM instruction from Yellow Paper

    def less_than(evm: Evm) -> None:
        # STACK
        left = pop(evm.stack)
        right = pop(evm.stack)
    
        # GAS
        charge_gas(evm, GAS_VERY_LOW)
    
        # OPERATION
        result = U256(left < right)
    
        push(evm.stack, result)
    
        # PROGRAM COUNTER
        evm.pc += 1
    

    Figure 3. Less-than (LT) EVM instruction from EELS

    While Figure 2 might be digestible to academics, Figure 3 is indisputably more natural to programmers.

    Here’s a video walk-through of adding a simple EVM instruction if that’s your kind of thing.

    Writing Tests

    It bears repeating: EELS is just regular Python. It can be tested like any other Python library! In addition to the entire ethereum/tests suite, we also have a selection of pytest tests.

    With a little help from execution-spec-tests, any tests written for EELS can also be applied to production clients!2

    Showing Differences

    Having snapshots at each fork is great for a smart contract developer popping in to see the specifics of how an EVM instruction works, but isn’t very helpful for client developers themselves. For them, EELS can display the differences between forks:

    Screenshot of the differences in the apply_fork function between homestead and the DAO fork

    Figure 4. one difference between homestead and the DAO fork

    An Example EIP

    EIP-6780 is the first EIP to get an EELS implementation provided by the author, Guillaume Ballet! Let’s take a look.

    Screenshot of EIP-6780's specification section

    Figure 5. EIP-6768’s specification section

    First, we introduce a created_contracts variable to the EVM with transaction-level scope:

     @dataclass
     class Environment:
         caller: Address
         block_hashes: List[Hash32]
         origin: Address
         coinbase: Address
         number: Uint
         base_fee_per_gas: Uint
         gas_limit: Uint
         gas_price: Uint
         time: U256
         prev_randao: Bytes32
         state: State
         chain_id: U64
    +    created_contracts: Set[Address]
    

    Second, we note which contracts were created in each transaction:

    +    evm.env.created_contracts.add(contract_address)
    

    Finally, we modify selfdestruct so it only works for contracts noted in created_contracts:

    -    # register account for deletion
    -    evm.accounts_to_delete.add(originator)
    -
    +    # Only continue if the contract has been created in the same tx
    +    if originator in evm.env.created_contracts:
    +
    +        # register account for deletion
    +        evm.accounts_to_delete.add(originator)
    +
    

    Future

    We want EELS to become the default way to specify Core EIPs, the first place EIP authors go to prototype their proposals, and the best possible reference for how Ethereum works.

    If you’re interested in contributing or prototyping your EIP, join us on the #specifications channel or grab an issue from our repository.



    Source link

    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email
    Michael Johnson

    Related Posts

    V1.0 Announcing the Trillion Dollar Security Initiative

    May 14, 2025

    Ethereum (ETH) sees major uptick as Pectra upgrade goes live

    May 8, 2025

    Allocation Update – Q1 2025

    May 8, 2025
    Leave A Reply Cancel Reply

    Don't Miss

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    Lithosphere News Releases May 14, 2025

    … growing infrastructure vulnerabilities. AGII’s AI-powered detection … Unlike static security frameworks, AGII’s approach leverages…

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    FLOKI price eyes bullish continuation as correction targets major support zone

    May 14, 2025
    Stay In Touch
    • Facebook
    • Twitter
    • Pinterest
    • Instagram
    • YouTube
    • Vimeo
    Our Picks

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    Subscribe to Updates

    Get the latest creative news from SmartMag about art & design.

    Demo
    • Popular
    • Recent
    • Top Reviews

    30 Minutes of Exercise vs 100 Steps a Day: Which One is Better?

    May 16, 2021

    Quisque consectetur libero elit

    September 1, 2020

    Winter Fitness: These Poses Can Keep You Warm

    January 14, 2021

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025
    9.3

    Facilisis tincidunt justo eget urna leo dapibus at

    December 19, 2020
    8.9

    Review: Denmark Proposes Corona Pass Mandate for Workers

    January 9, 2020
    8.9

    Laoreet Sed: Suscipit nec dapibus at elit

    December 19, 2020
    Latest Galleries
    [latest_gallery cat="all" number="5" type="slider"]
    Latest Reviews
    8.5

    Review: How Research Could Help with Spinal Cord Injuries

    March 14, 2021
    8.9

    Review: How AI in Soccer could Predict Injuries?

    January 15, 2021
    8.9

    Review: Can Wisconsin Clinch the Big Ten West this Weekend

    January 15, 2021
    Demo
    Top Posts

    Atua AI Extends Bitcoin-Backed Infrastructure for Intelligent Enterprise Operations

    April 23, 202513 Views

    AGII Launches AI-Powered Web3 App To Advance Real-Time Decentralized Infrastructure

    April 26, 20251 Views

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 20250 Views

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 20250 Views
    Don't Miss

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    Lithosphere News Releases May 14, 2025

    … growing infrastructure vulnerabilities. AGII’s AI-powered detection … Unlike static security frameworks, AGII’s approach leverages…

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    FLOKI price eyes bullish continuation as correction targets major support zone

    May 14, 2025
    Stay In Touch
    • Facebook
    • Twitter
    • Pinterest
    • Instagram
    • YouTube
    • Vimeo

    Subscribe to Updates

    Get the latest creative news from SmartMag about art & design.

    Demo
    Top Posts

    Atua AI Extends Bitcoin-Backed Infrastructure for Intelligent Enterprise Operations

    April 23, 202513 Views

    AGII Launches AI-Powered Web3 App To Advance Real-Time Decentralized Infrastructure

    April 26, 20251 Views

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 20250 Views

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 20250 Views
    Don't Miss

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    Lithosphere News Releases May 14, 2025

    … growing infrastructure vulnerabilities. AGII’s AI-powered detection … Unlike static security frameworks, AGII’s approach leverages…

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    FLOKI price eyes bullish continuation as correction targets major support zone

    May 14, 2025
    Stay In Touch
    • Facebook
    • Twitter
    • Pinterest
    • Instagram
    • YouTube
    • Vimeo

    Subscribe to Updates

    Get the latest creative news from SmartMag about art & design.

    X (Twitter) Instagram YouTube LinkedIn
    Our Picks

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025

    Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report

    May 14, 2025

    AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience

    May 14, 2025
    Recent Posts
    • AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience
    • Low Cap Nasdaq-Listed Firm Reveals $300,000,000 Fundraising Plan To Acquire Crypto, Including President’s TRUMP Token: Report
    • AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience
    • FLOKI price eyes bullish continuation as correction targets major support zone
    • AGII Deploys Smart Detection Models for On-Chain Infrastructure Resilience
    © 2025 - 2026

    Type above and press Enter to search. Press Esc to cancel.