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

Use llvm.memset.p0i8.* to initialize all same-bytes arrays #135258

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

oli-obk
Copy link
Contributor

@oli-obk oli-obk commented Jan 8, 2025

It doesn't affect tests, LLVM seems smart enough for it, but then I wonder why we have the zero case at all (it was introduced in #43488, maybe LLVM wasn't smart enough then). So let's run perf to see if there's any build time effect, and if no, I'll remove the zero special case and also run perf.

@rustbot
Copy link
Collaborator

rustbot commented Jan 8, 2025

r? @saethlin

rustbot has assigned @saethlin.
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 Jan 8, 2025
@oli-obk
Copy link
Contributor Author

oli-obk commented Jan 8, 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 Jan 8, 2025
@oli-obk oli-obk force-pushed the push-ktzskvxuwnlt branch from 32099f0 to bed8b95 Compare January 8, 2025 15:44
@rust-log-analyzer

This comment has been minimized.

@oli-obk oli-obk force-pushed the push-ktzskvxuwnlt branch from bed8b95 to 3ca023e Compare January 8, 2025 16:56
@oli-obk
Copy link
Contributor Author

oli-obk commented Jan 8, 2025

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Jan 8, 2025

⌛ Trying commit 3ca023e with merge 7ed3665...

bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 8, 2025
Use llvm.memset.p0i8.* to initialize all same-bytes arrays

It doesn't affect tests, LLVM seems smart enough for it, but then I wonder why we have the zero case at all (it was introduced in rust-lang#43488, maybe LLVM wasn't smart enough then). So let's run perf to see if there's any build time effect, and if no, I'll remove the zero special case and also run perf.
@bors
Copy link
Contributor

bors commented Jan 8, 2025

☀️ Try build successful - checks-actions
Build commit: 7ed3665 (7ed366534d90da69be91456384caf3738966680a)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (7ed3665): comparison URL.

Overall result: ❌ regressions - 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.3% [0.3%, 0.3%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary 5.2%, secondary -2.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)
5.2% [2.0%, 8.3%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.5% [-2.5%, -2.5%] 1
All ❌✅ (primary) 5.2% [2.0%, 8.3%] 2

Cycles

Results (primary -1.9%, secondary -3.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
Improvements ✅
(primary)
-1.9% [-3.4%, -0.6%] 12
Improvements ✅
(secondary)
-3.3% [-3.8%, -2.2%] 3
All ❌✅ (primary) -1.9% [-3.4%, -0.6%] 12

Binary size

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

Bootstrap: 763.722s -> 763.396s (-0.04%)
Artifact size: 325.68 MiB -> 325.71 MiB (0.01%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 8, 2025
@oli-obk oli-obk force-pushed the push-ktzskvxuwnlt branch from 3ca023e to 45070ce Compare January 9, 2025 09:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants