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

Add support for 448-bit integers and fields #261

Merged
merged 2 commits into from
Apr 16, 2021

Conversation

daira
Copy link
Contributor

@daira daira commented Apr 16, 2021

Description

Add support for 448-bit integers and fields. These will be needed for the Pluto and Eris curves
(https://github.com/daira/pluto-eris).

The changes are trivial and amount to applying the existing macros to a length of 448 bits (7 64-bit words).
This interacts with #186, but it should be easy to resolve any conflict.


Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

  • Targeted PR against correct branch (master)
  • Linked to Github issue with discussion and accepted design OR have an explanation in the PR that describes this work.
  • Wrote unit tests
  • Updated relevant documentation in the code [not needed]
  • Added a relevant changelog entry to the Pending section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer

Copy link
Member

@Pratyush Pratyush left a comment

Choose a reason for hiding this comment

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

Thanks for the PR!

@daira daira marked this pull request as draft April 16, 2021 10:49
@daira
Copy link
Contributor Author

daira commented Apr 16, 2021

Changing this to draft while I check that it actually works for Pluto/Eris (there seems to be some minor problem with SquareRootField, so perhaps I missed something).

These are needed for the Pluto and Eris curves (https://github.com/daira/pluto-eris).

Signed-off-by: Daira Hopwood <daira@jacaranda.org>
@daira daira marked this pull request as ready for review April 16, 2021 12:54
@daira
Copy link
Contributor Author

daira commented Apr 16, 2021

I didn't miss anything. When testing with the Pluto/Eris implementation I just needed to patch ark-ff and ark-serialize to use the 0.2.0 releases plus this patch only. I.e. in Cargo.toml:

[patch.crates-io]
ark-ff = { path = '../algebra/ff' }
ark-serialize = { path = '../algebra/serialize' }

And then it works. So, I think this PR is fine. (I rebased it relative to the 0.2.0 release for more straightforward testing, and removed the CHANGELOG.md entry because that would conflict.)

Copy link
Member

@ValarDragon ValarDragon left a comment

Choose a reason for hiding this comment

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

LGTM!

@weikengchen weikengchen merged commit 8b8ba22 into arkworks-rs:master Apr 16, 2021
weikengchen added a commit that referenced this pull request Apr 16, 2021
@weikengchen weikengchen mentioned this pull request Apr 16, 2021
6 tasks
weikengchen added a commit that referenced this pull request Apr 16, 2021
@daira daira deleted the biginteger448 branch April 18, 2021 19:00
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.

4 participants