therealyingtong
b805f85f9f
sha256: Update Error::SynthesisError -> Error::Synthesis
2021-11-27 10:22:52 -05:00
therealyingtong
be1c0c080f
Introduce AssignedBits<LEN> type.
2021-11-27 10:22:52 -05:00
therealyingtong
b9230861f7
Introduce RoundIdx enum instead of using i32.
...
This is a more secure way to distinguish the initial round from
the main rounds.
2021-11-27 10:22:52 -05:00
therealyingtong
78e6e9f695
Use AssignedCell for CellValue{16,32}.
2021-11-27 10:22:52 -05:00
therealyingtong
0443740895
sha256: Replace fixed columns with selectors.
2021-11-27 10:22:52 -05:00
therealyingtong
e1c132d664
sha256: Use assign_table() API for lookup table.
2021-11-27 10:22:52 -05:00
therealyingtong
ee5bc8184a
Remove unwrap()s in synthesis.
2021-11-27 10:22:52 -05:00
therealyingtong
66268cf192
Update sha256 example to work with new API
2021-11-27 10:22:52 -05:00
therealyingtong
61c431edc7
Update examples to use AssignedCell.
2021-11-27 10:08:01 -05:00
therealyingtong
36183bd01a
Return AssignedCell from circuit::Region::assign_* APIs.
2021-11-27 10:07:39 -05:00
therealyingtong
4aabf7c1ca
circuit.rs: Introduce AssignedCell struct.
2021-11-27 08:49:12 -05:00
str4d
069aa1dd17
Merge pull request #376 from zcash/364-mockprover-constraint-values
...
dev: Collect values of queried cells for unsatisfied constraints
2021-11-18 19:23:42 +00:00
ying tong
9dc5002d55
Merge pull request #403 from zcash/402-improve-k-too-small-errors
...
Improve error message when `k` is too small
2021-11-17 15:27:39 +01:00
Jack Grigg
72a731cba1
Remove `minimum_k` from `Error::NotEnoughRowsAvailable`
...
Due to this error being detected and returned early, in practice
`minimum_k` would always be `current_k + 1`, and the error would be
returned repeatedly (as more of the circuit could be processed) until
`k` was set large enough. We now simply suggest that the user try a
larger value of `k`.
2021-11-17 08:07:42 +00:00
Jack Grigg
64680a1a2d
dev: Handle too-small `k` error in `CircuitLayout::render`
...
In most places within `CircuitLayout`, we are flexible on `k`. However,
for tracking selectors we need to know the number of rows. We could
change this, but given that we also want the number of rows to be
accurate for rendering unusable rows, we can instead use this as an
opportunity to inform the user that they will need to bump `k`.
2021-11-16 14:20:57 +00:00
Jack Grigg
eb88a2ebef
Replace `Error::BoundsFailure` uses with `Error::NotEnoughRowsAvailable`
...
The remaining uses of `Error::BoundsFailure` that are exposed to the
user, are for invalid column indices.
2021-11-15 22:50:35 +00:00
Jack Grigg
d055acda31
Augment `Error::NotEnoughRowsAvailable` with current and min-required k
...
This makes the error message more useful, by informing the user of a
possible solution.
2021-11-15 21:44:51 +00:00
Daira Hopwood
f358f72899
Merge pull request #401 from zcash/book-plonkish-terms
...
book: Rename remaining UPA references to PLONKish
2021-11-15 15:09:26 -05:00
Jack Grigg
fa61746526
book: Rename remaining UPA references to PLONKish
...
These were missed in zcash/halo2#320 .
2021-11-15 15:53:38 +00:00
str4d
cd5522496a
Merge pull request #338 from zcash/errors
...
Improved error handling
2021-11-12 12:13:11 +13:00
Jack Grigg
a222cdc6d4
book: Document Debian packages required for `dev-graph` feature flag
2021-11-10 16:22:20 +00:00
Jack Grigg
99fac53618
Fix broken doc link
2021-11-10 16:19:36 +00:00
Jack Grigg
d66b5c42a0
`impl std::error::Error for Error`
2021-11-10 16:19:36 +00:00
Jack Grigg
7da5605f51
Remove redundant Error suffix from Error cases
2021-11-10 16:19:36 +00:00
Jack Grigg
209e398cae
Store `io::Error` inside `Error::TranscriptError`
...
We `impl From<io::Error> for Error` to return `Error::TranscriptError`
because the transcript is the only source of `io::Error`.
`Error` no longer implements `PartialEq` because `io::Error` does not.
Tests can check for specific error cases with `assert!(matches!(..))`.
2021-11-10 14:49:35 +00:00
Jack Grigg
b091757668
Rename Error::IncompatibleParams to Error::InvalidInstances
...
This was leftover from when proofs were structured in memory.
2021-11-10 14:49:35 +00:00
Jack Grigg
de1a468691
Move Error struct into a submodule
...
Just to make it easier to work on.
2021-11-10 14:49:35 +00:00
str4d
a635b7c25a
Merge pull request #375 from zcash/366-dev-graph-examples
...
Update `dev-graph` examples
2021-11-11 03:48:41 +13:00
str4d
9dd1bffa76
Merge pull request #395 from zcash/dependabot-actions
...
CI: Add Dependabot config to keep Actions up-to-date
2021-11-05 07:00:55 +13:00
Jack Grigg
0c1c5be67f
CI: Add Dependabot config to keep Actions up-to-date
2021-11-04 16:42:47 +00:00
Jack Grigg
9c226d33b9
dev: Collect values of queried cells for unsatisfied constraints
...
Co-authored-by: ying tong <yingtong@z.cash>
Closes zcash/halo2#364 .
2021-11-04 14:03:47 +00:00
Jack Grigg
26622ce5b0
`impl Ord for plonk::Any`
2021-11-04 14:03:16 +00:00
Daira Hopwood
ddd34ff972
Merge pull request #389 from zcash/dev-faster-mockprover
...
dev: Remove O(n^2) loop in lookup checks.
2021-10-26 14:11:55 +01:00
therealyingtong
b94aab76a3
dev: Remove O(n^2) loop in lookup checks.
...
Co-authored-by: Kris Nuttycombe<kris@nutty.land>
2021-10-22 19:33:30 +02:00
ying tong
6eca11b37a
Merge pull request #386 from zcash/book-patch-2
...
[book] Update link `upa.md` -> `plonkish.md`
2021-10-14 12:39:25 +02:00
ying tong
3d2c0e429e
[book] Update link `upa.md` -> `plonkish.md`
...
Closes #367
2021-10-14 12:38:52 +02:00
Jack Grigg
5be597c3bc
book: Add example for `halo2::dev::circuit_dot_graph`
2021-10-01 16:01:24 +01:00
str4d
658c2db421
Merge pull request #374 from zcash/trait-usage
...
Clean up our trait usage
2021-10-02 01:54:55 +13:00
Jack Grigg
c9d890377c
book: Render example for `CircuitLayout`
2021-10-01 13:39:04 +01:00
Jack Grigg
e3e68bc5d7
book: Fix bugs in dev tools page
2021-10-01 13:39:04 +01:00
Jack Grigg
7463a6e931
examples: Reorganise circuit-layout example to use in book
2021-10-01 13:39:04 +01:00
Jack Grigg
b46ef35db5
clippy: Allow unused imports
...
We can remove this once `pasta_curves` has been updated to remove
`CurveAffine::read`.
2021-10-01 13:33:47 +01:00
Jack Grigg
3fba7434d1
Use `ff::PrimeField::root_of_unity` instead of `FieldExt::ROOT_OF_UNITY`
2021-09-30 23:06:32 +01:00
Jack Grigg
9dc2738305
Remove usages of `CurveAffine::{read, write}`
...
A new `CurveRead` helper trait brings in the `CurveAffine::read` impl.
2021-09-30 23:06:32 +01:00
Jack Grigg
17b8fe1baa
Use `ff::Field::pow_vartime` instead of `FieldExt::pow`
2021-09-30 22:54:42 +01:00
Jack Grigg
a5a3c8ca63
Use `From<u64>` instead of `FieldExt::from_u64`
2021-09-30 22:53:00 +01:00
Jack Grigg
0e6b0344f5
Use `ff::PrimeField::{from_repr, to_repr}` instead of `FieldExt`
2021-09-30 22:53:00 +01:00
Jack Grigg
9693065a00
Use `ff::BatchInvert` now that we have upstreamed it
2021-09-30 22:35:33 +01:00
str4d
3850b9ccd5
Merge pull request #371 from zcash/release-0.1.0-beta.1
...
halo2 0.1.0-beta.1
2021-09-28 16:42:51 +13:00
Jack Grigg
ca0f04dcb9
Add [BETA] to the crate description
...
Just so people see it when searching crates.io for halo2.
2021-09-24 17:08:46 +01:00