This proposal describes the introduction in clients of a controlled gas limit increase strategy to determine the gas limit of a specific block and set as default with conservative parameters, while keeping the possibility to change it in the future to a fixed value.
The EIP proposes the introduction of a new gas limit management mechanism that automatically increases the block gas limit over time. The incremental growth is controlled by a fixed rate, ensuring predictable network scaling while preventing sudden surges in block sizes. This strategy is meant to be used as a default setting, with the option to switch to a fixed gas limit if needed (or different parameters).
The Ethereum network faces increasing demand, but changes to the gas limit are often manually adjusted by miners or validators based on their preferences, which may cause unpredictable block sizes and network performance issues.
Need for Change:
Instead of sudden or unpredictable changes, this EIP proposes incremental gas limit increases over a specified amount of time, ensuring a smooth transition to higher transaction throughput, while still keeping the governance of the gas limit in the hand of the community.
Automatic Deactivation:
There are different approaches to implement a controlled gas limit increase strategy. The following are three possible strategies that can be used:
Add a new "Gas Limit" selection strategy that takes in Block Number N
and spits out the Gas Limit GL
for that block. The strategy is as follows:
GL_t
at block t
is calculated as:def compute_gas_limit(blockNum: int, blockNumStart: int, initialGasLimit: int, r: int, gasLimitCap: int) -> int:
if blockNum < blockNumStart:
return initialGasLimit
else:
return min(gasLimitCap, initialGasLimit + r * (blockNum - blockNumStart))
Where:
blockNum
is the block number for which the gas limit is being calculated.blockNumStart
is the block number at which the gas limit increase starts.initialGasLimit
is the initial gas limit at block blockNumStart
.r
is the rate at which the gas limit increases per block.gasLimitCap
is the maximum gas limit that can be reached.If we set blockNumStart
to the current block number, initialGasLimit
to the current gas limit (30_000_000
), r
to 6, and gasLimitCap
to 60_000_000
, the gas limit will increase by 6 gas per block for two years, reaching 30 million gas at the end of a $\approx$ 2 years period.
The result of compute_gas_limit
will be the gas limit aimed by the proposer for the block blockNum
. none of this is enforced at the protocol level, and the proposer needs to still follow protocol rules related to the gas limit.
Add a new "Gas Limit" selection strategy that takes in Block Number N
and spits out the Gas Limit GL
for that block. The strategy is as follows:
GL_t
at block t
is calculated as:def compute_gas_limit(blockNum: int, blockNumStart: int, r: int, step_blocks_interval: int, gasLimitCap: int) -> int:
if blockNum < blockNumStart:
return initialGasLimit
else:
return min(gasLimitCap, initialGasLimit + r * ((blockNum - blockNumStart) // step_blocks_interval))
Where:
blockNum
is the block number for which the gas limit is being calculated.blockNumStart
is the block number at which the gas limit increase starts.initialGasLimit
is the initial gas limit at block blockNumStart
.step_blocks_interval
is the number of blocks after which the gas limit increases (cooldown period).r
is the rate at which the gas limit increases per step.gasLimitCap
is the maximum gas limit that can be reached.This strategy has three main advantages:
Add a new "Gas Limit" selection strategy that takes in Block Number N
and spits out the Gas Limit GL
for that block. The strategy is as follows:
GL_t
at block t
is calculated as:def compute_gas_limit(blockNum: int, blockNumStart: int, doubling_blocks_interval: int) -> int:
if blockNum < blockNumStart:
return initialGasLimit
else:
return min(gasLimitCap, initialGasLimit * (2 ** ((blockNum - blockNumStart) / doubling_interval)))
Where:
blockNum
is the block number for which the gas limit is being calculated.blockNumStart
is the block number at which the gas limit increase starts.initialGasLimit
is the initial gas limit at block blockNumStart
.doubling_blocks_interval
is the number of blocks after which the gas limit doubles.The inclusion of a deactivation block ensures that the gas limit does not increase indefinitely, preventing potential negative impacts on network performance beyond the planned growth.
Community Consensus:
No Hard Fork Required
Copyright and related rights waived via CC0 1.0 Universal.