pub struct CircuitStat {Show 19 fields
pub n_gates: usize,
pub n_eval_insn: usize,
pub n_zero_constraints: usize,
pub n_and_constraints: usize,
pub n_imul_constraints: usize,
pub n_bmul_constraints: usize,
pub distinct_shifted_value_indices: usize,
pub distinct_unshifted_value_indices: usize,
pub committed_allocated: usize,
pub n_const: usize,
pub n_inout: usize,
pub n_witness: usize,
pub n_internal: usize,
pub n_scratch: usize,
pub scratch_peak_live: usize,
pub zero_allocated: usize,
pub and_allocated: usize,
pub imul_allocated: usize,
pub bmul_allocated: usize,
}Expand description
Various stats of a circuit that affect the prover performance.
Fields§
§n_gates: usizeNumber of gates in the circuit.
n_eval_insn: usizeNumber of instructions in the evaluation form of circuit.
Directly proportional to performance of witness filling.
n_zero_constraints: usizeNumber of ZERO constraints in the circuit.
Affects performance of the shift reduction only: the Zero reduction itself carries no sumcheck.
n_and_constraints: usizeNumber of AND constraints in the circuit.
Affects performance of AND reduction.
n_imul_constraints: usizeNumber of IMUL constraints in the circuit.
Affects performance of intmul reduction phase.
n_bmul_constraints: usizeNumber of BMUL constraints in the circuit.
Affects performance of binmul reduction phase.
distinct_shifted_value_indices: usizeNumber of distinct value indices with non-zero shift in the circuit.
Every use of a value with a distinct type and amount is counted here.
Affects performance of shift reduction phase.
distinct_unshifted_value_indices: usizeNumber of distinct value indices with zero shift in the circuit.
Affects performance of shift reduction phase.
committed_allocated: usizeLength of the committed trace in words, a power of two.
Affects performance of committing.
n_const: usizeNumber of constant values used by the circuit.
n_inout: usizeNumber of public input values in the circuit.
n_witness: usizeNumber of private input values in the circuit.
n_internal: usizeNumber of internal values in the circuit.
Internal values are values produced by gates.
n_scratch: usizeNumber of scratch values in the circuit.
Those values are not committed, those only exist during witness generation.
scratch_peak_live: usizeSmallest scratch segment this circuit could run with.
This is the largest number of uncommitted values alive at the same time. It equals the segment length when slots are shared, and is a lower bound on it otherwise.
zero_allocated: usizeAllocated size for ZERO constraints (power of 2, or zero when there are none)
and_allocated: usizeAllocated size for AND constraints (power of 2)
imul_allocated: usizeAllocated size for IMUL constraints (power of 2)
bmul_allocated: usizeAllocated size for BMUL constraints (power of 2)
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CircuitStat
impl RefUnwindSafe for CircuitStat
impl Send for CircuitStat
impl Sync for CircuitStat
impl Unpin for CircuitStat
impl UnsafeUnpin for CircuitStat
impl UnwindSafe for CircuitStat
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more