-
Notifications
You must be signed in to change notification settings - Fork 719
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 <[T]>::clone_from_slice()
.
#140
Conversation
Replace all occurences of `ring::polyfill::fill_from_slice`. Closes #136
What was the difference in performance (using crypto_bench)? |
Not yet testet. Are there benchmarks for |
https://github.com/briansmith/crypto-bench. You'll need to use a .cargo/config that contains a path override so that your local copy of ring is used instead of the one from GitHub when doing the "after" comparisons. |
The benchmarks show that |
The thing is, all your results are faster, even ones that shouldn't be affected by this change like the AES-GCM results. When I run the benchmarks with your changes on my machine, I don't get results consistent with that. We need to check out the generated assembly code and see what's going on. |
I used the following code on play.rust-lang.org to verify that the old code and the new code seem to optimize to the same thing:
|
Thanks! Landed in 7cdaeeb. |
Actually landed in 43af354. |
Replace all occurences of
ring::polyfill::fill_from_slice
.Closes #136