Skip to content

Commit

Permalink
Benches/Lottery: Updating with error
Browse files Browse the repository at this point in the history
  • Loading branch information
rrtoledo committed Feb 10, 2025
1 parent 32f49ef commit 77da918
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion benches/simple_lottery/proving_time.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ fn prove_duration(params: &BenchParam, truncate_size: u64, n: u64) -> Duration {
for _ in 0..n {
// Bench the proving time
let start = Instant::now();
black_box(telescope.prove(&dataset));
let _proof = black_box(telescope.prove(&dataset));
total_duration = total_duration.saturating_add(start.elapsed());
}
total_duration
Expand Down
4 changes: 2 additions & 2 deletions benches/simple_lottery/verifying_time.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ fn verify_duration(params: &BenchParam, truncate_size: u64, n: u64) -> Duration
// Generate the proof
let proof_opt = telescope.prove(&dataset);

if let Some(proof) = proof_opt {
if let Ok(proof) = proof_opt {
// Iterate on each sample `n` times
for _ in 0..n {
// Benching the verification time
let start = Instant::now();
black_box(telescope.verify(&proof));
let _ = black_box(telescope.verify(&proof));
total_duration = total_duration.saturating_add(start.elapsed());
}
}
Expand Down

0 comments on commit 77da918

Please sign in to comment.