-
Notifications
You must be signed in to change notification settings - Fork 147
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 the dettman square operation #1576
Conversation
I benchmarked the generated C implementation for square using the tools in https://github.com/bitcoin-core/secp256k1/. It's significantly faster than the mul operation, which is reassuring. I wasn't able to discern a significant difference between the performance of the generated C implementation vs. that of the handwritten assembly version. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Here are a couple suggestions that I think will make the organization slightly cleaner
What's up with the
errors? (Does the branch just need to be rebased, or is something bigger going on?) |
I don't know what could've caused that. |
c806b12
to
dfc64fa
Compare
Seems to be failing on master now? https://github.com/mit-plv/fiat-crypto/actions/workflows/docker-coq.yml?query=branch%3Amaster |
Turns out that the squaring algorithm is essentially identical to the multiplication algorithm. To transform the mul function into the square function, I just had to replace
Associational.mul
withAssociational.square
.