Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Specify max L2 block gas limit #186

Merged
merged 1 commit into from
May 13, 2024
Merged

feat: Specify max L2 block gas limit #186

merged 1 commit into from
May 13, 2024

Conversation

clabby
Copy link
Member

@clabby clabby commented May 10, 2024

Overview

Specifies that the max gas limit in the SystemConfig is 200_000_000

Copy link
Member Author

clabby commented May 10, 2024

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @clabby and the rest of your teammates on Graphite Graphite

@clabby clabby self-assigned this May 10, 2024
@clabby clabby changed the title feat: Specify max gas limit feat: Specify max L2 block gas limit May 10, 2024
@tynes
Copy link
Contributor

tynes commented May 10, 2024

Ideally the rationale is included, ie ensure that its fault provable

Specifies that the max gas limit in the `SystemConfig` can be set to
`200_000_000`
@tynes tynes merged commit 3f37bc0 into main May 13, 2024
1 check passed
@tynes tynes deleted the cl/sys-cfg-max branch May 13, 2024 10:49
@mds1
Copy link
Contributor

mds1 commented Jun 21, 2024

Rationale for 200M per @ajsutton:

Primarily it was based on the fact that we previously fault proved many blocks during FPA and now even using the fullest blocks we can find executing the block itself is under a minute in cannon. Trawling through a full sequence window of L1 blocks to find the batch data we need takes 3-4 hours 😢
So we have a ton of scope to increase gas limits and no scope to increase sequencing window. That said we haven’t done worst case analysis of this which is why the 200m is still reasonably conservative compared to the amount of gas we have executed in cannon in some tests. A single call to some if the precompiles was enough to be not fault provable for example and we had to go via the preimage oracle to skirt around that (we now just call the L1 precompile instead of running it in cannon).

And yeah the interop fault proof is designed such that the gas limit is per chain. We only ever execute a single block from a single chain in each cannon run.
The thing we do need to sort out is the cross checking of interop messages - we can’t afford to walk back a lot of blocks of each chain. Those limits are very very tight and we’re going to have to come up with something if we want to fault prove executing messages that reference initiating messages older than a few hours I suspect (depending on number of chains in the interop set). There are some options there but need to work through the details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants