Skip to content

Remove check_mod_loops query and run the checks per-body instead #141883

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 11, 2025

Conversation

oli-obk
Copy link
Contributor

@oli-obk oli-obk commented Jun 2, 2025

This analysis is older than my first rustc contribution I believe. It was never querified. Ideally we'd merge it into the analysis happening within typeck anyway (typeck just uses span_delayed_bug instead of erroring), but I didn't want to do that within this PR that also moves things around and subtly changes diagnostic ordering.

@rustbot
Copy link
Collaborator

rustbot commented Jun 2, 2025

r? @nnethercote

rustbot has assigned @nnethercote.
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

@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 Jun 2, 2025
@oli-obk
Copy link
Contributor Author

oli-obk commented Jun 2, 2025

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jun 2, 2025
@oli-obk
Copy link
Contributor Author

oli-obk commented Jun 2, 2025

@bors2 try @rust-timer queue

bors added a commit that referenced this pull request Jun 2, 2025
Remove check_mod_loops query and run the checks per-body instead

This analysis is older than my first rustc contribution I believe. It was never querified. Ideally we'd merge it into the analysis happening within typeck anyway (typeck just uses span_delayed_bug instead of erroring), but I didn't want to do that within this PR that also moves things around and subtly changes diagnostic ordering.
@bors
Copy link
Collaborator

bors commented Jun 2, 2025

⌛ Trying commit 12e39f2 with merge 4969ee0...

@rust-timer

This comment has been minimized.

@rust-bors
Copy link

rust-bors bot commented Jun 2, 2025

⌛ Trying commit 12e39f2 with merge 70deff4

rust-bors bot added a commit that referenced this pull request Jun 2, 2025
Remove check_mod_loops query and run the checks per-body instead

This analysis is older than my first rustc contribution I believe. It was never querified. Ideally we'd merge it into the analysis happening within typeck anyway (typeck just uses span_delayed_bug instead of erroring), but I didn't want to do that within this PR that also moves things around and subtly changes diagnostic ordering.
@rust-log-analyzer

This comment has been minimized.

@oli-obk oli-obk force-pushed the remove-check-mod-loops branch from 12e39f2 to d718532 Compare June 2, 2025 08:45
@rust-bors
Copy link

rust-bors bot commented Jun 2, 2025

☀️ Try build successful (CI)
Build commit: 70deff4 (70deff44501588bf26b8650f6e7b1b9c354fd45a)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (70deff4): comparison URL.

Overall result: ✅ improvements - no action needed

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf.

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

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.2% [0.2%, 0.2%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.6% [-1.2%, -0.2%] 14
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -1.2%, secondary -0.3%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
1.1% [0.4%, 3.2%] 8
Improvements ✅
(primary)
-1.2% [-1.2%, -1.2%] 1
Improvements ✅
(secondary)
-1.9% [-6.6%, -0.7%] 7
All ❌✅ (primary) -1.2% [-1.2%, -1.2%] 1

Cycles

Results (secondary -0.3%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.9% [0.4%, 1.4%] 7
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-1.1% [-2.8%, -0.4%] 11
All ❌✅ (primary) - - 0

Binary size

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

Bootstrap: 774.333s -> 774.617s (0.04%)
Artifact size: 372.28 MiB -> 371.80 MiB (-0.13%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jun 3, 2025
@nnethercote
Copy link
Contributor

@bors r+

@bors
Copy link
Collaborator

bors commented Jun 3, 2025

📌 Commit d718532 has been approved by nnethercote

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 Jun 3, 2025
@bors
Copy link
Collaborator

bors commented Jun 6, 2025

☔ The latest upstream changes (presumably #141774) made this pull request unmergeable. Please resolve the merge conflicts.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jun 6, 2025
@oli-obk oli-obk force-pushed the remove-check-mod-loops branch from d718532 to 7f4093e Compare June 10, 2025 09:38
@oli-obk
Copy link
Contributor Author

oli-obk commented Jun 10, 2025

@bors r=nnethercote

@bors
Copy link
Collaborator

bors commented Jun 10, 2025

📌 Commit 7f4093e has been approved by nnethercote

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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 10, 2025
@fmease
Copy link
Member

fmease commented Jun 10, 2025

@bors p=6 move it above the next rollup

@bors
Copy link
Collaborator

bors commented Jun 10, 2025

⌛ Testing commit 7f4093e with merge 1c04750...

@bors
Copy link
Collaborator

bors commented Jun 11, 2025

☀️ Test successful - checks-actions
Approved by: nnethercote
Pushing 1c04750 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 11, 2025
@bors bors merged commit 1c04750 into rust-lang:master Jun 11, 2025
11 checks passed
@rustbot rustbot added this to the 1.89.0 milestone Jun 11, 2025
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 1677d46 (parent) -> 1c04750 (this PR)

Test differences

Show 175 test diffs

Stage 1

  • errors::verify_hir_typeck_break_inside_closure_20: [missing] -> pass (J0)
  • errors::verify_hir_typeck_break_inside_coroutine_21: [missing] -> pass (J0)
  • errors::verify_hir_typeck_cast_enum_drop_20: pass -> [missing] (J0)
  • errors::verify_hir_typeck_cast_enum_drop_25: [missing] -> pass (J0)
  • errors::verify_hir_typeck_cast_thin_pointer_to_wide_pointer_27: [missing] -> pass (J0)
  • errors::verify_hir_typeck_continue_labeled_block_19: [missing] -> pass (J0)
  • errors::verify_hir_typeck_ctor_is_private_21: pass -> [missing] (J0)
  • errors::verify_hir_typeck_ctor_is_private_26: [missing] -> pass (J0)
  • errors::verify_hir_typeck_fn_item_to_variadic_function_29: [missing] -> pass (J0)
  • errors::verify_hir_typeck_naked_asm_outside_naked_fn_26: pass -> [missing] (J0)
  • errors::verify_hir_typeck_naked_asm_outside_naked_fn_31: [missing] -> pass (J0)
  • errors::verify_hir_typeck_naked_functions_must_naked_asm_29: pass -> [missing] (J0)
  • errors::verify_hir_typeck_no_associated_item_19: pass -> [missing] (J0)
  • errors::verify_hir_typeck_no_patterns_27: pass -> [missing] (J0)
  • errors::verify_hir_typeck_no_patterns_32: [missing] -> pass (J0)
  • errors::verify_hir_typeck_params_not_allowed_28: pass -> [missing] (J0)
  • errors::verify_hir_typeck_params_not_allowed_33: [missing] -> pass (J0)
  • errors::verify_hir_typeck_pass_to_variadic_function_23: pass -> [missing] (J0)
  • errors::verify_hir_typeck_pass_to_variadic_function_28: [missing] -> pass (J0)
  • errors::verify_hir_typeck_register_type_unstable_25: pass -> [missing] (J0)
  • errors::verify_hir_typeck_register_type_unstable_30: [missing] -> pass (J0)
  • errors::verify_hir_typeck_unlabeled_cf_in_while_condition_23: [missing] -> pass (J0)
  • errors::verify_hir_typeck_unlabeled_in_labeled_block_22: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_enum_137: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_enum_142: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_138: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_struct_143: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_enum_function_method_union_146: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_enum_union_140: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_struct_enum_union_145: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_union_144: pass -> [missing] (J0)
  • errors::verify_passes_attr_only_in_functions_128: [missing] -> pass (J0)
  • errors::verify_passes_attr_only_in_functions_133: pass -> [missing] (J0)
  • errors::verify_passes_break_inside_closure_128: pass -> [missing] (J0)
  • errors::verify_passes_break_inside_coroutine_129: pass -> [missing] (J0)
  • errors::verify_passes_cannot_stabilize_deprecated_145: [missing] -> pass (J0)
  • errors::verify_passes_cannot_stabilize_deprecated_150: pass -> [missing] (J0)
  • errors::verify_passes_const_stable_not_stable_154: [missing] -> pass (J0)
  • errors::verify_passes_const_stable_not_stable_159: pass -> [missing] (J0)
  • errors::verify_passes_continue_labeled_block_127: pass -> [missing] (J0)
  • errors::verify_passes_deprecated_attribute_143: [missing] -> pass (J0)
  • errors::verify_passes_deprecated_attribute_148: pass -> [missing] (J0)
  • errors::verify_passes_duplicate_feature_err_152: [missing] -> pass (J0)
  • errors::verify_passes_duplicate_feature_err_157: pass -> [missing] (J0)
  • errors::verify_passes_extern_main_135: pass -> [missing] (J0)
  • errors::verify_passes_implied_feature_not_exist_151: [missing] -> pass (J0)
  • errors::verify_passes_implied_feature_not_exist_156: pass -> [missing] (J0)
  • errors::verify_passes_incorrect_crate_type_132: [missing] -> pass (J0)
  • errors::verify_passes_incorrect_crate_type_137: pass -> [missing] (J0)
  • errors::verify_passes_incorrect_target_131: [missing] -> pass (J0)
  • errors::verify_passes_ineffective_unstable_impl_167: pass -> [missing] (J0)
  • errors::verify_passes_inline_ignored_for_exported_140: pass -> [missing] (J0)
  • errors::verify_passes_missing_const_err_153: [missing] -> pass (J0)
  • errors::verify_passes_missing_const_err_158: pass -> [missing] (J0)
  • errors::verify_passes_missing_const_stab_attr_148: [missing] -> pass (J0)
  • errors::verify_passes_missing_const_stab_attr_153: pass -> [missing] (J0)
  • errors::verify_passes_missing_stability_attr_147: [missing] -> pass (J0)
  • errors::verify_passes_missing_stability_attr_152: pass -> [missing] (J0)
  • errors::verify_passes_multiple_rustc_main_129: [missing] -> pass (J0)
  • errors::verify_passes_naked_functions_incompatible_attribute_127: [missing] -> pass (J0)
  • errors::verify_passes_no_sanitize_164: [missing] -> pass (J0)
  • errors::verify_passes_no_sanitize_169: pass -> [missing] (J0)
  • errors::verify_passes_object_lifetime_err_136: [missing] -> pass (J0)
  • errors::verify_passes_object_lifetime_err_141: pass -> [missing] (J0)
  • errors::verify_passes_only_has_effect_on_134: [missing] -> pass (J0)
  • errors::verify_passes_only_has_effect_on_139: pass -> [missing] (J0)
  • errors::verify_passes_rustc_const_stable_indirect_pairing_170: pass -> [missing] (J0)
  • errors::verify_passes_trait_impl_const_stable_149: [missing] -> pass (J0)
  • errors::verify_passes_trait_impl_const_stable_154: pass -> [missing] (J0)
  • errors::verify_passes_transparent_incompatible_147: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_adt_with_private_fields_173: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_adt_with_private_fields_178: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_fn_abi_169: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_fn_abi_174: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_generic_fn_168: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_generic_fn_173: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_item_167: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_item_172: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_priv_item_172: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_priv_item_177: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_type_repr_175: pass -> [missing] (J0)
  • errors::verify_passes_unknown_feature_150: [missing] -> pass (J0)
  • errors::verify_passes_unknown_feature_155: pass -> [missing] (J0)
  • errors::verify_passes_unlabeled_cf_in_while_condition_131: pass -> [missing] (J0)
  • errors::verify_passes_unlabeled_in_labeled_block_130: pass -> [missing] (J0)
  • errors::verify_passes_unnecessary_stable_feature_160: [missing] -> pass (J0)
  • errors::verify_passes_unreachable_due_to_uninhabited_156: [missing] -> pass (J0)
  • errors::verify_passes_unreachable_due_to_uninhabited_161: pass -> [missing] (J0)
  • errors::verify_passes_unstable_attr_for_already_stable_feature_146: [missing] -> pass (J0)
  • errors::verify_passes_unsupported_attributes_in_where_166: [missing] -> pass (J0)
  • errors::verify_passes_unused_assign_passed_163: [missing] -> pass (J0)
  • errors::verify_passes_unused_assign_passed_168: pass -> [missing] (J0)
  • errors::verify_passes_unused_capture_maybe_capture_ref_158: [missing] -> pass (J0)
  • errors::verify_passes_unused_var_assigned_only_159: [missing] -> pass (J0)
  • errors::verify_passes_unused_var_maybe_capture_ref_157: [missing] -> pass (J0)
  • errors::verify_passes_unused_var_maybe_capture_ref_162: pass -> [missing] (J0)
  • errors::verify_passes_useless_assignment_133: [missing] -> pass (J0)
  • errors::verify_passes_useless_assignment_138: pass -> [missing] (J0)
  • errors::verify_passes_useless_stability_144: [missing] -> pass (J0)
  • errors::verify_passes_useless_stability_149: pass -> [missing] (J0)

(and 26 additional test diffs)

Additionally, 49 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 1c047506f94cd2d05228eb992b0a6bbed1942349 --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-apple: 5385.4s -> 6303.5s (17.0%)
  2. mingw-check-tidy: 66.1s -> 75.9s (14.9%)
  3. x86_64-rust-for-linux: 2581.5s -> 2922.1s (13.2%)
  4. dist-apple-various: 7066.4s -> 7994.5s (13.1%)
  5. x86_64-gnu-llvm-19-1: 3212.7s -> 3627.6s (12.9%)
  6. i686-gnu-2: 5416.3s -> 6032.3s (11.4%)
  7. i686-gnu-nopt-1: 7119.2s -> 7908.7s (11.1%)
  8. x86_64-gnu-llvm-20-1: 3185.7s -> 3508.9s (10.1%)
  9. x86_64-gnu-debug: 5375.4s -> 5904.6s (9.8%)
  10. mingw-check-1: 1683.9s -> 1835.7s (9.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
Collaborator

Finished benchmarking commit (1c04750): 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
Regressions ❌
(secondary)
0.2% [0.2%, 0.3%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.3% [-0.4%, -0.2%] 8
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -1.6%, secondary -1.7%)

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)
2.1% [1.0%, 3.2%] 2
Improvements ✅
(primary)
-1.6% [-1.6%, -1.6%] 1
Improvements ✅
(secondary)
-4.3% [-8.7%, -1.0%] 3
All ❌✅ (primary) -1.6% [-1.6%, -1.6%] 1

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: 755.082s -> 756.123s (0.14%)
Artifact size: 372.15 MiB -> 372.14 MiB (-0.00%)

@rustbot rustbot added the perf-regression Performance regression. label Jun 11, 2025
@oli-obk oli-obk deleted the remove-check-mod-loops branch June 11, 2025 08:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. 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.

7 participants