| Age | Commit message (Collapse) | Author | Lines |
|
- Use `cargo metadata` to determine whether a crate has a library
package or not
- Collect metadata for all workspaces, not just the root workspace and
cargo
- Don't pass `--lib` for crates without a library
- Use `run_cargo_test` for rust-installer
- Don't build documentation in `lint-docs` if `--no-doc` is passed
|
|
|
|
|
|
Co-authored-by: Scott Schafer <schaferjscott@gmail.com>
Co-authored-by: Eric Huss <eric@huss.org>
|
|
Add `libLLVM.so` to the target libdir when download-rustc is enabled
Previously, we would only add it to the host libdir, which meant it couldn't be loaded by `ui-fulldeps` tests that used rustc_private.
Fixes https://github.com/rust-lang/rust/issues/110225, fixes https://github.com/rust-lang/rust/issues/110226.
|
|
Create "suggested tests" tool in `rustbuild`
Not the claimed person in #97339 but:
I've done a very rough implementation of this feature in-tree. I'm very new to `rustc` development (outside of docs) so some help would be greatly appreciated. The UI of this new subcommand obviously will change and I need some mentoring with the `--run` flag.
r? ```@jyn514```
|
|
Previously, we would only add it to the host libdir, which meant it
couldn't be loaded by `ui-fulldeps` tests that used rustc_private.
|
|
Initial support for loongarch64-unknown-linux-gnu
Hi, We hope to add a new port in rust for LoongArch.
LoongArch intro
LoongArch is a RISC style ISA which is independently designed by Loongson
Technology in China. It is divided into two versions, the 32-bit version (LA32)
and the 64-bit version (LA64). LA64 applications have application-level
backward binary compatibility with LA32 applications. LoongArch is composed of
a basic part (Loongson Base) and an expanded part. The expansion part includes
Loongson Binary Translation (LBT), Loongson VirtualiZation (LVZ), Loongson SIMD
EXtension (LSX) and Loongson Advanced SIMD EXtension(LASX).
Currently the LA464 processor core supports LoongArch ISA and the Loongson
3A5000 processor integrates 4 64-bit LA464 cores. LA464 is a four-issue 64-bit
high-performance processor core. It can be used as a single core for high-end
embedded and desktop applications, or as a basic processor core to form an
on-chip multi-core system for server and high-performance machine applications.
Documentations:
ISA:
https://loongson.github.io/LoongArch-Documentation/LoongArch-Vol1-EN.html
ABI:
https://loongson.github.io/LoongArch-Documentation/LoongArch-ELF-ABI-EN.html
More docs can be found at:
https://loongson.github.io/LoongArch-Documentation/README-EN.html
Since last year, we have locally adapted two versions of rust, rust1.41 and rust1.57, and completed the test locally.
I'm not sure if I'm submitting all the patches at once, so I split up the patches and here's one of the commits
|
|
|
|
|
|
|
|
|
|
This has two advantages:
1. If `build.build` changes between runs, the symlink is no longer
silently wrong.
2. If the entire build directory is moved, the symlink is no longer
broken because it points to the wrong absolute path.
|
|
Add OpenHarmony targets
- `aarch64-unknown-linux-ohos`
- `armv7-unknown-linux-ohos`
Compiler team MCP: https://github.com/rust-lang/compiler-team/issues/568
|
|
- `aarch64-unknown-linux-ohos`
- `armv7-unknown-linux-ohos`
|
|
socket ancillary data implementation for FreeBSD (from 13 and above).
introducing new build config as well.
|
|
introducing new build config as well.
|
|
Renamed 'native.rs' to 'llvm.rs', also moved `TestHelpers` to `test.rs`.Replaced all the `native.rs` ocurrences at `src/bootstrap` files to `llvm.rs`
|
|
refactor `fn bootstrap::builder::Builder::compiler_for` logic
- check compiler stage before forcing for stage2.
- check if download_rustc is not set before forcing for stage1.
resolves #109286
|
|
Include executed tests in the build metrics (and use a custom test display impl)
The main goal of this PR is to include all tests executed in CI inside the build metrics JSON files. I need this for Ferrocene, and `@Mark-Simulacrum` expressed desire to have this as well to ensure all tests are executed at least once somewhere in CI.
Unfortunately implementing this required rewriting inside of bootstrap all of the code to render the test output to console. libtest supports outputting JSON instead of raw text, which we can indeed use to populate the build metrics. Doing that suppresses the console output though, and compared to rustc and Cargo the console output is not included as a JSON field.
Because of that, this PR had to reimplement both the "pretty" format (one test per line, with `rust.verbose-tests = true`), and the "terse" format (the wall of dots, with `rust.verbose-tests = false`). The current implementation should have the exact same output as libtest, except for the benchmark output. libtest's benchmark output is broken in the "terse" format, so since that's our default I slightly improved how it's rendered.
Also, to bring parity with libtest I had to introduce support for coloring output from bootstrap, using the same dependencies `annotate-snippets` uses. It's now possible to use `builder.color_for_stdout(Color::Red, "text")` and `builder.color_for_stderr(Color::Green, "text")` across all of bootstrap, automatically respecting the `--color` flag and whether the stream is a terminal or not.
I recommend reviewing the PR commit-by-commit.
r? `@Mark-Simulacrum`
|
|
|
|
- check compiler stage before forcing for stage2.
- check if download_rustc is not set before forcing for stage1.
Signed-off-by: ozkanonur <work@onurozkan.dev>
|
|
|
|
Import rust-installer & adjust compression settings
This brings in rust-lang/rust-installer#123, which enables a larger compression window (8 -> 64MB) amongst other changes to the xz compression settings. The net effect should be smaller compressed tarballs which will decrease bandwidth usage for
static.rust-lang.org, download times, and decompression time.
This comes at the cost of higher baseline requirements for running rustup to use these files, which we believe should be largely acceptable (running rustc is likely to use at least this much memory) but if we get specific reports we may explore options to decrease impact (e.g., using the gzip tarballs automatically in rustup).
To simplify iteration on compression settings this also imports the rust-lang/rust-installer submodule, it is now hosted fully inside rust-lang/rust. Once we land this I'll file a followup to add a note to that repo and we can subsequently archive it.
--
CI times for dist-x86_64-linux builds:
* threads=6, master - 2h 50m
* threads=1, new - 3h 40m
* threads=6, new - 2h 50m
|
|
config.download_rustc is set
|
|
|
|
|
|
|
|
|
|
symlink for legacy rustfmt path"
This reverts commit 41c6c5d4996728b5a635319ef9b077a3d0ccc480.
|
|
legacy rustfmt path
|
|
consolidate bootstrap docs
With this diff, I tried to consolidate bootstrap documentations and remove the duplicated informations.
Coupled with https://github.com/rust-lang/rustc-dev-guide/pull/1563
Resolves #90686
Signed-off-by: ozkanonur <work@onurozkan.dev>
|
|
Signed-off-by: ozkanonur <work@onurozkan.dev>
|
|
r=Mark-Simulacrum
bootstrap: cleanup the list of extra check cfgs
This PR performs some cleanups on the `EXTRA_CHECK_CFGS` list in bootstrap.
- `target_os=watchos`: no longer relevant because there are now proper targets `*-apple-watchos`
- `target_arch=nvptx64`: target `nvptx64-nvidia-cuda` makes it useless
- `target_arch=le32`: target was removed (https://github.com/rust-lang/rust/pull/45041)
- `release`: was removed from rustfmt (https://github.com/rust-lang/rustfmt/pull/5375 and https://github.com/rust-lang/rustfmt/pull/5449)
- `dont_compile_me`: was removed from stdarch (https://github.com/rust-lang/stdarch/pull/1308)
Also made some external cfg exception mode clear and only activated for rustc and rustc tools (as to not have the Standard Library unintentionally depend on them).
|
|
Pass `branch.{branch}.remote=origin` to `git submodule update`
This works around a bug in git itself.
Fixes https://github.com/rust-lang/rust/issues/101144.
|
|
|
|
|
|
- `target_os=watchos`: no longer relevant because there are now proper
targets `*-apple-watchos`
- `target_arch=nvptx64`: `nvptx64-nvidia-cuda`
- `target_arch=le32`: target was removed
(https://github.com/rust-lang/rust/pull/45041)
- `release`: was removed from rustfmt
(https://github.com/rust-lang/rustfmt/pull/5375 and
https://github.com/rust-lang/rustfmt/pull/5449)
- `dont_compile_me`: was removed from stdarch
(https://github.com/rust-lang/stdarch/pull/1308)
Also made some external cfg exception mode clear and only activated for
rustc and rustc tools (as to not have the Standard Library
unintentionally depend on them).
|
|
|
|
Nilstrieb:no-merge-commits-for-you-only-bors-is-allowed-to-do-that, r=jyn514"
This reverts commit 4839886f0abe208ab8f2bb73a3076a59fe2ab60c, reversing
changes made to ce85c98575e3016cf2007d90a85be321e592aa96.
|
|
|
|
Allow cleaning individual crates
As a bonus, this stops special casing `clean` in `Builder`.
## Motivation
Cleaning artifacts isn't strictly necessary to get cargo to rebuild; `touch compiler/rustc_driver/src/lib.rs` (for example) will also work. There's two reasons I thought making this part of bootstrap proper was a better approach:
1. `touch` does not *remove* artifacts, it just causes a rebuild. This is unhelpful for when you want to measure how long the compiler itself takes to build (e.g. for https://github.com/rust-lang/rust/issues/65031).
2. It seems a little more discoverable; and I want to extend it in the future to things like `x clean --stage 1 rustc`, which makes it easier to work around https://github.com/rust-lang/rust/issues/76720 without having to completely wipe all the stage 0 artifacts, or having to be intimately familiar with which directories to remove.
|
|
As a bonus, this stops special casing `clean` in `Builder`.
|
|
This also makes the panic message a little more informative in case it
happens again.
|
|
This works around a bug in git itself; see
https://github.com/rust-lang/rust/issues/101144.
|
|
Rollup of 6 pull requests
Successful merges:
- #105978 (Mark `proc_macro_decls_static` as always used)
- #106051 (Allow building std with cranelift)
- #106056 (Make `sess.bug` much less noisy)
- #106057 (Give a more helpful error for "trimmed_def_paths constructed")
- #106058 (Fix the issue number in comment for as_local_call_operand)
- #106059 (Avoid running the `Profile` step twice on `x setup`)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Allow building std with cranelift
- Don't pass llvm-specific args when using cranelift
- Don't use `asm` in compiler_builtins when using cranelift
r? `@bjorn3` cc `@Mark-Simulacrum`
|
|
The primary motivation is to have the cargo docs show up on https://doc.rust-lang.org/nightly/nightly-rustc/cargo, but as a nice side effect this makes `x doc cargo` work locally.
|
|
- Don't pass llvm-specific args when using cranelift
- Don't use `asm` in compiler_builtins when using cranelift
|
|
Fix `x setup -h -v` should work
r? `@jyn514`
I have to convert profile to path and back in order to remove special-casing in bootstrap. I also check for `dry_run` so that `config.toml` and/ or `.git/hooks/pre-push` will not be created if `--dry-run` is specified.
Please help me see if this is ok, thanks alot!
|