Daniel Lubarov
03179e5674
Couple fixes related to blinding
...
- `self.gates` -> `self.gate_instances`
- Some tests were using a single binary FRI reduction, which doesn't provide enough succinctness for our blinding scheme to work. This caused `blinding_counts` to continue until it overflowed.
2021-06-30 12:54:45 -07:00
wborgeaud
a017e79f65
Merge branch 'main' into add_routed_wires
...
# Conflicts:
# src/gadgets/arithmetic.rs
2021-06-30 08:30:10 +02:00
wborgeaud
bae3777bcd
Use max filtered degree found with the tree method in CircuitBuilder::build
2021-06-29 14:00:34 +02:00
Daniel Lubarov
7734aed62c
Performance tweaks ( #77 )
2021-06-28 08:56:36 -07:00
wborgeaud
c2b2ef921a
PR feedback
2021-06-28 09:47:47 +02:00
wborgeaud
e195fe58ed
Merge branch 'main' into add_routed_wires
2021-06-25 13:53:30 +02:00
wborgeaud
810d1869a1
Minor improvements
2021-06-25 11:49:29 +02:00
wborgeaud
625377b4c0
Merge constant and sigma polynomials
2021-06-25 11:24:26 +02:00
wborgeaud
21e7e8fdad
Merge branch 'main' into permutation_argument
...
# Conflicts:
# src/circuit_builder.rs
2021-06-24 22:35:13 +02:00
wborgeaud
8aa9c7b816
Merge branch 'main' into gate_tree
...
# Conflicts:
# src/circuit_data.rs
# src/witness.rs
2021-06-24 20:58:17 +02:00
wborgeaud
c7753186b8
Clippy
2021-06-24 18:11:37 +02:00
wborgeaud
54315d1735
Remove GatePrefixes to avoid using a HashMap
2021-06-24 18:08:39 +02:00
wborgeaud
ef7561fc84
Merge branch 'main' into permutation_argument
...
# Conflicts:
# src/circuit_builder.rs
# src/circuit_data.rs
# src/polynomial/commitment.rs
# src/prover.rs
# src/witness.rs
2021-06-24 10:51:18 +02:00
wborgeaud
8796c73362
Change MulExtensionGate to ArithmeticExtensionGate and change gadgets to use the new wires in this gate.
2021-06-23 18:04:43 +02:00
wborgeaud
6c864ca522
Merge branch 'main' into fix_target_partition
...
# Conflicts:
# src/witness.rs
2021-06-23 14:17:02 +02:00
wborgeaud
bc90909fa3
Add check of copy constraints after witness generation
2021-06-23 14:16:05 +02:00
wborgeaud
3bc27c65ef
Rollback to previous semantics
2021-06-23 13:46:19 +02:00
wborgeaud
680d7a6389
Add eval_filtered methods
2021-06-22 17:10:36 +02:00
wborgeaud
79e99148ef
Minor
2021-06-17 16:31:24 +02:00
wborgeaud
ad5c18b499
Comments and Clippy
2021-06-17 16:23:15 +02:00
wborgeaud
a71909ba15
Implement compute_z and rewrite of compute_vanishing_polys
2021-06-17 15:49:21 +02:00
wborgeaud
1b99f8272f
Merge branch 'main' into permutation_argument
2021-06-17 14:00:44 +02:00
wborgeaud
bfd5f06384
Hardcode Plonk polynomials indices and blinding flags.
2021-06-17 11:54:31 +02:00
wborgeaud
a6acd14dfa
Minor rewrites and optimizations
2021-06-16 17:43:41 +02:00
wborgeaud
39c793a380
Fixes from PR feedback
2021-06-15 08:35:06 +02:00
wborgeaud
ea6a724560
Enforce copy constraints in partial witness generation.
2021-06-14 17:02:52 +02:00
wborgeaud
1eb372326a
Add CircuitConfig::large_config() for tests.
2021-06-11 09:44:19 +02:00
Daniel Lubarov
cb7f8c8b8c
Draw challenge points from the extension field ( #51 )
...
* Draw challenge points from the extension field
* Now building
* Misc
* Default eval_unfiltered_base
* fmt
* A few field settings
* Add to Sage
* Display tweak
* eval_filtered_base
* Quartic in bench
* Missing methods
* Fix tests
* PR feedback
2021-05-30 13:25:53 -07:00
Daniel Lubarov
5a5a86a416
First bit of verifier
...
Mostly stubbed out, more coming soon...
2021-05-26 16:23:17 -07:00
wborgeaud
9cd00532ce
Generic tests
2021-05-18 16:06:47 +02:00
wborgeaud
adf5c2d4ec
Const generics everywhere
2021-05-18 15:44:50 +02:00
wborgeaud
a2cf2c03b6
Working FRI with field extensions
2021-05-18 15:22:06 +02:00
Daniel Lubarov
7ff5496308
num_checks -> num_challenges
2021-05-14 08:07:00 -07:00
wborgeaud
ce0507ba12
Blinding parameter can be set differently for each Merkle tree in a FRI proof.
2021-05-11 09:56:21 +02:00
wborgeaud
1bae3a02f6
Batch open for PLONK
2021-05-07 11:30:03 +02:00
Daniel Lubarov
a50ba9f590
More unnecessary clones
2021-04-24 11:20:28 -07:00
Daniel Lubarov
6d164adc6a
Have the prover use the new MerkleTree API
...
Before it was storing leaf data and Merkle roots, but nothing in between, since it wasn't yet interacting with intermediate layers (but it will once we hook up the FRI code).
2021-04-24 11:15:11 -07:00
Daniel Lubarov
b7bc1bf313
Seed Challenger with a hash of the instance
...
I think this is the recommended way to apply Fiat-Shamir, to avoid any possible attacks like taking someone else's proof and using it to prove a slightly different statement.
2021-04-22 16:38:49 -07:00
wborgeaud
6b407e45ef
Progress on FRI
2021-04-21 22:31:45 +02:00
Daniel Lubarov
cb1c69e50f
Validate that the cosets for Plonk's permutation argument are disjoint
...
When we had a large field, we could just pick random shifts, and get disjoint cosets with high probability. With a 64-bit field, I think the probability of a collision is non-negligible (something like 1 in a million), so we should probably verify that the cosets are disjoint.
If there are any concerns with this method (or if it's just confusing), I think it would also be reasonable to use the brute force approach of explicitly computing the cosets and checking that they're disjoint. I coded that as well, and it took like 80ms, so not really a big deal since it's a one-time preprocessing cost.
Also fixes some overflow bugs in the inversion code.
2021-04-04 14:34:33 -07:00
Daniel Lubarov
22f7c359af
Fix visibility
2021-04-03 15:30:33 -07:00
Daniel Lubarov
524005579d
Comments etc
2021-04-02 20:58:19 -07:00
Daniel Lubarov
80e87becb8
Minor refactor
2021-04-02 19:15:39 -07:00
Daniel Lubarov
4086b2b447
Arithmetic & permutation gadgets
2021-04-02 15:29:21 -07:00
Daniel Lubarov
8302c10f21
Multiple vanishing polys, and multiple associated quotient polys
...
With different random alphas
2021-04-01 13:22:54 -07:00
Daniel Lubarov
347206d161
Add Z terms in vanishing poly
2021-03-30 23:12:47 -07:00
Daniel Lubarov
44eeb505eb
Tweaks
2021-03-30 10:02:00 -07:00
Daniel Lubarov
f42120482a
No more polynomial programming abstraction
...
It was too expensive.
2021-03-28 19:52:01 -07:00
Daniel Lubarov
ba96ab4e99
More prover work
2021-03-26 23:51:48 -07:00
Daniel Lubarov
5f92611df1
Bit of prover work
2021-03-21 11:57:33 -07:00