EIP-7742 Decoupling CL-EL blob count (Uncouple blob count between CL and EL)

No call decision · Scaling & data · EIP status Stagnant · created 2024-07-12

Removes the blob maximum that the execution layer (EL) used to validate directly, and instead has the consensus layer (CL) pass the blob target to the EL every block, loosening the coupling between the two layers.

Why it is needed

After blobs were introduced by EIP-4844, the execution layer (EL) has kept the per-block blob maximum (max) and target (target) hardcoded in its code. However, the blob maximum is already indirectly validated through the number of versioned hashes the consensus layer (CL) passes via the Engine API, so having the EL validate the same value again is redundant work. A bigger problem is that the target is fixed only by the relationship "target == max / 2," so every time Ethereum wants to increase blob parameters as part of its scaling roadmap, the CL and EL code must be changed and deployed together. This EIP aims to remove the EL's redundant validation and have the CL dynamically pass the target in every payload, decoupling the development and deployment schedules of the two layers.

What changes

Today

After EIP-7742

Who is affected

In depth

Background: EIP-4844's blobs and the roles of the two layers

EIP-4844 added the ability to include blobs, data bundles with no execution meaning, in blocks. The protocol sets a per-block blob maximum to prevent DoS risk from abuse of data resources, and, similar to EIP-1559, sets a target for average blob throughput per unit time to adjust the blob base fee. After EIP-4844, both values were hardcoded in the EL, and the maximum was also separately hardcoded in the CL. This EIP aims to redivide these two values between the CL and EL to make changes and deployment easier.

Removing blob maximum validation

The blob maximum is validated at the CL node, and the EL inherits this validation through the consistency check of versioned hashes provided by the Engine API. Therefore, the EL does not need to redo the strict maximum check defined by EIP-4844. After this EIP is activated, the EL's logic for validating MAX_BLOB_GAS_PER_BLOCK is no longer needed. However, the blob maximum itself continues to be provided during block production via the Engine API.

Dynamic delivery of the target

In EIP-4844, the target was determined only by the fixed relationship "target == max / 2." This rigid relationship becomes an obstacle when Ethereum wants to increase blob parameters as part of its scaling strategy. This EIP removes the maximum from EL validation and instead has the CL send the current target to the EL via the Engine API on every payload. This lets the EL know the target without needing the maximum.

Block header extension and validation rules

Once this EIP is activated, the EL must add a new 64-bit field called target_blobs_per_block to the header schema. This value is set to the current target blob count. When validating a block, the EL must check that the target blob count recorded in the header matches the value sent by the CL. The validity of this value is guaranteed by the CL, in the same way as withdrawal processing. For the genesis block, which has no parent block, the agreed-upon value follows the rules of that genesis block.

Change to the excess_blob_gas calculation formula

The calc_excess_blob_gas function changes to calculate based on target_blob_gas, which is parent.target_blobs_per_block multiplied by GAS_PER_BLOB, instead of a fixed TARGET. If the sum of parent.excess_blob_gas and parent.blob_gas_used is less than target_blob_gas, it returns 0; otherwise, it returns that sum minus target_blob_gas. Aside from this, the blob base fee calculation and the way excess_blob_gas is tracked remain the same as in EIP-4844.

Engine API extension

When the CL requests payload construction from the EL, the Engine API is extended to supply target_blobs_per_block and max_blobs_per_block together. The EL must use these two values to include the correct number of blobs in the payload and to perform the blob base fee calculations correctly.

Why the CL does not take over the entire blob base fee calculation

It would be possible for the CL to handle the entire blob base fee calculation, but that would break the separation of roles between the CL and the EL. This EIP is designed to preserve the current division of responsibility, where the CL manages the maximum to guard against DoS risk and the EL knows the target for fee accounting. Moving the target calculation to the CL would mix the responsibilities each layer is supposed to hold.

Current status

This EIP's status is marked Stagnant, meaning discussion has stalled and it has not yet been reflected on mainnet. No separate decision on fork inclusion was found in the call records.

Original EIP · ← EIPs