75 Commits

Author SHA1 Message Date
wborgeaud
cfa5807556 Add insert gadget to insert inferred leaf in FRI query rounds 2021-06-14 15:15:22 +02:00
wborgeaud
5200d70cf0 Add interpolation gadgets 2021-06-11 16:22:29 +02:00
wborgeaud
81ce0eb710 Fix bugs 2021-06-10 16:48:05 +02:00
wborgeaud
6cce4c1f78 Add low-high split 2021-06-10 15:55:29 +02:00
wborgeaud
bb551092a0 Remove mul_extension_naive 2021-06-09 21:12:15 +02:00
wborgeaud
89761ef22a Added in-circuit reverse_bits and exp. 2021-06-09 17:39:45 +02:00
wborgeaud
9adf5bb43f Use ExtensionAlgebra + new CircuitBuilder::mul_extension 2021-06-09 10:51:50 +02:00
wborgeaud
7f63276623 Merge branch 'main' into recursive_verifier 2021-06-09 10:04:45 +02:00
Daniel Lubarov
72c2e19bc5
Bit of verifier work (#54)
* Bit of verifier work

* Minor

* next_plonk_zs now available after William's changes
2021-06-08 21:23:52 -07:00
Daniel Lubarov
db1ef913e0 Remove quartic_quartic 2021-06-08 10:08:17 -07:00
wborgeaud
c674d6c1f6 Remove unused imports 2021-06-08 12:53:04 +02:00
wborgeaud
19a38682ab Minor tweaks 2021-06-08 12:49:45 +02:00
wborgeaud
070dc7c9f1 s/ext_ext/ext_algebra 2021-06-08 11:30:39 +02:00
wborgeaud
d727f84a56 Working test 2021-06-08 11:18:21 +02:00
wborgeaud
5678c7ebda Added ExtensionAlgebra 2021-06-08 10:58:03 +02:00
wborgeaud
8cf2758b6c Division gadget for extension field 2021-06-07 17:55:27 +02:00
wborgeaud
a8da9b945e Working MulExtensionGate 2021-06-07 17:09:53 +02:00
wborgeaud
6f2275bc6d Progress 2021-06-07 11:19:54 +02:00
wborgeaud
1169870163 Added test 2021-06-04 17:07:14 +02:00
wborgeaud
51c06d74ee Recursive PoW 2021-06-04 16:02:48 +02:00
wborgeaud
42d5b80a7a BaseSum gate 2021-06-04 15:40:54 +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
wborgeaud
4f6e9fb2e0 Recursive evaluation for interpolation gate. 2021-05-24 17:31:55 +02:00
Daniel Lubarov
741dc4c94c Tweaks to bench_ldes 2021-05-22 09:38:07 -07:00
Daniel Lubarov
a4be58557e Fix GMiMCGate 2021-05-20 05:35:16 -07:00
Daniel Lubarov
747974558f Add test_low_degree for other gates 2021-05-20 05:27:56 -07:00
Daniel Lubarov
229784e574 Delete old FRI gate 2021-05-20 05:27:47 -07:00
Daniel Lubarov
621b097a70 Address most feedback 2021-05-20 05:15:25 -07:00
Daniel Lubarov
d05513475c Not just quartic 2021-05-19 23:07:24 -07:00
Daniel Lubarov
6e83d956e9 Finish up 2021-05-19 23:03:52 -07:00
Daniel Lubarov
3311981fc4 Minor 2021-05-19 15:57:28 -07:00
Daniel Lubarov
0ce1a4c5eb Minor 2021-05-19 15:13:33 -07:00
Daniel Lubarov
110763fa79 Minor 2021-05-19 15:00:35 -07:00
Daniel Lubarov
b535bf239a Minor 2021-05-19 12:24:19 -07:00
Daniel Lubarov
227c80c82e fmt 2021-05-19 12:10:41 -07:00
Daniel Lubarov
c6fa7eb18e Minor 2021-05-19 12:10:41 -07:00
Daniel Lubarov
0c91739b3b [DRAFT] Interpolation gate
Over quartic field extension (for now). This would be used in our FRI recursive verifier later, for the consistency check.

To summarize the wires,
- `n` inputs for the `n` points to interpolate (don't need `4n` since they'll be in the subgroup of the base field)
- `4n` inputs for the `n` (extension field) values to interpolate
- `4` inputs for the point to evaluate the interpolant at (beta, which will be drawn from the extension field right?)
- `4` outputs for the interpolated value
- `4n` internal wires for the interpolant's coefficients

This definitely isn't the most optimal approach, e.g. we could route in a single "base" point and derive its neighboring points, but just wanted to keep it simple for now.
2021-05-19 12:10:41 -07:00
Daniel Lubarov
83354972aa cargo fmt 2021-04-28 13:57:22 -07:00
Daniel Lubarov
aabfbe82cd Fix GMiMCEvalGate 2021-04-28 13:50:40 -07:00
Daniel Lubarov
d3ac365667 Recursive evaluation of GMiMCGate
If we did it all with `ArithmeticGate`s, the main loop (with ~101 iterations of cubing and a couple adds) would be fairly expensive, so this uses a (much smaller) custom gate called `GMiMCEvalGate` which does all the computations for one iteration of that loop.
2021-04-27 13:16:24 -07:00
Daniel Lubarov
b18f152c43 Remove access to "next" wire & constant values
As discussed, it seems like the batch opening argument will be a significant cost, and we can reduce that cost by not including shifted openings (except for `Z`s which need them).
2021-04-23 13:54:35 -07:00
wborgeaud
6b3aa02b01 Merge master 2021-04-21 22:36:06 +02:00
wborgeaud
6b407e45ef Progress on FRI 2021-04-21 22:31:45 +02:00
Daniel Lubarov
70f4f2aab8 Minimal num_wires 2021-04-16 21:40:51 -07:00
Daniel Lubarov
62dccedda4 Fix id() to include (generic) R param 2021-04-16 09:01:54 -07:00
wborgeaud
7ff4150679 Merge with merkle_proofs_2 2021-04-12 10:38:07 +02:00
Daniel Lubarov
a14ddc3b03 Fix constraint count 2021-04-10 14:54:46 -07:00
Daniel Lubarov
04f74446fa Misc fixes to get tests green again 2021-04-09 11:40:51 -07:00
Daniel Lubarov
959aaccae6 Merkle proofs 2021-04-08 09:38:57 -07:00
Daniel Lubarov
5fe8d633b6 Split main into multiple binaries
... and other minor refactoring.

`bench_recursion` will be the default bin run by `cargo run`; the otheres can be selected with the `--bin` flag.

We could probably delete some of the other binaries later. E.g. `field_search` might not be useful any more. `bench_fft` should maybe be converted to a benchmark (although there are some pros and cons, e.g. the bench framework has a minimum number of runs, and isn't helpful in testing multi-core performance).
2021-04-06 13:23:47 -07:00