Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
bb::MegaRecursiveFlavor_< BuilderType > Class Template Reference

The recursive counterpart to the "native" Mega flavor. More...

#include <mega_recursive_flavor.hpp>

Inheritance diagram for bb::MegaRecursiveFlavor_< BuilderType >:
bb::MegaZKRecursiveFlavor_< BuilderType >

Classes

class  AllValues
 A field element for each entity of the flavor. These entities represent the prover polynomials evaluated at one point. More...
 
class  VerificationKey
 The verification key is responsible for storing the commitments to the precomputed (non-witnessk) polynomials used by the verifier. More...
 

Public Types

using CircuitBuilder = BuilderType
 
using Curve = stdlib::bn254< CircuitBuilder >
 
using PCS = KZG< Curve >
 
using GroupElement = typename Curve::Element
 
using FF = typename Curve::ScalarField
 
using Commitment = typename Curve::Element
 
using NativeFlavor = MegaFlavor
 
using Transcript = bb::BaseTranscript< bb::stdlib::recursion::honk::StdlibTranscriptParams< CircuitBuilder > >
 
using VerifierCommitmentKey = bb::VerifierCommitmentKey< NativeFlavor::Curve >
 
using Relations = MegaFlavor::Relations_< FF >
 
using SubrelationSeparators = std::array< FF, NUM_SUBRELATIONS - 1 >
 
using WitnessCommitments = MegaFlavor::WitnessEntities< Commitment >
 A container for the witness commitments.
 
using CommitmentLabels = MegaFlavor::CommitmentLabels
 
using VerifierCommitments = MegaFlavor::VerifierCommitments_< Commitment, VerificationKey >
 
using VKAndHash = VKAndHash_< FF, VerificationKey >
 

Static Public Attributes

static constexpr size_t VIRTUAL_LOG_N = MegaFlavor::VIRTUAL_LOG_N
 
static constexpr bool USE_SHORT_MONOMIALS = MegaFlavor::USE_SHORT_MONOMIALS
 
static constexpr bool HasZK = false
 
static constexpr bool USE_PADDING = MegaFlavor::USE_PADDING
 
static constexpr size_t NUM_WIRES = MegaFlavor::NUM_WIRES
 
static constexpr size_t NUM_ALL_ENTITIES = MegaFlavor::NUM_ALL_ENTITIES
 
static constexpr size_t NUM_PRECOMPUTED_ENTITIES = MegaFlavor::NUM_PRECOMPUTED_ENTITIES
 
static constexpr size_t NUM_WITNESS_ENTITIES = MegaFlavor::NUM_WITNESS_ENTITIES
 
static constexpr size_t NUM_FOLDED_ENTITIES = NUM_PRECOMPUTED_ENTITIES + NUM_WITNESS_ENTITIES
 
static constexpr size_t MAX_PARTIAL_RELATION_LENGTH = compute_max_partial_relation_length<Relations>()
 
static constexpr size_t MAX_TOTAL_RELATION_LENGTH = compute_max_total_relation_length<Relations>()
 
static constexpr size_t BATCHED_RELATION_PARTIAL_LENGTH = MAX_PARTIAL_RELATION_LENGTH + 1
 
static constexpr RepeatedCommitmentsData REPEATED_COMMITMENTS = MegaFlavor::REPEATED_COMMITMENTS
 
static constexpr size_t NUM_RELATIONS = std::tuple_size_v<Relations>
 
static constexpr size_t NUM_SUBRELATIONS = MegaFlavor::NUM_SUBRELATIONS
 

Detailed Description

template<typename BuilderType>
class bb::MegaRecursiveFlavor_< BuilderType >

The recursive counterpart to the "native" Mega flavor.

This flavor can be used to instantiate a recursive Ultra Honk verifier for a proof created using the Mega flavor. It is similar in structure to its native counterpart with two main differences: 1) the curve types are stdlib types (e.g. field_t instead of field) and 2) it does not specify any Prover related types (e.g. Polynomial, ExtendedEdges, etc.) since we do not emulate prover computation in circuits, i.e. it only makes sense to instantiate a Verifier with this flavor.

Note
Unlike conventional flavors, "recursive" flavors are templated by a builder (much like native vs stdlib types). This is because the flavor itself determines the details of the underlying verifier algorithm (i.e. the set of relations), while the Builder determines the arithmetization of that algorithm into a circuit.
Template Parameters
BuilderTypeDetermines the arithmetization of the verifier circuit defined based on this flavor.

Definition at line 39 of file mega_recursive_flavor.hpp.

Member Typedef Documentation

◆ CircuitBuilder

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::CircuitBuilder = BuilderType

Definition at line 41 of file mega_recursive_flavor.hpp.

◆ Commitment

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::Commitment = typename Curve::Element

Definition at line 46 of file mega_recursive_flavor.hpp.

◆ CommitmentLabels

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::CommitmentLabels = MegaFlavor::CommitmentLabels

Definition at line 200 of file mega_recursive_flavor.hpp.

◆ Curve

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::Curve = stdlib::bn254<CircuitBuilder>

Definition at line 42 of file mega_recursive_flavor.hpp.

◆ FF

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::FF = typename Curve::ScalarField

Definition at line 45 of file mega_recursive_flavor.hpp.

◆ GroupElement

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::GroupElement = typename Curve::Element

Definition at line 44 of file mega_recursive_flavor.hpp.

◆ NativeFlavor

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::NativeFlavor = MegaFlavor

Definition at line 47 of file mega_recursive_flavor.hpp.

◆ PCS

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::PCS = KZG<Curve>

Definition at line 43 of file mega_recursive_flavor.hpp.

◆ Relations

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::Relations = MegaFlavor::Relations_<FF>

Definition at line 75 of file mega_recursive_flavor.hpp.

◆ SubrelationSeparators

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::SubrelationSeparators = std::array<FF, NUM_SUBRELATIONS - 1>

Definition at line 93 of file mega_recursive_flavor.hpp.

◆ Transcript

◆ VerifierCommitmentKey

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::VerifierCommitmentKey = bb::VerifierCommitmentKey<NativeFlavor::Curve>

Definition at line 54 of file mega_recursive_flavor.hpp.

◆ VerifierCommitments

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::VerifierCommitments = MegaFlavor::VerifierCommitments_<Commitment, VerificationKey>

Definition at line 202 of file mega_recursive_flavor.hpp.

◆ VKAndHash

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::VKAndHash = VKAndHash_<FF, VerificationKey>

Definition at line 204 of file mega_recursive_flavor.hpp.

◆ WitnessCommitments

template<typename BuilderType >
using bb::MegaRecursiveFlavor_< BuilderType >::WitnessCommitments = MegaFlavor::WitnessEntities<Commitment>

A container for the witness commitments.

Definition at line 198 of file mega_recursive_flavor.hpp.

Member Data Documentation

◆ BATCHED_RELATION_PARTIAL_LENGTH

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::BATCHED_RELATION_PARTIAL_LENGTH = MAX_PARTIAL_RELATION_LENGTH + 1
staticconstexpr

Definition at line 83 of file mega_recursive_flavor.hpp.

◆ HasZK

template<typename BuilderType >
constexpr bool bb::MegaRecursiveFlavor_< BuilderType >::HasZK = false
staticconstexpr

Definition at line 56 of file mega_recursive_flavor.hpp.

◆ MAX_PARTIAL_RELATION_LENGTH

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::MAX_PARTIAL_RELATION_LENGTH = compute_max_partial_relation_length<Relations>()
staticconstexpr

Definition at line 77 of file mega_recursive_flavor.hpp.

◆ MAX_TOTAL_RELATION_LENGTH

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::MAX_TOTAL_RELATION_LENGTH = compute_max_total_relation_length<Relations>()
staticconstexpr

Definition at line 78 of file mega_recursive_flavor.hpp.

◆ NUM_ALL_ENTITIES

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_ALL_ENTITIES = MegaFlavor::NUM_ALL_ENTITIES
staticconstexpr

Definition at line 64 of file mega_recursive_flavor.hpp.

◆ NUM_FOLDED_ENTITIES

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_FOLDED_ENTITIES = NUM_PRECOMPUTED_ENTITIES + NUM_WITNESS_ENTITIES
staticconstexpr

Definition at line 71 of file mega_recursive_flavor.hpp.

◆ NUM_PRECOMPUTED_ENTITIES

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_PRECOMPUTED_ENTITIES = MegaFlavor::NUM_PRECOMPUTED_ENTITIES
staticconstexpr

Definition at line 67 of file mega_recursive_flavor.hpp.

◆ NUM_RELATIONS

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_RELATIONS = std::tuple_size_v<Relations>
staticconstexpr

Definition at line 87 of file mega_recursive_flavor.hpp.

◆ NUM_SUBRELATIONS

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_SUBRELATIONS = MegaFlavor::NUM_SUBRELATIONS
staticconstexpr

Definition at line 92 of file mega_recursive_flavor.hpp.

◆ NUM_WIRES

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_WIRES = MegaFlavor::NUM_WIRES
staticconstexpr

Definition at line 60 of file mega_recursive_flavor.hpp.

◆ NUM_WITNESS_ENTITIES

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::NUM_WITNESS_ENTITIES = MegaFlavor::NUM_WITNESS_ENTITIES
staticconstexpr

Definition at line 69 of file mega_recursive_flavor.hpp.

◆ REPEATED_COMMITMENTS

template<typename BuilderType >
constexpr RepeatedCommitmentsData bb::MegaRecursiveFlavor_< BuilderType >::REPEATED_COMMITMENTS = MegaFlavor::REPEATED_COMMITMENTS
staticconstexpr

Definition at line 85 of file mega_recursive_flavor.hpp.

◆ USE_PADDING

template<typename BuilderType >
constexpr bool bb::MegaRecursiveFlavor_< BuilderType >::USE_PADDING = MegaFlavor::USE_PADDING
staticconstexpr

Definition at line 59 of file mega_recursive_flavor.hpp.

◆ USE_SHORT_MONOMIALS

template<typename BuilderType >
constexpr bool bb::MegaRecursiveFlavor_< BuilderType >::USE_SHORT_MONOMIALS = MegaFlavor::USE_SHORT_MONOMIALS
staticconstexpr

Definition at line 52 of file mega_recursive_flavor.hpp.

◆ VIRTUAL_LOG_N

template<typename BuilderType >
constexpr size_t bb::MegaRecursiveFlavor_< BuilderType >::VIRTUAL_LOG_N = MegaFlavor::VIRTUAL_LOG_N
staticconstexpr

Definition at line 50 of file mega_recursive_flavor.hpp.


The documentation for this class was generated from the following files: