48template <
typename Flavor>
51 size_t public_inputs_size,
54 requires IsRecursiveFlavor<Flavor>
57 using NativeFlavor =
typename Flavor::NativeFlavor;
63 BB_ASSERT_EQ(proof_size, NativeFlavor::PROOF_LENGTH_WITHOUT_PUB_INPUTS());
65 size_t num_inner_public_inputs = public_inputs_size - IO::PUBLIC_INPUTS_SIZE;
66 uint32_t pub_inputs_offset = NativeFlavor::has_zero_row ? 1 : 0;
69 auto honk_vk = create_mock_honk_vk<typename Flavor::NativeFlavor, IO>(
75 for (
auto& vk_element : honk_vk->to_field_elements()) {
76 builder.set_variable(key_fields[
offset].witness_index, vk_element);
81 bb::HonkProof honk_proof = create_mock_honk_proof<typename Flavor::NativeFlavor, IO>(num_inner_public_inputs);
85 for (
auto& proof_element : honk_proof) {
86 builder.set_variable(proof_fields[
offset].witness_index, proof_element);
103template <
typename Flavor>
106 requires(IsRecursiveFlavor<Flavor> && IsUltraHonk<typename Flavor::NativeFlavor>)
110 using RecursiveVKAndHash = Flavor::VKAndHash;
116 ASSERT(input.proof_type ==
HONK || input.proof_type ==
HONK_ZK || HasIPAAccumulator<Flavor>);
128 std::vector<uint32_t> proof_indices =
133 if (!has_valid_witness_assignments) {
136 size_t size_of_proof_with_no_pub_inputs = input.proof.size() - IO::PUBLIC_INPUTS_SIZE;
137 size_t total_num_public_inputs = input.public_inputs.size() + IO::PUBLIC_INPUTS_SIZE;
139 create_dummy_vkey_and_proof<Flavor>(
140 builder, size_of_proof_with_no_pub_inputs, total_num_public_inputs, key_fields, proof_fields);
146 RecursiveVerifier verifier(&
builder, vk_and_hash);
150 return verifier_output;
156 bool has_valid_witness_assignments);
161 bool has_valid_witness_assignments);
166 bool has_valid_witness_assignments);
171 bool has_valid_witness_assignments);
176 bool has_valid_witness_assignments);
#define BB_ASSERT_EQ(actual, expected,...)
#define ASSERT(expression,...)
The verification key is responsible for storing the commitments to the precomputed (non-witness) poly...
MegaCircuitBuilder CircuitBuilder
static constexpr size_t VIRTUAL_LOG_N
An object storing two bn254 points that represent the inputs to a pairing check.
The recursive counterpart to the "native" Ultra flavor.
The recursive counterpart to the "native" UltraRollupFlavor.
The recursive counterpart to the Ultra flavor with ZK.
A simple wrapper around a vector of stdlib field elements representing a proof.
static field_t from_witness_index(Builder *ctx, uint32_t witness_index)
Manages the data that is propagated on the public inputs of an application/function circuit.
The data that is propagated on the public inputs of a rollup circuit.
Base class templates for structures that contain data parameterized by the fundamental polynomials of...
Entry point for Barretenberg command-line interface.
std::vector< fr > HonkProof
constexpr decltype(auto) get(::tuplet::tuple< T... > &&t) noexcept
An object storing two EC points that represent the inputs to a pairing check.