4 ms·
How do Rust build times compare to Scala?
by ibraheemdev 6y ago
How do Rust build times compare to Scala?
- nindalf 6y agoIt’s hard to compare across languages. Too many independent variables to consider. Take the example of grep vs Ripgrep. Is it fair to compare the compile times of grep written in C with ripgrep? I can see arguments both ways. What I can say with confidence is that Rust build times have improved continuously in the last 2 years. It’s now 30-50% faster on common programs. The future is bright too, a new debug back end out in 2021 promises a further 50% improvement.
- ibraheemdev 6y agoDo you have a reference for that "new debug back end"?
- estebank 6y agohttps://hacks.mozilla.org/2020/10/a-new-backend-for-cranelift-part-1-instruction-selection/ https://hacks.mozilla.org/2020/10/a-new-backend-for-cranelif... https://github.com/bjorn3/rustc_codegen_cranelift https://github.com/bjorn3/rustc_codegen_cranelift
- ComputerGuru 6y agoProject Cranelift
- deleted 6y ago[deleted]
- dmit 6y agoOne of the reasons why it's hard to compare the two is that the standard metric is time/loc, and it varies hugely depending on which language features are used. Both languages have features that can blow up compile times by a factor of 1000 or more.
- lalaithion 6y agoIn my experience, cargo build (as of recently) is significantly faster than sbt compile (as of 3 years ago), but only a little faster than compile (as of 3 years ago) called from within the sbt shell. This comparison is my gut feeling, on pretty small programs.