Hello, I'm interested in rustc' compile time. Some preliminary test left me with some questions.
I measured building a minimal application. https://gist.github.com/Voultapher/ebc3abb55994ea90f3ac604c5ffccc19
Things I noticed:
- nightly is significantly faster than stable, yay!
- clang's full run is less than emit llvm ir + compile llvm ir
- rustc's full run is much slower than emit llvm ir + compile llvm ir
clang's full time could be explained by avoiding separate stages and using llvm as lib. However rustc taking longer than the separate stages seem weird. Maybe this is less noticeable in bigger builds and a fixed cost. What is rustc doing that is taking so much time when building an app?
Comparing it to building a library: https://gist.github.com/Voultapher/7fbcf7e307896ea557b50eff5fb0db42
clang somehow takes longer to build the library than the application. rustc is similar to clang, as long as the std modules aren't used.