-
Notifications
You must be signed in to change notification settings - Fork 89
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
Implement GrandProductOps for SIMD backend #640
Implement GrandProductOps for SIMD backend #640
Conversation
0d73973
to
e17f7b8
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #640 +/- ##
==========================================
+ Coverage 93.05% 93.16% +0.10%
==========================================
Files 86 86
Lines 11209 11364 +155
Branches 11209 11364 +155
==========================================
+ Hits 10431 10587 +156
+ Misses 685 682 -3
- Partials 93 95 +2 ☔ View full report in Codecov by Sentry. |
f7837b1
to
7878fb0
Compare
e17f7b8
to
7ae75ab
Compare
7878fb0
to
13b3e3c
Compare
7ae75ab
to
c7b643e
Compare
13b3e3c
to
ed308eb
Compare
c7b643e
to
1910db0
Compare
ed308eb
to
0e58c2e
Compare
1910db0
to
0757511
Compare
0e58c2e
to
3b03377
Compare
0757511
to
953ed1c
Compare
8de5550
to
51c9107
Compare
f704c3f
to
410fcd3
Compare
51c9107
to
78201c2
Compare
410fcd3
to
789e767
Compare
78201c2
to
27886bf
Compare
58bc4df
to
42e1c4a
Compare
27886bf
to
4d47325
Compare
3c315c4
to
490481c
Compare
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.
Reviewed 5 of 7 files at r2, 3 of 3 files at r5, all commit messages.
Reviewable status: all files reviewed, 4 unresolved discussions (waiting on @andrewmilson and @shaharsamocha7)
crates/prover/src/core/backend/cpu/lookups/gkr.rs
line 90 at r5 (raw file):
// Note `inp(r, t, x) = eq(t, 0) * inp(r, 0, x) + eq(t, 1) * inp(r, 1, x)` // => `inp(r, 2, x) = 2 * inp(r, 1, x) - inp(r, 0, x)` // TODO: Consider evaluation at `1/2` to save an addition operation since `inp(r, 1/2, x) =
Cool idea
Suggestion:
/ TODO(andrew): Consider e
crates/prover/src/core/backend/simd/lookups/gkr.rs
line 120 at r5 (raw file):
// Can assume `len(layer) > N_LANES * 2` fn next_grand_product_layer(layer: &Mle<SimdBackend, SecureField>) -> Layer<SimdBackend> {
Suggestion:
/// Assumpion: `len(layer) > N_LANES * 2`
fn next_grand_product_layer(layer: &Mle<SimdBackend, SecureField>) -> Layer<SimdBackend> {
crates/prover/src/core/backend/simd/lookups/mod.rs
line 2 at r5 (raw file):
mod gkr; // mod grandproduct;
Remove?
crates/prover/src/core/lookups/gkr_prover.rs
line 6 at r5 (raw file):
use std::ops::Deref; use educe::Educe;
What is this?
4d47325
to
6cf72d3
Compare
490481c
to
37bcff3
Compare
6cf72d3
to
6f4cd6f
Compare
37bcff3
to
e096de0
Compare
6f4cd6f
to
5d63696
Compare
e096de0
to
1df0a57
Compare
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.
Reviewable status: 6 of 10 files reviewed, 4 unresolved discussions (waiting on @shaharsamocha7 and @spapinistarkware)
crates/prover/src/core/backend/cpu/lookups/gkr.rs
line 90 at r5 (raw file):
Previously, spapinistarkware (Shahar Papini) wrote…
Cool idea
Done.
crates/prover/src/core/backend/simd/lookups/gkr.rs
line 120 at r5 (raw file):
// Can assume `len(layer) > N_LANES * 2` fn next_grand_product_layer(layer: &Mle<SimdBackend, SecureField>) -> Layer<SimdBackend> {
Done.
crates/prover/src/core/backend/simd/lookups/mod.rs
line 2 at r5 (raw file):
Previously, spapinistarkware (Shahar Papini) wrote…
Remove?
Done.
crates/prover/src/core/lookups/gkr_prover.rs
line 6 at r5 (raw file):
Previously, spapinistarkware (Shahar Papini) wrote…
What is this?
Gives us better derive macros for Clone Debug etc.
It gets around trait bound requirements of the default derive.
e.g.
#[derive(clone)]
struct Something<B: Backend> {
column: Col<B, SecureField>
}
This only implements Clone if B: Clone. But Col<B, SecureField> is Clone so B:Clone is a bad bound.
#[derive(Educe)]
#[educe(Clone)]
struct Something<B: Backend> {
column: Col<B, SecureField>
}
Understands that B doesn't have to be clone
1a10524
to
a454e56
Compare
a454e56
to
0dc6a31
Compare
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.
Reviewed 6 of 6 files at r7, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @shaharsamocha7)
* CircleDomainBitRevIterator (starkware-libs#757) * Implement GrandProductOps for SIMD backend (starkware-libs#640) * Update SecureFieldVec to SecureColumn in GKR (starkware-libs#758) --------- Co-authored-by: Shahar Papini <[email protected]> Co-authored-by: Andrew Milson <[email protected]>
This change is