Skip to content

Commit

Permalink
Merge pull request #113 from novifinancial/aux-trace-log
Browse files Browse the repository at this point in the history
Add logging for aux trace segment construction
  • Loading branch information
irakliyk authored Oct 24, 2022
2 parents 1a1815a + 1044186 commit d4ab4cf
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions prover/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -254,13 +254,23 @@ pub trait Prover {
let mut aux_trace_segments = Vec::new();
let mut aux_trace_rand_elements = AuxTraceRandElements::new();
for i in 0..trace.layout().num_aux_segments() {
#[cfg(feature = "std")]
let now = Instant::now();

// draw a set of random elements required to build an auxiliary trace segment
let rand_elements = channel.get_aux_trace_segment_rand_elements(i);

// build the trace segment
let aux_segment = trace
.build_aux_segment(&aux_trace_segments, &rand_elements)
.expect("failed build auxiliary trace segment");
#[cfg(feature = "std")]
debug!(
"Built auxiliary trace segment of {} columns and 2^{} steps in {} ms",
aux_segment.num_cols(),
log2(aux_segment.num_rows()),
now.elapsed().as_millis()
);

// extend the auxiliary trace segment and build a Merkle tree from the extended trace
let (aux_segment_lde, aux_segment_tree, aux_segment_polys) =
Expand Down

0 comments on commit d4ab4cf

Please sign in to comment.