-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
simplify_cfg: rename some passes so that they make more sense #122656
Conversation
rustbot has assigned @compiler-errors. Use r? to explicitly pick a reviewer |
Some changes occurred to MIR optimizations cc @rust-lang/wg-mir-opt |
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.
seems reasonable, thanks for the comments
SimplifyCfg::EarlyOpt => "SimplifyCfg-early-opt", | ||
SimplifyCfg::ElaborateDrops => "SimplifyCfg-elaborate-drops", | ||
SimplifyCfg::PostAnalysis => "SimplifyCfg-post-analysis", | ||
SimplifyCfg::PreOptimization => "SimplifyCfg-pre-optimizations", |
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.
Oh, I should make this consistent... "optimization" vs "optimizations"
@bors r=compiler-errors |
…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.
…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
…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
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.
I was extremely confused by
SimplifyCfg::ElaborateDrops
, since it runs way later than drop elaboration. It is used e.g. inmir-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
I am open to other suggestions.