Skip to content

Change per-module naked fn checks to happen during typeck instead #141774

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 6, 2025

Conversation

oli-obk
Copy link
Contributor

@oli-obk oli-obk commented May 30, 2025

cc @Lokathor @Amanieu @folkertdev

just seems nicer this way

@rustbot
Copy link
Collaborator

rustbot commented May 30, 2025

r? @petrochenkov

rustbot has assigned @petrochenkov.
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 May 30, 2025
@oli-obk
Copy link
Contributor Author

oli-obk commented May 30, 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 May 30, 2025
@rust-log-analyzer

This comment has been minimized.

@oli-obk oli-obk force-pushed the naked-fn-queries branch from b45bba1 to 02e2766 Compare May 30, 2025 16:08
@petrochenkov
Copy link
Contributor

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@petrochenkov petrochenkov removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 31, 2025
@oli-obk
Copy link
Contributor Author

oli-obk commented Jun 2, 2025

@bors2 try @rust-timer queue

@rust-timer

This comment has been minimized.

@rust-bors
Copy link

rust-bors bot commented Jun 2, 2025

⌛ Trying commit 02e2766 with merge 55ef540

rust-bors bot added a commit that referenced this pull request Jun 2, 2025
Change per-module naked fn checks to happen during typeck instead

cc `@Lokathor` `@Amanieu` `@folkertdev`

just seems nicer this way
@rust-bors
Copy link

rust-bors bot commented Jun 2, 2025

☀️ Try build successful (CI)
Build commit: 55ef540 (55ef5407fba09550587d2a224a32fde19b7202d5)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (55ef540): 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
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.6% [-1.3%, -0.2%] 16
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -2.4%, secondary -2.2%)

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)
1.4% [1.4%, 1.4%] 1
Regressions ❌
(secondary)
0.7% [0.5%, 1.0%] 5
Improvements ✅
(primary)
-2.7% [-4.6%, -1.1%] 14
Improvements ✅
(secondary)
-2.4% [-4.3%, -0.4%] 75
All ❌✅ (primary) -2.4% [-4.6%, 1.4%] 15

Cycles

Results (secondary -0.2%)

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.6% [0.5%, 0.7%] 5
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.8% [-1.8%, -0.4%] 8
All ❌✅ (primary) - - 0

Binary size

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

Bootstrap: 774.333s -> 775.253s (0.12%)
Artifact size: 372.28 MiB -> 371.78 MiB (-0.13%)

@rustbot rustbot removed 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

Yay?!

@oli-obk oli-obk added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jun 2, 2025
@petrochenkov
Copy link
Contributor

@bors r+

@petrochenkov
Copy link
Contributor

Hmm, this PR is not in the bors queue at all.

@petrochenkov petrochenkov reopened this Jun 3, 2025
@petrochenkov
Copy link
Contributor

@bors r+

@bors
Copy link
Collaborator

bors commented Jun 3, 2025

📌 Commit 02e2766 has been approved by petrochenkov

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

⌛ Testing commit 02e2766 with merge 44f415c...

@bors
Copy link
Collaborator

bors commented Jun 6, 2025

☀️ Test successful - checks-actions
Approved by: petrochenkov
Pushing 44f415c to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 6, 2025
@bors bors merged commit 44f415c into rust-lang:master Jun 6, 2025
19 checks passed
@rustbot rustbot added this to the 1.89.0 milestone Jun 6, 2025
Copy link
Contributor

github-actions bot commented Jun 6, 2025

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 9f0e5d9 (parent) -> 44f415c (this PR)

Test differences

Show 151 test diffs

Stage 1

  • errors::verify_hir_typeck_naked_asm_outside_naked_fn_26: [missing] -> pass (J0)
  • errors::verify_hir_typeck_naked_functions_must_naked_asm_29: [missing] -> pass (J0)
  • errors::verify_hir_typeck_no_patterns_27: [missing] -> pass (J0)
  • errors::verify_hir_typeck_params_not_allowed_28: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_enum_142: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_enum_146: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_143: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_struct_147: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_enum_function_method_union_146: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_struct_enum_function_method_union_150: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_enum_union_145: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_struct_enum_union_149: pass -> [missing] (J0)
  • errors::verify_passes_attr_application_struct_union_144: [missing] -> pass (J0)
  • errors::verify_passes_attr_application_struct_union_148: pass -> [missing] (J0)
  • errors::verify_passes_attr_only_in_functions_133: [missing] -> pass (J0)
  • errors::verify_passes_attr_only_in_functions_137: pass -> [missing] (J0)
  • errors::verify_passes_cannot_stabilize_deprecated_150: [missing] -> pass (J0)
  • errors::verify_passes_cannot_stabilize_deprecated_154: pass -> [missing] (J0)
  • errors::verify_passes_const_stable_not_stable_159: [missing] -> pass (J0)
  • errors::verify_passes_const_stable_not_stable_163: pass -> [missing] (J0)
  • errors::verify_passes_deprecated_attribute_148: [missing] -> pass (J0)
  • errors::verify_passes_deprecated_attribute_152: pass -> [missing] (J0)
  • errors::verify_passes_duplicate_feature_err_157: [missing] -> pass (J0)
  • errors::verify_passes_duplicate_feature_err_161: pass -> [missing] (J0)
  • errors::verify_passes_extern_main_135: [missing] -> pass (J0)
  • errors::verify_passes_extern_main_139: pass -> [missing] (J0)
  • errors::verify_passes_implied_feature_not_exist_156: [missing] -> pass (J0)
  • errors::verify_passes_implied_feature_not_exist_160: pass -> [missing] (J0)
  • errors::verify_passes_incorrect_crate_type_137: [missing] -> pass (J0)
  • errors::verify_passes_incorrect_crate_type_141: pass -> [missing] (J0)
  • errors::verify_passes_incorrect_target_136: [missing] -> pass (J0)
  • errors::verify_passes_incorrect_target_140: pass -> [missing] (J0)
  • errors::verify_passes_ineffective_unstable_impl_167: [missing] -> pass (J0)
  • errors::verify_passes_ineffective_unstable_impl_171: pass -> [missing] (J0)
  • errors::verify_passes_inline_ignored_for_exported_140: [missing] -> pass (J0)
  • errors::verify_passes_inline_ignored_for_exported_144: pass -> [missing] (J0)
  • errors::verify_passes_missing_const_err_158: [missing] -> pass (J0)
  • errors::verify_passes_missing_const_err_162: pass -> [missing] (J0)
  • errors::verify_passes_missing_const_stab_attr_153: [missing] -> pass (J0)
  • errors::verify_passes_missing_const_stab_attr_157: pass -> [missing] (J0)
  • errors::verify_passes_missing_stability_attr_152: [missing] -> pass (J0)
  • errors::verify_passes_missing_stability_attr_156: pass -> [missing] (J0)
  • errors::verify_passes_multiple_rustc_main_134: [missing] -> pass (J0)
  • errors::verify_passes_multiple_rustc_main_138: pass -> [missing] (J0)
  • errors::verify_passes_naked_asm_outside_naked_fn_136: pass -> [missing] (J0)
  • errors::verify_passes_naked_functions_incompatible_attribute_132: [missing] -> pass (J0)
  • errors::verify_passes_naked_functions_incompatible_attribute_135: pass -> [missing] (J0)
  • errors::verify_passes_naked_functions_must_naked_asm_134: pass -> [missing] (J0)
  • errors::verify_passes_no_patterns_132: pass -> [missing] (J0)
  • errors::verify_passes_no_sanitize_169: [missing] -> pass (J0)
  • errors::verify_passes_no_sanitize_173: pass -> [missing] (J0)
  • errors::verify_passes_object_lifetime_err_141: [missing] -> pass (J0)
  • errors::verify_passes_object_lifetime_err_145: pass -> [missing] (J0)
  • errors::verify_passes_only_has_effect_on_139: [missing] -> pass (J0)
  • errors::verify_passes_only_has_effect_on_143: pass -> [missing] (J0)
  • errors::verify_passes_params_not_allowed_133: pass -> [missing] (J0)
  • errors::verify_passes_proc_macro_bad_sig_160: [missing] -> pass (J0)
  • errors::verify_passes_proc_macro_bad_sig_164: pass -> [missing] (J0)
  • errors::verify_passes_rustc_const_stable_indirect_pairing_170: [missing] -> pass (J0)
  • errors::verify_passes_rustc_const_stable_indirect_pairing_174: pass -> [missing] (J0)
  • errors::verify_passes_trait_impl_const_stable_154: [missing] -> pass (J0)
  • errors::verify_passes_trait_impl_const_stable_158: pass -> [missing] (J0)
  • errors::verify_passes_transparent_incompatible_147: [missing] -> pass (J0)
  • errors::verify_passes_transparent_incompatible_151: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_adt_with_private_fields_178: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_adt_with_private_fields_182: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_fn_abi_174: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_generic_fn_173: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_generic_fn_177: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_item_172: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_item_176: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_priv_item_177: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_priv_item_181: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_type_in_interface_176: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_type_in_interface_180: pass -> [missing] (J0)
  • errors::verify_passes_unexportable_type_repr_175: [missing] -> pass (J0)
  • errors::verify_passes_unexportable_type_repr_179: pass -> [missing] (J0)
  • errors::verify_passes_unknown_feature_155: [missing] -> pass (J0)
  • errors::verify_passes_unknown_feature_159: pass -> [missing] (J0)
  • errors::verify_passes_unnecessary_partial_stable_feature_166: [missing] -> pass (J0)
  • errors::verify_passes_unnecessary_partial_stable_feature_170: pass -> [missing] (J0)
  • errors::verify_passes_unnecessary_stable_feature_165: [missing] -> pass (J0)
  • errors::verify_passes_unnecessary_stable_feature_169: pass -> [missing] (J0)
  • errors::verify_passes_unreachable_due_to_uninhabited_161: [missing] -> pass (J0)
  • errors::verify_passes_unreachable_due_to_uninhabited_165: pass -> [missing] (J0)
  • errors::verify_passes_unstable_attr_for_already_stable_feature_155: pass -> [missing] (J0)
  • errors::verify_passes_unsupported_attributes_in_where_171: [missing] -> pass (J0)
  • errors::verify_passes_unsupported_attributes_in_where_175: pass -> [missing] (J0)
  • errors::verify_passes_unused_assign_passed_168: [missing] -> pass (J0)
  • errors::verify_passes_unused_assign_passed_172: pass -> [missing] (J0)
  • errors::verify_passes_unused_capture_maybe_capture_ref_163: [missing] -> pass (J0)
  • errors::verify_passes_unused_capture_maybe_capture_ref_167: pass -> [missing] (J0)
  • errors::verify_passes_unused_var_assigned_only_164: [missing] -> pass (J0)
  • errors::verify_passes_unused_var_assigned_only_168: pass -> [missing] (J0)
  • errors::verify_passes_unused_var_maybe_capture_ref_162: [missing] -> pass (J0)
  • errors::verify_passes_unused_var_maybe_capture_ref_166: pass -> [missing] (J0)
  • errors::verify_passes_useless_assignment_138: [missing] -> pass (J0)
  • errors::verify_passes_useless_assignment_142: pass -> [missing] (J0)
  • errors::verify_passes_useless_stability_149: [missing] -> pass (J0)
  • errors::verify_passes_useless_stability_153: pass -> [missing] (J0)

(and 2 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 44f415c1d617ebc7b931a243b7b321ef8a6ca47c --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. x86_64-apple-1: 6827.2s -> 9697.9s (42.0%)
  2. dist-aarch64-apple: 5990.1s -> 4680.0s (-21.9%)
  3. mingw-check-1: 1618.1s -> 1898.4s (17.3%)
  4. dist-apple-various: 6565.9s -> 5844.1s (-11.0%)
  5. dist-ohos-armv7: 4314.7s -> 3865.0s (-10.4%)
  6. x86_64-apple-2: 4723.3s -> 5212.7s (10.4%)
  7. dist-ohos-aarch64: 4557.0s -> 4118.2s (-9.6%)
  8. dist-powerpc-linux: 5294.1s -> 4804.5s (-9.2%)
  9. dist-arm-linux-gnueabi: 5002.1s -> 4550.9s (-9.0%)
  10. x86_64-rust-for-linux: 2729.9s -> 2947.4s (8.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 (44f415c): comparison URL.

Overall result: ✅ improvements - no action needed

@rustbot label: -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
Improvements ✅
(primary)
-0.1% [-0.1%, -0.1%] 11
Improvements ✅
(secondary)
-0.3% [-0.4%, -0.2%] 11
All ❌✅ (primary) -0.1% [-0.1%, -0.1%] 11

Max RSS (memory usage)

Results (primary 0.4%, secondary 1.5%)

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)
2.2% [2.2%, 2.2%] 1
Regressions ❌
(secondary)
1.5% [0.7%, 3.1%] 5
Improvements ✅
(primary)
-1.3% [-1.3%, -1.3%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.4% [-1.3%, 2.2%] 2

Cycles

Results (primary 1.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)
1.3% [1.0%, 1.7%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.3% [1.0%, 1.7%] 2

Binary size

Results (secondary -0.0%)

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

Bootstrap: 751.346s -> 752.053s (0.09%)
Artifact size: 372.49 MiB -> 372.47 MiB (-0.01%)

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

6 participants