Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
test_utils.hpp
Go to the documentation of this file.
1#pragma once
2
4
5namespace bb {
6
14{
16 using FF = Flavor::FF;
17 using Commitment = Flavor::Commitment;
19
20 Accumulator recursive_accumulator;
21
22 for (const auto& native_challenge : native_accumulator.challenge) {
23 recursive_accumulator.challenge.emplace_back(FF::from_witness(builder, native_challenge));
24 recursive_accumulator.challenge.back().unset_free_witness_tag();
25 }
26
27 recursive_accumulator.non_shifted_evaluation = FF::from_witness(builder, native_accumulator.non_shifted_evaluation);
28 recursive_accumulator.non_shifted_evaluation.unset_free_witness_tag();
29 recursive_accumulator.shifted_evaluation = FF::from_witness(builder, native_accumulator.shifted_evaluation);
30 recursive_accumulator.shifted_evaluation.unset_free_witness_tag();
31 recursive_accumulator.non_shifted_commitment =
32 Commitment::from_witness(builder, native_accumulator.non_shifted_commitment);
33 recursive_accumulator.non_shifted_commitment.unset_free_witness_tag();
34 recursive_accumulator.shifted_commitment = Commitment::from_witness(builder, native_accumulator.shifted_commitment);
35 recursive_accumulator.shifted_commitment.unset_free_witness_tag();
36
37 return recursive_accumulator;
38}
39
40} // namespace bb
typename Curve::ScalarField FF
typename G1::affine_element Commitment
Recursive counterpart to MegaKernelFlavor.
AluTraceBuilder builder
Definition alu.test.cpp:124
Entry point for Barretenberg command-line interface.
Definition api.hpp:5
MultilinearBatchingVerifierClaim< bb::MegaKernelRecursiveFlavor::Curve > create_recursive_verifier_accumulator(MegaCircuitBuilder *builder, const MultilinearBatchingVerifierClaim< bb::MegaKernelFlavor::Curve > &native_accumulator)
Test helper to create a recursive verifier accumulator from a native one.
Verifier's claim for multilinear batching - contains commitments and evaluation claims.