Skip to content

Commit

Permalink
document vector capacity
Browse files Browse the repository at this point in the history
  • Loading branch information
plafer committed Mar 19, 2024
1 parent 9132ffe commit 1cd4c9e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion prover/src/constraints/evaluator/lagrange.rs
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,9 @@ impl<E: FieldElement> LagrangeKernelTransitionConstraintsDivisor<E> {
domain: &StarkDomain<E::BaseField>,
) -> Self {
let divisor_evals_inv = {
// TODO: Explain why `* 2`
// The number of divisor evaluations is
// `ce_domain_size + ce_domain_size/2 + ce_domain_size/4 + ... + ce_domain_size/(log(ce_domain_size)-1)`,
// which is slightly smaller than `ce_domain_size * 2`
let mut divisor_evals: Vec<E> = Vec::with_capacity(domain.ce_domain_size() * 2);

for trans_constraint_idx in 0..lagrange_kernel_transition_constraints.len() {
Expand Down

0 comments on commit 1cd4c9e

Please sign in to comment.