-
Notifications
You must be signed in to change notification settings - Fork 6k
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
Non-interactive mode for yulopti. #12221
Conversation
c53d7f7
to
f91cfc7
Compare
Ah, sigh, I mainly wanted to have something quickly to be able to get back to people who would need this :-). |
Oh, true, forgot that it's not public. Still, It's not a huge change and I think that not having two separate pieces of code executing these sequences is worth it. And people might want the ability to run bracketed and nested sequences anyway (we do have them in our default sequence after all). |
a037003
to
4213773
Compare
Happier now :-)? We could spend a week to make this nicer, but I'd really just like to have anything working fast ;-). |
261d13f
to
a06cb09
Compare
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.
Looks good.
I have some suggestions about stdin handling and exceptions but I'd only consider the ones about exceptions to be important (and I provided suggestions for them that you can just commit and squash) so in the interest of getting it through quickly, I'm approving already.
m_dialect, | ||
m_nameDispenser, | ||
m_reservedIdentifiers, | ||
solidity::frontend::OptimiserSettings::standard().expectedExecutionsPerDeployment |
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.
Just a question: I just noticed that we have it hard-coded. Isn't this parameter kinda important when playing with the optimizer? Maybe we should have a prameter for this (not in this PR of course)?
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.
Yep, when I stumbled across this now, I also thought, it should probably be configurable - it would be a bit annoying to do in interactive mode (i.e. allow changing it between steps on the fly), but at least a command line option might be nice. But yeah, we can do it separately.
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.
It's a good easy task for an external contributor. I'll create an issue.
c398990
to
4966717
Compare
Updated. I also noticed that most parser errors are fatal and throw, so to properly report that, we need to catch in It also doesn't ignore |
4966717
to
e809e8a
Compare
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.
Again, I have some change suggestions but none of it is critical so I'm approving in case you just want to merge it as is.
e809e8a
to
584d217
Compare
Ok, I globalized the exception handling and while doing so eliminated some status returns :-). |
584d217
to
95c973d
Compare
Rebased in hopes of it fixing an hopefully random download error in external tests. |
Was it a download error or a test error? #12187 was merged today so we will start getting errors if the upstream of these tests has breakage in its main branch. At least for OZ and ENS (and Gnosis after the respective PR gets merged). |
I didn't pay that much attention and don't see the run anymore... I think it was one of the |
The fact that it tries to download the compiler is probably due to #10745 - it builds with hardhat but we only configure truffle. #12192 fixes that for good but restarting the test seems to have helped here. |
Background: make it possible to easily run isolated optimizer steps to aid in developing automated verification tools.
Not sure how much we want to refine this, the PR is just a quickly written version that seems to work.