about summary refs log tree commit diff
path: root/src/bootstrap
AgeCommit message (Collapse)AuthorLines
2025-08-12Unify all groups in bootstrap to use `Builder::msg`Jakub Beránek-239/+206
2025-08-12Consolidate stageN directories in the build directoryJakub Beránek-18/+24
Now stageN-X corresponds to stage N X, as it should.
2025-08-12bootstrap: Only warn about `rust.debug-assertions` if downloading rustcZalathar-1/+1
2025-08-11Add new Tier-3 target: riscv64a23-unknown-linux-gnuChen Zhongyao-0/+1
2025-08-11Auto merge of #145254 - GuillaumeGomez:rollup-7bp43pv, r=GuillaumeGomezbors-3/+5
Rollup of 4 pull requests Successful merges: - rust-lang/rust#144966 ( Improve suggestion for "missing function argument" on multiline call) - rust-lang/rust#145111 (remove some unused private trait impls) - rust-lang/rust#145221 (Fix Cargo cross-compilation (take two)) - rust-lang/rust#145247 (Update `sysinfo` version to `0.37.0`) r? `@ghost` `@rustbot` modify labels: rollup
2025-08-11Print created location of executed commandsJakub Beránek-20/+57
2025-08-11Use `pretty_step_name` in `step_graph`Jakub Beránek-11/+5
2025-08-11Create tracing directory symlink even during dry runJakub Beránek-2/+14
2025-08-11Do not create a span for cached commandsJakub Beránek-3/+3
2025-08-11Always profile commands and generate Chrome profile when tracing is enabledJakub Beránek-56/+37
2025-08-11Correctly show executed command name in Chrome traceJakub Beránek-27/+54
2025-08-11Move tracing setup to the `tracing` moduleJakub Beránek-298/+304
2025-08-11Remove manual `#[instrument]` annotations on stepsJakub Beránek-161/+1
They could easily get out of sync and miss some fields. Now all steps are instrumented automatically.
2025-08-11Remove ad-hoc print of executed/cached steps in verbose modeJakub Beránek-4/+0
When verbose mode is enabled, it is very hard to see the actually executed steps.
2025-08-11Create a span for each executed stepJakub Beránek-28/+108
2025-08-11Replace `tracing_forest` with custom span formattingJakub Beránek-44/+338
2025-08-11Print step timings also when the stap starts to executeJakub Beránek-6/+18
So that it is easier to see which was the last started step when a failure happens on CI.
2025-08-11Use shorter command span labelJakub Beránek-1/+1
2025-08-11Store Chrome step trace into the tracing directoryJakub Beránek-14/+48
2025-08-11Store `latest` symlink to the latest tracing output directoryJakub Beránek-6/+15
2025-08-11Store bootstrap tracing outputs to a unified directoryJakub Beránek-28/+34
2025-08-11Auto merge of #145207 - Kobzol:codegen-backend-clif-dist, r=jieyouxubors-30/+35
Ship correct Cranelift library in its dist component The first commit adds a post-dist UI test to check that Cranelift can be used with the extracted dist x64 Linux archive. The original codegen copy logic in the Cranelift dist step was a bit redundant, and I didn't notice in https://github.com/rust-lang/rust/pull/144787 that it's copying the codegen backend from the build compiler's sysroot, rather than the target compiler's sysroot. The second commit modifies the logic to directly access the built codegen file (there is no need to search for it in the compiler's sysroot, in fact when you run just `x dist rustc_codegen_cranelift`, it shouldn't "taint" the sysroot with the codegen backend! Which it did before https://github.com/rust-lang/rust/pull/144787) and copy it to the tarball under a normalized name. Thus we get around any similar potential issues in the future, and make previously implicit logic more explicit. This also fixes running just `x dist rustc_codegen_cranelift` without enabling `cranelift` in `rust.codegen-backends`, which should have been enabled by https://github.com/rust-lang/rust/pull/144787, but it didn't work fully, because the dist step tried to copy the codegen backend from the compiler's sysroot, but it didn't contain the codegen backend if it was not enabled by `rust.codegen-backends`. Fixes: https://github.com/rust-lang/rust/issues/145201 try-job: dist-x86_64-linux
2025-08-11Rollup merge of #145247 - GuillaumeGomez:update-sysinfo, r=KobzolGuillaume Gomez-3/+3
Update `sysinfo` version to `0.37.0` Some small performance improvements and internal cleanups.
2025-08-11Rollup merge of #145221 - Kobzol:cargo-dist-fix-2, r=jieyouxuGuillaume Gomez-0/+2
Fix Cargo cross-compilation (take two) In https://github.com/rust-lang/rust/pull/145083, I fixed the case of manually invoking `x dist cargo`, but I realized that `x install` creates the `tool::Cargo` step through the `from_build_frompiler` constructor, which doesn't go through `get_tool_target_compiler`. So we just prepare both the host and target stdlibs directly before building Cargo. Ideally we would get rid of `from_build_compiler`, but that will require refactoring the dist and test steps, which is upcoming. Hopefully fixes https://github.com/rust-lang/rust/issues/145059 for good.
2025-08-11Update `sysinfo` version to `0.37.0`Guillaume Gomez-3/+3
2025-08-11Auto merge of #145011 - Kobzol:bootstrap-doc, r=jieyouxubors-239/+510
Enforce in bootstrap that doc must have stage at least 1 Following with the bootstrap cleanups, this time around `doc` steps. Should be pretty straightforward, because the supporting infrastructure was already there. The only thing I found a bit fishy is using `Mode::ToolBootstrap` as a "catch-all" mode for non-rustc-private steps in `tool_doc!`, but I don't think that we need to distinguish the tools in some special way when documenting them, apart from supporting `rustc_private`. Before, `x doc` more or less defaulted to what we call stage 2 now. Now it is properly stage 1, so e.g. `x doc compiler` documents the compiler using the stage0/beta rust(do)c. r? `@jieyouxu` try-job: dist-aarch64-msvc
2025-08-11Rollup merge of #145149 - ↵Stuart Cook-306/+439
Shourya742:2025-07-08-convert-config-method-invoke-inside-parse-functions, r=Kobzol Make config method invoke inside parse use dwn_ctx This PR is part of a series of config refactorings. It removes calls from config methods to solid functions defined in `config.rs`. After this, we will remove the default dependencies in the config. r? ```@Kobzol```
2025-08-10Rollup merge of #145121 - ↵Jacob Pratt-0/+14
lambdageek:dist-must-keep-llvm-third-party-siphash, r=Kobzol bootstrap: `x.py dist rustc-src` should keep LLVM's siphash Fixes rust-lang/rust#145117
2025-08-10Fix Cargo cross-compilation (take two)Jakub Beránek-0/+2
2025-08-10Ship the correct Cranelift backend in its dist stepJakub Beránek-30/+35
2025-08-10Explicitly pass path to built stdlib JSON docs and use the correct compiler ↵Jakub Beránek-23/+26
for it
2025-08-10Rollup merge of #145156 - Kobzol:cargo-build-dir, r=lqd,jieyouxuStuart Cook-0/+9
Override custom Cargo `build-dir` in bootstrap The context for this issue is in https://github.com/rust-lang/rust/issues/145107. The issue is that if people configure `build-dir`, it would break bootstrap. For now, we just hard-code it to our self-contained target directories inside the build directory. Tested by putting the following: ```toml [build] build-dir = "/tmp/foo" [unstable] build-dir = true ``` into `<rustc-checkout>/.cargo/config.toml`. `x build` works with this PR, doesn't work without this PR. Fixes: https://github.com/rust-lang/rust/issues/145107
2025-08-10Rollup merge of #145129 - dpaoliello:arm64eclink, r=wesleywiserStuart Cook-0/+7
[win][arm64ec] Add `/machine:arm64ec` when linking LLVM as Arm64EC When the MSVC linker sees an Arm64EC object file, it needs to know if it's linking the final executable as Arm64EC or Arm64X. This change adds the `/machine:arm64ec` flag to the linker when building LLVM as Arm64EC to avoid that ambiguity (and resulting linker error).
2025-08-10Rollup merge of #145089 - Kobzol:bootstrap-cmd-error, r=jieyouxuStuart Cook-82/+83
Improve error output when a command fails in bootstrap I fixed this because it was being an issue for debugging CI failures. We try to print as much information as possible, just with a slightly less verbose command description in non-verbose mode. The code is now more unified and hopefully simpler to understand. I also fixed the `format_short_cmd` logic, it was a bit weird after some recent refactors. Fixes: https://github.com/rust-lang/rust/issues/145002 r? `````````@jieyouxu````````` CC `````````@Shourya742`````````
2025-08-10Bless testsJakub Beránek-3/+20
2025-08-10Review remarksJakub Beránek-2/+6
2025-08-10Add change tracker entryJakub Beránek-0/+5
2025-08-10Update testsJakub Beránek-37/+208
2025-08-10Update `Std` doc stepJakub Beránek-27/+40
2025-08-10Fix documentation of toolsJakub Beránek-54/+54
2025-08-10Update `Standalone` and `Releases` doc stepsJakub Beránek-16/+29
2025-08-10Update `RustcBook` doc stepJakub Beránek-14/+26
2025-08-10Update `Reference` doc stepJakub Beránek-15/+56
2025-08-10Fix staging for `doc compiler`Jakub Beránek-30/+31
2025-08-10Forbid documenting anything on stage 0Jakub Beránek-34/+25
2025-08-10Auto merge of #144787 - Kobzol:codegen-backend-restructure, r=jieyouxubors-217/+291
Refactor codegen backends in bootstrap This PR refactors the codegen backend steps, in preparation to make more progress on the integration of the GCC codegen backend in bootstrap. It does several things: 1) Splits the `CodegenBackend` step into two, one for clif and another one for gcc. Even though their code is mostly similar, that's IMO mostly fake similarity, and they do (or will) ultimately require different handling. This was already visible in the requirement of building GCC for cg_gcc, of course. 2) It is now possible to build both backends (and dist cranelift) even if they are not specified in `rust.codegen-backends`. It was quite weird that it wasn't possible to even invoke the corresponding codegen backend if the backend wasn't specified in that array, as that array should ideally only change defaults (see later below). 3) Changes the path specification of these steps to an alias. In other words, instead of `compiler/rustc_codegen_cranelift`, the step is now built only using `rustc_codegen_cranelift` or `cg_clif`. This is done to avoid an annoying clash with `x build compiler`, which would otherwise build both codegen backends after the 2) change. 4) Made the copying of codegen backend artifacts more explicit, in particular in the `Assemble` step. 5) Codifies the semantics of `rust.codegen-backends`, which now only affects the defaults of whether a codegen backend will be included in rustc's sysroot and whether it will be disted in `x dist` by default. We can change the behavior later, e.g. to dist cranelift by default in `x dist` once it becomes stabilized. Currently I left the existing behavior that we use on CI, I just tried to document it better. I don't think that this requires a change tracker entry, because the defaults should work the same as before. It is just now possible to do `x build/dist rustc_codegen_cranelift` even if CLIF is not in the `codegen-backends` array. It is no longer possible to do `./x build compiler/rustc_codegen_cranelift` though, not sure if that requires a change tracker entry. There is one thing that I didn't touch yet, and that is the fact that `rust.codegen-backends` not only affects the default behavior of `x dist` w.r.t. Cranelift, but also of `x test`. In other words, `x test rustc_codegen_cranelift` still does not hing if cranelift isn't in `rust.codegen-backends`. I plan to take a look at this once I get to refactoring the test steps. r? `@jieyouxu`
2025-08-09add review commentsbit-aloo-44/+11
2025-08-09Override custom Cargo `build-dir` in bootstrapJakub Beránek-0/+9
2025-08-09extend download context and change functions to directly use thatbit-aloo-227/+130
2025-08-09Rollup merge of #145083 - Kobzol:fix-cargo-cross-build, r=jieyouxuStuart Cook-2/+22
Fix cross-compilation of Cargo Regressed in https://github.com/rust-lang/rust/pull/144303. I guess this wasn't seen in other `ToolTarget` tools, because they are more dependent on the compiler and are ~always built together with other stuff that also built the std, while Cargo is relatively self-contained. Fixes: https://github.com/rust-lang/rust/issues/145059 r? ``@jieyouxu``