diff --git a/ArbAggregator.sol b/ArbAggregator.sol index 03dd42d..b538bc8 100644 --- a/ArbAggregator.sol +++ b/ArbAggregator.sol @@ -41,7 +41,10 @@ interface ArbAggregator { /// This reverts unless called by the batch poster, its fee collector, or a chain owner /// @param batchPoster The batch poster to set the fee collector for /// @param newFeeCollector The new fee collector to set - function setFeeCollector(address batchPoster, address newFeeCollector) external; + function setFeeCollector( + address batchPoster, + address newFeeCollector + ) external; /// @notice Deprecated, always returns zero /// @notice Get the tx base fee (in approximate L1 gas) for aggregator @@ -56,5 +59,8 @@ interface ArbAggregator { /// Revert if feeInL1Gas is outside the chain's allowed bounds /// @param aggregator The aggregator to set the fee for /// @param feeInL1Gas The base fee in L1 gas - function setTxBaseFee(address aggregator, uint256 feeInL1Gas) external; + function setTxBaseFee( + address aggregator, + uint256 feeInL1Gas + ) external; } diff --git a/ArbDebug.sol b/ArbDebug.sol index ac42b4d..2fc7850 100644 --- a/ArbDebug.sol +++ b/ArbDebug.sol @@ -13,7 +13,10 @@ interface ArbDebug { function becomeChainOwner() external; /// @notice Emit events with values based on the args provided - function events(bool flag, bytes32 value) external payable returns (address, uint256); + function events( + bool flag, + bytes32 value + ) external payable returns (address, uint256); /// @notice Tries (and fails) to emit logs in a view context function eventsView() external view; diff --git a/ArbFunctionTable.sol b/ArbFunctionTable.sol index be2b30e..9d9c207 100644 --- a/ArbFunctionTable.sol +++ b/ArbFunctionTable.sol @@ -22,5 +22,8 @@ interface ArbFunctionTable { ) external view returns (uint256); /// @notice No-op - function get(address addr, uint256 index) external view returns (uint256, bool, uint256); + function get( + address addr, + uint256 index + ) external view returns (uint256, bool, uint256); } diff --git a/ArbGasInfo.sol b/ArbGasInfo.sol index 0261252..32c2ed2 100644 --- a/ArbGasInfo.sol +++ b/ArbGasInfo.sol @@ -50,6 +50,7 @@ interface ArbGasInfo { /// @notice Get the gas accounting parameters. `gasPoolMax` is always zero, as the exponential pricing model has no such notion. /// @return (speedLimitPerSecond, gasPoolMax, maxBlockGasLimit) + /// @dev Deprecated starting from ArbOS version 50. function getGasAccountingParams() external view returns (uint256, uint256, uint256); /// @notice Get the maxTxGasLimit @@ -80,12 +81,15 @@ interface ArbGasInfo { function getCurrentTxL1GasFees() external view returns (uint256); /// @notice Get the backlogged amount of gas burnt in excess of the speed limit + /// @dev Deprecated starting from ArbOS version 50. function getGasBacklog() external view returns (uint64); /// @notice Get how slowly ArbOS updates the L2 basefee in response to backlogged gas + /// @dev Deprecated starting from ArbOS version 50. function getPricingInertia() external view returns (uint64); /// @notice Get the forgivable amount of backlogged gas ArbOS will ignore when raising the basefee + /// @dev Deprecated starting from ArbOS version 50. function getGasBacklogTolerance() external view returns (uint64); /// @notice Returns the surplus of funds for L1 batch posting payments (may be negative). @@ -120,4 +124,13 @@ interface ArbGasInfo { /// @notice Returns the L1 pricing surplus as of the last update (may be negative). /// @notice Available in ArbOS version 20 and above function getLastL1PricingSurplus() external view returns (int256); + + /// @notice Get the current gas pricing constraints used by the Multi-Constraint Pricer. + /// @notice Each constraint contains: + /// - uint64 gas_target (in gas/second) + /// - uint64 time_constant (in seconds) + /// - uint64 backlog (in gas units) + /// @return constraints Array of triples (gas_target_per_second, time_constant_seconds, backlog) + /// @notice Available in ArbOS version 50 and above. + function getGasPricingConstraints() external view returns (uint64[3][] memory constraints); } diff --git a/ArbOwner.sol b/ArbOwner.sol index ac6963a..5e0e75d 100644 --- a/ArbOwner.sol +++ b/ArbOwner.sol @@ -77,6 +77,8 @@ interface ArbOwner { ) external; /// @notice Set the computational speed limit for the chain + /// @dev Deprecated starting from ArbOS version 50. + /// Replaced by `setGasPricingConstraints`, which supports multiple constraints. function setSpeedLimit( uint64 limit ) external; @@ -93,11 +95,15 @@ interface ArbOwner { ) external; /// @notice Set the L2 gas pricing inertia + /// @dev Deprecated starting from ArbOS version 50. + /// Replaced by `setGasPricingConstraints`, which supports multiple constraints. function setL2GasPricingInertia( uint64 sec ) external; /// @notice Set the L2 gas backlog tolerance + /// @dev Deprecated starting from ArbOS version 50. + /// Ignored by the Multi-Constraint Pricer model. function setL2GasBacklogTolerance( uint64 sec ) external; @@ -121,7 +127,10 @@ interface ArbOwner { ) external; /// @notice Upgrades ArbOS to the requested version at the requested timestamp - function scheduleArbOSUpgrade(uint64 newVersion, uint64 timestamp) external; + function scheduleArbOSUpgrade( + uint64 newVersion, + uint64 timestamp + ) external; /// @notice Sets equilibration units parameter for L1 price adjustment algorithm function setL1PricingEquilibrationUnits( @@ -217,7 +226,10 @@ interface ArbOwner { /// @notice Available in ArbOS version 30 and above /// @param gas amount of gas paid in increments of 256 when not the program is not cached /// @param cached amount of gas paid in increments of 64 when the program is cached - function setWasmMinInitGas(uint8 gas, uint16 cached) external; + function setWasmMinInitGas( + uint8 gas, + uint16 cached + ) external; /// @notice Sets the linear adjustment made to program init costs. /// @notice Available in ArbOS version 30 and above @@ -268,6 +280,14 @@ interface ArbOwner { bool enable ) external; + /// @notice Sets the list of gas pricing constraints for the Multi-Constraint Pricer. + /// @notice Replaces existing constraints configuration and resets all backlogs to zero. + /// @notice Available in ArbOS version 50 and above. + /// @param constraints Array of pairs (gas_target_per_second, time_constant_seconds) + function setGasPricingConstraints( + uint64[2][] calldata constraints + ) external; + /// Emitted when a successful call is made to this precompile event OwnerActs(bytes4 indexed method, address indexed owner, bytes data); } diff --git a/ArbStatistics.sol b/ArbStatistics.sol index f5ae31c..0238f52 100644 --- a/ArbStatistics.sol +++ b/ArbStatistics.sol @@ -15,8 +15,5 @@ interface ArbStatistics { /// Number of transaction receipt issued, /// Number of contracts created, /// ) - function getStats() - external - view - returns (uint256, uint256, uint256, uint256, uint256, uint256); + function getStats() external view returns (uint256, uint256, uint256, uint256, uint256, uint256); }