Commit graph

299297 commits

Author SHA1 Message Date
Jakub Beránek
775c970aae
Add support for allowing features when checking tools 2025-07-06 17:25:19 +02:00
Jakub Beránek
20719767bc
Use stage auto-bump when cross-checking on stage 1 2025-07-06 17:25:19 +02:00
Jakub Beránek
97da04c922
Add #[tracing::instrument] to the LLVM build step 2025-07-06 17:25:19 +02:00
Jakub Beránek
33e6b7aa09
Update library cross-compilation test 2025-07-06 17:25:19 +02:00
Jakub Beránek
8d4d0502bd
Update Mode::ToolStd comment 2025-07-06 17:25:19 +02:00
Jakub Beránek
40176388d2
Add staging comment to check::Rustc 2025-07-06 17:25:19 +02:00
Jakub Beránek
38b09dd838
Add change tracker entry 2025-07-06 17:25:18 +02:00
Jakub Beránek
c054c115a5
Unify selection of build compiler for checking in a single function 2025-07-06 17:25:18 +02:00
Jakub Beránek
4a3cfaa745
Implement CoverageDump checking through the tool_check_step macro 2025-07-06 17:25:18 +02:00
Zalathar
b4da3bd872
Fixup check of rust-analyzer, codegen backends, compiletest and other tools 2025-07-06 17:25:12 +02:00
Jakub Beránek
9906de2510
Make build compiler explicit in check::Rustc and check::Std 2025-07-06 17:12:44 +02:00
Jakub Beránek
50e5599d1d
Remove custom_stage override from check::Std and make 1 be the default check stage for it 2025-07-06 17:12:43 +02:00
Jakub Beránek
0aa4ef964d
Make default check stage be 1, and error out on checking with stage 0 2025-07-06 17:12:43 +02:00
bors
c83e217d26 Auto merge of #143521 - matthiaskrgr:rollup-kpv1og3, r=matthiaskrgr
Rollup of 6 pull requests

Successful merges:

 - rust-lang/rust#143416 (mbe: Defer checks for `compile_error!` until reporting an unused macro rule)
 - rust-lang/rust#143470 (std: sys: net: uefi: tcp4: Implement read)
 - rust-lang/rust#143477 (use `is_multiple_of` and `div_ceil`)
 - rust-lang/rust#143484 (distinguish the duplicate item of rpitit)
 - rust-lang/rust#143493 (tidy: use --bless for tidy spellcheck instead of spellcheck:fix)
 - rust-lang/rust#143504 (compiletest: print slightly more information on fs::write failure)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-07-06 10:20:27 +00:00
Matthias Krüger
097efc07cc
Rollup merge of #143504 - RalfJung:compiletest-err, r=jieyouxu
compiletest: print slightly more information on fs::write failure

See [#t-infra > compiletest: panic in dump_output_file: No such file or dire @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/compiletest.3A.20panic.20in.20dump_output_file.3A.20No.20such.20file.20or.20dire/near/527294714)
2025-07-06 10:03:24 +02:00
Matthias Krüger
e25654fb94
Rollup merge of #143493 - lolbinarycat:tidy-spellcheck-bless, r=Kobzol
tidy: use --bless for tidy spellcheck instead of spellcheck:fix

previous behavior was inconsistent with existing extra checks.

unsure if this needs a change tracker entry or a warning for people who try to use the old behavior.

unsure if we should call this `spellcheck:lint` for consistency.

making this consistent is a prerequisite for https://github.com/rust-lang/rust/pull/143398

cc `@nnethercote`

r? `@Kobzol`
2025-07-06 10:03:24 +02:00
Matthias Krüger
534c09a779
Rollup merge of #143484 - bvanjoi:issue-140796, r=compiler-errors
distinguish the duplicate item of rpitit

Fixes rust-lang/rust#140796

r? compiler

cc `@Zoxc`
2025-07-06 10:03:23 +02:00
Matthias Krüger
6fb00b1514
Rollup merge of #143477 - folkertdev:use-is-multiple-of, r=joshtriplett
use `is_multiple_of` and `div_ceil`

In tricky logic, these functions are much more informative than the manual implementations. They also catch subtle bugs:

- the manual `is_multiple_of` often does not handle division by zero
- manual `div_ceil` often does not consider overflow

The transformation is free for `is_multiple_of` if the divisor is compile-time known to be non-zero. For `div_ceil` there is a small cost to considering overflow. Here is some assembly https://godbolt.org/z/5zP8KaE1d.
2025-07-06 10:03:23 +02:00
Matthias Krüger
19f8ba4733
Rollup merge of #143470 - Ayush1325:uefi-tcp4-recv, r=joshtriplett
std: sys: net: uefi: tcp4: Implement read

- A blocking implementation of tcp4 read.
- Basically a copy of [write](https://github.com/rust-lang/rust/pull/141532)
2025-07-06 10:03:22 +02:00
Matthias Krüger
71b73e529a
Rollup merge of #143416 - joshtriplett:mbe-simplifications, r=nnethercote
mbe: Defer checks for `compile_error!` until reporting an unused macro rule

The current MBE parser checks rules at initial parse time to see if their RHS has `compile_error!` in it, and returns a list of rule indexes and LHS spans that don't map to `compile_error!`, for use in unused macro rule checking.

Instead, have the unused macro rule reporting ask the macro for the rule to report, and let the macro check at that time. That avoids checking rules unless they're unused.

In the process, refactor the data structure used to store macro rules, to group the LHS and RHS (and LHS span) of each rule together, and refactor the unused rule tracking to only track rule indexes.

This builds atop a couple of minor MBE refactors. I would suggest reviewing commit-by-commit.

The overall result is a further simplification of the macro code.
2025-07-06 10:03:22 +02:00
bors
e804cd4a5f Auto merge of #143354 - Shourya742:2025-07-03-bye-bye-as_mut-command, r=Kobzol
Port streaming commands in bootstrap to `BootstrapCommand` and remove `as_command_mut`

This PR adds streaming capabilities to BootstrapCommand and migrate existing command streaming scenario's used in bootstrap.

r? `@Kobzol`
2025-07-06 07:13:02 +00:00
bohan
5bbab8967d distinguish the duplicate item of rpitit 2025-07-06 14:04:40 +08:00
bors
febb10d0a2 Auto merge of #143507 - matthiaskrgr:rollup-lpg7t12, r=matthiaskrgr
Rollup of 6 pull requests

Successful merges:

 - rust-lang/rust#143238 (Port `#[ignore]` to the new attribute parsing infrastructure)
 - rust-lang/rust#143441 (Stop using `Key` trait unnecessarily)
 - rust-lang/rust#143478 (Miri subtree update)
 - rust-lang/rust#143486 (remove armv5te-unknown-linux-gnueabi target maintainer)
 - rust-lang/rust#143489 (Complete rustc_ast::mut_visit for spans.)
 - rust-lang/rust#143494 (Remove yields_in_scope from the scope tree.)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-07-06 04:09:12 +00:00
bors
75d5834a6c Auto merge of #143126 - dianqk:update-llvm, r=nikic
Update LLVM submodule

Fixes rust-lang/rust#140686, fixes rust-lang/rust#141913, fixes rust-lang/rust#142752, fixes rust-lang/rust#143399.
2025-07-06 01:03:18 +00:00
Josh Triplett
63cfb3af37 mbe: Defer checks for compile_error! until reporting an unused macro rule
The MBE parser checks rules at initial parse time to see if their RHS
has `compile_error!` in it, and returns a list of rule indexes and LHS
spans that don't map to `compile_error!`, for use in unused macro rule
checking.

Instead, have the unused macro rule reporting ask the macro for the rule
to report, and let the macro check at that time. That avoids checking
rules unless they're unused.

In the process, refactor the data structure used to store macro rules,
to group the LHS and RHS (and LHS span) of each rule together, and
refactor the unused rule tracking to only track rule indexes.

This ends up being a net simplification, and reduction in code size.
2025-07-05 16:23:13 -07:00
Josh Triplett
0d5ab3e46c mbe: Simplify a match to a let-else 2025-07-05 16:23:13 -07:00
Josh Triplett
a7382eae3f mbe: Add a helper to parse a single TokenTree
The parser repeatedly invokes the `parse` function, constructing a
one-entry vector, and assuming that the return value will be a one-entry
vector. Add a helper for that case. This will simplify adding additional
callers, and put all the logic in one place to allow potential future
simplification of the one-TT case.
2025-07-05 16:23:07 -07:00
Matthias Krüger
c3c4fd7c9c
Rollup merge of #143494 - cjgillot:no-yield-in-scope, r=compiler-errors
Remove yields_in_scope from the scope tree.

I believe this has not been in use since we removed the HIR-based generator interior type computation.
2025-07-05 22:34:43 +02:00
Matthias Krüger
8a5d239949
Rollup merge of #143489 - cjgillot:mut-visit-span, r=petrochenkov
Complete rustc_ast::mut_visit for spans.

Extracted from https://github.com/rust-lang/rust/pull/127241

r? `@petrochenkov`
2025-07-05 22:34:42 +02:00
Matthias Krüger
5aa7be4473
Rollup merge of #143486 - husqvarnagroup:af/no-armv5te-target-maintainer, r=petrochenkov
remove armv5te-unknown-linux-gnueabi target maintainer

Sadly my former employer doesn't want to maintain this any more and I have no personal interest in maintaining it.
2025-07-05 22:34:42 +02:00
Matthias Krüger
7ad67e6b54
Rollup merge of #143478 - RalfJung:miri-sync, r=RalfJung
Miri subtree update

r? `@ghost`
2025-07-05 22:34:41 +02:00
Matthias Krüger
0311159e02
Rollup merge of #143441 - compiler-errors:no-key, r=petrochenkov
Stop using `Key` trait unnecessarily

Few places where the `Key` trait was being used but not really for a useful reason. This fixes those usages.

Namely, `<Ty as Key>::default_span()` is `DUMMY_SP` anyways.
2025-07-05 22:34:41 +02:00
Matthias Krüger
9a921a32f6
Rollup merge of #143238 - JonathanBrouwer:ignore_parser, r=jdonszelmann
Port `#[ignore]` to the new attribute parsing infrastructure

Ports `ignore` to the new attribute parsing infrastructure for https://github.com/rust-lang/rust/issues/131229#issuecomment-2971353197

This PR duplicates a change from https://github.com/rust-lang/rust/pull/143237
Draft until that one is merged
2025-07-05 22:34:40 +02:00
bors
5adb489a80 Auto merge of #142732 - compiler-errors:more-root, r=lcnr
Canonicalize input ty/ct infer/placeholder in the root universe

We shouldn't care what universe the inputs are, since we only ever do the leak check on the universes instantiated after entering the canonical binder.
2025-07-05 20:34:08 +00:00
binarycat
9f78173bb5 bootstrap: add change_tracker entry for removal of spellcheck:fix 2025-07-05 15:24:45 -05:00
Ralf Jung
9c9c5b041b compiletest: print slightly more information on fs::write failure 2025-07-05 22:21:23 +02:00
Jonathan Brouwer
2d8ffff10a
Port #[ignore] to the new attribute parsing infrastructure
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com>
2025-07-05 21:23:09 +02:00
Michael Goulet
4185874592 Don't compress input universes 2025-07-05 18:41:59 +00:00
bit-aloo
312de35d3a
restructure try_run_tests 2025-07-06 00:11:20 +05:30
Michael Goulet
7f5d286de3 Canonicalize input ty/ct infer/placeholder in the root universe 2025-07-05 18:37:54 +00:00
Michael Goulet
8eb9f70979 Stop using Key trait randomly 2025-07-05 18:37:11 +00:00
bors
175e04331b Auto merge of #143496 - saethlin:rollup-4u43rgj, r=saethlin
Rollup of 3 pull requests

Successful merges:

 - rust-lang/rust#143291 (codegen_ssa: replace a Result by an Either)
 - rust-lang/rust#143445 (move `va_copy`, `va_arg` and `va_end` to `core::intrinsics`)
 - rust-lang/rust#143447 ([COMPILETEST-UNTANGLE 4/N] Improve compiletest config documentation)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-07-05 17:32:26 +00:00
Ben Kimock
53757e6725
Rollup merge of #143447 - jieyouxu:compiletest-maintenance-4, r=Kobzol
[COMPILETEST-UNTANGLE 4/N] Improve compiletest config documentation

This is part of a patch series to untangle `compiletest` to hopefully nudge it towards being more maintainable.

This PR should contain **no functional changes**.

This is pulled out to its own PR to make follow-up changes easier to review.

There are *intentionally* a *lot* of FIXME comments, intended to be gradually addressed in follow-ups.

r? `@Kobzol`
2025-07-05 12:32:54 -04:00
Ben Kimock
7245febecd
Rollup merge of #143445 - folkertdev:va-list-intrinsics, r=RalfJung
move `va_copy`, `va_arg` and `va_end` to `core::intrinsics`

some questions:

- should these functions be `pub`?
- is a separate module justified?

r? `@RalfJung`
2025-07-05 12:32:53 -04:00
Ben Kimock
61bdd11b20
Rollup merge of #143291 - RalfJung:result-isnt-either, r=scottmcm
codegen_ssa: replace a Result by an Either

`Err` here clearly does not indicate an "error" of any sort, so the use of `Result` is confusing. Let's use a sum type that does not come with the baggage of `Result`.
2025-07-05 12:32:53 -04:00
binarycat
c1ed2ac8a2 tidy: add specific error message for trying to use spellcheck:fix. 2025-07-05 10:24:17 -05:00
Camille GILLOT
39ee1b2d77 Remove yields_in_scope from the scope tree. 2025-07-05 15:24:15 +00:00
binarycat
971feb6185 tidy: use --bless for tidy spellcheck instead of spellcheck:fix
previous behavior was inconsistent with existing extra checks.
2025-07-05 10:17:31 -05:00
Ralf Jung
3cd13f72a2 codegen_ssa: replace a Result by an Either 2025-07-05 15:53:56 +02:00
bors
6dec76f1c2 Auto merge of #143474 - jieyouxu:bootstrap-llvm-snapshot, r=Kobzol
Pretend in bootstrap snapshot tests that we always build in-tree LLVM

Otherwise, depending on whether CI LLVM is inhibited or if an externally-provided LLVM is used, bootstrap host LLVM build step could be missing in step snapshots.

Note that I'm not sure if this is the *right* solution (this might be *a* solution). I imagine we do want to control for the set of configuration that these snapshot tests are run, as much as possible.

r? `@Kobzol`
2025-07-05 12:42:59 +00:00