-
Notifications
You must be signed in to change notification settings - Fork 140
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
Stark continuous read-only memory example #940
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #940 +/- ##
==========================================
+ Coverage 70.99% 71.04% +0.05%
==========================================
Files 153 153
Lines 32770 32770
==========================================
+ Hits 23264 23283 +19
+ Misses 9506 9487 -19 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
// (a'_{i+1} - a'_i)(a'_{i+1} - a'_i - 1) = 0 where a' is the sorted address | ||
let res = (a_sorted1 - a_sorted0) * (a_sorted1 - a_sorted0 - FieldElement::<F>::one()); | ||
|
||
transition_evaluations[self.constraint_idx()] = res; |
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.
you should check if the vector can hold the value at that position
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.
Fix in commit
|
||
let mut aux_col = Vec::new(); | ||
let num = z - (&a[0] + alpha * &v[0]); | ||
let den = z - (&a_sorted[0] + alpha * &v_sorted[0]); |
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.
For learning purposes this is ok, but for performance reasons, it's best to compute all the denominators, due batch inverse and then compute
} | ||
} | ||
|
||
#[derive(Clone)] |
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.
this annotation should be placed after the documentation
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.
ok, done.
Add Stark example for continuous read-only memory constraints
Checklist