How to speed up the Rust compiler in 2018 https://blog.mozilla.org/nnethercote/2018/04/30/how-to-speed-up-the-rust-compiler-in-2018/ …
-
Show this thread
-
I consider rustc's slowness an existential threat to Rust's success. "Great language, but the compiler was too slow" is a tragic outcome. If you find this kind of work interesting at all, please consider pitching in! I'm very happy to help getting people up to speed.
3 replies 5 retweets 25 likesShow this thread -
Replying to @nnethercote
I don't quite understand the problem well enough to go off on a big rant about it, but I suspect that to make a step change, the compiler needs to process multiple crates at once so that it can start compiling a crate as soon as its dependencies have been typechecked.
4 replies 0 retweets 5 likes -
Replying to @rocallahan @nnethercote
I'm also really excited by the work
@nokusu is leading up in a new WG working on compiler optimizations within rustc, pre-LLVM. LLVM pass times are still the biggest culprit (for Servo/Firefox) and I am guessing the best way to do that is shrinking/pre-optimizing the input IR.3 replies 0 retweets 2 likes -
I'm sure you're right about "the biggest culprit" when you look at profiles, but don't let that obscure the limitations on parallelism imposed by running all those LLVM passes before even starting to parse crates higher on the dependence graph.
2 replies 0 retweets 2 likes -
It's totally servo-specific, but we've noticed that the non-linear compile times for code and unbalanced crate sizes mean that anything else we do apart from improving the performance of compiling the script crate or the final link is useful but shuffling 1% here or there.
2 replies 0 retweets 0 likes -
Replying to @larsberg_ @rocallahan and
w.r.t. compiling other crates, are you suggesting that we could be parsing the higher crates once enough metadata from the compilation of lower crates is complete? Typically one problem we have on Servo that could help is just doing a smarter schedule.
2 replies 0 retweets 0 likes
.@eddyb_r has suggested just that for quite a while now.
-
-
Replying to @pcwalton @rocallahan and
Yes, we used to talk about it every six months or so :-) Of course, as often happens in the meantime
@alex_crichton appears to have already fixed it https://github.com/rust-lang/cargo/pull/5100 … ! /me should check it out in Servo...0 replies 0 retweets 0 likesThanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.