Skip to content

Conversation

@ehuss
Copy link
Contributor

@ehuss ehuss commented Oct 8, 2025

This adds a test for the cold attribute to verify that it actually does something, and that it applies correctly in all the positions it is expected to work.

@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 Oct 8, 2025
@rustbot
Copy link
Collaborator

rustbot commented Oct 8, 2025

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
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
Copy link
Member

@bors r=chenyukang

@bors
Copy link
Collaborator

bors commented Oct 8, 2025

📌 Commit 849feea has been approved by chenyukang

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 8, 2025
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Oct 8, 2025
…ukang

Add a test for the cold attribute

This adds a test for the cold attribute to verify that it actually does something, and that it applies correctly in all the positions it is expected to work.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Oct 8, 2025
…ukang

Add a test for the cold attribute

This adds a test for the cold attribute to verify that it actually does something, and that it applies correctly in all the positions it is expected to work.
bors added a commit that referenced this pull request Oct 8, 2025
Rollup of 6 pull requests

Successful merges:

 - #143900 ([rustdoc] Correctly handle `should_panic` doctest attribute and fix `--no-run` test flag on the 2024 edition)
 - #147420 (Add diagnostic items for `pub mod consts` of FP types)
 - #147467 (Fix double warnings on `#[no_mangle]`)
 - #147476 (Add a test for the cold attribute)
 - #147480 (Do not invalidate CFG caches in CtfeLimit.)
 - #147481 (format: some small cleanup)

r? `@ghost`
`@rustbot` modify labels: rollup
@chenyukang
Copy link
Member

@bors r-
seems failed for: #147492 (comment)

@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 Oct 9, 2025
This adds a test for the cold attribute to verify that it actually does
something, and that it applies correctly in all the positions it is
expected to work.
@ehuss ehuss force-pushed the cold-attribute-test branch from 849feea to 50e1884 Compare October 10, 2025 03:24
@ehuss
Copy link
Contributor Author

ehuss commented Oct 10, 2025

I was worried that the exact match could be a problem there. I have updated it to use CHECK-NOT which I think should be more robust, and tested that job in docker.

@ehuss
Copy link
Contributor Author

ehuss commented Oct 21, 2025

Ping @chenyukang, just wondering if you have any questions?

@chenyukang
Copy link
Member

sorry for the delay.

@bors r=chenyukang

@bors
Copy link
Collaborator

bors commented Oct 21, 2025

📌 Commit 50e1884 has been approved by chenyukang

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

bors commented Oct 21, 2025

⌛ Testing commit 50e1884 with merge cf8346d...

@bors
Copy link
Collaborator

bors commented Oct 21, 2025

☀️ Test successful - checks-actions
Approved by: chenyukang
Pushing cf8346d to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Oct 21, 2025
@bors bors merged commit cf8346d into rust-lang:master Oct 21, 2025
11 checks passed
@rustbot rustbot added this to the 1.92.0 milestone Oct 21, 2025
@github-actions
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 e821cb8 (parent) -> cf8346d (this PR)

Test differences

Show 4 test diffs

Stage 1

  • [codegen] tests/codegen-llvm/cold-attribute.rs: [missing] -> pass (J1)

Stage 2

  • [codegen] tests/codegen-llvm/cold-attribute.rs: [missing] -> pass (J0)

Additionally, 2 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 cf8346dd4ccb3514c8b48c6890297e16abafd814 --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: 7527.1s -> 8775.6s (16.6%)
  2. aarch64-apple: 7321.5s -> 8367.1s (14.3%)
  3. x86_64-msvc-ext2: 5602.5s -> 6168.5s (10.1%)
  4. x86_64-gnu-llvm-20-3: 5756.1s -> 6298.1s (9.4%)
  5. i686-msvc-1: 10406.0s -> 9537.7s (-8.3%)
  6. aarch64-gnu-debug: 4041.6s -> 3750.2s (-7.2%)
  7. x86_64-gnu-miri: 4392.7s -> 4094.8s (-6.8%)
  8. x86_64-mingw-2: 7834.5s -> 7314.8s (-6.6%)
  9. dist-powerpc64le-linux-musl: 5837.2s -> 5458.4s (-6.5%)
  10. dist-various-1: 3781.6s -> 4024.5s (6.4%)
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 (cf8346d): comparison URL.

Overall result: ✅ improvements - no action needed

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

Max RSS (memory usage)

Results (secondary 2.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)
4.0% [1.2%, 5.2%] 12
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.7% [-3.0%, -2.3%] 3
All ❌✅ (primary) - - 0

Cycles

Results (secondary -0.4%)

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.0% [1.8%, 9.0%] 6
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-4.4% [-9.5%, -1.9%] 8
All ❌✅ (primary) - - 0

Binary size

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

Bootstrap: 472.699s -> 472.752s (0.01%)
Artifact size: 390.70 MiB -> 388.66 MiB (-0.52%)

makai410 pushed a commit to makai410/rust that referenced this pull request Nov 8, 2025
Add a test for the cold attribute

This adds a test for the cold attribute to verify that it actually does something, and that it applies correctly in all the positions it is expected to work.
makai410 pushed a commit to makai410/rust that referenced this pull request Nov 10, 2025
Add a test for the cold attribute

This adds a test for the cold attribute to verify that it actually does something, and that it applies correctly in all the positions it is expected to work.
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