Skip to content

Rollup of 5 pull requests - #164193

Merged
rust-bors[bot] merged 15 commits into
rust-lang:mainfrom
jhpratt:rollup-H0cWA8g
Oct 12, 2026
Merged

rust-bors[bot] merged 15 commits into
rust-lang:mainfrom
jhpratt:rollup-H0cWA8g

Conversation

@jhpratt

@jhpratt jhpratt commented Oct 12, 2026

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost

Create a similar rollup

RalfJung and others added 15 commits October 10, 2026 15:20
The rust-analyzer impls of these methods will need to be removed on the
next sync.
It's faster than `extend` to initialize these structures.
A lot of work can be skipped if the two values being related are equal.
(There are various early-return equality checks like this further down
the call chain, this just adds one earlier.)
The former has an early return check and a single call site, so the
check can be moved before the call site. Also, in the `Err(NoSolution)`
case we can skip the `CandidateHeadUsages::default()` stuff because
that's just an empty list and `merge_usages` is a no-op.
Instead of getting it within `fast_reject_assumption`.

`fast_reject_assumption` has three call sites. For two of them this
change doesn't help perf, but the third call occurs in a loop, and this
lets us get the goal lang item once per loop instead of once per loop
element.
- Increase the number of preinterned type vars and anon bound types.
- Preintern some root-universe placeholder types with anon bounds.
- Adjust some comments.
- Also rename a lot of the preinterning names for more consistency.
In unused macro lint, mention when its enclosing `mod` isn't annotated with `#[macro_use]`:

```
error: unused macro definition: `unused`
  --> $DIR/unused-macros-decl.rs:17:11
   |
LL |     macro unused {
   |           ^^^^^^
   |
note: the lint level is defined here
  --> $DIR/unused-macros-decl.rs:16:12
   |
LL |     #[deny(unused_macros)]
   |            ^^^^^^^^^^^^^
help: consider annotating the enclosing module with `#[macro_use]`
   |
LL + #[macro_use]
LL | mod bar {
   |
```

On resolution error for unexported macro, point at macro of the same name and mention its enclosing scope could be marked with `#[macro_use]`:

```
error: cannot find macro `a_macro` in this scope
  --> $DIR/unresolved-macro-missing-macro-use.rs:11:5
   |
LL |     a_macro!();
   |     ^^^^^^^
   |
help: you might be missing a `#[macro_use]` attribute on a `mod` module or `use` import
  --> $DIR/unresolved-macro-missing-macro-use.rs:5:5
   |
LL | / mod has_a_macro {
LL | |
LL | |     macro_rules! a_macro { () => {} }
   | |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ a macro with the same name is defined here
...  |
LL | | }
   | |_- consider annotating this `mod` with `#[macro_use]`
```

On ambiguous macro use, suggest removing invalid import:

```
error[E0659]: `a_macro` is ambiguous
  --> $DIR/unresolved-macro-missing-macro-use-3.rs:15:5
   |
LL |     a_macro!();
   |     ^^^^^^^ ambiguous name
   |
   = note: ambiguous because of a conflict between a `macro_rules` name and a non-`macro_rules` name from another module
note: `a_macro` could refer to the macro defined here
  --> $DIR/unresolved-macro-missing-macro-use-3.rs:5:5
   |
LL |     macro_rules! a_macro { () => {} }
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: `a_macro` could also refer to the unresolved item imported here
  --> $DIR/unresolved-macro-missing-macro-use-3.rs:9:5
   |
LL | use crate::has_a_macro::a_macro;
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^
   = help: consider removing this
```
…zelmann

New solver opts for `diesel`

A collection of small optimizations. Details in individual commits.

Local measurements:
```
solver         icounts (B)
------         -----------
old            37.9
new (orig)     56.4 (1.49x)
new (this PR)  49.5 (1.31x)
```
Also some small improvements on a range of other benchmarks.

r? @jdonszelmann
const-check: clarify when and how we can rely on non-UB assumptions

Turns out const-checking relies on `&x` being immutable. This is the "most obvious" property we get from the aliasing model, and we emit LLVM attributes and have MIR-opts that rely on it. I just didn't realize that taking away this UB would actually be a breaking change; there is code that runs on stable that we'd have to stop accepting if we took away this UB:
```rust
struct NotConstDestruct;

impl Drop for NotConstDestruct {
    fn drop(&mut self) {
        eprintln!("this is not const");
    }
}

const _: () = {
    let x = None::<NotConstDestruct>;
    let ptr = std::ptr::from_ref(&x);
    unsafe { ptr.cast_mut().write(Some(NotConstDestruct)) };
};
```
This means that I accidentally fixed a hole in const-checking when I added `&` immutability checking to const-eval.

r? @oli-obk
Cc @rust-lang/opsem @tmiasko
… r=mu001999

Remove unnecessary indirection around `hir::ConstArg`

Probably doesn't have measurable perf effect because `ConstArg` is not that common of a type (yet), but it's nicer this way regardless imo :)
Tweak output on unused/unaccessible local macro

In unused macro lint, mention when its enclosing `mod` isn't annotated with `#[macro_use]`:

```
error: unused macro definition: `unused`
  --> $DIR/unused-macros-decl.rs:17:11
   |
LL |     macro unused {
   |           ^^^^^^
   |
note: the lint level is defined here
  --> $DIR/unused-macros-decl.rs:16:12
   |
LL |     #[deny(unused_macros)]
   |            ^^^^^^^^^^^^^
help: consider annotating the enclosing module with `#[macro_use]`
   |
LL + #[macro_use]
LL | mod bar {
   |
```

On resolution error for unexported macro, point at macro of the same name and mention its enclosing scope could be marked with `#[macro_use]`:

```
error: cannot find macro `a_macro` in this scope
  --> $DIR/unresolved-macro-missing-macro-use.rs:11:5
   |
LL |     a_macro!();
   |     ^^^^^^^
   |
help: you might be missing a `#[macro_use]` attribute on a `mod` module or `use` import
  --> $DIR/unresolved-macro-missing-macro-use.rs:5:5
   |
LL | / mod has_a_macro {
LL | |
LL | |     macro_rules! a_macro { () => {} }
   | |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ a macro with the same name is defined here
...  |
LL | | }
   | |_- consider annotating this `mod` with `#[macro_use]`
```

On ambiguous macro use, suggest removing invalid import:

```
error[E0659]: `a_macro` is ambiguous
  --> $DIR/unresolved-macro-missing-macro-use-3.rs:15:5
   |
LL |     a_macro!();
   |     ^^^^^^^ ambiguous name
   |
   = note: ambiguous because of a conflict between a `macro_rules` name and a non-`macro_rules` name from another module
note: `a_macro` could refer to the macro defined here
  --> $DIR/unresolved-macro-missing-macro-use-3.rs:5:5
   |
LL |     macro_rules! a_macro { () => {} }
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: `a_macro` could also refer to the unresolved item imported here
  --> $DIR/unresolved-macro-missing-macro-use-3.rs:9:5
   |
LL | use crate::has_a_macro::a_macro;
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^
   = help: consider removing this
```

Fix rust-lang#57966.
…ns, r=jieyouxu

Update actions/upload-artifact action to v7.0.2

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [actions/upload-artifact](https://redirect.github.com/actions/upload-artifact) | action | patch | `v7.0.1` → `v7.0.2` |

---

### Release Notes

<details>
<summary>actions/upload-artifact (actions/upload-artifact)</summary>

### [`v7.0.2`](https://redirect.github.com/actions/upload-artifact/releases/tag/v7.0.2)

[Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v7.0.1...v7.0.2)

#### What's Changed

- Improves artifact download retries when the service returns HTTP 429 (rate limiting), including honoring valid Retry-After headers.
- Updates [@&rust-lang#8203;actions/artifact](https://redirect.github.com/actions/artifact) to v6.3.1.

#### New Contributors

- [@&rust-lang#8203;tunc-d](https://redirect.github.com/tunc-d) made their first contribution in [#&rust-lang#8203;821](https://redirect.github.com/actions/upload-artifact/pull/821)

**Full Changelog**: <actions/upload-artifact@v7.0.1...v7.0.2>

</details>

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - Between 12:00 AM and 03:59 AM, only on Monday (`* 0-3 * * 1`)
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/rust-lang/rust).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4xMzQuMSIsInVwZGF0ZWRJblZlciI6IjQ0LjEzNC4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
@rust-bors rust-bors Bot added the rollup A PR which is a rollup label Oct 12, 2026
@rustbot rustbot added A-CI Area: Our Github Actions CI S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) labels Oct 12, 2026
@jhpratt

jhpratt commented Oct 12, 2026

Copy link
Copy Markdown
Member Author

@bors r+ p=5 force

@rust-bors

rust-bors Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 63b5b35 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 Oct 12, 2026
@rust-bors

This comment has been minimized.

rust-bors Bot pushed a commit that referenced this pull request Oct 12, 2026
Rollup of 5 pull requests

Successful merges:

 - #163981 (New solver opts for `diesel`)
 - #164088 (const-check: clarify when and how we can rely on non-UB assumptions)
 - #164105 (Remove unnecessary indirection around `hir::ConstArg`)
 - #164181 (Tweak output on unused/unaccessible local macro)
 - #164186 (Update actions/upload-artifact action to v7.0.2)
@rust-bors rust-bors Bot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Oct 12, 2026
@rust-bors

rust-bors Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

💔 Test for 5e21f07 failed: CI. Failed job:

@jhpratt

jhpratt commented Oct 12, 2026

Copy link
Copy Markdown
Member Author

spurious

@bors retry

@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 Oct 12, 2026
@rust-bors

This comment has been minimized.

@rust-log-analyzer

Copy link
Copy Markdown
Collaborator

The job dist-powerpc64-linux-musl failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)

@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 Oct 12, 2026
@rust-bors

rust-bors Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

☀️ Test successful - CI
Approved by: jhpratt
Duration: 3h 2m 53s
Pushing fb5f32b to main...

@rust-bors
rust-bors Bot merged commit fb5f32b into rust-lang:main Oct 12, 2026
15 checks passed
@rustbot rustbot added this to the 1.101.0 milestone Oct 12, 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 b542750 (parent) -> fb5f32b (this PR)

Test differences

Show 65 test diffs

Stage 1

  • [ui (polonius)] tests/ui/macros/unresolved-macro-missing-macro-use-2.rs: [missing] -> pass (J1)
  • [ui (polonius)] tests/ui/macros/unresolved-macro-missing-macro-use-3.rs: [missing] -> pass (J1)
  • [ui (polonius)] tests/ui/macros/unresolved-macro-missing-macro-use.rs: [missing] -> pass (J1)
  • [ui] tests/ui/macros/unresolved-macro-missing-macro-use-2.rs: [missing] -> pass (J2)
  • [ui] tests/ui/macros/unresolved-macro-missing-macro-use-3.rs: [missing] -> pass (J2)
  • [ui] tests/ui/macros/unresolved-macro-missing-macro-use.rs: [missing] -> pass (J2)

Stage 2

  • [ui] tests/ui/macros/unresolved-macro-missing-macro-use-2.rs: [missing] -> pass (J0)
  • [ui] tests/ui/macros/unresolved-macro-missing-macro-use-3.rs: [missing] -> pass (J0)
  • [ui] tests/ui/macros/unresolved-macro-missing-macro-use.rs: [missing] -> pass (J0)

Additionally, 56 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 fb5f32bdbe75e9114c62589cb86ace65f14a5b78 --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. test-i686-msvc: 1h 27m -> 2h 34m (+76.8%)
  2. test-x86_64-gnu-miri: 52m 15s -> 1h 21m (+55.6%)
  3. dist-x86_64-solaris: 1h 8m -> 1h 43m (+50.6%)
  4. dist-loongarch64-linux: 1h 23m -> 2h 5m (+49.0%)
  5. test-x86_64-gnu-llvm-22-2: 1h 4m -> 1h 35m (+47.8%)
  6. test-aarch64-apple-macos-26-1: 1h 43m -> 2h 31m (+46.6%)
  7. dist-x86_64-musl: 1h 38m -> 2h 24m (+46.2%)
  8. test-pr-check-2: 23m 23s -> 33m 47s (+44.5%)
  9. dist-android: 21m 37s -> 30m 30s (+41.1%)
  10. dist-i586-gnu-i586-i686-musl: 19m 53s -> 27m 50s (+40.0%)
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 (fb5f32b): comparison URL.

Overall result: ❌✅ regressions and improvements - 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.4% [0.1%, 0.8%] 9
Regressions ❌
(secondary)
0.4% [0.1%, 0.9%] 25
Improvements ✅
(primary)
-0.1% [-0.2%, -0.1%] 5
Improvements ✅
(secondary)
-2.5% [-11.1%, -0.3%] 18
All ❌✅ (primary) 0.2% [-0.2%, 0.8%] 14

Max RSS (memory usage)

Results (primary -2.3%, secondary 0.0%)

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)
5.2% [2.1%, 8.1%] 5
Improvements ✅
(primary)
-2.3% [-2.3%, -2.2%] 2
Improvements ✅
(secondary)
-3.6% [-6.3%, -1.2%] 7
All ❌✅ (primary) -2.3% [-2.3%, -2.2%] 2

Cycles

Results (primary 2.3%, secondary -3.4%)

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

mean range count
Regressions ❌
(primary)
2.3% [2.2%, 2.4%] 2
Regressions ❌
(secondary)
3.7% [3.7%, 3.7%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-5.1% [-6.3%, -2.2%] 4
All ❌✅ (primary) 2.3% [2.2%, 2.4%] 2

Binary size

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

Bootstrap: 490.336s -> 490.047s (-0.06%)
Artifact size: 406.60 MiB -> 406.77 MiB (0.04%)

@rustbot rustbot added the perf-regression Performance regression. label Oct 12, 2026
@rust-bors

rust-bors Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#163981 New solver opts for diesel bc8e72c9fd61a8224033a704e951b9d31c2d1567
(link)
#164088 const-check: clarify when and how we can rely on non-UB ass… 2419b82b684c770dbdf736b6691efe3b44b52484
(link)
#164105 Remove unnecessary indirection around hir::ConstArg bbcd44c1d49bf865f4a27c7438f59b6bb696e9ef
(link)
#164181 Tweak output on unused/unaccessible local macro 478b77d9fb81b19b75e004b725e4fe730846ba1e
(link)
#164186 Update actions/upload-artifact action to v7.0.2 d7fb7757312b4797f821abecf564d0c0a5fdb5dd
(link)

parent commit: b5427502da

In the case of a perf regression, run the following command with the SHAs of each PR you suspect might be the cause: @rust-timer triage $SHA $SHA $SHA..., or run @rust-timer triage all to benchmark all rollup members.

@JonathanBrouwer

Copy link
Copy Markdown
Member

@rust-timer triage all

@rust-timer

rust-timer commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator
Running triage with 21 benchmarks

Triage only executes the benchmarks on rollup members, that were changed significantly on the rollup.
For this rollup, these benchmarks are:

  • await-call-tree
  • bitmaps-3.2.1
  • coercions
  • deeply-nested-multi
  • deref-sidebar-stress
  • diesel-2.2.10
  • diesel-2.2.10-new-solver
  • helloworld
  • hyper-1.6.0
  • issue-46449
  • issue-58319
  • match-stress
  • nalgebra-0.33.0-new-solver
  • projection-caching
  • serde-1.0.219-new-solver
  • token-stream-stress
  • tt-muncher
  • typenum-1.18.0-new-solver
  • unify-linearly
  • wf-projection-stress-65510
  • wg-grammar-new-solver

#163981 bc8e72c New solver opts for diesel

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.3% [0.2%, 0.6%] 4
Regressions ❌
(secondary)
0.3% [0.1%, 0.7%] 7
Improvements ✅
(primary)
-0.2% [-0.5%, -0.1%] 7
Improvements ✅
(secondary)
-1.5% [-11.1%, -0.1%] 36
All ❌✅ (primary) -0.0% [-0.5%, 0.6%] 11

Max RSS (memory usage)

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

Cycles

Results (secondary -4.0%)

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)
3.7% [3.7%, 3.7%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-6.6% [-6.8%, -6.4%] 3
All ❌✅ (primary) - - 0

Binary size

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


#164088 2419b82 const-check: clarify when and how we can rely on non-UB assumptions

This perf run didn't have relevant results for the `instruction count` metric.

Instruction count

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

Max RSS (memory usage)

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

Cycles

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

Binary size

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


#164105 bbcd44c Remove unnecessary indirection around hir::ConstArg

This perf run didn't have relevant results for the `instruction count` metric.

Instruction count

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

Max RSS (memory usage)

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

Cycles

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

Binary size

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


#164181 478b77d Tweak output on unused/unaccessible local macro

This perf run didn't have relevant results for the `instruction count` metric.

Instruction count

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

Max RSS (memory usage)

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

Cycles

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

Binary size

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


#164186 d7fb775 Update actions/upload-artifact action to v7.0.2

This perf run didn't have relevant results for the `instruction count` metric.

Instruction count

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

Max RSS (memory usage)

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

Cycles

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

Binary size

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-CI Area: Our Github Actions CI merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. rollup A PR which is a rollup T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants