Skip to content
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

Support running with new pass manager #64289

Closed
nikic opened this issue Sep 8, 2019 · 3 comments · Fixed by #67954
Closed

Support running with new pass manager #64289

nikic opened this issue Sep 8, 2019 · 3 comments · Fixed by #67954
Assignees
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@nikic
Copy link
Contributor

nikic commented Sep 8, 2019

Rustc currently still uses the legacy LLVM pass manager. There's been some discussion about enabling NewPM by default for Clang 10, so we might want to start migrating in that direction as well.

To start with, we'd probably want a debug option -Z llvm-pass-manager=new that is not enabled by default, but can be used to perform initial evaluation.

For reference, this is how newpm use looks like in clang: https://github.com/llvm/llvm-project/blob/90d2be0163e8f84dfc0b73128d873ac8d84c10f8/clang/lib/CodeGen/BackendUtil.cpp#L985

@nikic nikic added A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Sep 8, 2019
@cuviper
Copy link
Member

cuviper commented Sep 11, 2019

I'm going to take a shot at this.

@cuviper cuviper self-assigned this Sep 11, 2019
@nikic nikic self-assigned this Jan 5, 2020
@nikic
Copy link
Contributor Author

nikic commented Jan 5, 2020

Also looking into this now. Seems less hard than I originally expected, though some things can't be supported (e.g. MergeFunctions doesn't seem to support NewPM yet?)

bors added a commit that referenced this issue Jan 6, 2020
[WIP] Support new LLVM pass manager

This is a prototype to add support for the new LLVM pass manager. For now this is only for the optimization phase.

Closes #64289.

r? @ghost
@nikic
Copy link
Contributor Author

nikic commented Jan 7, 2020

I've created a prototype for newpm at #67954.

@bors bors closed this as completed in f127aba Feb 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants