-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change the global default for download-ci-llvm
to if-available
#566
Comments
This issue is not meant to be used for technical discussion. There is a Zulip stream for that. Use this issue to leave procedural comments, such as volunteering to review, indicating that you second the proposal (or third, etc), or raising a concern that you would like to be addressed. cc @rust-lang/compiler @rust-lang/compiler-contributors |
@rustbot second |
@rustbot label -final-comment-period +major-change-accepted |
…ev"` See rust-lang/compiler-team#566. The motivation for changing the default is to avoid downloading and building LLVM when someone runs `x build` before running `x setup`. The motivation for only doing it on `channel = "dev"` is to avoid breaking distros or users installing from source. It works because `dev` is also the default channel. The diff looks larger than it is; most of it is moving the `llvm` branch below the `rust` so `config.channel` is set.
…=Mark-Simulacrum Set `download-ci-llvm = "if-available"` by default when `channel = dev` See rust-lang/compiler-team#566. The motivation for changing the default is to avoid downloading and building LLVM when someone runs `x build` before running `x setup`. The motivation for only doing it on `channel = "dev"` is to avoid breaking distros or users installing from source. It works because `dev` is also the default channel. The diff looks larger than it is; most of it is moving the `llvm` branch below the `rust` so `config.channel` is set. r? `@Mark-Simulacrum` cc `@oli-obk` `@bjorn3` `@cuviper`
Proposal
Switch the
None
branch of this match to returnis_ci_llvm_available
instead of false: https://github.com/rust-lang/rust/blob/b0f3940c35d565399dccf8c79f38147b40f2724a/src/bootstrap/config.rs#L1086-L1092Background and Motivation
x.py has a tiered defaults system. It has a global default, which is used if no
config.toml
exists, and then opt-in "profiles" (library, compiler, user). Right now, the global default for download_ci_llvm isfalse
and the profile default is "if-available" for all profiles exceptuser
. This works generally well for frequent contributors to the compiler, but means that first-time contributors get a sub-standard experience (see for example @pnkfelix's stream where more than half of the first-time build is spent building llvm: https://www.youtube.com/watch?v=oG-JshUmkuA). This is particularly bad because LLVM takes enormously long to build, and it's worse on computers with fewer hardware threads.I suggest changing the global default to
if-available
. "if-available" currently means "any tier 1 platform" (there are some additional checks related to running in CI, but they're not important for local development).Drawbacks
There are two possible downsides:
rust-dev
LLVM artifacts are corrupt on FreeBSD 13 rust#96633. We can avoid regressing behavior there by removing them from theif-available
check if we notice they're broken../configure --set llvm.download-ci-llvm=false
. I think this is fine as long as the change is documented in bootstrap's changelog.Mentors or Reviewers
@pnkfelix for helping me convince t-compiler this is a good idea
@Mark-Simulacrum for thinking of any downsides I may have missed
Process
The main points of the Major Change Process are as follows:
@rustbot second
.-C flag
, then full team check-off is required.@rfcbot fcp merge
on either the MCP or the PR.You can read more about Major Change Proposals on forge.
Comments
This issue is not meant to be used for technical discussion. There is a Zulip stream for that. Use this issue to leave procedural comments, such as volunteering to review, indicating that you second the proposal (or third, etc), or raising a concern that you would like to be addressed.
The text was updated successfully, but these errors were encountered: