Skip to content

Rollup of 5 pull requests - #161731

Merged
rust-bors[bot] merged 17 commits into
rust-lang:mainfrom
jhpratt:rollup-cUfsCoq
Aug 25, 2026
Merged

Rollup of 5 pull requests#161731
rust-bors[bot] merged 17 commits into
rust-lang:mainfrom
jhpratt:rollup-cUfsCoq

Conversation

@jhpratt

@jhpratt jhpratt commented Aug 25, 2026

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost

Create a similar rollup

im-lunex and others added 17 commits August 20, 2026 22:45
`.pdr` holds MIPS procedure-descriptor debug data. It is not allocated, so
`--gc-sections` does not collect it, but the relocations kept for it by the
target's `--emit-relocs` still refer to the functions that were collected.
rust-lld reports each of those as "relocation refers to a discarded section";
a hello-world picks up 70 such warnings, now that cargo no longer suppresses
linker output.

Nothing on the PSP reads `.pdr`, so discard it alongside the other non-loadable
sections already listed. This also drops ~9% off the resulting EBOOT.

Fixes overdrivenpotato/rust-psp#203 (in part)
And instead explicitly depend on the output of the `TestHelpers` step.
It doesn't seem to be used anywhere anymore.
It doesn't seem to be used anywhere anymore.
It was only used at one place.
And instead depend on the generated md doc directory path explicitly.
remove `box_patterns`

This PR removes the old feature `box_patterns`, tracked in rust-lang#29641. As explained in rust-lang#29641 (comment), this feature will not be stabilized since `deref_patterns` (rust-lang#87121) is a better and more general version of this feature.

It was not possible to remove this feature until recently since the compiler itself still depended on this feature. This was changed with rust-lang/compiler-team#984.

This PR currently breaks crates that rely on box patterns using the incorrect pre-expansion feature gating (see rust-lang#154045 for more details). Therefore, this needs a crater run.

Closes rust-lang#29641.
Closes rust-lang#105099.
Closes rust-lang#156110.
avoid overlapping const suggestions

Avoid emitting the optional `const-extraction` suggestion when its **component spans** overlap, this avoids the compiler panic while still emitting the normal error and keeping the suggestion for cases where it can be
generated correctly

Fixes rust-lang#161213
…rcote

Discard `.pdr` in the PSP linker script

The `mipsel-sony-psp` target passes `--emit-relocs` and relies on `--gc-sections`. `.pdr` (MIPS procedure-descriptor debug data) is not allocated, so it survives collection, but the relocations kept for it still point at the functions that *were* collected. rust-lld reports every one of those:

```
rust-lld: relocation refers to a discarded section: .text._RNvNtNtCs1mwba6qCgei_4libm4math3log3log
>>> referenced by libm-...-cgu.3.rcgu.o:(.rel.pdr+0xbfa0) in archive .../liblibm-....rlib
```

A hello-world picks up **70** of these. They were always emitted; they only became visible when cargo stopped suppressing linker output, and are now reported by the `linker_messages` lint. Reported downstream as overdrivenpotato/rust-psp#203.

Nothing on the PSP reads `.pdr`, so this discards it alongside the non-loadable sections the script already drops (`.MIPS.abiflags`, `.reginfo`). Discarding `.pdr` also removes `.rel.pdr`, since `--emit-relocs` only emits relocations for sections that survive.

### Verification

Building `rust-psp`'s `ci/tests` suite and running it on PPSSPP:

|                        | before      | after       |
| ---------------------- | ----------- | ----------- |
| discarded-section warnings | 70      | **0**       |
| `EBOOT.PBP` size       | 1,395,948 B | 1,264,396 B (−9.4%) |
| test suite             | 47 pass / 0 fail | 47 pass / 0 fail (`FINAL_SUCCESS`) |

Since the linker script lives in the target spec, I validated the exact change by building against a patched `--print target-spec-json` copy of the target, and cross-checked it by passing an equivalent `/DISCARD/` fragment as an extra `--script` to a normal `cargo psp` build. Both give the same result.

This is the target's own linker script and affects no other target. The remaining warnings in that issue have a separate cause (`EF_MIPS_CPIC`) and are handled in a follow-up PR.
…=jieyouxu

Reduce dependency on implicit paths in bootstrap

Minor drive-by cleanup, reducing usage of some shared directories, and replacing it with depending on explicit paths.

Also found some env. vars. that I think have been unused for a long time.

r? jieyouxu
…nethercote

rename rust_target_features query to make it clear that these are *all* target features

r? @nnethercote
@rust-bors rust-bors Bot added the rollup A PR which is a rollup label Aug 25, 2026
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) 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-clippy Relevant to the Clippy team. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue. labels Aug 25, 2026
@jhpratt

jhpratt commented Aug 25, 2026

Copy link
Copy Markdown
Member Author

@bors r+ p=5

@rust-bors

rust-bors Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

📌 Commit e0f4541 has been approved by jhpratt

It is now in the queue for this repository.

@rust-bors rust-bors Bot 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 Aug 25, 2026
@rust-bors

This comment has been minimized.

@rust-bors rust-bors Bot added merged-by-bors This PR was explicitly merged by bors. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Aug 25, 2026
@rust-bors

rust-bors Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

☀️ Test successful - CI
Approved by: jhpratt
Duration: 2h 50m 50s
Pushing cc05892 to main...

@rust-bors
rust-bors Bot merged commit cc05892 into rust-lang:main Aug 25, 2026
14 checks passed
@rustbot rustbot added this to the 1.100.0 milestone Aug 25, 2026
@github-actions

Copy link
Copy Markdown
Contributor
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 26747db (parent) -> cc05892 (this PR)

Test differences

Show 120 test diffs

Stage 1

  • [ui] tests/ui/borrowck/bindings-after-at-or-patterns-slice-patterns-box-patterns.rs: pass -> [missing] (J1)
  • [ui] tests/ui/borrowck/bindings-after-at-or-patterns-slice-patterns-deref-patterns.rs: [missing] -> pass (J1)
  • [ui] tests/ui/box/box-patterns-feature-usage-6557.rs: pass -> [missing] (J1)
  • [ui] tests/ui/box/unit/unique-pat.rs: pass -> [missing] (J1)
  • [ui] tests/ui/deref/box-pattern-trait-object-cannot-deref.rs: pass -> [missing] (J1)
  • [ui] tests/ui/feature-gates/feature-gate-box_patterns.rs: pass -> [missing] (J1)
  • [ui] tests/ui/feature-gates/soft-feature-gate-box_patterns.rs: pass -> [missing] (J1)
  • [ui] tests/ui/or-patterns/box-patterns.rs: pass -> [missing] (J1)
  • [ui] tests/ui/or-patterns/deref-patterns.rs: [missing] -> pass (J1)
  • [ui] tests/ui/parser/recover/recover-pat-range-macro-span-overlap.rs: [missing] -> pass (J1)
  • [ui] tests/ui/parser/removed-syntax/removed-syntax-box-patterns.rs: [missing] -> pass (J1)
  • [ui] tests/ui/pattern/bindings-after-at/box-patterns.rs: pass -> [missing] (J1)
  • [ui] tests/ui/pattern/bindings-after-at/deref-patterns.rs: [missing] -> pass (J1)
  • [ui] tests/ui/pattern/bindings-after-at/or-patterns-box-patterns.rs: pass -> [missing] (J1)
  • [ui] tests/ui/pattern/bindings-after-at/or-patterns-deref-patterns.rs: [missing] -> pass (J1)
  • [ui] tests/ui/pattern/box-pattern-constructor-mismatch.rs: pass -> [missing] (J1)
  • [ui] tests/ui/pattern/box-pattern-nested.rs: pass -> [missing] (J1)
  • [ui] tests/ui/pattern/box-pattern-type-mismatch.rs: pass -> [missing] (J1)
  • [ui] tests/ui/pattern/deref-pattern-box-constructor-mismatch.rs: [missing] -> pass (J1)
  • [ui] tests/ui/pattern/deref-pattern-nested.rs: [missing] -> pass (J1)
  • [ui] tests/ui/pattern/deref-pattern-type-mismatch.rs: [missing] -> pass (J1)
  • [ui] tests/ui/pattern/pattern-bad-ref-box-order.rs: pass -> [missing] (J1)
  • [ui] tests/ui/range/range-inclusive-pattern-precedence2.rs: pass -> [missing] (J1)
  • [ui] tests/ui/rfcs/rfc-2005-default-binding-mode/box.rs: pass -> [missing] (J1)
  • [ui (polonius)] tests/ui/borrowck/bindings-after-at-or-patterns-slice-patterns-box-patterns.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/borrowck/bindings-after-at-or-patterns-slice-patterns-deref-patterns.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/box/box-patterns-feature-usage-6557.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/box/unit/unique-pat.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/deref/box-pattern-trait-object-cannot-deref.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/feature-gates/feature-gate-box_patterns.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/feature-gates/soft-feature-gate-box_patterns.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/or-patterns/box-patterns.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/or-patterns/deref-patterns.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/parser/recover/recover-pat-range-macro-span-overlap.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/parser/removed-syntax/removed-syntax-box-patterns.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/pattern/bindings-after-at/box-patterns.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/pattern/bindings-after-at/deref-patterns.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/pattern/bindings-after-at/or-patterns-box-patterns.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/pattern/bindings-after-at/or-patterns-deref-patterns.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/pattern/box-pattern-constructor-mismatch.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/pattern/box-pattern-nested.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/pattern/box-pattern-type-mismatch.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/pattern/deref-pattern-box-constructor-mismatch.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/pattern/deref-pattern-nested.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/pattern/deref-pattern-type-mismatch.rs: [missing] -> pass (J2)
  • [ui (polonius)] tests/ui/pattern/pattern-bad-ref-box-order.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/range/range-inclusive-pattern-precedence2.rs: pass -> [missing] (J2)
  • [ui (polonius)] tests/ui/rfcs/rfc-2005-default-binding-mode/box.rs: pass -> [missing] (J2)

Stage 2

  • [ui] tests/ui/borrowck/bindings-after-at-or-patterns-slice-patterns-box-patterns.rs: pass -> [missing] (J0)
  • [ui] tests/ui/borrowck/bindings-after-at-or-patterns-slice-patterns-deref-patterns.rs: [missing] -> pass (J0)
  • [ui] tests/ui/box/box-patterns-feature-usage-6557.rs: pass -> [missing] (J0)
  • [ui] tests/ui/box/unit/unique-pat.rs: pass -> [missing] (J0)
  • [ui] tests/ui/deref/box-pattern-trait-object-cannot-deref.rs: pass -> [missing] (J0)
  • [ui] tests/ui/feature-gates/feature-gate-box_patterns.rs: pass -> [missing] (J0)
  • [ui] tests/ui/feature-gates/soft-feature-gate-box_patterns.rs: pass -> [missing] (J0)
  • [ui] tests/ui/or-patterns/box-patterns.rs: pass -> [missing] (J0)
  • [ui] tests/ui/or-patterns/deref-patterns.rs: [missing] -> pass (J0)
  • [ui] tests/ui/parser/recover/recover-pat-range-macro-span-overlap.rs: [missing] -> pass (J0)
  • [ui] tests/ui/parser/removed-syntax/removed-syntax-box-patterns.rs: [missing] -> pass (J0)
  • [ui] tests/ui/pattern/bindings-after-at/box-patterns.rs: pass -> [missing] (J0)
  • [ui] tests/ui/pattern/bindings-after-at/deref-patterns.rs: [missing] -> pass (J0)
  • [ui] tests/ui/pattern/bindings-after-at/or-patterns-box-patterns.rs: pass -> [missing] (J0)
  • [ui] tests/ui/pattern/bindings-after-at/or-patterns-deref-patterns.rs: [missing] -> pass (J0)
  • [ui] tests/ui/pattern/box-pattern-constructor-mismatch.rs: pass -> [missing] (J0)
  • [ui] tests/ui/pattern/box-pattern-nested.rs: pass -> [missing] (J0)
  • [ui] tests/ui/pattern/box-pattern-type-mismatch.rs: pass -> [missing] (J0)
  • [ui] tests/ui/pattern/deref-pattern-box-constructor-mismatch.rs: [missing] -> pass (J0)
  • [ui] tests/ui/pattern/deref-pattern-nested.rs: [missing] -> pass (J0)
  • [ui] tests/ui/pattern/deref-pattern-type-mismatch.rs: [missing] -> pass (J0)
  • [ui] tests/ui/pattern/pattern-bad-ref-box-order.rs: pass -> [missing] (J0)
  • [ui] tests/ui/range/range-inclusive-pattern-precedence2.rs: pass -> [missing] (J0)
  • [ui] tests/ui/rfcs/rfc-2005-default-binding-mode/box.rs: pass -> [missing] (J0)

Additionally, 48 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 cc05892c8346313865afd91ca12ee1fde6d3603c --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. i686-gnu-nopt-1: 1h 14m -> 2h 18m (+84.8%)
  2. x86_64-msvc-ext2: 1h 6m -> 1h 48m (+62.2%)
  3. x86_64-gnu-stdlib-semver-check: 11m 26s -> 18m 12s (+59.2%)
  4. x86_64-gnu-aux: 1h 48m -> 2h 46m (+54.0%)
  5. x86_64-gnu-miri: 1h -> 1h 30m (+48.3%)
  6. dist-x86_64-freebsd: 1h 3m -> 1h 29m (+41.3%)
  7. x86_64-gnu-llvm-21-1: 44m 4s -> 1h 2m (+40.8%)
  8. x86_64-gnu-gcc-core-tests: 12m 1s -> 16m 39s (+38.6%)
  9. i686-gnu-nopt-2: 1h 44m -> 2h 24m (+37.9%)
  10. dist-various-2: 36m 6s -> 48m 18s (+33.8%)
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
Copy Markdown
Collaborator

Finished benchmarking commit (cc05892): comparison URL.

Overall result: ❌ regressions - please read:

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
Regressions ❌
(secondary)
0.3% [0.2%, 0.4%] 10
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -2.3%)

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)
-2.3% [-2.3%, -2.3%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -2.3% [-2.3%, -2.3%] 1

Cycles

Results (primary 0.3%, secondary 13.1%)

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

mean range count
Regressions ❌
(primary)
3.7% [3.7%, 3.7%] 1
Regressions ❌
(secondary)
13.1% [13.1%, 13.1%] 1
Improvements ✅
(primary)
-3.0% [-3.0%, -3.0%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.3% [-3.0%, 3.7%] 2

Binary size

This perf run didn't have relevant results for this metric.

Bootstrap: 471.198s -> 477.242s (1.28%)
Artifact size: 400.99 MiB -> 401.00 MiB (0.00%)

@rustbot rustbot added the perf-regression Performance regression. label Aug 25, 2026
@rust-bors

rust-bors Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#156749 remove box_patterns c8d485691eaeccf288519553313d75a75b6c962c
(link)
#161411 avoid overlapping const suggestions 80e51adc07907692be8e0ad37f42bc64befa9e89
(link)
#161484 Discard .pdr in the PSP linker script 895c85aa61fb3d00de2dd656dd36011e913a0d06
(link)
#161663 Reduce dependency on implicit paths in bootstrap f5892e8270be7b9eebaadc3d2fa549b67cc06552
(link)
#161720 rename rust_target_features query to make it clear that the… 09b72b2cf2a0a3b15d1a826ae1913f1970054b71
(link)

parent commit: 26747db4f5

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

@JonathanBrouwer

Copy link
Copy Markdown
Member

@rustbot label: +perf-regression-triaged
Noise

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

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) 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 T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-clippy Relevant to the Clippy team. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants