Skip to content

Commit 78cf366

Browse files
authored
Increase MAX_GAS_LIMIT to a new value that's safe with MT Cannon (#15864)
1 parent 96f9a13 commit 78cf366

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

packages/contracts-bedrock/snapshots/semver-lock.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@
3636
"sourceCodeHash": "0xad12c20a00dc20683bd3f68e6ee254f968da6cc2d98930be6534107ee5cb11d9"
3737
},
3838
"src/L1/SystemConfig.sol:SystemConfig": {
39-
"initCodeHash": "0x19e352bb99cab389e0eead6178746c49b14d061bea89c444f26e768f601bd6d8",
40-
"sourceCodeHash": "0x5ab5f6a63e40b3c491167afa4a207daebc87286829e3cf07cc2a8ce04abe70e9"
39+
"initCodeHash": "0x07b7039de5b8a4dc57642ee9696e949d70516b7f6dce41dde4920efb17105ef2",
40+
"sourceCodeHash": "0x997212ceadabb306c2abd31918b09bccbba0b21662c1d8930a3599831c374b13"
4141
},
4242
"src/L2/BaseFeeVault.sol:BaseFeeVault": {
4343
"initCodeHash": "0x9b664e3d84ad510091337b4aacaa494b142512e2f6f7fbcdb6210ed62ca9b885",

packages/contracts-bedrock/src/L1/StandardValidator.sol

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ contract StandardValidator {
170170

171171
/// @notice Returns the expected SystemConfig version.
172172
function systemConfigVersion() public pure returns (string memory) {
173-
return "3.3.0";
173+
return "3.4.0";
174174
}
175175

176176
/// @notice Returns the expected OptimismPortal version.
@@ -267,7 +267,7 @@ contract StandardValidator {
267267
{
268268
ISemver _semver = ISemver(address(_sysCfg));
269269
_errors = internalRequire(LibString.eq(_semver.version(), systemConfigVersion()), "SYSCON-10", _errors);
270-
_errors = internalRequire(_sysCfg.gasLimit() <= uint64(200_000_000), "SYSCON-20", _errors);
270+
_errors = internalRequire(_sysCfg.gasLimit() <= uint64(500_000_000), "SYSCON-20", _errors);
271271
_errors = internalRequire(_sysCfg.scalar() != 0, "SYSCON-30", _errors);
272272
_errors =
273273
internalRequire(_admin.getProxyImplementation(address(_sysCfg)) == systemConfigImpl, "SYSCON-40", _errors);

packages/contracts-bedrock/src/L1/SystemConfig.sol

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ contract SystemConfig is ProxyAdminOwnedBase, OwnableUpgradeable, Reinitializabl
8787
/// @notice The maximum gas limit that can be set for L2 blocks. This limit is used to enforce that the blocks
8888
/// on L2 are not too large to process and prove. Over time, this value can be increased as various
8989
/// optimizations and improvements are made to the system at large.
90-
uint64 internal constant MAX_GAS_LIMIT = 200_000_000;
90+
uint64 internal constant MAX_GAS_LIMIT = 500_000_000;
9191

9292
/// @notice Fixed L2 gas overhead. Used as part of the L2 fee calculation.
9393
/// Deprecated since the Ecotone network upgrade
@@ -142,9 +142,9 @@ contract SystemConfig is ProxyAdminOwnedBase, OwnableUpgradeable, Reinitializabl
142142
event ConfigUpdate(uint256 indexed version, UpdateType indexed updateType, bytes data);
143143

144144
/// @notice Semantic version.
145-
/// @custom:semver 3.3.0
145+
/// @custom:semver 3.4.0
146146
function version() public pure virtual returns (string memory) {
147-
return "3.3.0";
147+
return "3.4.0";
148148
}
149149

150150
/// @notice Constructs the SystemConfig contract.

packages/contracts-bedrock/test/L1/OPContractsManager.t.sol

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,7 @@ contract OPContractsManager_Upgrade_Harness is CommonTest {
603603

604604
// Make sure that the SystemConfig is upgraded to the right version. It must also have the
605605
// right l2ChainId and must be properly initialized.
606-
assertEq(ISemver(address(systemConfig)).version(), "3.3.0");
606+
assertEq(ISemver(address(systemConfig)).version(), "3.4.0");
607607
assertEq(impls.systemConfigImpl, EIP1967Helper.getImplementation(address(systemConfig)));
608608
assertEq(systemConfig.l2ChainId(), l2ChainId);
609609
DeployUtils.assertInitialized({ _contractAddress: address(systemConfig), _isProxy: true, _slot: 0, _offset: 0 });

packages/contracts-bedrock/test/L1/StandardValidator.t.sol

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ contract StandardValidator_validate_Test is StandardValidator_TestInit {
313313
/// @notice Tests that the validate function successfully returns the right error when the
314314
/// SystemConfig gas limit is invalid.
315315
function test_validate_systemConfigInvalidGasLimit_succeeds() public {
316-
vm.mockCall(address(systemConfig), abi.encodeCall(ISystemConfig.gasLimit, ()), abi.encode(uint64(200_000_001)));
316+
vm.mockCall(address(systemConfig), abi.encodeCall(ISystemConfig.gasLimit, ()), abi.encode(uint64(500_000_001)));
317317
assertEq("SYSCON-20", _validate(true));
318318
}
319319

0 commit comments

Comments
 (0)