Repository navigation
Precompiles for multi dimensional multi constraint pricer #3995
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
Merged
eljobe
merged 10 commits into
master
from
precompiles-for-multi-dimensional-multi-constraint-pricer
Nov 24, 2025
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
fa076c6
Add Arbos 60 version
MishkaRogachev 0b6beab
Implement multi-gas constraints precompiles
MishkaRogachev e81d373
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev d7eb2d6
Add precompile constraint types and check max bips
MishkaRogachev 56df1a5
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev ecb4533
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev 67e141c
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev 2ed17ee
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev 58375d7
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev 1fa83ea
Merge branch 'master' into precompiles-for-multi-dimensional-multi-co…
MishkaRogachev File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule precompiles
updated
3 files
| +19 −0 | ArbGasInfo.sol | |
| +44 −0 | ArbMultiGasConstraintsTypes.sol | |
| +27 −0 | ArbOwner.sol |
Submodule nitro-testnode
updated
3 files
| +1 −1 | blockscout | |
| +3 −3 | scripts/config.ts | |
| +1 −1 | test-node.bash |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| // Copyright 2025, Offchain Labs, Inc. | ||
| // For license information, see https://github.com/OffchainLabs/nitro/blob/master/LICENSE.md | ||
|
|
||
| package precompiles | ||
|
|
||
| // Defines the relative contribution of a specific resource type within a constraint. | ||
| type WeightedResource = struct { | ||
| Resource uint8 | ||
| Weight uint64 | ||
| } | ||
|
|
||
| // Describes a single pricing constraint that applies to one or more weighted resources. | ||
| type MultiGasConstraint = struct { | ||
| Resources []WeightedResource | ||
| AdjustmentWindowSecs uint32 | ||
| TargetPerSec uint64 | ||
| Backlog uint64 | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gligneul I'm not 100% sure it's a good place for this check. Probably in the following PR with implemented model it's worth to extract math into a pure function and use it to sample new base fee for all constraints at once
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, but this code is good also.