Skip to content

Conversation

@Zalathar
Copy link
Member

@Zalathar Zalathar commented Jan 4, 2026

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

Enselic and others added 16 commits December 23, 2025 15:33
…tests

This not only reduces code duplication already, it also gives us
revision parsing for free which we need in an upcoming commit.
…, `no-SingleUseConsts-mir-pass`

To prevent the test from regressing both with and without
`SingleUseConsts` MIR pass.
Now `Iterator::last`'s docs specify that it might panic only if the iterator is infinite, rather than if it has more than `usize::MAX` elements.
…, r=Zalathar

compiletest: Support revisions in debuginfo (read: debugger) tests

And start using revisions in `tests/debuginfo/macro-stepping.rs` to prevent regressing both with and without `SingleUseConsts` MIR pass.

I recommend commit-by-commit review.

## ~TODO~

- [x] Verify this more carefully.
- [x] Possibly do some preparatory PRs before taking this PR out of draft.
    - [x] Rebase on rust-lang#150205 once merged so we don't have to add another "`+ 1`".

## CC

CC ``@Zalathar`` since you might have opinions about that I expose a helper function to reduce duplication

CC ``@saethlin`` since this is what we will use for `tests/debuginfo/basic-stepping.rs` in rust-lang#147426 (in the same way I use it in `tests/debuginfo/macro-stepping.rs` here)
…pratt

mutex.rs: remove needless-maybe-unsized bounds

Fixes for:

```text
warning: `?Sized` bound is ignored because of a `Sized` requirement
   --> library/std/src/sync/nonpoison/mutex.rs:425:9
    |
425 | impl<T: ?Sized + Default> Default for Mutex<T> {
    |         ^^^^^^
    |
note: `T` cannot be unsized because of the bound
   --> library/std/src/sync/nonpoison/mutex.rs:425:18
    |
425 | impl<T: ?Sized + Default> Default for Mutex<T> {
    |                  ^^^^^^^
    = note: ...because `Default` has the bound `Sized`
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_maybe_sized
    = note: `-W clippy::needless-maybe-sized` implied by `-W clippy::suspicious`
    = help: to override `-W clippy::suspicious` add `#[allow(clippy::needless_maybe_sized)]`
help: change the bounds that require `Sized`, or remove the `?Sized` bound
    |
425 - impl<T: ?Sized + Default> Default for Mutex<T> {
425 + impl<T: Default> Default for Mutex<T> {
    |

warning: `?Sized` bound is ignored because of a `Sized` requirement
   --> library/std/src/sync/poison/mutex.rs:691:9
    |
691 | impl<T: ?Sized + Default> Default for Mutex<T> {
    |         ^^^^^^
    |
note: `T` cannot be unsized because of the bound
   --> library/std/src/sync/poison/mutex.rs:691:18
    |
691 | impl<T: ?Sized + Default> Default for Mutex<T> {
    |                  ^^^^^^^
    = note: ...because `Default` has the bound `Sized`
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_maybe_sized
help: change the bounds that require `Sized`, or remove the `?Sized` bound
    |
691 - impl<T: ?Sized + Default> Default for Mutex<T> {
691 + impl<T: Default> Default for Mutex<T> {
```
… r=tgross35

vec in-place-drop: avoid creating an intermediate slice

Avoids clippy warning:
```text
warning: implicitly casting the result of `from_raw_parts_mut` to `*mut [T]`
  --> library/alloc/src/vec/in_place_drop.rs:25:32
   |
25 |             ptr::drop_in_place(slice::from_raw_parts_mut(self.inner, self.len()));
   |                                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace_with: `core::ptr::slice_from_raw_parts_mut(self.inner, self.len())`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_slice_from_raw_parts
   = note: `-W clippy::cast-slice-from-raw-parts` implied by `-W clippy::suspicious`
   = help: to override `-W clippy::suspicious` add `#[allow(clippy::cast_slice_from_raw_parts)]`
```
Forbid generic parameters in types of #[type_const] items

fixes rust-lang#150614

we enforce the same restriction on `#[type_const]` const items that already exists for const generic parameters - when `generic_const_parameter_types` feature gate is not enabled, the type of a `#[type_const]` item cannot reference generic parameters.  implementation follows the same pattern used for const generic parameters. we check if the item has the `#[type_const]` attribute and if the feature gate is disabled, then we apply `RibKind::ConstParamTy` restrictions when visiting the type, which prevents the use of generic parameters.

check is added in three places:
- Free const items (`ItemKind::Const`)
- Trait associated consts (`AssocItemKind::Const` in traits)
- Impl associated consts (`AssocItemKind::Const` in impls)

added tests for new feature, hope i get this task right :>

r? `@BoxyUwU`
Clarify panic conditions in `Iterator::last`

Follow-up PR to rust-lang#150580.

Now `Iterator::last`'s docs specify that it might panic only if the iterator is infinite, rather than if it has more than `usize::MAX` elements.

# Motivation
This is because `Iterator::last`, unlike `count`, also works on iterators with more than `usize::MAX` elements, but could panic on infinite iterators (as in `Repeat`), as discussed in rust-lang#150580.

r? ``@jhpratt``
Add missing translator resources for interface parse_cfg and parse_check_cfg

Missing resources leads to the failure of `translate_message`.

Fixes rust-lang#150654
@rustbot rustbot added A-compiletest Area: The compiletest test runner A-testsuite Area: The testsuite used to check the correctness of rustc S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Jan 4, 2026
@Zalathar
Copy link
Member Author

Zalathar commented Jan 4, 2026

Rollup of almost everything.

@bors r+ rollup=never p=5

@bors
Copy link
Collaborator

bors commented Jan 4, 2026

📌 Commit 85dc7c2 has been approved by Zalathar

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 4, 2026
@bors
Copy link
Collaborator

bors commented Jan 4, 2026

⌛ Testing commit 85dc7c2 with merge 5afdf5d...

@bors
Copy link
Collaborator

bors commented Jan 4, 2026

☀️ Test successful - checks-actions
Approved by: Zalathar
Pushing 5afdf5d to main...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jan 4, 2026
@bors bors merged commit 5afdf5d into rust-lang:main Jan 4, 2026
12 checks passed
@rustbot rustbot added this to the 1.94.0 milestone Jan 4, 2026
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#150201 compiletest: Support revisions in debuginfo (read: debugger… 00a94cbfa8674d49ca1707e9d6cf9f6d28a9feb0 (link)
#150642 mutex.rs: remove needless-maybe-unsized bounds d7361cf48fc6a3823b933f51fff18c69b6e541cd (link)
#150643 vec in-place-drop: avoid creating an intermediate slice 5750ac53851bb668af0d7d75f0cf95c5b297eed9 (link)
#150650 Forbid generic parameters in types of #[type_const] items 6c2c1c56242ff133f28be0b09f76754b6eaa9c8d (link)
#150658 Clarify panic conditions in Iterator::last 0a2a59fbfcd10e58b4efb6b929ec242eff53619c (link)
#150659 Add missing translator resources for interface parse_cfg an… be7f2c20a396427c44c1192760e12dde3638d7eb (link)
#150666 Fix ambig-unambig-ty-and-consts link 3193af48e016e7f2362b817fa768b3a9c65ccce8 (link)

previous master: f8b1d59a81

In the case of a perf regression, run the following command for each PR you suspect might be the cause: @rust-timer build $SHA

@github-actions
Copy link
Contributor

github-actions bot commented Jan 4, 2026

What is this? This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.

Comparing f8b1d59 (parent) -> 5afdf5d (this PR)

Test differences

Show 601 test diffs

Stage 1

  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs: pass -> [missing] (J2)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs#default-mir-passes: [missing] -> pass (J2)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs#no-SingleUseConsts-mir-pass: [missing] -> pass (J2)
  • [ui] tests/ui/cfg/invalid-cli-cfg-pred.rs: [missing] -> pass (J2)
  • [ui] tests/ui/cfg/invalid-cli-check-cfg-pred.rs: [missing] -> pass (J2)
  • [ui] tests/ui/const-generics/mgca/type_const-generic-param-in-type.rs#gate: [missing] -> pass (J2)
  • [ui] tests/ui/const-generics/mgca/type_const-generic-param-in-type.rs#nogate: [missing] -> pass (J2)

Stage 2

  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs: ignore (ignored when the GDB version is lower than 13.0) -> [missing] (J0)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs#default-mir-passes: [missing] -> ignore (ignored when the GDB version is lower than 13.0) (J0)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs#no-SingleUseConsts-mir-pass: [missing] -> ignore (ignored when the GDB version is lower than 13.0) (J0)
  • [ui] tests/ui/cfg/invalid-cli-cfg-pred.rs: [missing] -> pass (J1)
  • [ui] tests/ui/cfg/invalid-cli-check-cfg-pred.rs: [missing] -> pass (J1)
  • [ui] tests/ui/const-generics/mgca/type_const-generic-param-in-type.rs#gate: [missing] -> pass (J1)
  • [ui] tests/ui/const-generics/mgca/type_const-generic-param-in-type.rs#nogate: [missing] -> pass (J1)
  • [debuginfo-cdb] tests/debuginfo/macro-stepping.rs: pass -> [missing] (J3)
  • [debuginfo-cdb] tests/debuginfo/macro-stepping.rs#default-mir-passes: [missing] -> pass (J3)
  • [debuginfo-cdb] tests/debuginfo/macro-stepping.rs#no-SingleUseConsts-mir-pass: [missing] -> pass (J3)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs: pass -> [missing] (J4)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs#default-mir-passes: [missing] -> pass (J4)
  • [debuginfo-gdb] tests/debuginfo/macro-stepping.rs#no-SingleUseConsts-mir-pass: [missing] -> pass (J4)
  • [debuginfo-gdb (split-dwarf)] tests/debuginfo/macro-stepping.rs: ignore (ignored when the GDB version is lower than 13.0) -> [missing] (J5)
  • [debuginfo-gdb (split-dwarf)] tests/debuginfo/macro-stepping.rs#default-mir-passes: [missing] -> ignore (ignored when the GDB version is lower than 13.0) (J5)
  • [debuginfo-gdb (split-dwarf)] tests/debuginfo/macro-stepping.rs#no-SingleUseConsts-mir-pass: [missing] -> ignore (ignored when the GDB version is lower than 13.0) (J5)
  • [debuginfo-lldb] tests/debuginfo/macro-stepping.rs: ignore (ignored when the LLDB version is 1800) -> [missing] (J6)
  • [debuginfo-lldb] tests/debuginfo/macro-stepping.rs#default-mir-passes: [missing] -> ignore (ignored when the LLDB version is 1800) (J6)
  • [debuginfo-lldb] tests/debuginfo/macro-stepping.rs#no-SingleUseConsts-mir-pass: [missing] -> ignore (ignored when the LLDB version is 1800) (J6)

Additionally, 575 doctest diffs were found. These are ignored, as they are noisy.

Job group index

Test dashboard

Run

cargo run --manifest-path src/ci/citool/Cargo.toml -- \
    test-dashboard 5afdf5d8c0377d6babd2504986982b5e5d724798 --output-dir test-dashboard

And then open test-dashboard/index.html in your browser to see an overview of all executed tests.

Job duration changes

  1. aarch64-gnu-llvm-20-1: 3220.0s -> 4061.0s (+26.1%)
  2. dist-aarch64-apple: 5551.6s -> 6815.8s (+22.8%)
  3. aarch64-msvc-1: 6632.3s -> 7994.9s (+20.5%)
  4. pr-check-1: 1660.5s -> 1962.8s (+18.2%)
  5. aarch64-gnu-llvm-20-2: 2747.3s -> 3246.8s (+18.2%)
  6. i686-gnu-2: 5281.0s -> 6182.5s (+17.1%)
  7. aarch64-apple: 9719.4s -> 11067.1s (+13.9%)
  8. i686-gnu-1: 7464.2s -> 8403.2s (+12.6%)
  9. aarch64-gnu-debug: 4070.8s -> 4565.8s (+12.2%)
  10. i686-gnu-nopt-1: 7588.8s -> 8446.9s (+11.3%)
How to interpret the job duration changes?

Job durations can vary a lot, based on the actual runner instance
that executed the job, system noise, invalidated caches, etc. The table above is provided
mostly for t-infra members, for simpler debugging of potential CI slow-downs.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (5afdf5d): comparison URL.

Overall result: ❌✅ regressions and improvements - please read the text below

Our benchmarks found a performance regression caused by this PR.
This might be an actual regression, but it can also be just noise.

Next Steps:

  • If the regression was expected or you think it can be justified,
    please write a comment with sufficient written justification, and add
    @rustbot label: +perf-regression-triaged to it, to mark the regression as triaged.
  • If you think that you know of a way to resolve the regression, try to create
    a new PR with a fix for the regression.
  • If you do not understand the regression or you think that it is just noise,
    you can ask the @rust-lang/wg-compiler-performance working group for help (members of this group
    were already notified of this PR).

@rustbot label: +perf-regression
cc @rust-lang/wg-compiler-performance

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
0.7% [0.7%, 0.7%] 1
Regressions ❌
(secondary)
0.1% [0.1%, 0.1%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.5% [-0.6%, -0.2%] 4
All ❌✅ (primary) 0.7% [0.7%, 0.7%] 1

Max RSS (memory usage)

Results (primary 2.4%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
2.4% [2.4%, 2.4%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 2.4% [2.4%, 2.4%] 1

Cycles

Results (secondary -2.2%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.2% [-2.2%, -2.2%] 1
All ❌✅ (primary) - - 0

Binary size

Results (primary 1.3%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
1.3% [1.3%, 1.3%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.3% [1.3%, 1.3%] 1

Bootstrap: 475.255s -> 475.624s (0.08%)
Artifact size: 390.83 MiB -> 390.88 MiB (0.01%)

@rustbot rustbot added the perf-regression Performance regression. label Jan 4, 2026
@Zalathar Zalathar deleted the rollup-7ar4hqp branch January 4, 2026 21:39
@Kobzol
Copy link
Member

Kobzol commented Jan 6, 2026

The cargo benchmark seems a bit noisy, over a longer time period, the "up" jumps seem to come and go:

image

Over all benchmarks it's a wash, I don't think we need to investigate further.

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label Jan 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-compiletest Area: The compiletest test runner A-testsuite Area: The testsuite used to check the correctness of rustc merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. perf-regression-triaged The performance regression has been triaged. rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.