Skip to content

Deferred Montgomery reductions - #20

Open
ebfull wants to merge 2 commits into
mainfrom
deferred-reductions
Open

Deferred Montgomery reductions#20
ebfull wants to merge 2 commits into
mainfrom
deferred-reductions

Conversation

@ebfull

@ebfull ebfull commented Nov 22, 2019

Copy link
Copy Markdown
Contributor

Closes #3.

There are some places in the curve arithmetic where this could help also, I haven't exhaustively looked yet.

Comment thread src/fp.rs
/// Negates an element of magnitude 1 by subtracting it from a multiple of
/// the prime that is larger than this element could be (p^2), increasing
/// the magnitude by 1.
pub const fn negate(&self) -> FpWide {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be called negate_u1. (I would use a generic, but it's not stable in Rust yet for const functions...)

@ebfull
ebfull changed the base branch from master to main September 8, 2020 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement deferred Montgomery reduction

1 participant