-
Notifications
You must be signed in to change notification settings - Fork 23
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
61bit field #1019
61bit field #1019
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1019 +/- ##
==========================================
+ Coverage 90.57% 90.61% +0.04%
==========================================
Files 170 170
Lines 24763 25137 +374
==========================================
+ Hits 22428 22779 +351
- Misses 2335 2358 +23 ☔ View full report in Codecov by Sentry. |
ipa-core/src/ff/prime_field.rs
Outdated
<$store_multiply>::MAX >> $bits | ||
>= <$store_multiply>::try_from(<$store>::MAX).unwrap() | ||
); | ||
const_assert!((<$store_multiply>::MAX >> $bits) as u128 >= (<$store>::MAX) as u128); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hopefully the compiler will optimize it, but you could also lift this statement outside of this function because it belongs to the macro itself
straightforward implementation of 61bit fields, i.e. prime fields for prime 2^61-1