Skip to content
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

[clean] endomorphism + code generation #281

Merged
merged 1 commit into from
Dec 13, 2022
Merged

Conversation

yelhousni
Copy link
Collaborator

@yelhousni yelhousni commented Dec 13, 2022

fixed #60
When GLV is set to false (endomorphism not available) in the config file, the templates still generate code for some computations (ClearCofactorl(), IsInSubgroupl(), ScalarMul()) that use the endomorphism phi(). This PR fixes the problem.

When the GLV is set to false, the templates:

  • use mulWindowed() instead of mulGLV()
  • multiply by r for IsInSubGroup()
  • multiply by the cofactors for ClearCofactor() (for BW6 curves)

@gbotrel gbotrel merged commit 0142c0d into develop Dec 13, 2022
@gbotrel gbotrel deleted the clean/GLV-template branch December 13, 2022 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Suggestion to clean up the code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants