Skip to content

Commit

Permalink
chore: use round state
Browse files Browse the repository at this point in the history
  • Loading branch information
alannotnerd committed Sep 18, 2023
1 parent 273f5e3 commit b61b1e9
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions halo2_proofs/src/plonk/evaluation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ impl<C: CurveAffine> Evaluator<C> {
// Calculate the quotient polynomial for each part
let mut current_extended_omega = one;
let value_parts: Vec<Polynomial<C::ScalarExt, LagrangeCoeff>> = (0..num_parts)
.map(|part_idx| {
.map(|_| {
let fixed: Vec<Polynomial<C::ScalarExt, LagrangeCoeff>> = pk
.fixed_polys
.iter()
Expand Down Expand Up @@ -179,7 +179,6 @@ impl<C: CurveAffine> Evaluator<C> {

let mut values = domain.empty_lagrange();

let mut round = part_idx * advice.len();
// Core expression evaluations
for (((advice, instance), lookups), permutation) in advice
.iter()
Expand All @@ -200,7 +199,7 @@ impl<C: CurveAffine> Evaluator<C> {
&y,
rot_scale,
isize,
round,
0,
);

// Permutations
Expand Down Expand Up @@ -334,6 +333,7 @@ impl<C: CurveAffine> Evaluator<C> {
current_extended_omega,
);
let mut table_values = vec![C::ScalarExt::zero(); values.len()];
let round = if n + 1 == lookups.len() { 1 } else { 2 };
self.lookups[n].evaluate(
&mut table_values,
fixed,
Expand Down Expand Up @@ -394,7 +394,6 @@ impl<C: CurveAffine> Evaluator<C> {
}
});
}
round += 1;
}
current_extended_omega *= extended_omega;
values
Expand Down

0 comments on commit b61b1e9

Please sign in to comment.