Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
ultra_recursive_flavor.hpp
Go to the documentation of this file.
1// === AUDIT STATUS ===
2// internal: { status: Completed, auditors: [Sergei], commit: }
3// external_1: { status: not started, auditors: [], commit: }
4// external_2: { status: not started, auditors: [], commit: }
5// =====================
6
7#pragma once
11
12namespace bb {
13
28template <typename BuilderType> class UltraRecursiveFlavor_ {
29 public:
30 using CircuitBuilder = BuilderType; // Determines arithmetization of circuit instantiated with this flavor
32 using PCS = KZG<Curve>;
33 using GroupElement = typename Curve::Element;
34 using Commitment = typename Curve::Element;
35 using FF = typename Curve::ScalarField;
40
41 static constexpr size_t VIRTUAL_LOG_N = UltraFlavor::VIRTUAL_LOG_N;
42 // indicates when evaluating sumcheck, edges can be left as degree-1 monomials
44
45 // Indicates that this flavor runs with non-ZK Sumcheck.
46 static constexpr bool HasZK = false;
48 static constexpr bool HasElliptic = UltraFlavor::HasElliptic;
49 static constexpr bool HasMemory = UltraFlavor::HasMemory;
52 static constexpr bool HasDataBus = UltraFlavor::HasDataBus;
53 // To achieve fixed proof size and that the recursive verifier circuit is constant, we are using padding in Sumcheck
54 // and Shplemini
55 static constexpr bool USE_PADDING = UltraFlavor::USE_PADDING;
56 static constexpr size_t NUM_WIRES = UltraFlavor::NUM_WIRES;
60
61 static constexpr size_t FINAL_PCS_MSM_SIZE(size_t log_n = VIRTUAL_LOG_N)
62 {
64 };
66
67 // define the tuple of Relations that comprise the Sumcheck relation
69
70 static constexpr size_t MAX_PARTIAL_RELATION_LENGTH = compute_max_partial_relation_length<Relations>();
72 static constexpr size_t NUM_RELATIONS = std::tuple_size<Relations>::value;
73
74 // A challenge whose powers are used to batch subrelation contributions during Sumcheck
77
81
87 public:
89 using Base::Base;
90 };
91
94
96
98};
99
100} // namespace bb
Common transcript class for both parties. Stores the data for the current round, as well as the manif...
Base Native verification key class.
Definition flavor.hpp:138
Base Stdlib verification key class.
Definition flavor.hpp:378
static constexpr size_t NUM_PRECOMPUTED_ENTITIES
std::tuple< bb::UltraPermutationRelation< FF >, bb::LogDerivLookupRelation< FF >, bb::ArithmeticRelation< FF >, bb::DeltaRangeConstraintRelation< FF >, bb::EllipticRelation< FF >, bb::MemoryRelation< FF >, bb::NonNativeFieldRelation< FF >, bb::Poseidon2ExternalRelation< FF >, bb::Poseidon2InternalRelation< FF > > Relations_
static constexpr RepeatedCommitmentsData REPEATED_COMMITMENTS
static constexpr bool HasLogDerivLookup
static constexpr bool HasNonNativeField
static constexpr size_t NUM_ALL_ENTITIES
static constexpr size_t NUM_WITNESS_ENTITIES
static const CommitmentLabels & commitment_labels()
static constexpr bool USE_PADDING
static constexpr bool USE_SHORT_MONOMIALS
static constexpr size_t FINAL_PCS_MSM_SIZE(size_t log_n=VIRTUAL_LOG_N)
NativeVerificationKey_< PrecomputedEntities< Commitment >, Codec, HashFunction, CommitmentKey > VerificationKey
The verification key stores commitments to the precomputed (non-witness) polynomials used by the veri...
static constexpr size_t NUM_SUBRELATIONS
static constexpr size_t VIRTUAL_LOG_N
AllEntities< std::string > CommitmentLabels
static constexpr size_t NUM_WIRES
A field element for each entity of the flavor. These entities represent the prover polynomials evalua...
The recursive counterpart to the "native" Ultra flavor.
static constexpr size_t NUM_PRECOMPUTED_ENTITIES
UltraFlavor::CommitmentLabels CommitmentLabels
static constexpr size_t NUM_ALL_ENTITIES
static constexpr size_t FINAL_PCS_MSM_SIZE(size_t log_n=VIRTUAL_LOG_N)
typename Curve::Element GroupElement
static constexpr bool HasEccOpQueue
static constexpr size_t VIRTUAL_LOG_N
typename Curve::Element Commitment
static constexpr RepeatedCommitmentsData REPEATED_COMMITMENTS
static constexpr bool USE_SHORT_MONOMIALS
static constexpr bool HasNonNativeField
static constexpr size_t NUM_WIRES
UltraFlavor::Relations_< FF > Relations
static constexpr size_t NUM_RELATIONS
static constexpr size_t MAX_PARTIAL_RELATION_LENGTH
typename Curve::ScalarField FF
static const CommitmentLabels & commitment_labels()
static constexpr size_t BATCHED_RELATION_PARTIAL_LENGTH
static constexpr bool HasLogDerivLookup
static constexpr size_t NUM_SUBRELATIONS
static constexpr size_t NUM_WITNESS_ENTITIES
Wrapper holding a verification key and its precomputed hash.
Definition flavor.hpp:551
Entry point for Barretenberg command-line interface.
Definition api.hpp:5
field_t< CircuitBuilder > ScalarField
Definition bn254.hpp:30