Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
Language Features:

Compiler Features:
* Yul Optimizer: Remove redundant prerequisite steps from the default optimizer sequence.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we name them?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't because I did not think it was all that relevant to the user. If you do not use a custom sequence, you do not have to do anything. If you do and want to have the default sequence with just some modifications, you have to look at the diff anyway. We do not document the exact shape of the default sequence anyway.


Bugfixes:

Expand Down
2 changes: 1 addition & 1 deletion docs/using-the-compiler.rst
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ Input Description
// In particular if the whole value consists only of the delimiter, both sequences are empty.
// Note that there are several hard-coded steps that always run, even when both sequences are empty.
// For more information see "The Optimizer > Selecting Optimizations".
"optimizerSteps": "dhfoDgvulfnTUtnIf..."
"optimizerSteps": "dfDvulfnTUtnIf..."
}
}
},
Expand Down
8 changes: 4 additions & 4 deletions libsolidity/interface/OptimiserSettings.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ enum class OptimisationPreset
struct OptimiserSettings
{
static char constexpr DefaultYulOptimiserSteps[] =
"dhfoDgvulfnTUtnIf" // None of these can make stack problems worse
"dfDvulfnTUtnIf" // None of these can make stack problems worse

"xa[r]EscLM" // Turn into SSA and simplify
"Vcul [j]" // Reverse SSA
Expand All @@ -51,13 +51,13 @@ struct OptimiserSettings

"Trpeul" // Run functional expression inliner
"xa[r]cL" // Turn into SSA again and simplify
"gvifM" // Run full inliner
"vifM" // Run full inliner
"CTUca[r]LSsTFOtfDnca[r]Iulc" // SSA plus simplify

"scCTUt"
"gvifM" // Run full inliner
"vifM" // Run full inliner
"x[scCTUt] TOntnfDIul" // Perform structural simplification
"gvifM" // Run full inliner
"vifM" // Run full inliner

"jmul[jul] VcTOcul jmul"; // Make source short and pretty

Expand Down