Skip to content
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

Rollup of 7 pull requests #124675

Merged
merged 17 commits into from
May 3, 2024
Merged

Rollup of 7 pull requests #124675

merged 17 commits into from
May 3, 2024

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

GrigorenkoPV and others added 17 commits March 14, 2024 16:01
Because this now always takes place at the start of the function, we can just
use the normal `alloca` method and then initialize each bitmap immediately.

This patch also moves bitmap setup out of the `mcdc_parameters` method, because
there is no longer any particular reason for it to be there.
This clearly distinguishes individual decision-depth indices from the total
number of condition bitmaps to allocate.
… r=workingjubilee

Implement ptr_as_ref_unchecked

Implementation of rust-lang#122034.

Prefixed the feature name with `ptr_` for clarity.

Linked const-unstability to rust-lang#91822, so the post there should probably be updated to mentions the 3 new methods when/if this PR is merged.
Fix cannot usage in time.rs

Fix a small grammar error in usage of cannot in time.rs errors
… r=workingjubilee

default_alloc_error_hook: explain difference to default __rdl_oom in alloc

Though I'm not sure if that is really the reason that this code is duplicated. On no_std it may already be possible to call user-defined code on allocation failure.
…ion, r=fmease

Add raw identifier in a typo suggestion

Fixes rust-lang#68962
coverage: Clean up creation of MC/DC condition bitmaps

This PR improves the code for creating and initializing [MC/DC](https://en.wikipedia.org/wiki/Modified_condition/decision_coverage) condition bitmap variables, as introduced by rust-lang#123409 and modified by rust-lang#124255.

- The condition bitmap variables are now created eagerly at the start of per-function codegen, via a new `init_coverage` method in `CoverageInfoBuilderMethods`. This avoids having to retroactively create the bitmaps while doing codegen for an individual coverage statement.
- As a result, we can now create and initialize those bitmaps using existing safe APIs, instead of having to perform our own unsafe call to `llvm::LLVMBuildAlloca`.
- This PR also tweaks the way we count the number of condition bitmaps needed, by tracking the total number of bitmaps needed (max depth + 1), instead of only tracking the maximum depth. This reduces the potential for subtle off-by-one confusion.
…workingjubilee

Describe and use CStr literals in CStr and CString docs

Mention CStr literals in the description of both types, and use them in some of the code samples for CStr. This is intended to make C string literals more discoverable.

Additionally, I don't think the orange "This example is not tested" warnings are very encouraging, so I have made the examples on `CStr` build.
CI: remove `env-x86_64-apple-tests` YAML anchor

This PR removes the only remaining anchor in the definition of CI jobs. This anchor made it annoying to copy-paste the job e.g. to PR CI.

Fixes: https://rust-lang.zulipchat.com/#narrow/stream/242791-t-infra/topic/How.20do.20you.20edit.20PR.20CI.20to.20test.20PR.20now.3F

r? ``@pietroalbini``
@rustbot rustbot added 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-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels May 3, 2024
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=7

@bors
Copy link
Contributor

bors commented May 3, 2024

📌 Commit 56b2989 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 May 3, 2024
@bors
Copy link
Contributor

bors commented May 3, 2024

⌛ Testing commit 56b2989 with merge befabbc...

@bors
Copy link
Contributor

bors commented May 3, 2024

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

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label May 3, 2024
@bors bors merged commit befabbc into rust-lang:master May 3, 2024
7 checks passed
@rustbot rustbot added this to the 1.80.0 milestone May 3, 2024
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#122492 Implement ptr_as_ref_unchecked 2e596f517823cf964bb95d64e79ec793a86a26a7 (link)
#123815 Fix cannot usage in time.rs 5b26ff3327b6de021502e8a4e23e4eb0d950bdfc (link)
#124059 default_alloc_error_hook: explain difference to default __r… b808ab5da86c3a0ca264a10afefae76fe47d812b (link)
#124510 Add raw identifier in a typo suggestion b8c2085dce07c3203d3f3c3dd356be3eb66ea62f (link)
#124555 coverage: Clean up creation of MC/DC condition bitmaps 02c0a6ac42c3197c678674719facd9405bde3e43 (link)
#124593 Describe and use CStr literals in CStr and CString docs 8f7bc815b32cadf933a1ab088d4f00af09cfb389 (link)
#124630 CI: remove env-x86_64-apple-tests YAML anchor 79eff908a2a8be35ab1a16cf8f3efa15a6c85bd0 (link)

previous master: 0d7b2fb797

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

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (befabbc): comparison URL.

Overall result: ❌ regressions - ACTION NEEDED

Next Steps: If you can justify the regressions found in this perf run, please indicate this with @rustbot label: +perf-regression-triaged along with sufficient written justification. If you cannot justify the regressions please open an issue or create a new PR that fixes the regressions, add a comment linking to the newly created issue or PR, and then add the perf-regression-triaged label to this PR.

@rustbot label: +perf-regression
cc @rust-lang/wg-compiler-performance

Instruction count

This is a highly reliable metric that was used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
0.5% [0.2%, 1.2%] 11
Regressions ❌
(secondary)
0.8% [0.4%, 1.3%] 17
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.5% [0.2%, 1.2%] 11

Max RSS (memory usage)

Results

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)
4.0% [3.2%, 4.9%] 2
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

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: 675.47s -> 674.658s (-0.12%)
Artifact size: 315.93 MiB -> 315.94 MiB (0.00%)

@rustbot rustbot added the perf-regression Performance regression. label May 3, 2024
@Kobzol
Copy link
Contributor

Kobzol commented May 4, 2024

@rust-timer build 2e596f5

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (2e596f5): comparison URL.

Overall result: no relevant changes - no action needed

Instruction count

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

Max RSS (memory usage)

Results

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

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: 675.47s -> 676.68s (0.18%)
Artifact size: 315.93 MiB -> 315.86 MiB (-0.02%)

@lqd
Copy link
Member

lqd commented May 4, 2024

@rust-timer build 8f7bc81

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (8f7bc81): comparison URL.

Overall result: ❌ regressions - ACTION NEEDED

Instruction count

This is a highly reliable metric that was used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
0.5% [0.2%, 1.4%] 11
Regressions ❌
(secondary)
0.8% [0.2%, 1.2%] 18
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.5% [0.2%, 1.4%] 11

Max RSS (memory usage)

Results

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

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: 675.47s -> 676.61s (0.17%)
Artifact size: 315.93 MiB -> 315.94 MiB (0.00%)

@Kobzol
Copy link
Contributor

Kobzol commented May 5, 2024

Looks like #124593 is the "culprit". I'm not sure if there's anything to investigate though, since only docs were modified in that PR.

@pnkfelix
Copy link
Member

pnkfelix commented May 7, 2024

Agree with @Kobzol. Marking as triaged.

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label May 7, 2024
@matthiaskrgr matthiaskrgr deleted the rollup-x6n79ua branch September 1, 2024 17:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-testsuite Area: The testsuite used to check the correctness of rustc merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. perf-regression-triaged The performance regression has been triaged. 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-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.