-
Notifications
You must be signed in to change notification settings - Fork 227
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
bench test with golang std ed25519 #200
Comments
CGo has high overhead compared to the time it takes to actually perform the cryptographic operations. See the “Why not cgo” section of this blog post: |
I had add a empty CGO call to my test project.It shows the cgo call only has lower overhead.you can review my project. the empty CGO call takes ~25ns on my laptap, ~50ns on my aws machine. the real work takes about 12611ns. the cgo call only takes about 0.2% time costs. the result:
and
|
hi, I run a the test between go crypto/ed25519(without cgo) vs ed25519-dalek: test Method:
for ed25519-dalek(1.0.1) run:
the result: case 1env:
ed25519-dalek's sign performance improvement: 43.91%; ed25519-dalek's verify performance improvement: 37.11%; case 2env:
reusult:
ed25519-dalek's sign performance improvement: 26.67%; ed25519-dalek's verify performance improvement: 22.77%; |
hi,
I want to use the project to my go project.
1. I wrappered the project with rust lib and generate a C header.
2. make a project to test the perfermance.
I got the result.
and
It seems the perfermance is not outstanding. Am I missing something?
my test project: https://github.com/giskook/ed25519_bench
The text was updated successfully, but these errors were encountered: