Skip to content

Conversation

matthiaskrgr
Copy link
Member

@matthiaskrgr matthiaskrgr commented Oct 18, 2025

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

Oneirical and others added 16 commits October 12, 2025 00:33
…deathness

error from const eval lint causes ICE at check_pat in late_lint, because the function expects the typeck result isn't tainted by error but it is.
To avoid the ICE, check_pat returns earlier if the typeck_result is tainted.

check_mod_deathness also has an issue from the same reason. visit_body for making live symbols expects the typeck result has no error.
So this commit adds a check in visit_nested_body to avoid the ICE.
However, if visit_nested_body just returns without doing anything, all codes with the error are marked as dead, because live_symbols is empty.
To avoid this side effect, visit_nested_body and other visit_* functions in MarkSymbolVistior should return appropriate error.
If a function returns ControlFlow::Break, live_symbols_and_ignore_derived_traits returns earlier with error,
then check_mod_deathness, the caller of the function returns earlier without pushing everything into dead_codes.
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com>
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com>
Issue-125323: ICE non-ADT in struct pattern when long time constant evaluation is in for loop

This PR fixes rust-lang#125323

## Context
According to the issue, the ICE happens since rust-lang#121206.
In the PR, some error methods were reorganized. For example, has_errors() was renamed to has_errors_exclude_lint_errors(). However, some codes which used the original has_errors() were not switched to has_errors_exclude_lint_errors(). I finally found that report_error() in writeback.rs causes this ICE. Currently the method uses tainted_by_errors() to get guar (ErrorGuaranteed), but originally it used dcx().has_errors() but it wasn't changed to has_errors_exclude_lint_errors() when changes in rust-lang#121206 were merged. I don't think I fully understand how an error is propagated, but I suppose that the error from long time constant evaluation is unexpectedly propagated other parts (in this ICE, for loop), then cause the non-ADT in struct pattern ICE.

## Change
- Fix report_error() in writeback.rs: use dcx().has_errors_exclude_lint_errors() instead of tainted_by_errors() to prevent error propagation from constant evaluation.
- Add test for the ICE
- Modify some tests to align the change: Due to this fix, E0282 error happens (or not happen anymore) in some tests.

## NOTE
The 4th commit aims to revert the fix in rust-lang#123516 because I confirmed that the ICE solved by the PR doesn't happen if I modify report_error(). I think the root cause of that ICE is the same as rust-lang#125323 . But I can discard this commit since we can fix rust-lang#125323 without it.
…r=jieyouxu

Rehome 26 `tests/ui/issues/` tests to other subdirectories under `tests/ui/` [rust-lang#5 of Batch rust-lang#2]

Part of rust-lang#133895

Methodology:

1. Refer to the previously written `tests/ui/SUMMARY.md`
2. Find an appropriate category for the test, using the original issue thread and the test contents.
3. Add the issue URL at the bottom (not at the top, as that would mess up stderr line numbers)
4. Rename the tests to make their purpose clearer

Inspired by the methodology that Kivooeo was using.

r? ```@jieyouxu```
…dule-in-msg, r=fee1-dead

Rename "non-inline module" to "file module" in proc macro diagnostics

This PR updates diagnostic messages to use "file module" instead of "non-inline module". because the term "non-inline module" can be confusing, especially for non-native English speakers.

follow up PR rust-lang#147395
related of rust-lang#147314, [#general > Rename "non-inline modules" to "external modules"](https://rust-lang.zulipchat.com/#narrow/channel/122651-general/topic/.E2.9C.94.20Rename.20.22non-inline.20modules.22.20to.20.22external.20modules.22/near/543361244)

cc ```@Kivooeo```
…r=jdonszelmann

Fix ICE in pattern matching with generic const array length errors

Fixes rust-lang#139815
… r=jdonszelmann

Warn on unused_attributes in uitests

r? ```@jdonszelmann```

Because:
- unused_attributes warnings are usually actual mistakes, rather than just unused code, and we want to notify test writers they may be accidentally making a mistake
- Because the lint was allowed by default previously, we missed real bugs, because the test coverage is worse
  1. rust-lang#147417
  2. rust-lang#147411
…o, r=jieyouxu

Do not error out for `download-rustc` if LTO is configured

Noted [here](rust-lang#141953 (comment)). LTO should indeed be mostly a perf-only change.

r? ``@jieyouxu``
@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. rollup A PR which is a rollup labels Oct 18, 2025
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=5

@bors
Copy link
Collaborator

bors commented Oct 18, 2025

📌 Commit 54c6939 has been approved by matthiaskrgr

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 Oct 18, 2025
@bors
Copy link
Collaborator

bors commented Oct 19, 2025

⌛ Testing commit 54c6939 with merge 377a931...

@bors
Copy link
Collaborator

bors commented Oct 19, 2025

☀️ Test successful - checks-actions
Approved by: matthiaskrgr
Pushing 377a931 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Oct 19, 2025
@bors bors merged commit 377a931 into rust-lang:master Oct 19, 2025
12 checks passed
@rustbot rustbot added this to the 1.92.0 milestone Oct 19, 2025
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#138679 Issue-125323: ICE non-ADT in struct pattern when long time … 25137f3f668bc93feddaa31e773f81bdce6a6f45 (link)
#146490 Rehome 26 tests/ui/issues/ tests to other subdirectories … de1406e8b84af3ab0d84af83875a8519db237462 (link)
#147438 Rename "non-inline module" to "file module" in proc macro d… 7f5bd7af0255bb15e1e7d131bacdca51c1958a7b (link)
#147724 Fix ICE in pattern matching with generic const array length… e43a0c0d12fe07f86f870899a3b058e37771a8aa (link)
#147813 Warn on unused_attributes in uitests 903fe0d2d458639bfdc1b999994075435fb9a1eb (link)
#147816 Do not error out for download-rustc if LTO is configured 535d4679a27f11d23c89a9be707c845bf80c69a4 (link)
#147845 Add regression test for 134355 918f434ad96a21f6a915d53f4f26d69ebe762363 (link)

previous master: 6380899f32

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

Copy link
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 6380899 (parent) -> 377a931 (this PR)

Test differences

Show 231 test diffs

Stage 1

  • [crashes] tests/crashes/125323.rs: pass -> [missing] (J1)
  • [crashes] tests/crashes/139815.rs: pass -> [missing] (J1)
  • [ui] tests/ui/associated-types/ambiguous-associated-type-error-78622.rs: [missing] -> pass (J1)
  • [ui] tests/ui/associated-types/mismatched-types-in-associated-type-87490.rs: [missing] -> pass (J1)
  • [ui] tests/ui/attributes/invalid-attributes-on-const-params-78957.rs: pass -> [missing] (J1)
  • [ui] tests/ui/binding/invalid-assignment-in-while-77218.rs: [missing] -> pass (J1)
  • [ui] tests/ui/binding/invalid-assignment-in-while-loop-77218.rs: pass -> [missing] (J1)
  • [ui] tests/ui/borrowck/incorrect-use-after-storage-end-78192.rs: pass -> [missing] (J1)
  • [ui] tests/ui/coercion/index-coercion-over-indexmut-72002.rs: [missing] -> pass (J1)
  • [ui] tests/ui/const-generics/generic-const-array-pattern-ice-139815.rs: [missing] -> pass (J1)
  • [ui] tests/ui/const-generics/invalid-attributes-on-const-params-78957.rs: [missing] -> pass (J1)
  • [ui] tests/ui/consts/do-not-ice-long-constant-evaluation-in-for-loop.rs: [missing] -> pass (J1)
  • [ui] tests/ui/ffi/extern-static-mut-slice-54410.rs: [missing] -> pass (J1)
  • [ui] tests/ui/fmt/unicode-format-string-missing-parameter-70381.rs: [missing] -> pass (J1)
  • [ui] tests/ui/higher-ranked-trait-bounds/higher-trait-bounds-ice-60218.rs: [missing] -> pass (J1)
  • [ui] tests/ui/instrument-coverage/link-regex-crate-with-instrument-coverage-85461.rs: ignore (ignored when the profiler runtime is not available) -> [missing] (J1)
  • [ui] tests/ui/instrument-coverage/msvc-link-dead-code-inline-always-85461.rs: [missing] -> ignore (ignored when the profiler runtime is not available) (J1)
  • [ui] tests/ui/issues/issue-69455.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-69683.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-70381.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-70724-add_type_neq_err_label-unwrap.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-70746.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-71406.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-72002.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-72076.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-73112.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-73229.rs: pass -> [missing] (J1)
  • [ui] tests/ui/issues/issue-74082.rs: pass -> [missing] (J1)
  • [ui] tests/ui/lifetimes/late-bound-lifetime-arguments-warning-72278.rs: [missing] -> pass (J1)
  • [ui] tests/ui/mir/mir-cfg-unpretty-no-panic-81918.rs: [missing] -> pass (J1)
  • [ui] tests/ui/privacy/inaccessible-fields-pattern-matching-76077.rs: pass -> [missing] (J1)
  • [ui] tests/ui/privacy/inaccessible-private-fields-76077.rs: [missing] -> pass (J1)
  • [ui] tests/ui/proc-macro/inner-attr-file-mod.rs: [missing] -> pass (J1)
  • [ui] tests/ui/proc-macro/inner-attr-non-inline-mod.rs: pass -> [missing] (J1)
  • [ui] tests/ui/repr/invalid-repr-on-structs-74082.rs: [missing] -> pass (J1)
  • [ui] tests/ui/repr/packed-struct-contains-aligned-type-73112.rs: [missing] -> pass (J1)
  • [ui] tests/ui/resolve/function-module-ambiguity-error-71406.rs: [missing] -> pass (J1)
  • [ui] tests/ui/thir-print/break-outside-loop-error-83048.rs: pass -> [missing] (J1)
  • [ui] tests/ui/track-diagnostics/track-caller-for-once-87707.rs: pass -> [missing] (J1)
  • [ui] tests/ui/trait-bounds/invalid-bound-modifier-87199.rs: [missing] -> pass (J1)
  • [ui] tests/ui/trait-bounds/projection-predicate-not-satisfied-69455.rs: [missing] -> pass (J1)
  • [ui] tests/ui/trait-bounds/relaxed-bounds-assumed-unsized-87199.rs: pass -> [missing] (J1)
  • [ui] tests/ui/traits/callback-trait-implementation-73229.rs: [missing] -> pass (J1)
  • [ui] tests/ui/traits/duplicate-generic-parameter-error-86756.rs: [missing] -> pass (J1)
  • [ui] tests/ui/traits/trait-implementation-ambiguity-69602.rs: [missing] -> pass (J1)
  • [ui] tests/ui/typeck/return-unsized-coercion.rs: [missing] -> pass (J1)
  • [ui] tests/ui/unboxed-closures/callback-trait-prediction-70746.rs: [missing] -> pass (J1)
  • [ui] tests/ui/unpretty/thir-tree-break-outside-loop-83048.rs: [missing] -> pass (J1)

Stage 2

  • [ui] tests/ui/associated-consts/ambiguous-associated-type-error-78622.rs: pass -> [missing] (J0)
  • [ui] tests/ui/associated-types/ambiguous-associated-type-error-78622.rs: [missing] -> pass (J0)
  • [ui] tests/ui/associated-types/mismatched-types-in-associated-type-87490.rs: [missing] -> pass (J0)
  • [ui] tests/ui/associated-types/missing-default-associated-type-72076.rs: [missing] -> pass (J0)
  • [ui] tests/ui/attributes/invalid-attributes-on-const-params-78957.rs: pass -> [missing] (J0)
  • [ui] tests/ui/binding/invalid-assignment-in-while-loop-77218.rs: pass -> [missing] (J0)
  • [ui] tests/ui/binop/binary-operation-error-on-function-70724.rs: [missing] -> pass (J0)
  • [ui] tests/ui/borrowck/incorrect-use-after-storage-end-78192.rs: pass -> [missing] (J0)
  • [ui] tests/ui/borrowck/pointer-reassignment-after-deref-78192.rs: [missing] -> pass (J0)
  • [ui] tests/ui/coercion/index-coercion-over-indexmut-72002.rs: [missing] -> pass (J0)
  • [ui] tests/ui/const-generics/generic-const-array-pattern-ice-139815.rs: [missing] -> pass (J0)
  • [ui] tests/ui/const-generics/invalid-attributes-on-const-params-78957.rs: [missing] -> pass (J0)
  • [ui] tests/ui/consts/do-not-ice-long-constant-evaluation-in-for-loop.rs: [missing] -> pass (J0)
  • [ui] tests/ui/ffi/extern-static-mut-slice-54410.rs: [missing] -> pass (J0)
  • [ui] tests/ui/fmt/unicode-format-string-missing-parameter-70381.rs: [missing] -> pass (J0)
  • [ui] tests/ui/generics/duplicate-generic-parameter-error-86756.rs: pass -> [missing] (J0)
  • [ui] tests/ui/higher-ranked-trait-bounds/higher-trait-bounds-ice-60218.rs: [missing] -> pass (J0)
  • [ui] tests/ui/issues/issue-69455.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-70381.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-70724-add_type_neq_err_label-unwrap.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-70746.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-71406.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-72002.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-72076.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-72278.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-73112.rs: pass -> [missing] (J0)
  • [ui] tests/ui/issues/issue-74082.rs: pass -> [missing] (J0)
  • [ui] tests/ui/lifetimes/late-bound-lifetime-arguments-warning-72278.rs: [missing] -> pass (J0)
  • [ui] tests/ui/mir/mir-cfg-unpretty-check-81918.rs: pass -> [missing] (J0)
  • [ui] tests/ui/mir/mir-cfg-unpretty-no-panic-81918.rs: [missing] -> pass (J0)
  • [ui] tests/ui/mismatched_types/mismatched-types-in-trait-implementation-87490.rs: pass -> [missing] (J0)
  • [ui] tests/ui/pin/pin-deref-target-partial-eq-67039.rs: [missing] -> pass (J0)
  • [ui] tests/ui/privacy/inaccessible-fields-pattern-matching-76077.rs: pass -> [missing] (J0)
  • [ui] tests/ui/privacy/inaccessible-private-fields-76077.rs: [missing] -> pass (J0)
  • [ui] tests/ui/repr/packed-struct-contains-aligned-type-73112.rs: [missing] -> pass (J0)
  • [ui] tests/ui/sync/track-caller-for-once-87707.rs: [missing] -> pass (J0)
  • [ui] tests/ui/thread-local/thread-local-static-reference-70673.rs: [missing] -> pass (J0)
  • [ui] tests/ui/track-diagnostics/track-caller-for-once-87707.rs: pass -> [missing] (J0)
  • [ui] tests/ui/trait-bounds/invalid-bound-modifier-87199.rs: [missing] -> pass (J0)
  • [ui] tests/ui/trait-bounds/projection-predicate-not-satisfied-69455.rs: [missing] -> pass (J0)
  • [ui] tests/ui/trait-bounds/relaxed-bounds-assumed-unsized-87199.rs: pass -> [missing] (J0)
  • [ui] tests/ui/traits/duplicate-generic-parameter-error-86756.rs: [missing] -> pass (J0)
  • [ui] tests/ui/traits/trait-implementation-ambiguity-69602.rs: [missing] -> pass (J0)
  • [ui] tests/ui/typeck/return-unsized-coercion.rs: [missing] -> pass (J0)
  • [ui] tests/ui/typeck/type-inference-for-associated-types-69683.rs: [missing] -> pass (J0)
  • [ui] tests/ui/unboxed-closures/callback-trait-prediction-70746.rs: [missing] -> pass (J0)
  • [ui] tests/ui/unpretty/thir-tree-break-outside-loop-83048.rs: [missing] -> pass (J0)
  • [crashes] tests/crashes/125323.rs: pass -> [missing] (J2)
  • [crashes] tests/crashes/139815.rs: pass -> [missing] (J2)
  • [ui] tests/ui/instrument-coverage/link-regex-crate-with-instrument-coverage-85461.rs: pass -> [missing] (J3)
  • [ui] tests/ui/instrument-coverage/msvc-link-dead-code-inline-always-85461.rs: [missing] -> pass (J3)
  • [ui] tests/ui/instrument-coverage/msvc-link-dead-code-inline-always-85461.rs: [missing] -> ignore (ignored when the profiler runtime is not available) (J4)

(and 26 additional test diffs)

Additionally, 105 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 377a9310457f4e92d28fd0bef1fe9bfde47abe3b --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. dist-aarch64-linux: 9366.0s -> 6254.1s (-33.2%)
  2. dist-aarch64-apple: 5927.1s -> 6668.2s (12.5%)
  3. aarch64-gnu-llvm-20-2: 2565.0s -> 2274.4s (-11.3%)
  4. x86_64-gnu-aux: 7164.7s -> 6419.2s (-10.4%)
  5. x86_64-gnu-tools: 3618.7s -> 3249.4s (-10.2%)
  6. pr-check-1: 1596.0s -> 1433.3s (-10.2%)
  7. test-various: 4462.3s -> 4887.8s (9.5%)
  8. pr-check-2: 2351.0s -> 2521.8s (7.3%)
  9. x86_64-rust-for-linux: 2940.5s -> 2728.3s (-7.2%)
  10. dist-powerpc64-linux: 5457.1s -> 5100.8s (-6.5%)
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 (377a931): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

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

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

Binary size

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

Bootstrap: 471.955s -> 472.843s (0.19%)
Artifact size: 390.54 MiB -> 390.56 MiB (0.00%)

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. 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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants