24 Commits

Author SHA1 Message Date
wborgeaud
cdb2892969 Move inferred elements to a new struct 2021-10-12 08:38:43 +02:00
wborgeaud
ddac8026f2 Comments 2021-10-11 17:24:06 +02:00
wborgeaud
acadd64371 Clippy 2021-10-11 16:51:30 +02:00
wborgeaud
ea69a87338 Working 2021-10-11 16:40:31 +02:00
wborgeaud
d2a5e67980 Somewhat working 2021-10-07 19:30:39 +02:00
Daniel Lubarov
898cac1709
Automatically select FRI reduction arities (#282)
* Automatically select FRI reduction arities

This way when a proof's degree changes, we won't need to manually update the `FriConfig`s of any recursive proofs on top of it.

For now I've added two methods of selecting arities. The first, `ConstantArityBits`, just applies a fixed reduciton arity until the degree has shrunk below a certain threshold. The second, `MinSize`, searches for the sequence of arities that minimizes proof size.

Note that this optimization is approximate -- e.g. it doesn't account for the effect of compression, and doesn't count some minor contributions to proof size, like the Merkle roots from the commit phase. It also assumes we're not using Merkle caps in serialized proofs, and that we're inferring one of the evaluations, even though we haven't made those changes yet.

I think we should generally use `ConstantArityBits` for proofs that we will recurse on, since using a single arity tends to be more recursion-friendly. We could use `MinSize` for generating final bridge proofs, since we won't do further recursion on top of those.

* Fix tests

* Feedback
2021-10-04 13:52:05 -07:00
wborgeaud
84d1a1586f Merge branch 'duplicate_indices' into custom_serializer 2021-10-04 10:21:53 +02:00
wborgeaud
b4614991f7 Useless mut 2021-10-04 10:09:17 +02:00
wborgeaud
bbeb54c910 Remove pruning 2021-10-04 10:03:00 +02:00
wborgeaud
e3b2416025 Merge branch 'duplicate_indices' into custom_serializer 2021-10-02 13:56:46 +02:00
wborgeaud
76d3f488bd Fixes 2021-10-02 09:53:31 +02:00
wborgeaud
fb585064a9 (De)Serializer for CompressedProof 2021-10-01 16:54:14 +02:00
wborgeaud
28eca4bfdd Clippy 2021-09-30 19:09:27 +02:00
wborgeaud
dd68971609 Cleaning 2021-09-30 18:58:36 +02:00
wborgeaud
f92ce1a80c Add CompressedProof type 2021-09-30 06:56:32 +02:00
wborgeaud
a97b9a7112 Add compressed FRI proof type using a HashMap 2021-09-29 21:01:15 +02:00
Daniel Lubarov
f382289896
Derive challenges from other proof fields (#262)
* Derive challenges from other proof fields

* Delete failing test

Seems really hard to get the challenges right with the new model.

* Move PoW check

* Other feedback
2021-09-25 19:41:48 -07:00
wborgeaud
391759479e PR feedback 2021-09-21 08:37:23 +02:00
wborgeaud
1f42916bfc Comments 2021-09-20 17:58:25 +02:00
wborgeaud
36e4d3608d Working (de)compression for FRI proofs 2021-09-20 17:34:52 +02:00
wborgeaud
9f004c9664 Clippy 2021-08-10 16:18:42 +02:00
wborgeaud
e73c1d7769 Cleaning / Renaming 2021-08-10 15:53:27 +02:00
wborgeaud
ce71b536bf First pass 2021-08-10 13:33:44 +02:00
Daniel Lubarov
018fb005f8
Move stuff around (#135)
No functional changes here. The biggest change was moving certain files into new directories like `plonk` and `iop` (for things like `Challenger` that could be used in STARKs or other IOPs). I also split a few files, renames, etc, but again nothing functional, so I don't think a careful review is necessary (just a sanity check).
2021-07-29 22:00:29 -07:00