Skip to content

Commit a2310d9

Browse files
committed
Merge branch 'next' of github.com:AztecProtocol/aztec-packages into gj/the_great_wallet_refactor
2 parents 9d38e96 + 7be3515 commit a2310d9

File tree

25 files changed

+104
-57
lines changed

25 files changed

+104
-57
lines changed

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.87.6"
2+
".": "1.2.1"
33
}

.test_patterns.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,10 @@ tests:
137137
- regex: "src/e2e_p2p/preferred_gossip_network.test.ts"
138138
owners:
139139
- *palla
140+
- regex: "src/e2e_p2p/gossip_network.test.ts"
141+
error_regex: "Block 5 not yet synced"
142+
owners:
143+
- *palla
140144
- regex: "src/e2e_fees/private_payments"
141145
owners:
142146
- *phil

barretenberg/cpp/src/barretenberg/benchmark/protogalaxy_bench/protogalaxy.bench.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ using FF = typename Flavor::FF;
1717

1818
void vector_of_evaluations(State& state) noexcept
1919
{
20-
using RelationEvaluations = typename Flavor::TupleOfArraysOfValues;
20+
using RelationEvaluations = decltype(create_tuple_of_arrays_of_values<typename Flavor::Relations>());
2121

2222
for (auto _ : state) {
2323
std::vector<RelationEvaluations> evals(1 << state.range(0));

barretenberg/cpp/src/barretenberg/dsl/acir_format/avm2_recursion_constraint.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
// external_2: { status: not started, auditors: [], date: YYYY-MM-DD }
55
// =====================
66

7+
#include "barretenberg/numeric/bitop/get_msb.hpp"
78
#ifndef DISABLE_AZTEC_VM
89

910
#include "avm2_recursion_constraint.hpp"
@@ -16,6 +17,7 @@
1617
#include "barretenberg/stdlib/primitives/pairing_points.hpp"
1718
#include "barretenberg/vm2/common/avm_inputs.hpp"
1819
#include "barretenberg/vm2/common/aztec_constants.hpp"
20+
#include "barretenberg/vm2/common/constants.hpp"
1921
#include "barretenberg/vm2/constraining/recursion/goblin_avm_recursive_verifier.hpp"
2022
#include "barretenberg/vm2/constraining/recursion/recursive_flavor.hpp"
2123
#include "barretenberg/vm2/constraining/recursion/recursive_verifier.hpp"
@@ -63,7 +65,7 @@ void create_dummy_vkey_and_proof(Builder& builder,
6365
// (proof_size - Flavor::NUM_WITNESS_ENTITIES * Flavor::NUM_FRS_COM -
6466
// (Flavor::NUM_ALL_ENTITIES + 1) * Flavor::NUM_FRS_FR - Flavor::NUM_FRS_COM) /
6567
// (Flavor::NUM_FRS_COM + Flavor::NUM_FRS_FR * (Flavor::BATCHED_RELATION_PARTIAL_LENGTH + 1));
66-
const auto log_circuit_size = CONST_PROOF_SIZE_LOG_N;
68+
const auto log_circuit_size = numeric::get_msb(avm2::CIRCUIT_SUBGROUP_SIZE);
6769

6870
// First key field is log circuit size
6971
builder.set_variable(key_fields[0].witness_index, log_circuit_size);

barretenberg/cpp/src/barretenberg/eccvm/eccvm_flavor.hpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -149,16 +149,10 @@ class ECCVMFlavor {
149149
/* 29 Shplonk Q commitment */ (num_frs_comm) +
150150
/* 30 IPA proof */ IPA_PROOF_LENGTH;
151151

152-
// Instantiate the BarycentricData needed to extend each Relation Univariate
153-
154-
// define the containers for storing the contributions from each relation in Sumcheck
155-
using SumcheckTupleOfTuplesOfUnivariates = decltype(create_sumcheck_tuple_of_tuples_of_univariates<Relations>());
156-
157152
// The sub-protocol `compute_translation_opening_claims` outputs an opening claim for the batched univariate
158153
// evaluation of `op`, `Px`, `Py`, `z1`, and `z2`, and an array of opening claims for the evaluations of the
159154
// SmallSubgroupIPA witness polynomials.
160155
static constexpr size_t NUM_TRANSLATION_OPENING_CLAIMS = NUM_SMALL_IPA_EVALUATIONS + 1;
161-
using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values<Relations>());
162156

163157
// TODO(https://github.com/AztecProtocol/barretenberg/issues/989): refine access specifiers in flavors, this is
164158
// public as it is also used in the recursive flavor but the two could possibly me unified eventually

barretenberg/cpp/src/barretenberg/flavor/mega_flavor.hpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,6 @@ class MegaFlavor {
131131
decltype(create_protogalaxy_tuple_of_tuples_of_univariates<Relations,
132132
NUM_KEYS,
133133
/*optimised=*/true>());
134-
using SumcheckTupleOfTuplesOfUnivariates = decltype(create_sumcheck_tuple_of_tuples_of_univariates<Relations>());
135-
using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values<Relations>());
136134

137135
// Whether or not the first row of the execution trace is reserved for 0s to enable shifts
138136
static constexpr bool has_zero_row = true;

barretenberg/cpp/src/barretenberg/flavor/mega_recursive_flavor.hpp

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,6 @@ template <typename BuilderType> class MegaRecursiveFlavor_ {
9292
static constexpr size_t NUM_SUBRELATIONS = MegaFlavor::NUM_SUBRELATIONS;
9393
using SubrelationSeparators = std::array<FF, NUM_SUBRELATIONS - 1>;
9494

95-
// define the container for storing the univariate contribution from each relation in Sumcheck
96-
using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values<Relations>());
97-
9895
/**
9996
* @brief A field element for each entity of the flavor. These entities represent the prover polynomials evaluated
10097
* at one point.
@@ -179,6 +176,20 @@ template <typename BuilderType> class MegaRecursiveFlavor_ {
179176
}
180177
return VerificationKey(builder, vk_fields);
181178
}
179+
180+
/**
181+
* @brief Fixes witnesses of VK to be constants.
182+
*
183+
*/
184+
void fix_witness()
185+
{
186+
this->log_circuit_size.fix_witness();
187+
this->num_public_inputs.fix_witness();
188+
this->pub_inputs_offset.fix_witness();
189+
for (Commitment& commitment : this->get_all()) {
190+
commitment.fix_witness();
191+
}
192+
}
182193
};
183194

184195
/**

barretenberg/cpp/src/barretenberg/flavor/ultra_flavor.hpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,6 @@ class UltraFlavor {
137137
decltype(create_protogalaxy_tuple_of_tuples_of_univariates<Relations,
138138
NUM_KEYS,
139139
/*optimised=*/true>());
140-
using SumcheckTupleOfTuplesOfUnivariates = decltype(create_sumcheck_tuple_of_tuples_of_univariates<Relations>());
141-
using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values<Relations>());
142140

143141
// Whether or not the first row of the execution trace is reserved for 0s to enable shifts
144142
static constexpr bool has_zero_row = true;

barretenberg/cpp/src/barretenberg/flavor/ultra_recursive_flavor.hpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,9 +103,6 @@ template <typename BuilderType> class UltraRecursiveFlavor_ {
103103
static constexpr size_t NUM_SUBRELATIONS = NativeFlavor::NUM_SUBRELATIONS;
104104
using SubrelationSeparators = std::array<FF, NUM_SUBRELATIONS - 1>;
105105

106-
// define the container for storing the univariate contribution from each relation in Sumcheck
107-
using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values<Relations>());
108-
109106
/**
110107
* @brief The verification key is responsible for storing the commitments to the precomputed (non-witnessk)
111108
* polynomials used by the verifier.

barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,8 @@ TEST(Protogalaxy, CombinerOptimizationConsistency)
355355
RelationParameters<FF> relation_parameters;
356356
// Temporary accumulator to compute the sumcheck on the second key
357357
// Note: {} is required to initialize the tuple contents. Otherwise the values contain garbage.
358-
typename Flavor::TupleOfArraysOfValues temporary_accumulator{};
358+
using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values<typename Flavor::Relations>());
359+
TupleOfArraysOfValues temporary_accumulator{};
359360

360361
// Accumulate arithmetic relation over 2 rows on the second key
361362
for (size_t i = 0; i < 2; i++) {
@@ -391,7 +392,7 @@ TEST(Protogalaxy, CombinerOptimizationConsistency)
391392
// Compute the sum for each index separately, treating each extended key independently
392393
for (size_t idx = 0; idx < UNIVARIATE_LENGTH; idx++) {
393394
// Note: {} is required to initialize the tuple contents. Otherwise the values contain garbage.
394-
typename Flavor::TupleOfArraysOfValues accumulator{};
395+
TupleOfArraysOfValues accumulator{};
395396
if (idx < NUM_KEYS) {
396397
for (size_t i = 0; i < 2; i++) {
397398
UltraArithmeticRelation::accumulate(std::get<0>(accumulator),

0 commit comments

Comments
 (0)