Repository navigation
Pseudo-Mersenne and Montgomery reductions - #2
Merged
Merged
Conversation
timohanke
commented
May 5, 2026
- Fast pseudo-Mersenne reduction modulo the secp256k1 prime
- 40% reduction in ECDSA verify on curve secp256k1
- Montgomery reduction for the prime256v1 (P-256) prime
- 20% reduction in ECDSA verify on curve prime256v1 (P-256)
The skill file is: https://github.com/research-ag/motoko-skills/tree/main/skills/code-improvements It is installed into the local repo via: npx skills add research-ag/motoko-skills
curve kind comparison was incorrect
The benches were transformed to the bench-helper approach with this skill file: https://github.com/research-ag/motoko-skills/tree/main/skills/benchmarks-generation The bench-helper with the "rountines" approach is generally the most precise. The new benches are also grouped and easier to read. The old bench had a bug in the deserialization numbers (FromBytes) because the serialization used to construct the input was part of the runner function and was therefore counted.
This was done with the skill file: https://github.com/research-ag/motoko-skills/blob/main/skills/doc-strings/SKILL.md This will report "Documentation: 100%" on mops.one
Allow more variations of newlines at the footer
as promised by the code comment
Fixed 1 file(s) based on 1 unresolved review comment. Co-authored-by: CodeRabbit <noreply@coderabbit.ai>
This reverts commit c468abe.
Author
|
@Gekctek Please consider merging this and releasing as a new version. |
Collaborator
|
Thank you once again |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.