Hacker News new | ask | show | jobs
by jcranmer 1692 days ago
Distributed compilation isn't as helpful as it might seem at first glance. In order to compile something remotely, you need to slurp all the source files and the relevant environment information locally, send it to a remote compilation process, wait for it to compile, and get the results back. This extra network overhead is going to eat up a lot of the potential speed benefits you might get on a beefier machine, and limited bandwidth is likely to limit the maximum width of the parallelism you might encounter.

A better alternative than distributed compilation is artifact caching. Effectively, instead of shipping .rs files all over the place to compile them, just ship .o files around. Rust already has a decently canonical solution for this in the form of sccache, which was developed by Mozilla for caching the builds of Firefox using Amazon S3 as the storage (hence the name--S3 ccache [compiler cache]).