-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Open
Labels
Description
Summary
The current BLOCK_GAS_LIMIT_MAX_CHANGE constant is set to 10 (10 per million = 0.001% per block), which results in excessively long timeframes for gas limit adjustments even when all proposers coordinate to change the limit.
Problem
With the current configuration:
- BLOCK_GAS_LIMIT_MAX_CHANGE: 10 (0.001% per block)
- MIN_BLOCK_GAS_LIMIT: 10,000,000 (10M)
- MAX_BLOCK_GAS_LIMIT: 100,000,000 (100M)
- BLOCK_TIME_TARGET: 2 seconds
Time Required for Full Range Adjustment
To go from minimum (10M) to maximum (100M) gas limit:
10M × (1.00001)^n = 100M
n = ln(10) / ln(1.00001) ≈ 230,259 blocks
Time = 230,259 × 2s ≈ 5.33 days
| Direction | Blocks Required | Time (at 2s/block) |
|---|---|---|
| 10M → 100M | ~230,259 | 5.33 days |
| 100M → 10M | ~230,259 | 5.33 days |
This means even with unanimous proposer coordination, it would take over 5 days to adjust the gas limit across its full range.
Proposal
Increase BLOCK_GAS_LIMIT_MAX_CHANGE to allow faster gas limit adjustments. For reference:
| Value | Change per block | Time for 10x adjustment |
|---|---|---|
| 10 (current) | 0.001% | 5.33 days |
| 100 | 0.01% | 12.8 hours |
| 1000 | 0.1% | 1.28 hours |
Considerations
- The value should balance between allowing timely adjustments and preventing rapid destabilizing changes
- Compare with Ethereum L1's gas limit adjustment mechanism for reference
- Consider the impact on network stability and economic predictability
References
- Derivation.md:
packages/protocol/docs/Derivation.md(lines 567-569)