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

Add array::map benchmarks #107915

Merged
merged 1 commit into from
Feb 13, 2023
Merged

Add array::map benchmarks #107915

merged 1 commit into from
Feb 13, 2023

Conversation

JulianKnodt
Copy link
Contributor

Since there were no previous benchmarks for array::map, and it is known to have mediocre/poor performance, add some simple benchmarks. These benchmarks vary the length of the array and size of each item.

@rustbot
Copy link
Collaborator

rustbot commented Feb 11, 2023

r? @Mark-Simulacrum

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Feb 11, 2023
@rustbot
Copy link
Collaborator

rustbot commented Feb 11, 2023

Hey! It looks like you've submitted a new PR for the library teams!

If this PR contains changes to any rust-lang/rust public library APIs then please comment with @rustbot label +T-libs-api -T-libs to tag it appropriately. If this PR contains changes to any unstable APIs please edit the PR description to add a link to the relevant API Change Proposal or create one if you haven't already. If you're unsure where your change falls no worries, just leave it as is and the reviewer will take a look and make a decision to forward on if necessary.

Examples of T-libs-api changes:

  • Stabilizing library features
  • Introducing insta-stable changes such as new implementations of existing stable traits on existing stable types
  • Introducing new or changing existing unstable library APIs (excluding permanently unstable features / features without a tracking issue)
  • Changing public documentation in ways that create new stability guarantees
  • Changing observable runtime behavior of library APIs

@JulianKnodt JulianKnodt changed the title Add array::map benchmarks Add array::map benchmarks Feb 11, 2023
@Mark-Simulacrum
Copy link
Member

Hm. I'm not opposed to these, but we may get better mileage out of codegen tests which can assert that LLVM did the right thing. Not sure if we have those today.

@bors r+

@bors
Copy link
Contributor

bors commented Feb 12, 2023

📌 Commit cbd1b81 has been approved by Mark-Simulacrum

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 Feb 12, 2023
@scottmcm
Copy link
Member

I have some codegen tests in my PR to make array::map less bad 🙂

https://github.com/rust-lang/rust/pull/107634/files#diff-b83fad8dc170d433a4e4aaa27de41f508c1ec8e854326fe815d779e70338080a

bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 13, 2023
Rollup of 7 pull requests

Successful merges:

 - rust-lang#107654 (reword descriptions of the deprecated int modules)
 - rust-lang#107915 (Add `array::map` benchmarks)
 - rust-lang#107961 (Avoid copy-pasting the `ilog` panic string in a bunch of places)
 - rust-lang#107962 (Add a doc note about why `Chain` is not `ExactSizeIterator`)
 - rust-lang#107966 (Update browser-ui-test version to 0.14.3)
 - rust-lang#107970 (Hermit: Remove floor symbol)
 - rust-lang#107973 (Fix unintentional UB in SIMD tests)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@JulianKnodt
Copy link
Contributor Author

I think it may be worth having both, as I think codegen is most practical and understandable of whether the generated code is performant or not, but in the end we'd still ultimately want to see wall clock time improvements.

@bors bors merged commit c0d1e32 into rust-lang:master Feb 13, 2023
@rustbot rustbot added this to the 1.69.0 milestone Feb 13, 2023
@JulianKnodt JulianKnodt deleted the array_benches branch February 13, 2023 20:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. 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.

5 participants