Skip to content

Huge compile-time regression in beta/nightly #91128

Closed
@bnjbvr

Description

@bnjbvr

We have a serious Rust compile-time regression happening on an internal (unfortunately closed-source) crate, happening on both the beta and nightly channels.

Before, compiling the crate would take around 1 minute 30 seconds in automation. Now if I'm using the nightly channel, it seems to take around an hour or so.

Running with RUSTFLAGS="-Z new-llvm-pass-manager=no" makes the regression disappear on the nightly channel, so the new pass manager seems to be at fault here.

I've tried compiling with a rustc build from #89830, but it didn't make the regression disappear, so it might not be the same inlining issue.

Thanks a bunch to @lqd who suggested disabling the pass manager, and trying the above patch. Pinging LLVM people: @nikic @Mark-Simulacrum. Of course I'm happy to run any other diagnostic and try any tool that could help figure out what's going on here.

Metadata

Metadata

Assignees

Labels

A-LLVMArea: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.I-compiletimeIssue: Problems and improvements with respect to compile times.P-criticalCritical priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.perf-regressionPerformance regression.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions