9#include <condition_variable>
77 std::vector<size_t> indices,
79 std::chrono::steady_clock::time_point reduce_start);
81 const std::vector<size_t>& indices,
82 std::chrono::steady_clock::time_point reduce_start,
86 static double ms_since(std::chrono::steady_clock::time_point t)
88 return std::chrono::duration<double, std::milli>(std::chrono::steady_clock::now() - t).count();
90 static double ms_between(std::chrono::steady_clock::time_point from, std::chrono::steady_clock::time_point to)
92 return std::chrono::duration<double, std::milli>(to - from).count();
Asynchronous batch verifier for Chonk IVC proofs.
std::vector< ReduceResult > parallel_reduce(const std::vector< VerifyRequest > &batch)
void bisect(std::vector< ReduceResult > &results, std::vector< size_t > indices, uint32_t depth, std::chrono::steady_clock::time_point reduce_start)
static double ms_between(std::chrono::steady_clock::time_point from, std::chrono::steady_clock::time_point to)
ChonkBatchVerifier & operator=(const ChonkBatchVerifier &)=delete
ChonkBatchVerifier(const ChonkBatchVerifier &)=delete
std::thread coordinator_thread_
std::function< void(VerifyResult)> ResultCallback
void emit_ok(const std::vector< ReduceResult > &results, const std::vector< size_t > &indices, std::chrono::steady_clock::time_point reduce_start, double ipa_ms, uint32_t depth)
bool batch_check(const std::vector< ReduceResult > &results, const std::vector< size_t > &indices)
static double ms_since(std::chrono::steady_clock::time_point t)
std::vector< std::shared_ptr< MegaZKFlavor::VKAndHash > > vks_
std::deque< VerifyRequest > queue_
void enqueue(VerifyRequest request)
Enqueue a proof for verification.
std::condition_variable cv_
void stop()
Stop the processor, flushing remaining proofs.
ChonkBatchVerifier()=default
void start(std::vector< std::shared_ptr< MegaZKFlavor::VKAndHash > > vks, uint32_t num_cores, uint32_t batch_size, ResultCallback on_result)
Start the coordinator thread.
ResultCallback on_result_
Unverified claim (C,r,v) for some witness polynomial p(X) such that.
Entry point for Barretenberg command-line interface.
std::vector< fr > HonkProof
constexpr decltype(auto) get(::tuplet::tuple< T... > &&t) noexcept
Per-proof result from the reduce phase.
std::chrono::steady_clock::time_point enqueue_time
std::string error_message
OpeningClaim< curve::Grumpkin > ipa_claim
::bb::HonkProof ipa_proof
A request to verify a single Chonk proof.
Result of verifying a single proof within a batch.