simplify_cfg: rename some passes so that they make more sense#122656
Merged
bors merged 1 commit intorust-lang:masterfrom Mar 18, 2024
Merged
simplify_cfg: rename some passes so that they make more sense#122656bors merged 1 commit intorust-lang:masterfrom
bors merged 1 commit intorust-lang:masterfrom
Conversation
Collaborator
|
rustbot has assigned @compiler-errors. Use r? to explicitly pick a reviewer |
Collaborator
|
Some changes occurred to MIR optimizations cc @rust-lang/wg-mir-opt |
compiler-errors
approved these changes
Mar 17, 2024
Contributor
compiler-errors
left a comment
There was a problem hiding this comment.
seems reasonable, thanks for the comments
RalfJung
commented
Mar 17, 2024
| SimplifyCfg::EarlyOpt => "SimplifyCfg-early-opt", | ||
| SimplifyCfg::ElaborateDrops => "SimplifyCfg-elaborate-drops", | ||
| SimplifyCfg::PostAnalysis => "SimplifyCfg-post-analysis", | ||
| SimplifyCfg::PreOptimization => "SimplifyCfg-pre-optimizations", |
Member
Author
There was a problem hiding this comment.
Oh, I should make this consistent... "optimization" vs "optimizations"
Member
Author
|
@bors r=compiler-errors |
Collaborator
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this pull request
Mar 17, 2024
…errors simplify_cfg: rename some passes so that they make more sense I was extremely confused by `SimplifyCfg::ElaborateDrops`, since it runs way later than drop elaboration. It is used e.g. in `mir-opt/retag.rs` even though that pass doesn't care about drop elaboration at all. "Early opt" is also very confusing since that makes it sounds like it runs early during optimizations, i.e. on runtime MIR, but actually it runs way before that. So I decided to rename - early-opt -> post-analysis - elaborate-drops -> pre-optimizations I am open to other suggestions.
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Mar 17, 2024
…iaskrgr Rollup of 5 pull requests Successful merges: - rust-lang#121652 (Detect when move of !Copy value occurs within loop and should likely not be cloned) - rust-lang#122639 (Fix typos) - rust-lang#122645 (Remove some only- clauses from mir-opt tests) - rust-lang#122654 (interpret/memory: explain why we use == on bool) - rust-lang#122656 (simplify_cfg: rename some passes so that they make more sense) r? `@ghost` `@rustbot` modify labels: rollup
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Mar 18, 2024
…iaskrgr Rollup of 4 pull requests Successful merges: - rust-lang#122639 (Fix typos) - rust-lang#122654 (interpret/memory: explain why we use == on bool) - rust-lang#122656 (simplify_cfg: rename some passes so that they make more sense) - rust-lang#122657 (Move `option_env!` and `env!` tests to the `env-macro` directory) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Mar 18, 2024
Rollup merge of rust-lang#122656 - RalfJung:simplify-cfg, r=compiler-errors simplify_cfg: rename some passes so that they make more sense I was extremely confused by `SimplifyCfg::ElaborateDrops`, since it runs way later than drop elaboration. It is used e.g. in `mir-opt/retag.rs` even though that pass doesn't care about drop elaboration at all. "Early opt" is also very confusing since that makes it sounds like it runs early during optimizations, i.e. on runtime MIR, but actually it runs way before that. So I decided to rename - early-opt -> post-analysis - elaborate-drops -> pre-optimizations I am open to other suggestions.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
I was extremely confused by
SimplifyCfg::ElaborateDrops, since it runs way later than drop elaboration. It is used e.g. inmir-opt/retag.rseven though that pass doesn't care about drop elaboration at all."Early opt" is also very confusing since that makes it sounds like it runs early during optimizations, i.e. on runtime MIR, but actually it runs way before that.
So I decided to rename
I am open to other suggestions.