Skip to content

Commit

Permalink
Update constraint counts in election and fallback PoSt circuits.
Browse files Browse the repository at this point in the history
  • Loading branch information
porcuquine committed May 27, 2020
1 parent d77c866 commit 8f91e33
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions storage-proofs/post/src/election/circuit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -197,12 +197,12 @@ mod tests {

#[test]
fn test_election_post_circuit_pedersen() {
test_election_post_circuit::<LCTree<PedersenHasher, U8, U0, U0>>(389_883);
test_election_post_circuit::<LCTree<PedersenHasher, U8, U0, U0>>(388_523);
}

#[test]
fn test_election_post_circuit_poseidon() {
test_election_post_circuit::<LCTree<PoseidonHasher, U8, U0, U0>>(24_426);
test_election_post_circuit::<LCTree<PoseidonHasher, U8, U0, U0>>(23_066);
}

fn test_election_post_circuit<Tree: 'static + MerkleTreeTrait>(expected_constraints: usize) {
Expand Down
14 changes: 7 additions & 7 deletions storage-proofs/post/src/fallback/circuit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -191,37 +191,37 @@ mod tests {

#[test]
fn fallback_post_pedersen_single_partition_matching_base_8() {
fallback_post::<LCTree<PedersenHasher, U8, U0, U0>>(3, 3, 1, 19, 294_459);
fallback_post::<LCTree<PedersenHasher, U8, U0, U0>>(3, 3, 1, 19, 294_439);
}

#[test]
fn fallback_post_poseidon_single_partition_matching_base_8() {
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(3, 3, 1, 19, 17_988);
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(3, 3, 1, 19, 16_968);
}

#[test]
fn fallback_post_poseidon_single_partition_matching_sub_8_4() {
fallback_post::<LCTree<PoseidonHasher, U8, U4, U0>>(3, 3, 1, 19, 23_898);
fallback_post::<LCTree<PoseidonHasher, U8, U4, U0>>(3, 3, 1, 19, 22_818);
}

#[test]
fn fallback_post_poseidon_single_partition_matching_top_8_4_2() {
fallback_post::<LCTree<PoseidonHasher, U8, U4, U2>>(3, 3, 1, 19, 28_653);
fallback_post::<LCTree<PoseidonHasher, U8, U4, U2>>(3, 3, 1, 19, 27_573);
}

#[test]
fn fallback_post_poseidon_single_partition_smaller_base_8() {
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(2, 3, 1, 19, 17_988);
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(2, 3, 1, 19, 16_968);
}

#[test]
fn fallback_post_poseidon_two_partitions_matching_base_8() {
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(4, 2, 2, 13, 11_992);
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(4, 2, 2, 13, 11_312);
}

#[test]
fn fallback_post_poseidon_two_partitions_smaller_base_8() {
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(5, 3, 2, 19, 17_988);
fallback_post::<LCTree<PoseidonHasher, U8, U0, U0>>(5, 3, 2, 19, 16_968);
}

#[test]
Expand Down

0 comments on commit 8f91e33

Please sign in to comment.