From a06fdcd572f9575a157f022deb19f0cc402cba7c Mon Sep 17 00:00:00 2001 From: Mark Tyneway Date: Fri, 2 Aug 2024 06:05:44 +0300 Subject: [PATCH] specs: standardize folder structure (#306) Move fjord to the same folder structure as the other hardfork directories. Previously, fjord was special as it was in a subdirectory. It should be siblings to the other hardforks. Co-authored-by: protolambda --- book.toml | 4 ++++ specs/SUMMARY.md | 8 ++++---- specs/protocol/derivation.md | 10 +++++----- specs/{ => protocol}/fjord/derivation.md | 8 ++++---- specs/{ => protocol}/fjord/exec-engine.md | 0 specs/{ => protocol}/fjord/overview.md | 2 +- specs/{ => protocol}/fjord/predeploys.md | 0 7 files changed, 18 insertions(+), 14 deletions(-) rename specs/{ => protocol}/fjord/derivation.md (97%) rename specs/{ => protocol}/fjord/exec-engine.md (100%) rename specs/{ => protocol}/fjord/overview.md (92%) rename specs/{ => protocol}/fjord/predeploys.md (100%) diff --git a/book.toml b/book.toml index 3bd71dfef..5287c7845 100644 --- a/book.toml +++ b/book.toml @@ -27,5 +27,9 @@ additional-js = ["specs/static/solidity.min.js", "specs/static/mermaid.min.js", "/experimental/fault-proof/stage-one/fault-dispute-game.html" = "/fault-proof/stage-one/fault-dispute-game.html" "/experimental/fault-proof/stage-one/honest-challenger-fdg.html" = "/fault-proof/stage-one/honest-challenger-fdg.html" "/experimental/plasma.html" = "/experimental/alt-da.html" +"/fjord/overview.html" = "/protocol/fjord/overview.html" +"/fjord/derivation.html" = "/protocol/fjord/derivation.html" +"/fjord/exec-engine.html" = "/protocol/fjord/exec-engine.html" +"/fjord/predeploys.html" = "/protocol/fjord/predeploys.html" [output.linkcheck] diff --git a/specs/SUMMARY.md b/specs/SUMMARY.md index fa3f26e58..1f6795901 100644 --- a/specs/SUMMARY.md +++ b/specs/SUMMARY.md @@ -11,10 +11,10 @@ - [Delta](./protocol/delta/overview.md) - [Span Batches](./protocol/delta/span-batches.md) - [Ecotone](./protocol/ecotone/overview.md) - - [Fjord](./fjord/overview.md) - - [Execution Engine](./fjord/exec-engine.md) - - [Derivation](./fjord/derivation.md) - - [Predeploys](./fjord/predeploys.md) + - [Fjord](./protocol/fjord/overview.md) + - [Execution Engine](./protocol/fjord/exec-engine.md) + - [Derivation](./protocol/fjord/derivation.md) + - [Predeploys](./protocol/fjord/predeploys.md) - [Bridges](./protocol/bridges.md) - [Messengers](./protocol/messengers.md) - [Deposits](./protocol/deposits.md) diff --git a/specs/protocol/derivation.md b/specs/protocol/derivation.md index 1847e5ee3..46795f902 100644 --- a/specs/protocol/derivation.md +++ b/specs/protocol/derivation.md @@ -187,10 +187,10 @@ protocol upgrades. | Parameter | Bedrock (default) value | Latest (default) value | Changes | Notes | | --------- | ----------------------- | ---------------------- | ------- | ----- | -| `max_sequencer_drift` | 600 | 1800 | [Fjord](../fjord/derivation.md#constant-maximum-sequencer-drift) | Changed from a chain parameter to a constant with Fjord. | -| `MAX_RLP_BYTES_PER_CHANNEL` | 10,000,000 | 100,000,000 | [Fjord](../fjord/derivation.md#increasing-max_rlp_bytes_per_channel-and-max_channel_bank_size) | Constant increased with Fjord. | -| `MAX_CHANNEL_BANK_SIZE` | 100,000,000 | 1,000,000,000 | [Fjord](../fjord/derivation.md#increasing-max_rlp_bytes_per_channel-and-max_channel_bank_size) | Constant increased with Fjord. | -| `MAX_SPAN_BATCH_ELEMENT_COUNT` | 10,000,000 | 10,000,000 | Effectively introduced in [Fjord](../fjord/derivation.md#increasing-max_rlp_bytes_per_channel-and-max_channel_bank_size)| Number of elements | +| `max_sequencer_drift` | 600 | 1800 | [Fjord](./fjord/derivation.md#constant-maximum-sequencer-drift) | Changed from a chain parameter to a constant with Fjord. | +| `MAX_RLP_BYTES_PER_CHANNEL` | 10,000,000 | 100,000,000 | [Fjord](./fjord/derivation.md#increasing-max_rlp_bytes_per_channel-and-max_channel_bank_size) | Constant increased with Fjord. | +| `MAX_CHANNEL_BANK_SIZE` | 100,000,000 | 1,000,000,000 | [Fjord](./fjord/derivation.md#increasing-max_rlp_bytes_per_channel-and-max_channel_bank_size) | Constant increased with Fjord. | +| `MAX_SPAN_BATCH_ELEMENT_COUNT` | 10,000,000 | 10,000,000 | Effectively introduced in [Fjord](./fjord/derivation.md#increasing-max_rlp_bytes_per_channel-and-max_channel_bank_size)| Number of elements | --- @@ -393,7 +393,7 @@ where zlib_compress is the ZLIB algorithm (as specified in [RFC-1950][rfc1950]) [rfc1950]: https://www.rfc-editor.org/rfc/rfc1950.html The Fjord upgrade introduces an additional [versioned channel encoding -format](../fjord/derivation.md#brotli-channel-compression) to support alternate compression +format](./fjord/derivation.md#brotli-channel-compression) to support alternate compression algorithms. When decompressing a channel, we limit the amount of decompressed data to `MAX_RLP_BYTES_PER_CHANNEL` (defined in the diff --git a/specs/fjord/derivation.md b/specs/protocol/fjord/derivation.md similarity index 97% rename from specs/fjord/derivation.md rename to specs/protocol/fjord/derivation.md index d6e702139..52e9d041d 100644 --- a/specs/fjord/derivation.md +++ b/specs/protocol/fjord/derivation.md @@ -76,8 +76,8 @@ a security issue. With Fjord, `MAX_RLP_BYTES_PER_CHANNEL` will be increased from 10,000,000 bytes to 100,000,000 bytes, and `MAX_CHANNEL_BANK_SIZE` will be increased from 100,000,000 bytes to 1,000,000,000 bytes. -The usage of `MAX_RLP_BYTES_PER_CHANNEL` is defined in [Channel Format](../protocol/derivation.md#channel-format). -The usage of `MAX_CHANNEL_BANK_SIZE` is defined in [Channel Bank Pruning](../protocol/derivation.md#pruning). +The usage of `MAX_RLP_BYTES_PER_CHANNEL` is defined in [Channel Format](../derivation.md#channel-format). +The usage of `MAX_CHANNEL_BANK_SIZE` is defined in [Channel Bank Pruning](../derivation.md#pruning). Span Batches previously had a limit `MAX_SPAN_BATCH_SIZE` which was equal to `MAX_RLP_BYTES_PER_CHANNEL`. Fjord creates a new constant `MAX_SPAN_BATCH_ELEMENT_COUNT` for the element count limit & removes @@ -125,7 +125,7 @@ prior to this change which would cause the Fault Proof Program to consume a very # Brotli Channel Compression -[legacy-channel-format]: ../protocol/derivation.md#channel-format +[legacy-channel-format]: ../derivation.md#channel-format Fjord introduces a new versioned channel encoding format to support alternate compression algorithms, with the [legacy channel format][legacy-channel-format] remaining supported. The @@ -171,7 +171,7 @@ To perform this upgrade, a deposit transaction is derived with the following att - `mint`: `0` - `value`: `0` - `gasLimit`: `1,450,000` -- `data`: `0x60806040523...` ([full bytecode](../static/bytecode/fjord-gas-price-oracle-deployment.txt)) +- `data`: `0x60806040523...` ([full bytecode](../../static/bytecode/fjord-gas-price-oracle-deployment.txt)) - `sourceHash`: `0x86122c533fdcb89b16d8713174625e44578a89751d96c098ec19ab40a51a8ea3` computed with the "Upgrade-deposited" type, with `intent = "Fjord: Gas Price Oracle Deployment" diff --git a/specs/fjord/exec-engine.md b/specs/protocol/fjord/exec-engine.md similarity index 100% rename from specs/fjord/exec-engine.md rename to specs/protocol/fjord/exec-engine.md diff --git a/specs/fjord/overview.md b/specs/protocol/fjord/overview.md similarity index 92% rename from specs/fjord/overview.md rename to specs/protocol/fjord/overview.md index 09e8503c8..2da1bba3b 100644 --- a/specs/fjord/overview.md +++ b/specs/protocol/fjord/overview.md @@ -13,7 +13,7 @@ This document is not finalized and should be considered experimental. ## Execution Layer -- [RIP-7212: Precompile for secp256r1 Curve Support](../protocol/precompiles.md#P256VERIFY) +- [RIP-7212: Precompile for secp256r1 Curve Support](../precompiles.md#P256VERIFY) - [FastLZ compression for L1 data fee calculation](./exec-engine.md#fees) - [Deprecate the `getL1GasUsed` method on the `GasPriceOracle` contract](./predeploys.md#l1-gas-usage-estimation) - [Deprecate the `L1GasUsed` field on the transaction receipt](./exec-engine.md#l1-gas-usage-estimation) diff --git a/specs/fjord/predeploys.md b/specs/protocol/fjord/predeploys.md similarity index 100% rename from specs/fjord/predeploys.md rename to specs/protocol/fjord/predeploys.md