rustup: Slow startup on Windows

To reproduce:

  1. Download rustup-init.exe from https://www.rustup.rs/.
  2. Run it to install Rust.
  3. Run rustup --version.

Expected: this command to print its version (“rustup 1.10.0 (c6a8f7c60 2018-01-25)”) and exit instantly.

Actual behavior: this command takes about one second to print version and exit.


To investigate, I tried building rustup from source. I ran the following commands:

git clone git@github.com:rust-lang-nursery/rustup.rs.git
cd rustup.rs
cargo build --release
copy .\target\release\rustup-init.exe .\rustup.exe

And then

.\rustup.exe --version

Locally built rustup starts up instantly. The size of the executable is 6MB (for comparison, the official download is 13MB). Could it be that the official download was produced for the wrong configuration (debug build or something)?

I used the following compiler to build it:

> rustc --version --verbose
rustc 1.25.0-nightly (29c8276ce 2018-02-07)
binary: rustc
commit-hash: 29c8276cee4a0eab7e0634ff25c6b47bd9f87c6c
commit-date: 2018-02-07
host: x86_64-pc-windows-msvc
release: 1.25.0-nightly
LLVM version: 4.0

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 16 (16 by maintainers)

Commits related to this issue

Most upvoted comments

So this seems to be solved yes? We’re shipping the MSVC binary by default everywhere? I think we can close this ticket, as making the gnu binary faster isn’t a rustup project issue, rather its a rustlang toolchain issue.