Skip to content

Commit a1c8fb6

Browse files
committed
Update EIP-7892: harden BPO fork specs with p2p details.
1 parent 831645e commit a1c8fb6

File tree

1 file changed

+72
-13
lines changed

1 file changed

+72
-13
lines changed

EIPS/eip-7892.md

Lines changed: 72 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,16 @@ This EIP introduces **Blob Parameter Only (BPO) Hardforks**, a lightweight mecha
1818

1919
Ethereum's scaling strategy relies on Layer 2 (L2) solutions for transaction execution while using Ethereum as a **data availability (DA) layer**. However, the demand for DA has increased rapidly, and the current approach of only modifying blob parameters in large, infrequent hard forks is **not agile enough** to keep up with L2 growth.
2020

21-
The key motivations for BPO forks are:
21+
The key motivations for BPO forks are as follows:
2222

2323
1. **Continuous Scaling**
24-
- L2 DA demand is growing rapidly, leading to saturation of blob capacity.
24+
- L2 DA demand is growing rapidly, leading to ongoing saturation of blob capacity.
2525
- Large, infrequent blob parameter changes create high costs and inefficiencies.
2626
- BPO forks allow for more frequent, safer capacity increases.
2727

2828
2. **Reduced Operational Overhead**
29+
- Performance improvements and further testing will continue to unlock additional capacity.
30+
- It is desirable to reduce the time between core devs agreeing on a parameter increase and its effective deployment.
2931
- Full Ethereum hard forks require significant coordination, testing, and upgrade efforts across clients.
3032
- By isolating blob parameter changes, BPO forks reduce the complexity of upgrades.
3133

@@ -39,12 +41,22 @@ The key motivations for BPO forks are:
3941

4042
## Specification
4143

42-
BPO forks are a special class of hard fork which **only modifies any of the following** blob-related parameters:
44+
### Parametric hardforks
45+
46+
BPO forks are a category of **parametric hardforks**, which only change certain protocol parameters at a designated point in time without requiring client-side code changes. The new parameters are activated instantly, with no transition function. These hardforks are consensus-breaking, and therefore receive a `ForkVersion` in the consensus layer.
47+
48+
### Managed parameters
49+
50+
The following blob-related parameters are now managed by parametric configuration:
4351

4452
- **Blob Target (`blob_target`)**: The expected number of blobs per block.
4553
- **Blob Limit (`blob_limit`)**: The maximum number of blobs per block.
4654
- **Blob Base Fee Update Fraction (`baseFeeUpdateFraction`)**: Determines how blob gas pricing adjusts per block.
4755

56+
To ensure consistency, when a regular hardfork changes any of these parameters, it MUST do so by adding an entry to the blob schedule.
57+
58+
### Execution layer configuration
59+
4860
To facilitate these changes on the execution layer, the `blobSchedule` object specified in [EIP-7840](./eip-7840.md) is extended to allow for an arbitrary number of block timestamps at which these parameters **MAY** change.
4961

5062
```json
@@ -72,24 +84,71 @@ To facilitate these changes on the execution layer, the `blobSchedule` object sp
7284
}
7385
```
7486

75-
On the consensus layer, a new parameter is added to the configuration:
87+
### Consensus layer configuration
7688

77-
```
78-
BLOB_SCHEDULE:
79-
- EPOCH: 348618
89+
On the consensus layer, a new parameter is added to the configuration. The `FORK_VERSION` is only specified here for pure BPO forks. Regular forks have their own fork version specified in source, even if they alter blob parameters.
90+
91+
```yaml
92+
BLOB_PARAMETER_SCHEDULE:
93+
- EPOCH: 269568 ## Deneb (backported)
94+
MAX_BLOBS_PER_BLOCK: 6
95+
- EPOCH: 364032 ## Electra (backported)
96+
MAX_BLOBS_PER_BLOCK: 9
97+
- EPOCH: 400000 ## A future anonymous BPO fork carrying a fork version
98+
FORK_VERSION: 0x09000000
8099
MAX_BLOBS_PER_BLOCK: 24
81-
- EPOCH: 355368
100+
- EPOCH: 420000 ## A future anonymous BPO fork carrying a fork version
101+
FORK_VERSION: 0x0A000000
82102
MAX_BLOBS_PER_BLOCK: 56
83103
```
84104
85105
The parameters and schedules above are purely illustrative. Actual values and schedules are beyond the scope of this specification.
86106
87-
### Requirements
107+
**Requirements:**
108+
109+
- Execution and consensus clients **MUST** share consistent BPO fork schedules.
110+
- The timestamp in EL's `blobSchedule` **MUST** align with the start of the epoch specified in the consensus layer configuration.
111+
- The `max` field in `blobSchedule` **MUST** equal the `MAX_BLOBS_PER_BLOCK` value in the consensus layer configuration.
112+
113+
### Modified `compute_fork_version`
114+
115+
The `compute_fork_version` helper is updated to account for BPO forks:
116+
117+
```python
118+
def compute_fork_version(epoch: Epoch, blob_schedule: Sequence[BlobScheduleEntry]) -> Version:
119+
# Start with named forks.
120+
forks = [
121+
(ELECTRA_FORK_EPOCH, ELECTRA_FORK_VERSION),
122+
(DENEB_FORK_EPOCH, DENEB_FORK_VERSION),
123+
(CAPELLA_FORK_EPOCH, CAPELLA_FORK_VERSION),
124+
(BELLATRIX_FORK_EPOCH, BELLATRIX_FORK_VERSION),
125+
(ALTAIR_FORK_EPOCH, ALTAIR_FORK_VERSION),
126+
]
127+
128+
# Add blob schedule entries that define fork versions (therefore representing BPO forks).
129+
bpo_forks = [
130+
(entry.epoch, entry.fork_version)
131+
for entry in blob_schedule
132+
if entry.fork_version is not None
133+
]
134+
forks.extend(bpo_forks)
135+
136+
forks.sort(reverse=True)
137+
138+
# Find the most recent fork for this epoch.
139+
for fork_epoch, fork_version in forks:
140+
if epoch >= fork_epoch:
141+
return fork_version
142+
143+
return GENESIS_FORK_VERSION
144+
```
145+
146+
### P2P Networking
147+
148+
In the consensus layer:
88149

89-
- Execution and consensus clients **MUST** share consistent BPO fork schedules
90-
- BPO forks **MUST NOT** conflict with other fork schedules
91-
- The timestamp in `blobSchedule` **MUST** align with the start of the epoch specified in the consensus layer configuration
92-
- The `max` field in `blobSchedule` **MUST** equal the `MAX_BLOBS_PER_BLOCK` value in the consensus layer configuration
150+
- The ENR fields `next_fork_version` and `next_fork_epoch` are set from the configuration for the next BPO fork, if applicable.
151+
- It's worth noting that p2p topics will roll over when a BPO fork is activated, as the `fork_digest` parameter is derived from the `fork_version` (modified above to account for BPO forks).
93152

94153
## Rationale
95154

0 commit comments

Comments
 (0)