rustc_mir: hardcode pass list internally and remove premature pluggability.#45916
rustc_mir: hardcode pass list internally and remove premature pluggability.#45916bors merged 4 commits intorust-lang:masterfrom
Conversation
|
@bors r+ |
|
📌 Commit 9eadc36 has been approved by |
|
Please dont do this as this would make it very hard to update holyjit for the latest nightly. Currently it just requires a rustc patch of a few lines. |
|
@bjorn3 See this PR's description for the appropriate course of action. Being able to replace the provider for, e.g., the |
|
I see. Should have read the description completely. |
|
@bjorn3 Thanks for your concern for HolyJit. Yes this patch is going to break the ability to simply rebase a patch on top of rustc, but HolyJit is a prototype, and I have been warned and explicitly been suggested against using a plugin approach from the beginning. I still went with the plugin approach because this is something I understand and which was close enough to what is currently documented for making syntax plugins. |
|
☔ The latest upstream changes (presumably #45909) made this pull request unmergeable. Please resolve the merge conflicts. |
|
@bors r=nikomatsakis |
|
📌 Commit d6aa56f has been approved by |
rustc_mir: hardcode pass list internally and remove premature pluggability. Fixes #41712 by moving the MIR pass lists from `rustc_driver` to `rustc_mir`. The application of the passes is done with the `rustc_mir::transform::run_passes` macro, which is public, as are all the passes AFAIK, and can be used to apply MIR passes outside of `rustc_mir`. With the ability to override query providers through the `rustc_driver` (orthogonal to, and not included in this PR), custom drivers will be able to substitute the entire pass list if they want to. **EDIT**: the aforementioned ability is added by #45944. r? @nikomatsakis
|
☀️ Test successful - status-appveyor, status-travis |
Fixes #41712 by moving the MIR pass lists from
rustc_drivertorustc_mir.The application of the passes is done with the
rustc_mir::transform::run_passesmacro, which is public, as are all the passes AFAIK, and can be used to apply MIR passes outside ofrustc_mir.With the ability to override query providers through the
rustc_driver(orthogonal to, and not included in this PR), custom drivers will be able to substitute the entire pass list if they want to.EDIT: the aforementioned ability is added by #45944.
r? @nikomatsakis