Commit Graph

76 Commits

Author SHA1 Message Date
Sean Bowe 5be7d9525d
Update multiopen APIs to reflect changes made to Transcript APIs 2021-01-06 10:45:10 -07:00
Sean Bowe d30c6b62e4
Modification of the polynomial commitment scheme to compensate for Transcript API changes. 2021-01-06 10:40:26 -07:00
Jack Grigg f49e1e6177 Fix breakage of trait resolution in Rust 1.49.0
Previously, `ChallengeScalar` could use the operator traits defined on
the `F: Field` type it wrapped, due to its `impl Deref<Target = F>`.
This was technically ambiguous, and Rust 1.49.0 makes that ambiguity an
error.

We could fix this by adding operator impls with `ChallengeScalar` on the
RHS, but that would conflict with zcash/halo2#111. Instead we manually
dereference every challenge scalar when used in an arithmetic operation.
2021-01-06 00:48:29 +00:00
Sean Bowe 65ed1d8568
Check h_evals/h_commitments lengths in vanishing argument verifier. 2020-12-22 08:59:06 -07:00
Jack Grigg 8389389d37 model: metrics 0.13.0-alpha.13 2020-12-22 12:27:36 +00:00
Sean Bowe 6c0e6f7348
cargo fmt 2020-12-03 13:59:17 -07:00
Sean Bowe 95e41fcfcf
Rename curves to Pallas/Vesta (Pasta). 2020-12-03 13:47:47 -07:00
Jack Grigg 4d4c79be58 Move Challenge and ChallengeScalar into the transcript module 2020-12-01 22:40:54 +00:00
Jack Grigg 2e6ca274a4 Fix challenge types in poly::multiopen and poly::commitment
The argument to the poly::commitment prover and verifier was mistakenly
represented as a challenge, when in fact the commitments may be opened at
any scalar (which just happens to be a challenge within poly::multiopen).

The poly::commitment APIs are now public again.
2020-12-01 22:34:18 +00:00
Jack Grigg f0723dbbcc multiopen: Rename [x_4, x_5] challenges to [x_1, x_2]
Also added types for these challenges, even though it's not technically
necessary yet because we don't pass these around anywhere.
2020-12-01 21:42:32 +00:00
Jack Grigg eb7ce442f9 Rename ChallengeX6 to ChallengeZ 2020-12-01 21:40:16 +00:00
Jack Grigg f63f3ff2af Introduce typed challenge scalars
This also centralises the challenge generation logic in Challenge::get,
ensuring it is consistent across the codebase.
2020-12-01 21:09:03 +00:00
Jack Grigg 63e3bc1e15 Remove unnecessary Transcript::init_with_hashers constructor 2020-12-01 21:03:31 +00:00
Jack Grigg cdbc41148a Migrate to ff traits
The `Field` trait in this crate is now `FieldExt: ff::PrimeField`.
2020-12-01 20:55:03 +00:00
therealyingtong 72471dc07e Clippy fixes 2020-11-30 23:57:48 +08:00
therealyingtong 0b2ec8965f Update documentation in polycommit verifier 2020-11-30 15:28:19 +08:00
therealyingtong d168f5c21b Parallelize and rename methods in msm.rs 2020-11-30 15:28:19 +08:00
str4d cc5f45231d
Merge pull request #42 from zcash/plonk-benches
PLONK benchmarks
2020-11-24 18:14:07 +00:00
Jack Grigg 236b3a6692 Collect some verifier metrics 2020-11-23 12:47:51 +00:00
Jack Grigg d4424db8d4 Collect some prover metrics 2020-11-23 12:47:51 +00:00
ying tong 7822201c9c Remove redundant point checks in commitment verifier
Co-authored-by: Jack Grigg <jack@electriccoin.co>
2020-11-16 21:28:37 +00:00
therealyingtong 2375507f4f Update error handling 2020-11-16 21:26:46 +00:00
therealyingtong 43337dea1b Make Transcript generic over curve points
Co-authored-by: Jack Grigg <jack@electriccoin.co>
2020-11-16 21:26:46 +00:00
Jack Grigg 3407d13e4b Move curves and fields into tweedle module 2020-11-12 21:36:59 +00:00
ebfull 5a2f474616
Merge pull request #56 from zcash/coset-docs
Add to documentation for coset evaluation domain
2020-11-11 08:56:03 -07:00
therealyingtong 28e07eab16 Add to documentation for coset evaluation domain 2020-11-10 13:44:52 +08:00
Jack Grigg 5a6a45c6a8 Fix deref breakage with nightly-2020-10-06
I think this is related to rust-lang/rust#77638
2020-10-30 01:21:09 +00:00
Sean Bowe 011132337f
Remove notes on multiopen module 2020-10-20 08:57:48 -06:00
therealyingtong 3761419ebc Add documentation for multiopen.rs 2020-10-18 20:09:44 +08:00
therealyingtong a30719c245 Minor changes to multiopen
Co-authored-by: ebfull <ewillbefull@gmail.com>
2020-10-18 20:09:40 +08:00
Sean Bowe 1e9f7f37c6
Minor improvements to multiopen. 2020-10-15 17:16:44 -06:00
Sean Bowe 9d572c181d
Remove unnecessary enumeration in multiopen prover. 2020-10-15 17:12:17 -06:00
Sean Bowe 685bf79613
Relocate x_5 challenge sampling location to simplify logic. 2020-10-15 17:11:06 -06:00
Sean Bowe 123cacc7cc
Remove additional unnecessary vector clone from multiopen prover. 2020-10-15 17:06:35 -06:00
Sean Bowe 55ef4ea1f7
Unify the construct_intermediate_sets function between multiopen prover and verifier. 2020-10-15 17:01:30 -06:00
Sean Bowe d3f593e89c
Avoid unnecessary enumeration. 2020-10-15 14:18:02 -06:00
Sean Bowe 3955da435c
Avoid unnecessary vector cloning in multiopen. 2020-10-15 14:17:03 -06:00
therealyingtong 2f7b46ffa1 Remove use of parallelize() from multiopen::prover 2020-10-14 08:16:14 +08:00
therealyingtong 742c15bb51 Minor changes and documentation 2020-10-14 08:15:00 +08:00
therealyingtong b62d113031 Refactor to use fold() in multiple places 2020-10-14 00:35:36 +08:00
therealyingtong 79cabb3d8d Move random scaling of MSM into multiopen verifier
Co-authored-by: Sean Bowe <ewillbefull@gmail.com>
2020-10-14 00:35:36 +08:00
therealyingtong 088118cc5d Refactor lagrange_interpolate() method
Co-authored-by: daira <daira@electriccoin.co>
Co-authored-by: str4d <jack@z.cash>
2020-10-14 00:35:36 +08:00
therealyingtong 1441193de1 Refactoring from initial code review
Co-authored-by: ebfull <ewillbefull@gmail.com>
2020-10-14 00:35:36 +08:00
therealyingtong 97873fa6ea Use VerifierQuery and construct_intermediate_sets() in verifier 2020-10-14 00:35:36 +08:00
therealyingtong 6cd74999ff Use ProverQuery and construct_intermediate_sets() in prover 2020-10-14 00:35:25 +08:00
therealyingtong 9378d0cc70 Define construct_intermediate_sets() helper method for multiopen prover and verifier 2020-10-14 00:35:25 +08:00
therealyingtong cbe4415870 Introduce Query and CommitmentData structs for multiopen 2020-10-14 00:35:25 +08:00
therealyingtong c3d0a172a7 Create multiopen abstraction 2020-10-14 00:35:25 +08:00
Sean Bowe 67b35954f4
Move MSM into submodule. 2020-10-13 08:16:20 -06:00
Sean Bowe 4a37e05f49
cargo fmt 2020-09-25 10:21:54 -06:00