-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Cargo no-op build time is huge #5315
Comments
Is there a link as well to reproduce locally with? |
I've just tried it on the canonical random project of mine, http://github.com/matklad/rustraytracer |
So, even fresh "hello world" build is 180 ms |
|
Originally I had a hypothesis that this might be a regression in rustup shims as well, but, because I use the same rustup to try 1.18.0, that hypothesis is probably wrong. |
Hm, looks like a regression in rustc actually?
|
And this is true even for λ time rustc +stable -vV
rustc 1.25.0 (84203cac6 2018-03-25)
binary: rustc
commit-hash: 84203cac67e65ca8640b8392348411098c856985
commit-date: 2018-03-25
host: x86_64-unknown-linux-gnu
release: 1.25.0
LLVM version: 6.0
rustc +stable -vV 0.11s user 0.01s system 98% cpu 0.128 total
~/trash/foo master*
λ time rustc +1.18.0 -vV
rustc 1.18.0 (03fc9d622 2017-06-06)
binary: rustc
commit-hash: 03fc9d622e0ea26a3d37f5ab030737fcca6928b9
commit-date: 2017-06-06
host: x86_64-unknown-linux-gnu
release: 1.18.0
LLVM version: 3.9
rustc +1.18.0 -vV 0.03s user 0.01s system 98% cpu 0.047 total |
opened rust-lang/rust#49761 at rustc =P |
Some discussion about this here: https://botbot.me/mozilla/cargo/2018-04-07/?msg=98731867&page=2 The tl;dr; is:
|
Rustc cache This implements rustc caching, to speed-up no-op builds. The cache is per-project, and stored in `target` directory. To implement this, I had to move `rustc` from `Config` down to `BuildConfig`. closes #5315
Rustc cache This implements rustc caching, to speed-up no-op builds. The cache is per-project, and stored in `target` directory. To implement this, I had to move `rustc` from `Config` down to `BuildConfig`. closes #5315
You can get some internal profiling metrics by running
CARGO_PROFILE=1 cargo build
. Here's what I get with 1.18.0 and with current stable:Looks like we've regressed pretty significantly over time :-(
The text was updated successfully, but these errors were encountered: