Skip to content

Halve() instead of Multiplication by 1/2#81

Merged
gbotrel merged 4 commits into
developfrom
ML/DoubleStep-Halve
Oct 18, 2021
Merged

Halve() instead of Multiplication by 1/2#81
gbotrel merged 4 commits into
developfrom
ML/DoubleStep-Halve

Conversation

@yelhousni
Copy link
Copy Markdown
Collaborator

For all curves, at each step in the Miller loop computation, DoubleStep() is invoked. There are two field multiplications by 1/2 which can be implemented as a Montgomery-like Halve(a) function.

if a is even:
  a = a >> 1
else:
  a = a + modulus // no reduction
  a = a >> 1  

@gbotrel gbotrel merged commit a76e11c into develop Oct 18, 2021
@gbotrel gbotrel deleted the ML/DoubleStep-Halve branch October 18, 2021 14:25
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.

2 participants