| ▲ | nicoburns 10 hours ago | ||||||||||||||||
> Compiling stalwart takes about 20 minutes 20 minutes! What hardware is this on? I've worked on Rust projects with similar numbers of dependencies where the compile time (for a clean release build) was 2-4 minutes (on a MacBook M1 Pro) | |||||||||||||||||
| ▲ | nicoburns 6 hours ago | parent [-] | ||||||||||||||||
UPDATE: tried compiling stalwart on my machine, and it took 14 minutes, with a really weird timing profile: - 99% of the ~700 crates were done compiling in about a minute or 2 - RocksDB (a C++ dependency) was 2 minutes by itself - And then it took 10 minutes (ten!) just for the final binary at the end. That's not normal for Rust code at all. Even large ones like Servo or Rustc or Zed. UPDATE2: turns out they have LTO enabled by default. Disabling that brings the compile time down to 7 minutes. But that's still really unexpectedly slow. | |||||||||||||||||
| |||||||||||||||||