Skip to content

Conversation

@chenyukang
Copy link
Member

@chenyukang chenyukang commented Nov 20, 2025

Fixes #147648

@rustbot
Copy link
Collaborator

rustbot commented Nov 20, 2025

Some changes occurred to MIR optimizations

cc @rust-lang/wg-mir-opt

@rustbot rustbot added 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. labels Nov 20, 2025
@rustbot
Copy link
Collaborator

rustbot commented Nov 20, 2025

r? @SparrowLii

rustbot has assigned @SparrowLii.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@chenyukang chenyukang force-pushed the yukang-fix-unused_assignments-macro-gen-147648 branch from 0f7c6a0 to c21d817 Compare November 21, 2025 03:58
@rust-log-analyzer

This comment has been minimized.

@chenyukang chenyukang force-pushed the yukang-fix-unused_assignments-macro-gen-147648 branch from c21d817 to f943606 Compare November 21, 2025 04:20
@workingjubilee
Copy link
Member

r? compiler

@JonathanBrouwer
Copy link
Contributor

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Dec 3, 2025

📌 Commit f943606 has been approved by JonathanBrouwer

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 Dec 3, 2025
Zalathar added a commit to Zalathar/rust that referenced this pull request Dec 4, 2025
…nments-macro-gen-147648, r=JonathanBrouwer

Fix unused_assignments false positives from macros

Fixes rust-lang#147648
Zalathar added a commit to Zalathar/rust that referenced this pull request Dec 4, 2025
…nments-macro-gen-147648, r=JonathanBrouwer

Fix unused_assignments false positives from macros

Fixes rust-lang#147648
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Dec 4, 2025
…nments-macro-gen-147648, r=JonathanBrouwer

Fix unused_assignments false positives from macros

Fixes rust-lang#147648
bors added a commit that referenced this pull request Dec 4, 2025
Rollup of 12 pull requests

Successful merges:

 - #147841 (Fix ICE when applying test macro to crate root)
 - #149147 (Fix unused_assignments false positives from macros)
 - #149183 (Use `TypingMode::PostAnalysis` in `try_evaluate_const`)
 - #149456 (std: don't call `current_os_id` from signal handler)
 - #149501 (CTFE: avoid emitting a hard error on generic normalization failures)
 - #149528 (reword error for invalid range patterns)
 - #149539 (Additional test for uN::{gather,scatter}_bits)
 - #149549 (Regression test for system register `ttbr0_el2`)
 - #149550 (Disable native-lib for x check miri)
 - #149554 (build-manifest: generate MSI and MINGW arrays from rustc)
 - #149557 (c-variadic: bpf and spirv do not support c-variadic definitions)
 - #149569 (Fix mailmap issue)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 82a17b3 into rust-lang:main Dec 4, 2025
11 checks passed
@rustbot rustbot added this to the 1.93.0 milestone Dec 4, 2025
rust-timer added a commit that referenced this pull request Dec 4, 2025
Rollup merge of #149147 - chenyukang:yukang-fix-unused_assignments-macro-gen-147648, r=JonathanBrouwer

Fix unused_assignments false positives from macros

Fixes #147648
@Kobzol
Copy link
Member

Kobzol commented Dec 4, 2025

@rust-timer build 4da4cc5

For #149631 (comment).

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (4da4cc5): comparison URL.

Overall result: no relevant changes - BENCHMARK(S) FAILED

Benchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf.

@bors rollup=never
@rustbot label: -S-waiting-on-perf -perf-regression

❗ ❗ ❗ ❗ ❗
Warning ⚠️: The following benchmark(s) failed to build:

  • Job failure

❗ ❗ ❗ ❗ ❗

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

This benchmark run did not return any relevant results for this metric.

Cycles

This benchmark run did not return any relevant results for this metric.

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: missing data
Artifact size: missing data

@Kobzol
Copy link
Member

Kobzol commented Dec 4, 2025

@rust-timer build 4da4cc5

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (4da4cc5): comparison URL.

Overall result: ❌ regressions - please read the text below

Benchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf.

Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @rustbot label: +perf-regression-triaged. If not, please fix the regressions and do another perf run. If its results are neutral or positive, the label will be automatically removed.

@bors rollup=never
@rustbot label: -S-waiting-on-perf +perf-regression

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)
7.4% [0.1%, 25.0%] 10
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.0% [-0.0%, -0.0%] 1
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -1.0%, secondary 11.1%)

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)
14.4% [10.4%, 19.2%] 4
Improvements ✅
(primary)
-1.0% [-1.0%, -1.0%] 1
Improvements ✅
(secondary)
-2.2% [-2.2%, -2.2%] 1
All ❌✅ (primary) -1.0% [-1.0%, -1.0%] 1

Cycles

Results (secondary 23.6%)

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)
23.6% [4.3%, 40.2%] 4
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 468.789s -> 468.96s (0.04%)
Artifact size: 386.75 MiB -> 386.76 MiB (0.00%)

@rustbot rustbot added the perf-regression Performance regression. label Dec 4, 2025
@JonathanBrouwer
Copy link
Contributor

Oh wow I did not expect that regression from such a simple check.
Is .in_external_macro a slow check?
@chenyukang Do you have the time to look into this?

@workingjubilee
Copy link
Member

I'm expecting the answer to be "no" but I want to be sure we're confirming that answer given this is a beta regression:

@rustbot label +beta-nominated

@rustbot rustbot added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Dec 4, 2025
Kobzol added a commit to Kobzol/rust that referenced this pull request Dec 4, 2025
…ed_assignments-macro-gen-147648, r=JonathanBrouwer"

This reverts commit 82a17b3, reversing
changes made to 5019bda.
@Kobzol
Copy link
Member

Kobzol commented Dec 4, 2025

Posted a revert in #149657.

rust-bors bot added a commit that referenced this pull request Dec 4, 2025
Revert "Rollup merge of #149147 - chenyukang:yukang-fix-unused_assignments-macro-gen-147648, r=JonathanBrouwer"
@chenyukang
Copy link
Member Author

I'm on travel right now, will have a check it later.
seems the new testing code is on a hot path.

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

Labels

beta-nominated Nominated for backporting to the compiler in the beta channel. perf-regression Performance regression. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

nightly unused_assignments false positives for miette::Diagnostic fields

10 participants