From a766b950677850203001d819cb78dbdcbac0877a Mon Sep 17 00:00:00 2001 From: maramihali Date: Mon, 9 Dec 2024 14:59:46 +0000 Subject: [PATCH 01/18] first attempt --- .../cpp/scripts/analyze_client_ivc_bench.py | 2 + .../client_ivc_bench/client_ivc.bench.cpp | 2 +- .../src/barretenberg/goblin/mock_circuits.hpp | 2 +- .../composer/composer_lib.hpp | 14 +- .../composer/composer_lib.test.cpp | 128 +++++++++--------- .../execution_trace_usage_tracker.hpp | 12 +- .../execution_trace/mega_execution_trace.hpp | 82 ++++++----- .../protogalaxy_prover_internal.hpp | 11 +- .../relations/logderiv_lookup_relation.hpp | 4 +- .../stdlib_circuit_builders/mega_flavor.hpp | 33 +++-- .../ultra_honk/decider_proving_key.hpp | 46 ++++--- 11 files changed, 192 insertions(+), 144 deletions(-) diff --git a/barretenberg/cpp/scripts/analyze_client_ivc_bench.py b/barretenberg/cpp/scripts/analyze_client_ivc_bench.py index 600854679c5e..7ca1bec619a2 100755 --- a/barretenberg/cpp/scripts/analyze_client_ivc_bench.py +++ b/barretenberg/cpp/scripts/analyze_client_ivc_bench.py @@ -17,6 +17,8 @@ to_keep = [ "construct_circuits(t)", "DeciderProvingKey(Circuit&)(t)", + "Lookup::compute_logderivative_inverse(t)", + "Databus::compute_logderivative_inverse(t)", "ProtogalaxyProver::prove(t)", "Decider::construct_proof(t)", "ECCVMProver(CircuitBuilder&)(t)", diff --git a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp index 6033648972c4..7aa1b8910d83 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp @@ -33,7 +33,7 @@ class ClientIVCBench : public benchmark::Fixture { */ BENCHMARK_DEFINE_F(ClientIVCBench, Full)(benchmark::State& state) { - ClientIVC ivc{ { CLIENT_IVC_BENCH_STRUCTURE } }; + ClientIVC ivc{ { EXAMPLE_20 } }; auto total_num_circuits = 2 * static_cast(state.range(0)); // 2x accounts for kernel circuits auto mocked_vkeys = mock_verification_keys(total_num_circuits); diff --git a/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp b/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp index 03c86a55b083..95bc3a46d5af 100644 --- a/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp +++ b/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp @@ -25,13 +25,13 @@ namespace bb { static constexpr TraceStructure SMALL_TEST_STRUCTURE_FOR_OVERFLOWS{ .ecc_op = 1 << 14, .pub_inputs = 1 << 14, .busread = 1 << 14, + .lookup = 1 << 14, .arithmetic = 1 << 15, .delta_range = 1 << 14, .elliptic = 1 << 14, .aux = 1 << 14, .poseidon2_external = 1 << 14, .poseidon2_internal = 1 << 15, - .lookup = 1 << 14, .overflow = 0 }; class GoblinMockCircuits { diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp index 1216623ee32a..bab96617dd4f 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp @@ -24,7 +24,10 @@ void construct_lookup_table_polynomials(const RefArray tables_size + additional_offset); - size_t offset = dyadic_circuit_size - tables_size - additional_offset; + size_t offset = Flavor::has_zero_row ? 1 : 0; + // if constexpr (IsPlonkFlavor) { + // offset = dyadic_circuit_size - tables_size - additional_offset; + // } for (const auto& table : circuit.lookup_tables) { const fr table_index(table.table_index); @@ -50,11 +53,14 @@ template void construct_lookup_read_counts(typename Flavor::Polynomial& read_counts, typename Flavor::Polynomial& read_tags, typename Flavor::CircuitBuilder& circuit, - const size_t dyadic_circuit_size) + [[maybe_unused]] const size_t dyadic_circuit_size = 0) { - const size_t tables_size = circuit.get_tables_size(); + // const size_t tables_size = circuit.get_tables_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace - size_t table_offset = dyadic_circuit_size - tables_size; + size_t table_offset = Flavor::has_zero_row ? 1 : 0; + // if constexpr (IsPlonkFlavor) { + // offset = dyadic_circuit_size - tables_size - additional_offset; + // } // loop over all tables used in the circuit; each table contains data about the lookups made on it for (auto& table : circuit.lookup_tables) { diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp index 0cd69e9f523d..02a17a0c1c51 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp @@ -1,77 +1,81 @@ -#include "barretenberg/plonk_honk_shared/composer/composer_lib.hpp" -#include "barretenberg/srs/factories/crs_factory.hpp" -#include "barretenberg/stdlib_circuit_builders/ultra_circuit_builder.hpp" -#include "barretenberg/stdlib_circuit_builders/ultra_flavor.hpp" +// #include "barretenberg/plonk_honk_shared/composer/composer_lib.hpp" +// #include "barretenberg/srs/factories/crs_factory.hpp" +// #include "barretenberg/stdlib_circuit_builders/ultra_circuit_builder.hpp" +// #include "barretenberg/stdlib_circuit_builders/ultra_flavor.hpp" -#include -#include +// #include +// #include -using namespace bb; +// using namespace bb; -class ComposerLibTests : public ::testing::Test { - public: - using Flavor = UltraFlavor; - using FF = typename Flavor::FF; +// class ComposerLibTests : public ::testing::Test { +// public: +// using Flavor = UltraFlavor; +// using FF = typename Flavor::FF; - protected: - static void SetUpTestSuite() { bb::srs::init_crs_factory("../srs_db/ignition"); } -}; +// protected: +// static void SetUpTestSuite() { bb::srs::init_crs_factory("../srs_db/ignition"); } +// }; -/** - * @brief A test to demonstrate that lookup read counts/tags are computed correctly for a simple 'hand-computable' case - * using the uint32 XOR table - * - */ -TEST_F(ComposerLibTests, LookupReadCounts) -{ - using Builder = UltraCircuitBuilder; - using Flavor = UltraFlavor; - using FF = typename Flavor::FF; - using Polynomial = typename Flavor::Polynomial; - auto UINT32_XOR = plookup::MultiTableId::UINT32_XOR; +// /** +// * @brief A test to demonstrate that lookup read counts/tags are computed correctly for a simple 'hand-computable' +// case +// * using the uint32 XOR table +// * +// */ +// TEST_F(ComposerLibTests, LookupReadCounts) +// { +// using Builder = UltraCircuitBuilder; +// using Flavor = UltraFlavor; +// using FF = typename Flavor::FF; +// using Polynomial = typename Flavor::Polynomial; +// auto UINT32_XOR = plookup::MultiTableId::UINT32_XOR; - Builder builder; +// Builder builder; - // define some very simply inputs to XOR - FF left{ 1 }; - FF right{ 5 }; +// // define some very simply inputs to XOR +// FF left{ 1 }; +// FF right{ 5 }; - auto left_idx = builder.add_variable(left); - auto right_idx = builder.add_variable(right); +// auto left_idx = builder.add_variable(left); +// auto right_idx = builder.add_variable(right); - // create a single lookup from the uint32 XOR table - auto accumulators = plookup::get_lookup_accumulators(UINT32_XOR, left, right, /*is_2_to_1_lookup*/ true); - builder.create_gates_from_plookup_accumulators(UINT32_XOR, accumulators, left_idx, right_idx); +// // create a single lookup from the uint32 XOR table +// auto accumulators = plookup::get_lookup_accumulators(UINT32_XOR, left, right, /*is_2_to_1_lookup*/ true); +// builder.create_gates_from_plookup_accumulators(UINT32_XOR, accumulators, left_idx, right_idx); - EXPECT_EQ(builder.lookup_tables.size(), 1); // we only used a single table - EXPECT_EQ(builder.lookup_tables[0].size(), 4096); // table has size 64*64 (6 bit operands) +// EXPECT_EQ(builder.lookup_tables.size(), 1); // we only used a single table +// EXPECT_EQ(builder.lookup_tables[0].size(), 4096); // table has size 64*64 (6 bit operands) - size_t circuit_size = 8192; +// size_t circuit_size = 8192; - Polynomial read_counts{ circuit_size }; - Polynomial read_tags{ circuit_size }; +// Polynomial read_counts{ circuit_size }; +// Polynomial read_tags{ circuit_size }; - construct_lookup_read_counts(read_counts, read_tags, builder, circuit_size); +// construct_lookup_read_counts(read_counts, read_tags, builder, circuit_size); - // The table polys are constructed at the bottom of the trace, thus so to are the counts/tags - // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace - size_t offset = circuit_size - builder.get_tables_size(); +// // The table polys are constructed at the bottom of the trace, thus so to are the counts/tags +// // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace +// size_t offset = Flavor::has_zero_row ? 1 : 0; - // The uint32 XOR lookup table is constructed for 6 bit operands via double for loop that iterates through the left - // operand externally (0 to 63) then the right operand internally (0 to 63). Computing (1 XOR 5) will thus result in - // 1 lookup from the (1*64 + 5)th index in the table and 5 lookups from the (0*64 + 0)th index (for the remaining 5 - // limbs that are all 0). The counts and tags at all other indices should be zero. - for (auto [idx, count, tag] : zip_polys(read_counts, read_tags)) { - if (idx == (0 + offset)) { - EXPECT_EQ(count, 5); - EXPECT_EQ(tag, 1); - } else if (idx == (69 + offset)) { - EXPECT_EQ(count, 1); - EXPECT_EQ(tag, 1); - } else { - EXPECT_EQ(count, 0); - EXPECT_EQ(tag, 0); - } - idx++; - } -} \ No newline at end of file +// // The uint32 XOR lookup table is constructed for 6 bit operands via double for loop that iterates through the +// left +// // operand externally (0 to 63) then the right operand internally (0 to 63). Computing (1 XOR 5) will thus result +// in +// // 1 lookup from the (1*64 + 5)th index in the table and 5 lookups from the (0*64 + 0)th index (for the remaining +// 5 +// // limbs that are all 0). The counts and tags at all other indices should be zero. +// for (auto [idx, count, tag] : zip_polys(read_counts, read_tags)) { +// if (idx == (0 + offset)) { +// EXPECT_EQ(count, 5); +// EXPECT_EQ(tag, 1); +// } else if (idx == (69 + offset)) { +// EXPECT_EQ(count, 1); +// EXPECT_EQ(tag, 1); +// } else { +// EXPECT_EQ(count, 0); +// EXPECT_EQ(tag, 0); +// } +// idx++; +// } +// } \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index 91837b267dda..0c3685d93d38 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -84,7 +84,7 @@ struct ExecutionTraceUsageTracker { for (auto [max_size, fixed_block] : zip_view(max_sizes.get(), fixed_sizes.get())) { size_t start_idx = fixed_block.trace_offset; size_t end_idx = start_idx + max_size; - active_ranges.push_back(Range{ start_idx, end_idx }); + active_ranges.emplace_back(start_idx, end_idx); } // The active ranges must also include the rows where the actual databus and lookup table data are stored. @@ -93,16 +93,16 @@ struct ExecutionTraceUsageTracker { // the same fixed block sizes but might also have an overflow block potentially influencing the dyadic circuit // size. // TODO(https://github.com/AztecProtocol/barretenberg/issues/1160) - const size_t dyadic_circuit_size = circuit.blocks.get_structured_dyadic_size(); + // const size_t dyadic_circuit_size = circuit.blocks.get_structured_dyadic_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1152): should be able to use simply Range{ 0, // max_databus_size } but this breaks for certain choices of num_threads. size_t databus_end = std::max(max_databus_size, static_cast(fixed_sizes.busread.trace_offset + max_sizes.busread)); - active_ranges.push_back(Range{ 0, databus_end }); - size_t lookups_start = - std::min(dyadic_circuit_size - max_tables_size, static_cast(fixed_sizes.lookup.trace_offset)); - active_ranges.push_back(Range{ lookups_start, dyadic_circuit_size }); + active_ranges.emplace_back(0, databus_end); + size_t lookups_end = + std::max(max_tables_size, static_cast(fixed_sizes.lookup.trace_offset + max_sizes.lookup)); + active_ranges.emplace_back(0, lookups_end); } // Check whether an index is contained within the active ranges (or previous active ranges; needed for perturbator) diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp index a24d4131a93e..2abe11904474 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp @@ -19,13 +19,13 @@ template struct MegaTraceBlockData { T ecc_op; T pub_inputs; T busread; + T lookup; T arithmetic; T delta_range; T elliptic; T aux; T poseidon2_external; T poseidon2_internal; - T lookup; T overflow; // block gates of arbitrary type that overflow their designated block std::vector get_labels() const @@ -33,36 +33,50 @@ template struct MegaTraceBlockData { return { "ecc_op", "pub_inputs", "busread", + "lookup", "arithmetic", "delta_range", "elliptic", "aux", "poseidon2_external", "poseidon2_internal", - "lookup", "overflow" }; } auto get() { - return RefArray{ - ecc_op, pub_inputs, busread, arithmetic, delta_range, elliptic, aux, poseidon2_external, poseidon2_internal, - lookup, overflow - }; + return RefArray{ ecc_op, + pub_inputs, + busread, + lookup, + arithmetic, + delta_range, + elliptic, + aux, + poseidon2_external, + poseidon2_internal, + overflow }; } auto get() const { - return RefArray{ - ecc_op, pub_inputs, busread, arithmetic, delta_range, elliptic, aux, poseidon2_external, poseidon2_internal, - lookup, overflow - }; + return RefArray{ ecc_op, + pub_inputs, + busread, + lookup, + arithmetic, + delta_range, + elliptic, + aux, + poseidon2_external, + poseidon2_internal, + overflow }; } auto get_gate_blocks() { return RefArray{ - busread, arithmetic, delta_range, elliptic, aux, poseidon2_external, poseidon2_internal, lookup + busread, lookup, arithmetic, delta_range, elliptic, aux, poseidon2_external, poseidon2_internal, }; } @@ -125,24 +139,26 @@ class MegaTraceBlock : public ExecutionTraceBlockselectors[4]; }; auto& q_4() { return this->selectors[5]; }; auto& q_busread() { return this->selectors[6]; }; - auto& q_arith() { return this->selectors[7]; }; - auto& q_delta_range() { return this->selectors[8]; }; - auto& q_elliptic() { return this->selectors[9]; }; - auto& q_aux() { return this->selectors[10]; }; - auto& q_poseidon2_external() { return this->selectors[11]; }; - auto& q_poseidon2_internal() { return this->selectors[12]; }; - auto& q_lookup_type() { return this->selectors[13]; }; + auto& q_lookup_type() { return this->selectors[7]; }; + auto& q_arith() { return this->selectors[8]; }; + auto& q_delta_range() { return this->selectors[9]; }; + auto& q_elliptic() { return this->selectors[10]; }; + auto& q_aux() { return this->selectors[11]; }; + auto& q_poseidon2_external() { return this->selectors[12]; }; + auto& q_poseidon2_internal() { return this->selectors[13]; }; RefVector get_gate_selectors() { - return { q_busread(), - q_arith(), - q_delta_range(), - q_elliptic(), - q_aux(), - q_poseidon2_external(), - q_poseidon2_internal(), - q_lookup_type() }; + return { + q_busread(), + q_lookup_type(), + q_arith(), + q_delta_range(), + q_elliptic(), + q_aux(), + q_poseidon2_external(), + q_poseidon2_internal(), + }; } /** @@ -216,13 +232,13 @@ class MegaExecutionTraceBlocks : public MegaTraceBlockData { this->pub_inputs.get_fixed_size(), " (populated in decider pk constructor)"); info("busread :\t", this->busread.size(), "/", this->busread.get_fixed_size()); + info("lookups :\t", this->lookup.size(), "/", this->lookup.get_fixed_size()); info("arithmetic :\t", this->arithmetic.size(), "/", this->arithmetic.get_fixed_size()); info("delta range :\t", this->delta_range.size(), "/", this->delta_range.get_fixed_size()); info("elliptic :\t", this->elliptic.size(), "/", this->elliptic.get_fixed_size()); info("auxiliary :\t", this->aux.size(), "/", this->aux.get_fixed_size()); info("poseidon ext :\t", this->poseidon2_external.size(), "/", this->poseidon2_external.get_fixed_size()); info("poseidon int :\t", this->poseidon2_internal.size(), "/", this->poseidon2_internal.get_fixed_size()); - info("lookups :\t", this->lookup.size(), "/", this->lookup.get_fixed_size()); info("overflow :\t", this->overflow.size(), "/", this->overflow.get_fixed_size()); info(""); } @@ -253,13 +269,13 @@ class MegaExecutionTraceBlocks : public MegaTraceBlockData { static constexpr TraceStructure TINY_TEST_STRUCTURE{ .ecc_op = 18, .pub_inputs = 1, .busread = 3, + .lookup = 2, .arithmetic = 1 << 14, .delta_range = 5, .elliptic = 2, .aux = 10, .poseidon2_external = 2, .poseidon2_internal = 2, - .lookup = 2, .overflow = 0 }; /** @@ -268,13 +284,13 @@ static constexpr TraceStructure TINY_TEST_STRUCTURE{ .ecc_op = 18, static constexpr TraceStructure SMALL_TEST_STRUCTURE{ .ecc_op = 1 << 14, .pub_inputs = 1 << 14, .busread = 1 << 14, + .lookup = 1 << 14, .arithmetic = 1 << 15, .delta_range = 1 << 14, .elliptic = 1 << 14, .aux = 1 << 14, .poseidon2_external = 1 << 14, .poseidon2_internal = 1 << 15, - .lookup = 1 << 14, .overflow = 0 }; /** @@ -284,13 +300,13 @@ static constexpr TraceStructure SMALL_TEST_STRUCTURE{ .ecc_op = 1 << 14, static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .ecc_op = 1 << 10, .pub_inputs = 1 << 7, .busread = 1 << 7, + .lookup = 72000, .arithmetic = 198000, .delta_range = 90000, .elliptic = 9000, .aux = 136000, .poseidon2_external = 2500, .poseidon2_internal = 14000, - .lookup = 72000, .overflow = 0 }; /** @@ -299,13 +315,13 @@ static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .ecc_op = 1 << 10, static constexpr TraceStructure EXAMPLE_18{ .ecc_op = 1 << 10, .pub_inputs = 1 << 6, .busread = 1 << 6, + .lookup = 36000, .arithmetic = 84000, .delta_range = 45000, .elliptic = 9000, .aux = 68000, .poseidon2_external = 2500, .poseidon2_internal = 14000, - .lookup = 36000, .overflow = 0 }; /** @@ -314,13 +330,13 @@ static constexpr TraceStructure EXAMPLE_18{ .ecc_op = 1 << 10, static constexpr TraceStructure EXAMPLE_20{ .ecc_op = 1 << 11, .pub_inputs = 1 << 8, .busread = 1 << 8, + .lookup = 144000, .arithmetic = 396000, .delta_range = 180000, .elliptic = 18000, .aux = 272000, .poseidon2_external = 5000, .poseidon2_internal = 28000, - .lookup = 144000, .overflow = 0 }; /** @@ -329,13 +345,13 @@ static constexpr TraceStructure EXAMPLE_20{ .ecc_op = 1 << 11, static constexpr TraceStructure E2E_FULL_TEST_STRUCTURE{ .ecc_op = 1 << 10, .pub_inputs = 4000, .busread = 6000, + .lookup = 200000, .arithmetic = 200000, .delta_range = 25000, .elliptic = 80000, .aux = 100000, .poseidon2_external = 30128, .poseidon2_internal = 172000, - .lookup = 200000, .overflow = 0 }; template diff --git a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp index c635da8cfa25..c305a94fd252 100644 --- a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp +++ b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp @@ -407,16 +407,17 @@ template class ProtogalaxyProverInternal { // Distribute the execution trace rows across threads so that each handles an equal number of active rows trace_usage_tracker.construct_thread_ranges(num_threads, common_polynomial_size); + // size_t active = 0; // Accumulate the contribution from each sub-relation parallel_for(num_threads, [&](size_t thread_idx) { const size_t start = trace_usage_tracker.thread_ranges[thread_idx].first; const size_t end = trace_usage_tracker.thread_ranges[thread_idx].second; - for (size_t idx = start; idx < end; idx++) { if (trace_usage_tracker.check_is_active(idx)) { - // Instantiate univariates, possibly with skipping toto ignore computation in those indices (they - // are still available for skipping relations, but all derived univariate will ignore those - // evaluations) No need to initialise extended_univariates to 0, as it's assigned to. + // active++; + // Instantiate univariates, possibly with skipping toto ignore computation in those indices + // (they are still available for skipping relations, but all derived univariate will ignore + // those evaluations) No need to initialise extended_univariates to 0, as it's assigned to. constexpr size_t skip_count = skip_zero_computations ? DeciderPKs::NUM - 1 : 0; extend_univariates(extended_univariates[thread_idx], keys, idx); @@ -432,7 +433,7 @@ template class ProtogalaxyProverInternal { } } }); - + // info("active: ", active); RelationUtils::zero_univariates(univariate_accumulators); // Accumulate the per-thread univariate accumulators into a single set of accumulators for (auto& accumulators : thread_univariate_accumulators) { diff --git a/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp b/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp index dbd45cc2ed5c..a1c52f33ab47 100644 --- a/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp +++ b/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp @@ -163,12 +163,14 @@ template class LogDerivLookupRelationImpl { size_t num_threads = bb::calculate_num_threads_pow2(circuit_size, min_iterations_per_thread); size_t iterations_per_thread = circuit_size / num_threads; // actual iterations per thread + size_t lookup_active = 0; parallel_for(num_threads, [&](size_t thread_idx) { size_t start = thread_idx * iterations_per_thread; size_t end = (thread_idx + 1) * iterations_per_thread; for (size_t i = start; i < end; ++i) { // We only compute the inverse if this row contains a lookup gate or data that has been looked up if (polynomials.q_lookup.get(i) == 1 || polynomials.lookup_read_tags.get(i) == 1) { + lookup_active++; // TODO(https://github.com/AztecProtocol/barretenberg/issues/940): avoid get_row if possible. auto row = polynomials.get_row(i); // Note: this is a copy. use sparingly! auto value = compute_read_term(row, relation_parameters) * @@ -177,7 +179,7 @@ template class LogDerivLookupRelationImpl { } } }); - + info("lookup active: ", lookup_active); // Compute inverse polynomial I in place by inverting the product at each row FF::batch_invert(inverse_polynomial.coeffs()); }; diff --git a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp index 24919feb2577..884281f464f7 100644 --- a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp @@ -123,13 +123,13 @@ class MegaFlavor { q_o, // column 4 q_4, // column 5 q_busread, // column 6 - q_arith, // column 7 - q_delta_range, // column 8 - q_elliptic, // column 9 - q_aux, // column 10 - q_poseidon2_external, // column 11 - q_poseidon2_internal, // column 12 - q_lookup, // column 13 + q_lookup, // column 7 + q_arith, // column 8 + q_delta_range, // column 9 + q_elliptic, // column 10 + q_aux, // column 11 + q_poseidon2_external, // column 12 + q_poseidon2_internal, // column 13 sigma_1, // column 14 sigma_2, // column 15 sigma_3, // column 16 @@ -154,8 +154,15 @@ class MegaFlavor { auto get_gate_selectors() { return RefArray{ - q_busread, q_arith, q_delta_range, q_elliptic, q_aux, q_poseidon2_external, q_poseidon2_internal, - q_lookup + q_busread, + q_lookup, + q_arith, + q_delta_range, + q_elliptic, + q_aux, + q_poseidon2_external, + q_poseidon2_internal, + }; } auto get_selectors() { return concatenate(get_non_gate_selectors(), get_gate_selectors()); } @@ -644,13 +651,13 @@ class MegaFlavor { const Commitment& q_o, const Commitment& q_4, const Commitment& q_busread, + const Commitment& q_lookup, const Commitment& q_arith, const Commitment& q_delta_range, const Commitment& q_elliptic, const Commitment& q_aux, const Commitment& q_poseidon2_external, const Commitment& q_poseidon2_internal, - const Commitment& q_lookup, const Commitment& sigma_1, const Commitment& sigma_2, const Commitment& sigma_3, @@ -682,13 +689,13 @@ class MegaFlavor { this->q_o = q_o; this->q_4 = q_4; this->q_busread = q_busread; + this->q_lookup = q_lookup; this->q_arith = q_arith; this->q_delta_range = q_delta_range; this->q_elliptic = q_elliptic; this->q_aux = q_aux; this->q_poseidon2_external = q_poseidon2_external; this->q_poseidon2_internal = q_poseidon2_internal; - this->q_lookup = q_lookup; this->sigma_1 = sigma_1; this->sigma_2 = sigma_2; this->sigma_3 = sigma_3; @@ -720,13 +727,13 @@ class MegaFlavor { q_o, q_4, q_busread, + q_lookup, q_arith, q_delta_range, q_elliptic, q_aux, q_poseidon2_external, q_poseidon2_internal, - q_lookup, sigma_1, sigma_2, sigma_3, @@ -826,13 +833,13 @@ class MegaFlavor { q_4 = "Q_4"; q_m = "Q_M"; q_busread = "Q_BUSREAD"; + q_lookup = "Q_LOOKUP"; q_arith = "Q_ARITH"; q_delta_range = "Q_SORT"; q_elliptic = "Q_ELLIPTIC"; q_aux = "Q_AUX"; q_poseidon2_external = "Q_POSEIDON2_EXTERNAL"; q_poseidon2_internal = "Q_POSEIDON2_INTERNAL"; - q_lookup = "Q_LOOKUP"; sigma_1 = "SIGMA_1"; sigma_2 = "SIGMA_2"; sigma_3 = "SIGMA_3"; diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp index 7e114c40a3f4..7d108ccb350f 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp @@ -183,9 +183,12 @@ template class DeciderProvingKey_ { // return_data.size() }); proving_key.polynomials.databus_id = Polynomial(proving_key.circuit_size, proving_key.circuit_size); } - const size_t max_tables_size = - std::min(static_cast(MAX_LOOKUP_TABLES_SIZE), dyadic_circuit_size - 1); - size_t table_offset = dyadic_circuit_size - max_tables_size; + + size_t table_offset = Flavor::has_zero_row ? 1 : 0; + const size_t max_tables_size = std::min(static_cast(MAX_LOOKUP_TABLES_SIZE) - table_offset, + dyadic_circuit_size - table_offset); + // size_t table_offset = dyadic_circuit_size - max_tables_size; + { PROFILE_THIS_NAME("allocating table polynomials"); @@ -218,20 +221,29 @@ template class DeciderProvingKey_ { } { ZoneScopedN("allocating lookup and databus inverses"); + const size_t lookup_block_end = + static_cast((table_offset + circuit.blocks.lookup.get_fixed_size(is_structured))); + const auto tables_end = + std::min(dyadic_circuit_size - table_offset, MAX_LOOKUP_TABLES_SIZE + table_offset); + // Allocate the lookup_inverses polynomial - const size_t lookup_offset = static_cast(circuit.blocks.lookup.trace_offset); - // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts - // at top of trace - const size_t table_offset = - dyadic_circuit_size - - std::min(dyadic_circuit_size - 1, static_cast(MAX_LOOKUP_TABLES_SIZE)); - const size_t lookup_inverses_start = std::min(lookup_offset, table_offset); - const size_t lookup_inverses_end = - std::min(dyadic_circuit_size, - std::max(lookup_offset + circuit.blocks.lookup.get_fixed_size(is_structured), - table_offset + MAX_LOOKUP_TABLES_SIZE)); + // const size_t lookup_offset = static_cast(circuit.blocks.lookup.trace_offset); + // // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts + // // at top of trace + // const size_t table_offset = + // dyadic_circuit_size - + // std::min(dyadic_circuit_size - 1, static_cast(MAX_LOOKUP_TABLES_SIZE)); + // const size_t lookup_inverses_start = std::min(lookup_offset, table_offset); + // const size_t lookup_inverses_end = + // std::min(dyadic_circuit_size, + // std::max(lookup_offset + circuit.blocks.lookup.get_fixed_size(is_structured), + // table_offset + MAX_LOOKUP_TABLES_SIZE)); + const size_t lookup_inverses_start = table_offset; + const size_t lookup_inverses_end = std::max(lookup_block_end, tables_end); proving_key.polynomials.lookup_inverses = Polynomial( lookup_inverses_end - lookup_inverses_start, dyadic_circuit_size, lookup_inverses_start); + // proving_key.polynomials.lookup_inverses = Polynomial( + // lookup_inverses_end - lookup_inverses_start, dyadic_circuit_size, lookup_inverses_start); if constexpr (HasDataBus) { const size_t q_busread_end = circuit.blocks.busread.trace_offset + circuit.blocks.busread.get_fixed_size(is_structured); @@ -302,10 +314,8 @@ template class DeciderProvingKey_ { { PROFILE_THIS_NAME("constructing lookup read counts"); - construct_lookup_read_counts(proving_key.polynomials.lookup_read_counts, - proving_key.polynomials.lookup_read_tags, - circuit, - dyadic_circuit_size); + construct_lookup_read_counts( + proving_key.polynomials.lookup_read_counts, proving_key.polynomials.lookup_read_tags, circuit); } // Construct the public inputs array From d3b289b27a3f2d77c098e14b5a692be375c39122 Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 10 Dec 2024 10:51:38 +0000 Subject: [PATCH 02/18] try to start the comparison bench --- barretenberg/cpp/scripts/analyze_client_ivc_bench.py | 1 + barretenberg/cpp/scripts/compare_branch_vs_baseline.sh | 4 ++-- barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh | 4 ++-- .../cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp | 1 + barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp | 2 +- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/barretenberg/cpp/scripts/analyze_client_ivc_bench.py b/barretenberg/cpp/scripts/analyze_client_ivc_bench.py index 7ca1bec619a2..f844177bf316 100755 --- a/barretenberg/cpp/scripts/analyze_client_ivc_bench.py +++ b/barretenberg/cpp/scripts/analyze_client_ivc_bench.py @@ -18,6 +18,7 @@ "construct_circuits(t)", "DeciderProvingKey(Circuit&)(t)", "Lookup::compute_logderivative_inverse(t)", + "execute_log_derivative_inverse_round(t)", "Databus::compute_logderivative_inverse(t)", "ProtogalaxyProver::prove(t)", "Decider::construct_proof(t)", diff --git a/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh b/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh index f798893781e7..8beb689de454 100755 --- a/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh +++ b/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh @@ -2,7 +2,6 @@ # Install requirements (numpy + scipy) for comparison script if necessary. # Note: By default, installation will occur in $HOME/.local/bin. -# pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt # This script is used to compare a suite of benchmarks between baseline (default: master) and @@ -10,7 +9,7 @@ # it is up to date with local master, and run the script. # Specify the benchmark suite and the "baseline" branch against which to compare -BENCHMARK=${1:-goblin_bench} +BENCHMARK=${1:-client_ivc_bench} FILTER=${2:-""} PRESET=${3:-clang16} BUILD_DIR=${4:-build} @@ -19,6 +18,7 @@ HARDWARE_CONCURRENCY=${HARDWARE_CONCURRENCY:-16} BASELINE_BRANCH="master" BENCH_TOOLS_DIR="$BUILD_DIR/_deps/benchmark-src/tools" +pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt echo -e "\nComparing $BENCHMARK between $BASELINE_BRANCH and current branch:" # Move above script dir. diff --git a/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh b/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh index 7c9192fa3f73..c33f22bfacc5 100755 --- a/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh +++ b/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh @@ -2,7 +2,6 @@ # Install requirements (numpy + scipy) for comparison script if necessary. # Note: By default, installation will occur in $HOME/.local/bin. -# pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt # This script is used to compare a suite of benchmarks between baseline (default: master) and @@ -10,7 +9,7 @@ # it is up to date with local master, and run the script. # Specify the benchmark suite and the "baseline" branch against which to compare -BENCHMARK=${1:-goblin_bench} +BENCHMARK=${1:-client_ivc_bench} FILTER=${2:-"*."} PRESET=${3:-clang16} BUILD_DIR=${4:-build} @@ -19,6 +18,7 @@ HARDWARE_CONCURRENCY=${HARDWARE_CONCURRENCY:-16} BASELINE_BRANCH="master" BENCH_TOOLS_DIR="$BUILD_DIR/_deps/benchmark-src/tools" +pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt if [ ! -z "$(git status --untracked-files=no --porcelain)" ]; then echo "Git status is unclean; the script will not be able to check out $BASELINE_BRANCH." exit 1 diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp index 7d108ccb350f..7026bfb85029 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp @@ -242,6 +242,7 @@ template class DeciderProvingKey_ { const size_t lookup_inverses_end = std::max(lookup_block_end, tables_end); proving_key.polynomials.lookup_inverses = Polynomial( lookup_inverses_end - lookup_inverses_start, dyadic_circuit_size, lookup_inverses_start); + info("lookup_inverses_length: ", lookup_inverses_end - lookup_inverses_start); // proving_key.polynomials.lookup_inverses = Polynomial( // lookup_inverses_end - lookup_inverses_start, dyadic_circuit_size, lookup_inverses_start); if constexpr (HasDataBus) { diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp b/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp index 7377c7b31c72..e05bf0ec2685 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp @@ -41,7 +41,7 @@ template void OinkProver::prove() { - PROFILE_THIS_NAME("execute_log_derivative_inverse_round"); + PROFILE_THIS_NAME(); // Fiat-Shamir: beta & gamma execute_log_derivative_inverse_round(); From 82e31c06ca61f06a5123dc2e8ba50c68493291ca Mon Sep 17 00:00:00 2001 From: maramihali Date: Mon, 16 Dec 2024 10:39:16 +0000 Subject: [PATCH 03/18] update active ranges and move lookup and databus blocks to beginning of trace --- .../client_ivc_bench/client_ivc.bench.cpp | 2 +- .../commitment_schemes/commitment_key.hpp | 20 ++--- .../src/barretenberg/goblin/mock_circuits.hpp | 6 +- .../composer/composer_lib.hpp | 6 +- .../execution_trace_usage_tracker.hpp | 13 +-- .../execution_trace/mega_execution_trace.hpp | 80 +++++++------------ .../protogalaxy_prover_internal.hpp | 2 - .../relations/logderiv_lookup_relation.hpp | 4 +- .../trace_to_polynomials.cpp | 6 ++ .../ultra_honk/decider_proving_key.hpp | 14 ++-- .../barretenberg/ultra_honk/oink_prover.cpp | 2 +- 11 files changed, 69 insertions(+), 86 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp index 7aa1b8910d83..6033648972c4 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp @@ -33,7 +33,7 @@ class ClientIVCBench : public benchmark::Fixture { */ BENCHMARK_DEFINE_F(ClientIVCBench, Full)(benchmark::State& state) { - ClientIVC ivc{ { EXAMPLE_20 } }; + ClientIVC ivc{ { CLIENT_IVC_BENCH_STRUCTURE } }; auto total_num_circuits = 2 * static_cast(state.range(0)); // 2x accounts for kernel circuits auto mocked_vkeys = mock_verification_keys(total_num_circuits); diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp index 81ef54a2b9da..4ba7fac1a1ba 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp @@ -232,17 +232,19 @@ template class CommitmentKey { std::vector scalars; scalars.reserve(total_num_scalars); - for (const auto& range : active_ranges) { - auto start = &polynomial[range.first]; - auto end = &polynomial[range.second]; - scalars.insert(scalars.end(), start, end); - } std::vector points; points.reserve(total_num_scalars * 2); - for (const auto& range : active_ranges) { - auto start = &point_table[2 * range.first]; - auto end = &point_table[2 * range.second]; - points.insert(points.end(), start, end); + for (const auto& [first, second] : active_ranges) { + { + auto start = &polynomial[first]; + auto end = &polynomial[second]; + scalars.insert(scalars.end(), start, end); + } + { + auto start = &point_table[2 * first]; + auto end = &point_table[2 * second]; + points.insert(points.end(), start, end); + } } // Call pippenger diff --git a/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp b/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp index 95bc3a46d5af..c42e7a75f289 100644 --- a/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp +++ b/barretenberg/cpp/src/barretenberg/goblin/mock_circuits.hpp @@ -22,10 +22,10 @@ namespace bb { * @brief An arbitrary but small-ish structuring that can be used for testing with non-trivial circuits in cases when * they overflow */ -static constexpr TraceStructure SMALL_TEST_STRUCTURE_FOR_OVERFLOWS{ .ecc_op = 1 << 14, - .pub_inputs = 1 << 14, - .busread = 1 << 14, +static constexpr TraceStructure SMALL_TEST_STRUCTURE_FOR_OVERFLOWS{ .busread = 1 << 14, .lookup = 1 << 14, + .ecc_op = 1 << 14, + .pub_inputs = 1 << 14, .arithmetic = 1 << 15, .delta_range = 1 << 14, .elliptic = 1 << 14, diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp index bab96617dd4f..8dd433d93709 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp @@ -24,7 +24,7 @@ void construct_lookup_table_polynomials(const RefArray tables_size + additional_offset); - size_t offset = Flavor::has_zero_row ? 1 : 0; + size_t offset = circuit.blocks.lookup.trace_offset; // if constexpr (IsPlonkFlavor) { // offset = dyadic_circuit_size - tables_size - additional_offset; // } @@ -53,11 +53,11 @@ template void construct_lookup_read_counts(typename Flavor::Polynomial& read_counts, typename Flavor::Polynomial& read_tags, typename Flavor::CircuitBuilder& circuit, - [[maybe_unused]] const size_t dyadic_circuit_size = 0) + [[maybe_unused]] const size_t additional_offset = 0) { // const size_t tables_size = circuit.get_tables_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace - size_t table_offset = Flavor::has_zero_row ? 1 : 0; + size_t table_offset = circuit.blocks.lookup.trace_offset; // if constexpr (IsPlonkFlavor) { // offset = dyadic_circuit_size - tables_size - additional_offset; // } diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index 0c3685d93d38..acf5f00f21b1 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -33,16 +33,16 @@ struct ExecutionTraceUsageTracker { size_t max_tables_size = 0; // For printing only. Must match the order of the members in the arithmetization - static constexpr std::array block_labels{ "ecc_op", + static constexpr std::array block_labels{ "busread", + "lookup", + "ecc_op", "pub_inputs", - "busread", "arithmetic", "delta_range", "elliptic", "aux", "poseidon2_external", "poseidon2_internal", - "lookup", "overflow", "databus_table_data", "lookup_table_data" }; @@ -93,15 +93,18 @@ struct ExecutionTraceUsageTracker { // the same fixed block sizes but might also have an overflow block potentially influencing the dyadic circuit // size. // TODO(https://github.com/AztecProtocol/barretenberg/issues/1160) - // const size_t dyadic_circuit_size = circuit.blocks.get_structured_dyadic_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1152): should be able to use simply Range{ 0, // max_databus_size } but this breaks for certain choices of num_threads. size_t databus_end = std::max(max_databus_size, static_cast(fixed_sizes.busread.trace_offset + max_sizes.busread)); active_ranges.emplace_back(0, databus_end); + + // TODO: we should allocate the range starting from lookup_start but for some reason that breaks proofs, should + // be investigated + size_t lookups_start = fixed_sizes.lookup.trace_offset; size_t lookups_end = - std::max(max_tables_size, static_cast(fixed_sizes.lookup.trace_offset + max_sizes.lookup)); + std::max(lookups_start + max_tables_size, static_cast(lookups_start + max_sizes.lookup)); active_ranges.emplace_back(0, lookups_end); } diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp index 2abe11904474..0f5da8d3ec33 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp @@ -16,10 +16,10 @@ namespace bb { * trace structures (i.e., sets of capacities for each block type, which we use to optimize the folding prover). */ template struct MegaTraceBlockData { - T ecc_op; - T pub_inputs; T busread; T lookup; + T ecc_op; + T pub_inputs; T arithmetic; T delta_range; T elliptic; @@ -30,46 +30,22 @@ template struct MegaTraceBlockData { std::vector get_labels() const { - return { "ecc_op", - "pub_inputs", - "busread", - "lookup", - "arithmetic", - "delta_range", - "elliptic", - "aux", - "poseidon2_external", - "poseidon2_internal", + return { "busread", "lookup", "ecc_op", "pub_inputs", "arithmetic", + "delta_range", "elliptic", "aux", "poseidon2_external", "poseidon2_internal", "overflow" }; } auto get() { - return RefArray{ ecc_op, - pub_inputs, - busread, - lookup, - arithmetic, - delta_range, - elliptic, - aux, - poseidon2_external, - poseidon2_internal, + return RefArray{ busread, lookup, ecc_op, pub_inputs, arithmetic, + delta_range, elliptic, aux, poseidon2_external, poseidon2_internal, overflow }; } auto get() const { - return RefArray{ ecc_op, - pub_inputs, - busread, - lookup, - arithmetic, - delta_range, - elliptic, - aux, - poseidon2_external, - poseidon2_internal, + return RefArray{ busread, lookup, ecc_op, pub_inputs, arithmetic, + delta_range, elliptic, aux, poseidon2_external, poseidon2_internal, overflow }; } @@ -225,14 +201,14 @@ class MegaExecutionTraceBlocks : public MegaTraceBlockData { void summarize() const { info("Gate blocks summary: (actual gates / fixed capacity)"); + info("busread :\t", this->busread.size(), "/", this->busread.get_fixed_size()); + info("lookups :\t", this->lookup.size(), "/", this->lookup.get_fixed_size()); info("goblin ecc op :\t", this->ecc_op.size(), "/", this->ecc_op.get_fixed_size()); info("pub inputs :\t", this->pub_inputs.size(), "/", this->pub_inputs.get_fixed_size(), " (populated in decider pk constructor)"); - info("busread :\t", this->busread.size(), "/", this->busread.get_fixed_size()); - info("lookups :\t", this->lookup.size(), "/", this->lookup.get_fixed_size()); info("arithmetic :\t", this->arithmetic.size(), "/", this->arithmetic.get_fixed_size()); info("delta range :\t", this->delta_range.size(), "/", this->delta_range.get_fixed_size()); info("elliptic :\t", this->elliptic.size(), "/", this->elliptic.get_fixed_size()); @@ -266,10 +242,10 @@ class MegaExecutionTraceBlocks : public MegaTraceBlockData { /** * @brief A tiny structuring (for testing without recursive verifications only) */ -static constexpr TraceStructure TINY_TEST_STRUCTURE{ .ecc_op = 18, - .pub_inputs = 1, - .busread = 3, +static constexpr TraceStructure TINY_TEST_STRUCTURE{ .busread = 3, .lookup = 2, + .ecc_op = 18, + .pub_inputs = 1, .arithmetic = 1 << 14, .delta_range = 5, .elliptic = 2, @@ -281,10 +257,10 @@ static constexpr TraceStructure TINY_TEST_STRUCTURE{ .ecc_op = 18, /** * @brief An arbitrary but small-ish structuring that can be used for generic unit testing with non-trivial circuits */ -static constexpr TraceStructure SMALL_TEST_STRUCTURE{ .ecc_op = 1 << 14, - .pub_inputs = 1 << 14, - .busread = 1 << 14, +static constexpr TraceStructure SMALL_TEST_STRUCTURE{ .busread = 1 << 14, .lookup = 1 << 14, + .ecc_op = 1 << 14, + .pub_inputs = 1 << 14, .arithmetic = 1 << 15, .delta_range = 1 << 14, .elliptic = 1 << 14, @@ -297,10 +273,10 @@ static constexpr TraceStructure SMALL_TEST_STRUCTURE{ .ecc_op = 1 << 14, * @brief A minimal structuring specifically tailored to the medium complexity transaction of the Client IVC * benchmark. */ -static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .ecc_op = 1 << 10, - .pub_inputs = 1 << 7, - .busread = 1 << 7, +static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .busread = 1 << 7, .lookup = 72000, + .ecc_op = 1 << 10, + .pub_inputs = 1 << 7, .arithmetic = 198000, .delta_range = 90000, .elliptic = 9000, @@ -312,10 +288,10 @@ static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .ecc_op = 1 << 10, /** * @brief An example structuring of size 2^18. */ -static constexpr TraceStructure EXAMPLE_18{ .ecc_op = 1 << 10, - .pub_inputs = 1 << 6, - .busread = 1 << 6, +static constexpr TraceStructure EXAMPLE_18{ .busread = 1 << 6, .lookup = 36000, + .ecc_op = 1 << 10, + .pub_inputs = 1 << 6, .arithmetic = 84000, .delta_range = 45000, .elliptic = 9000, @@ -327,10 +303,10 @@ static constexpr TraceStructure EXAMPLE_18{ .ecc_op = 1 << 10, /** * @brief An example structuring of size 2^20. */ -static constexpr TraceStructure EXAMPLE_20{ .ecc_op = 1 << 11, - .pub_inputs = 1 << 8, - .busread = 1 << 8, +static constexpr TraceStructure EXAMPLE_20{ .busread = 1 << 8, .lookup = 144000, + .ecc_op = 1 << 11, + .pub_inputs = 1 << 8, .arithmetic = 396000, .delta_range = 180000, .elliptic = 18000, @@ -342,10 +318,10 @@ static constexpr TraceStructure EXAMPLE_20{ .ecc_op = 1 << 11, /** * @brief Structuring tailored to the full e2e TS test (TO BE UPDATED ACCORDINGLY) */ -static constexpr TraceStructure E2E_FULL_TEST_STRUCTURE{ .ecc_op = 1 << 10, - .pub_inputs = 4000, - .busread = 6000, +static constexpr TraceStructure E2E_FULL_TEST_STRUCTURE{ .busread = 6000, .lookup = 200000, + .ecc_op = 1 << 10, + .pub_inputs = 4000, .arithmetic = 200000, .delta_range = 25000, .elliptic = 80000, diff --git a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp index c305a94fd252..9baa153a019b 100644 --- a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp +++ b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp @@ -407,14 +407,12 @@ template class ProtogalaxyProverInternal { // Distribute the execution trace rows across threads so that each handles an equal number of active rows trace_usage_tracker.construct_thread_ranges(num_threads, common_polynomial_size); - // size_t active = 0; // Accumulate the contribution from each sub-relation parallel_for(num_threads, [&](size_t thread_idx) { const size_t start = trace_usage_tracker.thread_ranges[thread_idx].first; const size_t end = trace_usage_tracker.thread_ranges[thread_idx].second; for (size_t idx = start; idx < end; idx++) { if (trace_usage_tracker.check_is_active(idx)) { - // active++; // Instantiate univariates, possibly with skipping toto ignore computation in those indices // (they are still available for skipping relations, but all derived univariate will ignore // those evaluations) No need to initialise extended_univariates to 0, as it's assigned to. diff --git a/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp b/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp index a1c52f33ab47..dbd45cc2ed5c 100644 --- a/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp +++ b/barretenberg/cpp/src/barretenberg/relations/logderiv_lookup_relation.hpp @@ -163,14 +163,12 @@ template class LogDerivLookupRelationImpl { size_t num_threads = bb::calculate_num_threads_pow2(circuit_size, min_iterations_per_thread); size_t iterations_per_thread = circuit_size / num_threads; // actual iterations per thread - size_t lookup_active = 0; parallel_for(num_threads, [&](size_t thread_idx) { size_t start = thread_idx * iterations_per_thread; size_t end = (thread_idx + 1) * iterations_per_thread; for (size_t i = start; i < end; ++i) { // We only compute the inverse if this row contains a lookup gate or data that has been looked up if (polynomials.q_lookup.get(i) == 1 || polynomials.lookup_read_tags.get(i) == 1) { - lookup_active++; // TODO(https://github.com/AztecProtocol/barretenberg/issues/940): avoid get_row if possible. auto row = polynomials.get_row(i); // Note: this is a copy. use sparingly! auto value = compute_read_term(row, relation_parameters) * @@ -179,7 +177,7 @@ template class LogDerivLookupRelationImpl { } } }); - info("lookup active: ", lookup_active); + // Compute inverse polynomial I in place by inverting the product at each row FF::batch_invert(inverse_polynomial.coeffs()); }; diff --git a/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp b/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp index 39eccd6ef01a..4157f43ac6e1 100644 --- a/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp +++ b/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp @@ -98,6 +98,8 @@ typename TraceToPolynomials::TraceData TraceToPolynomials::const uint32_t offset = Flavor::has_zero_row ? 1 : 0; // Offset at which to place each block in the trace polynomials // For each block in the trace, populate wire polys, copy cycles and selector polys + info("print block ranges"); + size_t total = 0; for (auto& block : builder.blocks.get()) { auto block_size = static_cast(block.size()); @@ -105,6 +107,8 @@ typename TraceToPolynomials::TraceData TraceToPolynomials::const if constexpr (IsUltraFlavor) { // Mega and Ultra if (block.size() > 0) { proving_key.active_block_ranges.emplace_back(offset, offset + block.size()); + info(offset, " ", offset + block.size()); + total += block.size(); } } @@ -151,6 +155,8 @@ typename TraceToPolynomials::TraceData TraceToPolynomials::const offset += block.get_fixed_size(is_structured); } + info("total: ", total); + return trace_data; } diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp index 7026bfb85029..ea571e2620ed 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp @@ -91,6 +91,7 @@ template class DeciderProvingKey_ { final_active_wire_idx = block.trace_offset + block.size() - 1; } } + info("Final active wire idx: ", final_active_wire_idx); // TODO(https://github.com/AztecProtocol/barretenberg/issues/905): This is adding ops to the op queue but NOT to // the circuit, meaning the ECCVM/Translator will use different ops than the main circuit. This will lead to @@ -184,9 +185,9 @@ template class DeciderProvingKey_ { proving_key.polynomials.databus_id = Polynomial(proving_key.circuit_size, proving_key.circuit_size); } - size_t table_offset = Flavor::has_zero_row ? 1 : 0; - const size_t max_tables_size = std::min(static_cast(MAX_LOOKUP_TABLES_SIZE) - table_offset, - dyadic_circuit_size - table_offset); + size_t table_offset = circuit.blocks.lookup.trace_offset; + const size_t max_tables_size = + std::min(static_cast(MAX_LOOKUP_TABLES_SIZE), dyadic_circuit_size - table_offset); // size_t table_offset = dyadic_circuit_size - max_tables_size; { @@ -221,10 +222,9 @@ template class DeciderProvingKey_ { } { ZoneScopedN("allocating lookup and databus inverses"); - const size_t lookup_block_end = - static_cast((table_offset + circuit.blocks.lookup.get_fixed_size(is_structured))); - const auto tables_end = - std::min(dyadic_circuit_size - table_offset, MAX_LOOKUP_TABLES_SIZE + table_offset); + const size_t lookup_block_end = static_cast( + circuit.blocks.lookup.trace_offset + circuit.blocks.lookup.get_fixed_size(is_structured)); + const auto tables_end = circuit.blocks.lookup.trace_offset + max_tables_size; // Allocate the lookup_inverses polynomial // const size_t lookup_offset = static_cast(circuit.blocks.lookup.trace_offset); diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp b/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp index e05bf0ec2685..7377c7b31c72 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/oink_prover.cpp @@ -41,7 +41,7 @@ template void OinkProver::prove() { - PROFILE_THIS_NAME(); + PROFILE_THIS_NAME("execute_log_derivative_inverse_round"); // Fiat-Shamir: beta & gamma execute_log_derivative_inverse_round(); From 5656dacad0255bafd7ff86d0aa2d9b77496c9192 Mon Sep 17 00:00:00 2001 From: maramihali Date: Mon, 16 Dec 2024 11:59:06 +0000 Subject: [PATCH 04/18] cleanup --- .../cpp/scripts/compare_branch_vs_baseline.sh | 2 +- .../compare_branch_vs_baseline_remote.sh | 2 +- .../composer/composer_lib.hpp | 17 +-- .../composer/composer_lib.test.cpp | 128 +++++++++--------- .../protogalaxy_prover_internal.hpp | 9 +- .../trace_to_polynomials.cpp | 6 - .../ultra_honk/decider_proving_key.hpp | 22 +-- 7 files changed, 83 insertions(+), 103 deletions(-) diff --git a/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh b/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh index 8beb689de454..717b7be7800b 100755 --- a/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh +++ b/barretenberg/cpp/scripts/compare_branch_vs_baseline.sh @@ -2,6 +2,7 @@ # Install requirements (numpy + scipy) for comparison script if necessary. # Note: By default, installation will occur in $HOME/.local/bin. +# pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt # This script is used to compare a suite of benchmarks between baseline (default: master) and @@ -18,7 +19,6 @@ HARDWARE_CONCURRENCY=${HARDWARE_CONCURRENCY:-16} BASELINE_BRANCH="master" BENCH_TOOLS_DIR="$BUILD_DIR/_deps/benchmark-src/tools" -pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt echo -e "\nComparing $BENCHMARK between $BASELINE_BRANCH and current branch:" # Move above script dir. diff --git a/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh b/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh index c33f22bfacc5..50cf755990a5 100755 --- a/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh +++ b/barretenberg/cpp/scripts/compare_branch_vs_baseline_remote.sh @@ -2,6 +2,7 @@ # Install requirements (numpy + scipy) for comparison script if necessary. # Note: By default, installation will occur in $HOME/.local/bin. +# pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt # This script is used to compare a suite of benchmarks between baseline (default: master) and @@ -18,7 +19,6 @@ HARDWARE_CONCURRENCY=${HARDWARE_CONCURRENCY:-16} BASELINE_BRANCH="master" BENCH_TOOLS_DIR="$BUILD_DIR/_deps/benchmark-src/tools" -pip3 install --user -r $BUILD_DIR/_deps/benchmark-src/requirements.txt if [ ! -z "$(git status --untracked-files=no --porcelain)" ]; then echo "Git status is unclean; the script will not be able to check out $BASELINE_BRANCH." exit 1 diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp index 8dd433d93709..399c7b0d7f60 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp @@ -23,11 +23,12 @@ void construct_lookup_table_polynomials(const RefArray tables_size + additional_offset); size_t offset = circuit.blocks.lookup.trace_offset; - // if constexpr (IsPlonkFlavor) { - // offset = dyadic_circuit_size - tables_size - additional_offset; - // } + if constexpr (IsPlonkFlavor) { + offset = dyadic_circuit_size - tables_size - additional_offset; + } for (const auto& table : circuit.lookup_tables) { const fr table_index(table.table_index); @@ -53,14 +54,14 @@ template void construct_lookup_read_counts(typename Flavor::Polynomial& read_counts, typename Flavor::Polynomial& read_tags, typename Flavor::CircuitBuilder& circuit, - [[maybe_unused]] const size_t additional_offset = 0) + const size_t dyadic_circuit_size) { - // const size_t tables_size = circuit.get_tables_size(); + const size_t tables_size = circuit.get_tables_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace size_t table_offset = circuit.blocks.lookup.trace_offset; - // if constexpr (IsPlonkFlavor) { - // offset = dyadic_circuit_size - tables_size - additional_offset; - // } + if constexpr (IsPlonkFlavor) { + table_offset = dyadic_circuit_size - tables_size; + } // loop over all tables used in the circuit; each table contains data about the lookups made on it for (auto& table : circuit.lookup_tables) { diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp index 02a17a0c1c51..0cd69e9f523d 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.test.cpp @@ -1,81 +1,77 @@ -// #include "barretenberg/plonk_honk_shared/composer/composer_lib.hpp" -// #include "barretenberg/srs/factories/crs_factory.hpp" -// #include "barretenberg/stdlib_circuit_builders/ultra_circuit_builder.hpp" -// #include "barretenberg/stdlib_circuit_builders/ultra_flavor.hpp" +#include "barretenberg/plonk_honk_shared/composer/composer_lib.hpp" +#include "barretenberg/srs/factories/crs_factory.hpp" +#include "barretenberg/stdlib_circuit_builders/ultra_circuit_builder.hpp" +#include "barretenberg/stdlib_circuit_builders/ultra_flavor.hpp" -// #include -// #include +#include +#include -// using namespace bb; +using namespace bb; -// class ComposerLibTests : public ::testing::Test { -// public: -// using Flavor = UltraFlavor; -// using FF = typename Flavor::FF; +class ComposerLibTests : public ::testing::Test { + public: + using Flavor = UltraFlavor; + using FF = typename Flavor::FF; -// protected: -// static void SetUpTestSuite() { bb::srs::init_crs_factory("../srs_db/ignition"); } -// }; + protected: + static void SetUpTestSuite() { bb::srs::init_crs_factory("../srs_db/ignition"); } +}; -// /** -// * @brief A test to demonstrate that lookup read counts/tags are computed correctly for a simple 'hand-computable' -// case -// * using the uint32 XOR table -// * -// */ -// TEST_F(ComposerLibTests, LookupReadCounts) -// { -// using Builder = UltraCircuitBuilder; -// using Flavor = UltraFlavor; -// using FF = typename Flavor::FF; -// using Polynomial = typename Flavor::Polynomial; -// auto UINT32_XOR = plookup::MultiTableId::UINT32_XOR; +/** + * @brief A test to demonstrate that lookup read counts/tags are computed correctly for a simple 'hand-computable' case + * using the uint32 XOR table + * + */ +TEST_F(ComposerLibTests, LookupReadCounts) +{ + using Builder = UltraCircuitBuilder; + using Flavor = UltraFlavor; + using FF = typename Flavor::FF; + using Polynomial = typename Flavor::Polynomial; + auto UINT32_XOR = plookup::MultiTableId::UINT32_XOR; -// Builder builder; + Builder builder; -// // define some very simply inputs to XOR -// FF left{ 1 }; -// FF right{ 5 }; + // define some very simply inputs to XOR + FF left{ 1 }; + FF right{ 5 }; -// auto left_idx = builder.add_variable(left); -// auto right_idx = builder.add_variable(right); + auto left_idx = builder.add_variable(left); + auto right_idx = builder.add_variable(right); -// // create a single lookup from the uint32 XOR table -// auto accumulators = plookup::get_lookup_accumulators(UINT32_XOR, left, right, /*is_2_to_1_lookup*/ true); -// builder.create_gates_from_plookup_accumulators(UINT32_XOR, accumulators, left_idx, right_idx); + // create a single lookup from the uint32 XOR table + auto accumulators = plookup::get_lookup_accumulators(UINT32_XOR, left, right, /*is_2_to_1_lookup*/ true); + builder.create_gates_from_plookup_accumulators(UINT32_XOR, accumulators, left_idx, right_idx); -// EXPECT_EQ(builder.lookup_tables.size(), 1); // we only used a single table -// EXPECT_EQ(builder.lookup_tables[0].size(), 4096); // table has size 64*64 (6 bit operands) + EXPECT_EQ(builder.lookup_tables.size(), 1); // we only used a single table + EXPECT_EQ(builder.lookup_tables[0].size(), 4096); // table has size 64*64 (6 bit operands) -// size_t circuit_size = 8192; + size_t circuit_size = 8192; -// Polynomial read_counts{ circuit_size }; -// Polynomial read_tags{ circuit_size }; + Polynomial read_counts{ circuit_size }; + Polynomial read_tags{ circuit_size }; -// construct_lookup_read_counts(read_counts, read_tags, builder, circuit_size); + construct_lookup_read_counts(read_counts, read_tags, builder, circuit_size); -// // The table polys are constructed at the bottom of the trace, thus so to are the counts/tags -// // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace -// size_t offset = Flavor::has_zero_row ? 1 : 0; + // The table polys are constructed at the bottom of the trace, thus so to are the counts/tags + // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace + size_t offset = circuit_size - builder.get_tables_size(); -// // The uint32 XOR lookup table is constructed for 6 bit operands via double for loop that iterates through the -// left -// // operand externally (0 to 63) then the right operand internally (0 to 63). Computing (1 XOR 5) will thus result -// in -// // 1 lookup from the (1*64 + 5)th index in the table and 5 lookups from the (0*64 + 0)th index (for the remaining -// 5 -// // limbs that are all 0). The counts and tags at all other indices should be zero. -// for (auto [idx, count, tag] : zip_polys(read_counts, read_tags)) { -// if (idx == (0 + offset)) { -// EXPECT_EQ(count, 5); -// EXPECT_EQ(tag, 1); -// } else if (idx == (69 + offset)) { -// EXPECT_EQ(count, 1); -// EXPECT_EQ(tag, 1); -// } else { -// EXPECT_EQ(count, 0); -// EXPECT_EQ(tag, 0); -// } -// idx++; -// } -// } \ No newline at end of file + // The uint32 XOR lookup table is constructed for 6 bit operands via double for loop that iterates through the left + // operand externally (0 to 63) then the right operand internally (0 to 63). Computing (1 XOR 5) will thus result in + // 1 lookup from the (1*64 + 5)th index in the table and 5 lookups from the (0*64 + 0)th index (for the remaining 5 + // limbs that are all 0). The counts and tags at all other indices should be zero. + for (auto [idx, count, tag] : zip_polys(read_counts, read_tags)) { + if (idx == (0 + offset)) { + EXPECT_EQ(count, 5); + EXPECT_EQ(tag, 1); + } else if (idx == (69 + offset)) { + EXPECT_EQ(count, 1); + EXPECT_EQ(tag, 1); + } else { + EXPECT_EQ(count, 0); + EXPECT_EQ(tag, 0); + } + idx++; + } +} \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp index 9baa153a019b..c635da8cfa25 100644 --- a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp +++ b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy_prover_internal.hpp @@ -411,11 +411,12 @@ template class ProtogalaxyProverInternal { parallel_for(num_threads, [&](size_t thread_idx) { const size_t start = trace_usage_tracker.thread_ranges[thread_idx].first; const size_t end = trace_usage_tracker.thread_ranges[thread_idx].second; + for (size_t idx = start; idx < end; idx++) { if (trace_usage_tracker.check_is_active(idx)) { - // Instantiate univariates, possibly with skipping toto ignore computation in those indices - // (they are still available for skipping relations, but all derived univariate will ignore - // those evaluations) No need to initialise extended_univariates to 0, as it's assigned to. + // Instantiate univariates, possibly with skipping toto ignore computation in those indices (they + // are still available for skipping relations, but all derived univariate will ignore those + // evaluations) No need to initialise extended_univariates to 0, as it's assigned to. constexpr size_t skip_count = skip_zero_computations ? DeciderPKs::NUM - 1 : 0; extend_univariates(extended_univariates[thread_idx], keys, idx); @@ -431,7 +432,7 @@ template class ProtogalaxyProverInternal { } } }); - // info("active: ", active); + RelationUtils::zero_univariates(univariate_accumulators); // Accumulate the per-thread univariate accumulators into a single set of accumulators for (auto& accumulators : thread_univariate_accumulators) { diff --git a/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp b/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp index 4157f43ac6e1..39eccd6ef01a 100644 --- a/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp +++ b/barretenberg/cpp/src/barretenberg/trace_to_polynomials/trace_to_polynomials.cpp @@ -98,8 +98,6 @@ typename TraceToPolynomials::TraceData TraceToPolynomials::const uint32_t offset = Flavor::has_zero_row ? 1 : 0; // Offset at which to place each block in the trace polynomials // For each block in the trace, populate wire polys, copy cycles and selector polys - info("print block ranges"); - size_t total = 0; for (auto& block : builder.blocks.get()) { auto block_size = static_cast(block.size()); @@ -107,8 +105,6 @@ typename TraceToPolynomials::TraceData TraceToPolynomials::const if constexpr (IsUltraFlavor) { // Mega and Ultra if (block.size() > 0) { proving_key.active_block_ranges.emplace_back(offset, offset + block.size()); - info(offset, " ", offset + block.size()); - total += block.size(); } } @@ -155,8 +151,6 @@ typename TraceToPolynomials::TraceData TraceToPolynomials::const offset += block.get_fixed_size(is_structured); } - info("total: ", total); - return trace_data; } diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp index ea571e2620ed..c1e2e89af2e6 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp @@ -188,7 +188,6 @@ template class DeciderProvingKey_ { size_t table_offset = circuit.blocks.lookup.trace_offset; const size_t max_tables_size = std::min(static_cast(MAX_LOOKUP_TABLES_SIZE), dyadic_circuit_size - table_offset); - // size_t table_offset = dyadic_circuit_size - max_tables_size; { PROFILE_THIS_NAME("allocating table polynomials"); @@ -227,24 +226,11 @@ template class DeciderProvingKey_ { const auto tables_end = circuit.blocks.lookup.trace_offset + max_tables_size; // Allocate the lookup_inverses polynomial - // const size_t lookup_offset = static_cast(circuit.blocks.lookup.trace_offset); - // // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts - // // at top of trace - // const size_t table_offset = - // dyadic_circuit_size - - // std::min(dyadic_circuit_size - 1, static_cast(MAX_LOOKUP_TABLES_SIZE)); - // const size_t lookup_inverses_start = std::min(lookup_offset, table_offset); - // const size_t lookup_inverses_end = - // std::min(dyadic_circuit_size, - // std::max(lookup_offset + circuit.blocks.lookup.get_fixed_size(is_structured), - // table_offset + MAX_LOOKUP_TABLES_SIZE)); + const size_t lookup_inverses_start = table_offset; const size_t lookup_inverses_end = std::max(lookup_block_end, tables_end); proving_key.polynomials.lookup_inverses = Polynomial( lookup_inverses_end - lookup_inverses_start, dyadic_circuit_size, lookup_inverses_start); - info("lookup_inverses_length: ", lookup_inverses_end - lookup_inverses_start); - // proving_key.polynomials.lookup_inverses = Polynomial( - // lookup_inverses_end - lookup_inverses_start, dyadic_circuit_size, lookup_inverses_start); if constexpr (HasDataBus) { const size_t q_busread_end = circuit.blocks.busread.trace_offset + circuit.blocks.busread.get_fixed_size(is_structured); @@ -315,8 +301,10 @@ template class DeciderProvingKey_ { { PROFILE_THIS_NAME("constructing lookup read counts"); - construct_lookup_read_counts( - proving_key.polynomials.lookup_read_counts, proving_key.polynomials.lookup_read_tags, circuit); + construct_lookup_read_counts(proving_key.polynomials.lookup_read_counts, + proving_key.polynomials.lookup_read_tags, + circuit, + dyadic_circuit_size); } // Construct the public inputs array From 9c1f4b1b5a267edfae8ce0fccea06a1cc6dbfd94 Mon Sep 17 00:00:00 2001 From: maramihali Date: Mon, 16 Dec 2024 18:09:19 +0000 Subject: [PATCH 05/18] fix merge --- .../cpp/scripts/analyze_client_ivc_bench.py | 3 - .../execution_trace_usage_tracker.hpp | 6 +- .../execution_trace/mega_execution_trace.hpp | 2 +- .../protogalaxy/combiner.test.cpp | 694 +++++++++--------- .../protogalaxy/protogalaxy.test.cpp | 200 +++-- .../stdlib_circuit_builders/mega_flavor.hpp | 2 +- 6 files changed, 450 insertions(+), 457 deletions(-) diff --git a/barretenberg/cpp/scripts/analyze_client_ivc_bench.py b/barretenberg/cpp/scripts/analyze_client_ivc_bench.py index f844177bf316..600854679c5e 100755 --- a/barretenberg/cpp/scripts/analyze_client_ivc_bench.py +++ b/barretenberg/cpp/scripts/analyze_client_ivc_bench.py @@ -17,9 +17,6 @@ to_keep = [ "construct_circuits(t)", "DeciderProvingKey(Circuit&)(t)", - "Lookup::compute_logderivative_inverse(t)", - "execute_log_derivative_inverse_round(t)", - "Databus::compute_logderivative_inverse(t)", "ProtogalaxyProver::prove(t)", "Decider::construct_proof(t)", "ECCVMProver(CircuitBuilder&)(t)", diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index acf5f00f21b1..2b1226f6ea4f 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -96,16 +96,14 @@ struct ExecutionTraceUsageTracker { // TODO(https://github.com/AztecProtocol/barretenberg/issues/1152): should be able to use simply Range{ 0, // max_databus_size } but this breaks for certain choices of num_threads. + size_t databus_end = std::max(max_databus_size, static_cast(fixed_sizes.busread.trace_offset + max_sizes.busread)); active_ranges.emplace_back(0, databus_end); - - // TODO: we should allocate the range starting from lookup_start but for some reason that breaks proofs, should - // be investigated size_t lookups_start = fixed_sizes.lookup.trace_offset; size_t lookups_end = std::max(lookups_start + max_tables_size, static_cast(lookups_start + max_sizes.lookup)); - active_ranges.emplace_back(0, lookups_end); + active_ranges.emplace_back(lookups_start, lookups_end); } // Check whether an index is contained within the active ranges (or previous active ranges; needed for perturbator) diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp index 4da8999a1f05..2afc8175e52d 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp @@ -275,7 +275,7 @@ static constexpr TraceStructure SMALL_TEST_STRUCTURE{ .ecc_op = 1 << 14, * @brief A minimal structuring specifically tailored to the medium complexity transaction of the Client IVC * benchmark. */ -static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .ecc_op = 1 << 14, +static constexpr TraceStructure CLIENT_IVC_BENCH_STRUCTURE{ .ecc_op = 1 << 10, .busread = 1 << 7, .lookup = 72000, .pub_inputs = 1 << 7, diff --git a/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp b/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp index 74787541af30..614a56388684 100644 --- a/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp +++ b/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp @@ -1,347 +1,347 @@ -// #include "barretenberg/honk/utils/testing.hpp" -// #include "barretenberg/protogalaxy/protogalaxy_prover_internal.hpp" -// #include "barretenberg/relations/ultra_arithmetic_relation.hpp" -// #include "barretenberg/stdlib_circuit_builders/mega_flavor.hpp" -// #include "barretenberg/ultra_honk/decider_keys.hpp" -// #include - -// using namespace bb; - -// using Flavor = MegaFlavor; -// using Polynomial = typename Flavor::Polynomial; -// using FF = typename Flavor::FF; - -// // TODO(https://github.com/AztecProtocol/barretenberg/issues/780): Improve combiner tests to check more than the -// // arithmetic relation so we more than unit test folding relation parameters and alpha as well. -// TEST(Protogalaxy, CombinerOn2Keys) -// { -// constexpr size_t NUM_KEYS = 2; -// using DeciderProvingKey = DeciderProvingKey_; -// using DeciderProvingKeys = DeciderProvingKeys_; -// using PGInternal = ProtogalaxyProverInternal; - -// const auto restrict_to_standard_arithmetic_relation = [](auto& polys) { -// std::fill(polys.q_arith.coeffs().begin(), polys.q_arith.coeffs().end(), 1); -// std::fill(polys.q_delta_range.coeffs().begin(), polys.q_delta_range.coeffs().end(), 0); -// std::fill(polys.q_elliptic.coeffs().begin(), polys.q_elliptic.coeffs().end(), 0); -// std::fill(polys.q_aux.coeffs().begin(), polys.q_aux.coeffs().end(), 0); -// std::fill(polys.q_lookup.coeffs().begin(), polys.q_lookup.coeffs().end(), 0); -// std::fill(polys.q_4.coeffs().begin(), polys.q_4.coeffs().end(), 0); -// std::fill(polys.q_poseidon2_external.coeffs().begin(), polys.q_poseidon2_external.coeffs().end(), 0); -// std::fill(polys.q_poseidon2_internal.coeffs().begin(), polys.q_poseidon2_internal.coeffs().end(), 0); -// std::fill(polys.w_4.coeffs().begin(), polys.w_4.coeffs().end(), 0); -// std::fill(polys.w_4_shift.coeffs().begin(), polys.w_4_shift.coeffs().end(), 0); -// }; - -// auto run_test = [&](bool is_random_input) { -// PGInternal pg_internal; // instance of the PG internal prover - -// // Combiner test on prover polynomials containing random values, restricted to only the standard arithmetic -// // relation. -// if (is_random_input) { -// std::vector> keys_data(NUM_KEYS); - -// for (size_t idx = 0; idx < NUM_KEYS; idx++) { -// auto key = std::make_shared(); -// auto prover_polynomials = get_sequential_prover_polynomials( -// /*log_circuit_size=*/1, idx * 128); -// restrict_to_standard_arithmetic_relation(prover_polynomials); -// key->proving_key.polynomials = std::move(prover_polynomials); -// key->proving_key.circuit_size = 2; -// key->proving_key.log_circuit_size = 1; -// keys_data[idx] = key; -// } - -// DeciderProvingKeys keys{ keys_data }; -// PGInternal::UnivariateRelationSeparator alphas; -// alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only -// GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); -// PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; -// auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( -// keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); -// // The expected_result values are computed by running the python script combiner_example_gen.py -// auto expected_result = Univariate(std::array{ 11480UL, -// 14117208UL, -// 78456280UL, -// 230777432UL, -// 508829400UL, -// 950360920UL, -// 1593120728UL, -// 2474857560UL, -// 3633320152UL, -// 5106257240UL, -// 6931417560UL, -// 9146549848UL }); -// EXPECT_EQ(result_no_skipping, expected_result); -// } else { -// std::vector> keys_data(NUM_KEYS); - -// for (size_t idx = 0; idx < NUM_KEYS; idx++) { -// auto key = std::make_shared(); -// auto prover_polynomials = get_zero_prover_polynomials( -// /*log_circuit_size=*/1); -// restrict_to_standard_arithmetic_relation(prover_polynomials); -// key->proving_key.polynomials = std::move(prover_polynomials); -// key->proving_key.circuit_size = 2; -// key->proving_key.log_circuit_size = 1; -// keys_data[idx] = key; -// } - -// DeciderProvingKeys keys{ keys_data }; -// PGInternal::UnivariateRelationSeparator alphas; -// alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only - -// const auto create_add_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { -// polys.w_l.at(idx) = w_l; -// polys.w_r.at(idx) = w_r; -// polys.w_o.at(idx) = w_l + w_r; -// polys.q_l.at(idx) = 1; -// polys.q_r.at(idx) = 1; -// polys.q_o.at(idx) = -1; -// }; - -// const auto create_mul_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { -// polys.w_l.at(idx) = w_l; -// polys.w_r.at(idx) = w_r; -// polys.w_o.at(idx) = w_l * w_r; -// polys.q_m.at(idx) = 1; -// polys.q_o.at(idx) = -1; -// }; - -// create_add_gate(keys[0]->proving_key.polynomials, 0, 1, 2); -// create_add_gate(keys[0]->proving_key.polynomials, 1, 0, 4); -// create_add_gate(keys[1]->proving_key.polynomials, 0, 3, 4); -// create_mul_gate(keys[1]->proving_key.polynomials, 1, 1, 4); - -// restrict_to_standard_arithmetic_relation(keys[0]->proving_key.polynomials); -// restrict_to_standard_arithmetic_relation(keys[1]->proving_key.polynomials); - -// /* DeciderProvingKey 0 DeciderProvingKey 1 -// w_l w_r w_o q_m q_l q_r q_o q_c w_l w_r w_o q_m q_l q_r q_o q_c -// 1 2 3 0 1 1 -1 0 3 4 7 0 1 1 -1 0 -// 0 4 4 0 1 1 -1 0 1 4 4 1 0 0 -1 0 */ - -// /* Lagrange-combined values, row index 0 Lagrange-combined values, row index 1 -// in 0 1 2 3 4 5 6 in 0 1 2 3 4 5 6 -// w_l 1 3 5 7 9 11 13 w_l 0 1 2 3 4 5 6 -// w_r 2 4 6 8 10 12 14 w_r 4 4 4 4 4 4 4 -// w_o 3 7 11 15 19 23 27 w_o 4 4 4 4 4 4 0 -// q_m 0 0 0 0 0 0 0 q_m 0 1 2 3 4 5 6 -// q_l 1 1 1 1 1 1 1 q_l 1 0 -1 -2 -3 -4 -5 -// q_r 1 1 1 1 1 1 1 q_r 1 0 -1 -2 -3 -4 -5 -// q_o -1 -1 -1 -1 -1 -1 -1 q_o -1 -1 -1 -1 -1 -1 -1 -// q_c 0 0 0 0 0 0 0 q_c 0 0 0 0 0 0 0 - -// relation value: -// 0 0 0 0 0 0 0 0 0 6 18 36 60 90 */ - -// GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); -// PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; -// PGInternal::UnivariateRelationParameters univariate_relation_parameters; -// auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( -// keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); -// auto result_with_skipping = -// pg_internal.compute_combiner(keys, gate_separators, univariate_relation_parameters, alphas); -// auto expected_result = -// Univariate(std::array{ 0, 0, 12, 36, 72, 120, 180, 252, 336, 432, 540, 660 }); - -// EXPECT_EQ(result_no_skipping, expected_result); -// EXPECT_EQ(result_with_skipping, expected_result); -// } -// }; -// run_test(true); -// run_test(false); -// }; - -// // Check that the optimized combiner computation yields a result consistent with the unoptimized version -// TEST(Protogalaxy, CombinerOptimizationConsistency) -// { -// constexpr size_t NUM_KEYS = 2; -// using DeciderProvingKey = DeciderProvingKey_; -// using DeciderProvingKeys = DeciderProvingKeys_; -// using PGInternal = ProtogalaxyProverInternal; -// using UltraArithmeticRelation = UltraArithmeticRelation; - -// constexpr size_t UNIVARIATE_LENGTH = 12; -// const auto restrict_to_standard_arithmetic_relation = [](auto& polys) { -// std::fill(polys.q_arith.coeffs().begin(), polys.q_arith.coeffs().end(), 1); -// std::fill(polys.q_delta_range.coeffs().begin(), polys.q_delta_range.coeffs().end(), 0); -// std::fill(polys.q_elliptic.coeffs().begin(), polys.q_elliptic.coeffs().end(), 0); -// std::fill(polys.q_aux.coeffs().begin(), polys.q_aux.coeffs().end(), 0); -// std::fill(polys.q_lookup.coeffs().begin(), polys.q_lookup.coeffs().end(), 0); -// std::fill(polys.q_4.coeffs().begin(), polys.q_4.coeffs().end(), 0); -// std::fill(polys.w_4.coeffs().begin(), polys.w_4.coeffs().end(), 0); -// std::fill(polys.w_4_shift.coeffs().begin(), polys.w_4_shift.coeffs().end(), 0); -// }; - -// auto run_test = [&](bool is_random_input) { -// PGInternal pg_internal; // instance of the PG internal prover - -// // Combiner test on prover polynomisls containing random values, restricted to only the standard arithmetic -// // relation. -// if (is_random_input) { -// std::vector> keys_data(NUM_KEYS); -// ASSERT(NUM_KEYS == 2); // Don't want to handle more here - -// for (size_t idx = 0; idx < NUM_KEYS; idx++) { -// auto key = std::make_shared(); -// auto prover_polynomials = get_sequential_prover_polynomials( -// /*log_circuit_size=*/1, idx * 128); -// restrict_to_standard_arithmetic_relation(prover_polynomials); -// key->proving_key.polynomials = std::move(prover_polynomials); -// key->proving_key.circuit_size = 2; -// key->proving_key.log_circuit_size = 1; -// keys_data[idx] = key; -// } - -// DeciderProvingKeys keys{ keys_data }; -// PGInternal::UnivariateRelationSeparator alphas; -// alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only -// GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); - -// // Relation parameters are all zeroes -// RelationParameters relation_parameters; -// // Temporary accumulator to compute the sumcheck on the second key -// typename Flavor::TupleOfArraysOfValues temporary_accumulator; - -// // Accumulate arithmetic relation over 2 rows on the second key -// for (size_t i = 0; i < 2; i++) { -// UltraArithmeticRelation::accumulate(std::get<0>(temporary_accumulator), -// keys_data[NUM_KEYS - 1]->proving_key.polynomials.get_row(i), -// relation_parameters, -// gate_separators[i]); -// } -// // Get the result of the 0th subrelation of the arithmetic relation -// FF key_offset = std::get<0>(temporary_accumulator)[0]; -// // Subtract it from q_c[0] (it directly affect the target sum, making it zero and enabling the -// optimisation) keys_data[1]->proving_key.polynomials.q_c.at(0) -= key_offset; std::vector -// extended_polynomials; // These hold the extensions of prover polynomials - -// // Manually extend all polynomials. Create new ProverPolynomials from extended values -// for (size_t idx = NUM_KEYS; idx < UNIVARIATE_LENGTH; idx++) { - -// auto key = std::make_shared(); -// auto prover_polynomials = get_zero_prover_polynomials(1); -// for (auto [key_0_polynomial, key_1_polynomial, new_polynomial] : -// zip_view(keys_data[0]->proving_key.polynomials.get_all(), -// keys_data[1]->proving_key.polynomials.get_all(), -// prover_polynomials.get_all())) { -// for (size_t i = 0; i < /*circuit_size*/ 2; i++) { -// new_polynomial.at(i) = -// key_0_polynomial[i] + ((key_1_polynomial[i] - key_0_polynomial[i]) * idx); -// } -// } -// extended_polynomials.push_back(std::move(prover_polynomials)); -// } -// std::array precomputed_result{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; -// // Compute the sum for each index separately, treating each extended key independently -// for (size_t idx = 0; idx < UNIVARIATE_LENGTH; idx++) { - -// typename Flavor::TupleOfArraysOfValues accumulator; -// if (idx < NUM_KEYS) { -// for (size_t i = 0; i < 2; i++) { -// UltraArithmeticRelation::accumulate(std::get<0>(accumulator), -// keys_data[idx]->proving_key.polynomials.get_row(i), -// relation_parameters, -// gate_separators[i]); -// } -// } else { -// for (size_t i = 0; i < 2; i++) { -// UltraArithmeticRelation::accumulate(std::get<0>(accumulator), -// extended_polynomials[idx - NUM_KEYS].get_row(i), -// relation_parameters, -// gate_separators[i]); -// } -// } -// precomputed_result[idx] = std::get<0>(accumulator)[0]; -// } -// auto expected_result = Univariate(precomputed_result); -// PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; -// PGInternal::UnivariateRelationParameters univariate_relation_parameters; -// auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( -// keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); -// auto result_with_skipping = -// pg_internal.compute_combiner(keys, gate_separators, univariate_relation_parameters, alphas); - -// EXPECT_EQ(result_no_skipping, expected_result); -// EXPECT_EQ(result_with_skipping, expected_result); -// } else { -// std::vector> keys_data(NUM_KEYS); - -// for (size_t idx = 0; idx < NUM_KEYS; idx++) { -// auto key = std::make_shared(); -// auto prover_polynomials = get_zero_prover_polynomials( -// /*log_circuit_size=*/1); -// restrict_to_standard_arithmetic_relation(prover_polynomials); -// key->proving_key.polynomials = std::move(prover_polynomials); -// key->proving_key.circuit_size = 2; -// key->proving_key.log_circuit_size = 1; -// keys_data[idx] = key; -// } - -// DeciderProvingKeys keys{ keys_data }; -// PGInternal::UnivariateRelationSeparator alphas; -// alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only - -// const auto create_add_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { -// polys.w_l.at(idx) = w_l; -// polys.w_r.at(idx) = w_r; -// polys.w_o.at(idx) = w_l + w_r; -// polys.q_l.at(idx) = 1; -// polys.q_r.at(idx) = 1; -// polys.q_o.at(idx) = -1; -// }; - -// const auto create_mul_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { -// polys.w_l.at(idx) = w_l; -// polys.w_r.at(idx) = w_r; -// polys.w_o.at(idx) = w_l * w_r; -// polys.q_m.at(idx) = 1; -// polys.q_o.at(idx) = -1; -// }; - -// create_add_gate(keys[0]->proving_key.polynomials, 0, 1, 2); -// create_add_gate(keys[0]->proving_key.polynomials, 1, 0, 4); -// create_add_gate(keys[1]->proving_key.polynomials, 0, 3, 4); -// create_mul_gate(keys[1]->proving_key.polynomials, 1, 1, 4); - -// restrict_to_standard_arithmetic_relation(keys[0]->proving_key.polynomials); -// restrict_to_standard_arithmetic_relation(keys[1]->proving_key.polynomials); - -// /* DeciderProvingKey 0 DeciderProvingKey 1 -// w_l w_r w_o q_m q_l q_r q_o q_c w_l w_r w_o q_m q_l q_r q_o q_c -// 1 2 3 0 1 1 -1 0 3 4 7 0 1 1 -1 0 -// 0 4 4 0 1 1 -1 0 1 4 4 1 0 0 -1 0 */ - -// /* Lagrange-combined values, row index 0 Lagrange-combined values, row index 1 -// in 0 1 2 3 4 5 6 in 0 1 2 3 4 5 6 -// w_l 1 3 5 7 9 11 13 w_l 0 1 2 3 4 5 6 -// w_r 2 4 6 8 10 12 14 w_r 4 4 4 4 4 4 4 -// w_o 3 7 11 15 19 23 27 w_o 4 4 4 4 4 4 0 -// q_m 0 0 0 0 0 0 0 q_m 0 1 2 3 4 5 6 -// q_l 1 1 1 1 1 1 1 q_l 1 0 -1 -2 -3 -4 -5 -// q_r 1 1 1 1 1 1 1 q_r 1 0 -1 -2 -3 -4 -5 -// q_o -1 -1 -1 -1 -1 -1 -1 q_o -1 -1 -1 -1 -1 -1 -1 -// q_c 0 0 0 0 0 0 0 q_c 0 0 0 0 0 0 0 - -// relation value: -// 0 0 0 0 0 0 0 0 0 6 18 36 60 90 */ - -// GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); -// PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; -// PGInternal::UnivariateRelationParameters univariate_relation_parameters; -// auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( -// keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); -// auto result_with_skipping = -// pg_internal.compute_combiner(keys, gate_separators, univariate_relation_parameters, alphas); -// auto expected_result = -// Univariate(std::array{ 0, 0, 12, 36, 72, 120, 180, 252, 336, 432, 540, 660 }); - -// EXPECT_EQ(result_no_skipping, expected_result); -// EXPECT_EQ(result_with_skipping, expected_result); -// } -// }; -// run_test(true); -// run_test(false); -// }; \ No newline at end of file +#include "barretenberg/honk/utils/testing.hpp" +#include "barretenberg/protogalaxy/protogalaxy_prover_internal.hpp" +#include "barretenberg/relations/ultra_arithmetic_relation.hpp" +#include "barretenberg/stdlib_circuit_builders/mega_flavor.hpp" +#include "barretenberg/ultra_honk/decider_keys.hpp" +#include + +using namespace bb; + +using Flavor = MegaFlavor; +using Polynomial = typename Flavor::Polynomial; +using FF = typename Flavor::FF; + +// TODO(https://github.com/AztecProtocol/barretenberg/issues/780): Improve combiner tests to check more than the +// arithmetic relation so we more than unit test folding relation parameters and alpha as well. +TEST(Protogalaxy, CombinerOn2Keys) +{ + constexpr size_t NUM_KEYS = 2; + using DeciderProvingKey = DeciderProvingKey_; + using DeciderProvingKeys = DeciderProvingKeys_; + using PGInternal = ProtogalaxyProverInternal; + + const auto restrict_to_standard_arithmetic_relation = [](auto& polys) { + std::fill(polys.q_arith.coeffs().begin(), polys.q_arith.coeffs().end(), 1); + std::fill(polys.q_delta_range.coeffs().begin(), polys.q_delta_range.coeffs().end(), 0); + std::fill(polys.q_elliptic.coeffs().begin(), polys.q_elliptic.coeffs().end(), 0); + std::fill(polys.q_aux.coeffs().begin(), polys.q_aux.coeffs().end(), 0); + std::fill(polys.q_lookup.coeffs().begin(), polys.q_lookup.coeffs().end(), 0); + std::fill(polys.q_4.coeffs().begin(), polys.q_4.coeffs().end(), 0); + std::fill(polys.q_poseidon2_external.coeffs().begin(), polys.q_poseidon2_external.coeffs().end(), 0); + std::fill(polys.q_poseidon2_internal.coeffs().begin(), polys.q_poseidon2_internal.coeffs().end(), 0); + std::fill(polys.w_4.coeffs().begin(), polys.w_4.coeffs().end(), 0); + std::fill(polys.w_4_shift.coeffs().begin(), polys.w_4_shift.coeffs().end(), 0); + }; + + auto run_test = [&](bool is_random_input) { + PGInternal pg_internal; // instance of the PG internal prover + + // Combiner test on prover polynomials containing random values, restricted to only the standard arithmetic + // relation. + if (is_random_input) { + std::vector> keys_data(NUM_KEYS); + + for (size_t idx = 0; idx < NUM_KEYS; idx++) { + auto key = std::make_shared(); + auto prover_polynomials = get_sequential_prover_polynomials( + /*log_circuit_size=*/1, idx * 128); + restrict_to_standard_arithmetic_relation(prover_polynomials); + key->proving_key.polynomials = std::move(prover_polynomials); + key->proving_key.circuit_size = 2; + key->proving_key.log_circuit_size = 1; + keys_data[idx] = key; + } + + DeciderProvingKeys keys{ keys_data }; + PGInternal::UnivariateRelationSeparator alphas; + alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only + GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); + PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; + auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( + keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); + // The expected_result values are computed by running the python script combiner_example_gen.py + auto expected_result = Univariate(std::array{ 11480UL, + 14117208UL, + 78456280UL, + 230777432UL, + 508829400UL, + 950360920UL, + 1593120728UL, + 2474857560UL, + 3633320152UL, + 5106257240UL, + 6931417560UL, + 9146549848UL }); + EXPECT_EQ(result_no_skipping, expected_result); + } else { + std::vector> keys_data(NUM_KEYS); + + for (size_t idx = 0; idx < NUM_KEYS; idx++) { + auto key = std::make_shared(); + auto prover_polynomials = get_zero_prover_polynomials( + /*log_circuit_size=*/1); + restrict_to_standard_arithmetic_relation(prover_polynomials); + key->proving_key.polynomials = std::move(prover_polynomials); + key->proving_key.circuit_size = 2; + key->proving_key.log_circuit_size = 1; + keys_data[idx] = key; + } + + DeciderProvingKeys keys{ keys_data }; + PGInternal::UnivariateRelationSeparator alphas; + alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only + + const auto create_add_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { + polys.w_l.at(idx) = w_l; + polys.w_r.at(idx) = w_r; + polys.w_o.at(idx) = w_l + w_r; + polys.q_l.at(idx) = 1; + polys.q_r.at(idx) = 1; + polys.q_o.at(idx) = -1; + }; + + const auto create_mul_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { + polys.w_l.at(idx) = w_l; + polys.w_r.at(idx) = w_r; + polys.w_o.at(idx) = w_l * w_r; + polys.q_m.at(idx) = 1; + polys.q_o.at(idx) = -1; + }; + + create_add_gate(keys[0]->proving_key.polynomials, 0, 1, 2); + create_add_gate(keys[0]->proving_key.polynomials, 1, 0, 4); + create_add_gate(keys[1]->proving_key.polynomials, 0, 3, 4); + create_mul_gate(keys[1]->proving_key.polynomials, 1, 1, 4); + + restrict_to_standard_arithmetic_relation(keys[0]->proving_key.polynomials); + restrict_to_standard_arithmetic_relation(keys[1]->proving_key.polynomials); + + /* DeciderProvingKey 0 DeciderProvingKey 1 + w_l w_r w_o q_m q_l q_r q_o q_c w_l w_r w_o q_m q_l q_r q_o q_c + 1 2 3 0 1 1 -1 0 3 4 7 0 1 1 -1 0 + 0 4 4 0 1 1 -1 0 1 4 4 1 0 0 -1 0 */ + + /* Lagrange-combined values, row index 0 Lagrange-combined values, row index 1 + in 0 1 2 3 4 5 6 in 0 1 2 3 4 5 6 + w_l 1 3 5 7 9 11 13 w_l 0 1 2 3 4 5 6 + w_r 2 4 6 8 10 12 14 w_r 4 4 4 4 4 4 4 + w_o 3 7 11 15 19 23 27 w_o 4 4 4 4 4 4 0 + q_m 0 0 0 0 0 0 0 q_m 0 1 2 3 4 5 6 + q_l 1 1 1 1 1 1 1 q_l 1 0 -1 -2 -3 -4 -5 + q_r 1 1 1 1 1 1 1 q_r 1 0 -1 -2 -3 -4 -5 + q_o -1 -1 -1 -1 -1 -1 -1 q_o -1 -1 -1 -1 -1 -1 -1 + q_c 0 0 0 0 0 0 0 q_c 0 0 0 0 0 0 0 + + relation value: + 0 0 0 0 0 0 0 0 0 6 18 36 60 90 */ + + GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); + PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; + PGInternal::UnivariateRelationParameters univariate_relation_parameters; + auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( + keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); + auto result_with_skipping = + pg_internal.compute_combiner(keys, gate_separators, univariate_relation_parameters, alphas); + auto expected_result = + Univariate(std::array{ 0, 0, 12, 36, 72, 120, 180, 252, 336, 432, 540, 660 }); + + EXPECT_EQ(result_no_skipping, expected_result); + EXPECT_EQ(result_with_skipping, expected_result); + } + }; + run_test(true); + run_test(false); +}; + +// Check that the optimized combiner computation yields a result consistent with the unoptimized version +TEST(Protogalaxy, CombinerOptimizationConsistency) +{ + constexpr size_t NUM_KEYS = 2; + using DeciderProvingKey = DeciderProvingKey_; + using DeciderProvingKeys = DeciderProvingKeys_; + using PGInternal = ProtogalaxyProverInternal; + using UltraArithmeticRelation = UltraArithmeticRelation; + + constexpr size_t UNIVARIATE_LENGTH = 12; + const auto restrict_to_standard_arithmetic_relation = [](auto& polys) { + std::fill(polys.q_arith.coeffs().begin(), polys.q_arith.coeffs().end(), 1); + std::fill(polys.q_delta_range.coeffs().begin(), polys.q_delta_range.coeffs().end(), 0); + std::fill(polys.q_elliptic.coeffs().begin(), polys.q_elliptic.coeffs().end(), 0); + std::fill(polys.q_aux.coeffs().begin(), polys.q_aux.coeffs().end(), 0); + std::fill(polys.q_lookup.coeffs().begin(), polys.q_lookup.coeffs().end(), 0); + std::fill(polys.q_4.coeffs().begin(), polys.q_4.coeffs().end(), 0); + std::fill(polys.w_4.coeffs().begin(), polys.w_4.coeffs().end(), 0); + std::fill(polys.w_4_shift.coeffs().begin(), polys.w_4_shift.coeffs().end(), 0); + }; + + auto run_test = [&](bool is_random_input) { + PGInternal pg_internal; // instance of the PG internal prover + + // Combiner test on prover polynomisls containing random values, restricted to only the standard arithmetic + // relation. + if (is_random_input) { + std::vector> keys_data(NUM_KEYS); + ASSERT(NUM_KEYS == 2); // Don't want to handle more here + + for (size_t idx = 0; idx < NUM_KEYS; idx++) { + auto key = std::make_shared(); + auto prover_polynomials = get_sequential_prover_polynomials( + /*log_circuit_size=*/1, idx * 128); + restrict_to_standard_arithmetic_relation(prover_polynomials); + key->proving_key.polynomials = std::move(prover_polynomials); + key->proving_key.circuit_size = 2; + key->proving_key.log_circuit_size = 1; + keys_data[idx] = key; + } + + DeciderProvingKeys keys{ keys_data }; + PGInternal::UnivariateRelationSeparator alphas; + alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only + GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); + + // Relation parameters are all zeroes + RelationParameters relation_parameters; + // Temporary accumulator to compute the sumcheck on the second key + typename Flavor::TupleOfArraysOfValues temporary_accumulator; + + // Accumulate arithmetic relation over 2 rows on the second key + for (size_t i = 0; i < 2; i++) { + UltraArithmeticRelation::accumulate(std::get<0>(temporary_accumulator), + keys_data[NUM_KEYS - 1]->proving_key.polynomials.get_row(i), + relation_parameters, + gate_separators[i]); + } + // Get the result of the 0th subrelation of the arithmetic relation + FF key_offset = std::get<0>(temporary_accumulator)[0]; + // Subtract it from q_c[0] (it directly affect the target sum, making it zero and enabling the + optimisation) keys_data[1]->proving_key.polynomials.q_c.at(0) -= key_offset; + std::vector + extended_polynomials; // These hold the extensions of prover polynomials + + // Manually extend all polynomials. Create new ProverPolynomials from extended values + for (size_t idx = NUM_KEYS; idx < UNIVARIATE_LENGTH; idx++) { + + auto key = std::make_shared(); + auto prover_polynomials = get_zero_prover_polynomials(1); + for (auto [key_0_polynomial, key_1_polynomial, new_polynomial] : + zip_view(keys_data[0]->proving_key.polynomials.get_all(), + keys_data[1]->proving_key.polynomials.get_all(), + prover_polynomials.get_all())) { + for (size_t i = 0; i < /*circuit_size*/ 2; i++) { + new_polynomial.at(i) = + key_0_polynomial[i] + ((key_1_polynomial[i] - key_0_polynomial[i]) * idx); + } + } + extended_polynomials.push_back(std::move(prover_polynomials)); + } + std::array precomputed_result{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; + // Compute the sum for each index separately, treating each extended key independently + for (size_t idx = 0; idx < UNIVARIATE_LENGTH; idx++) { + + typename Flavor::TupleOfArraysOfValues accumulator; + if (idx < NUM_KEYS) { + for (size_t i = 0; i < 2; i++) { + UltraArithmeticRelation::accumulate(std::get<0>(accumulator), + keys_data[idx]->proving_key.polynomials.get_row(i), + relation_parameters, + gate_separators[i]); + } + } else { + for (size_t i = 0; i < 2; i++) { + UltraArithmeticRelation::accumulate(std::get<0>(accumulator), + extended_polynomials[idx - NUM_KEYS].get_row(i), + relation_parameters, + gate_separators[i]); + } + } + precomputed_result[idx] = std::get<0>(accumulator)[0]; + } + auto expected_result = Univariate(precomputed_result); + PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; + PGInternal::UnivariateRelationParameters univariate_relation_parameters; + auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( + keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); + auto result_with_skipping = + pg_internal.compute_combiner(keys, gate_separators, univariate_relation_parameters, alphas); + + EXPECT_EQ(result_no_skipping, expected_result); + EXPECT_EQ(result_with_skipping, expected_result); + } else { + std::vector> keys_data(NUM_KEYS); + + for (size_t idx = 0; idx < NUM_KEYS; idx++) { + auto key = std::make_shared(); + auto prover_polynomials = get_zero_prover_polynomials( + /*log_circuit_size=*/1); + restrict_to_standard_arithmetic_relation(prover_polynomials); + key->proving_key.polynomials = std::move(prover_polynomials); + key->proving_key.circuit_size = 2; + key->proving_key.log_circuit_size = 1; + keys_data[idx] = key; + } + + DeciderProvingKeys keys{ keys_data }; + PGInternal::UnivariateRelationSeparator alphas; + alphas.fill(bb::Univariate(FF(0))); // focus on the arithmetic relation only + + const auto create_add_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { + polys.w_l.at(idx) = w_l; + polys.w_r.at(idx) = w_r; + polys.w_o.at(idx) = w_l + w_r; + polys.q_l.at(idx) = 1; + polys.q_r.at(idx) = 1; + polys.q_o.at(idx) = -1; + }; + + const auto create_mul_gate = [](auto& polys, const size_t idx, FF w_l, FF w_r) { + polys.w_l.at(idx) = w_l; + polys.w_r.at(idx) = w_r; + polys.w_o.at(idx) = w_l * w_r; + polys.q_m.at(idx) = 1; + polys.q_o.at(idx) = -1; + }; + + create_add_gate(keys[0]->proving_key.polynomials, 0, 1, 2); + create_add_gate(keys[0]->proving_key.polynomials, 1, 0, 4); + create_add_gate(keys[1]->proving_key.polynomials, 0, 3, 4); + create_mul_gate(keys[1]->proving_key.polynomials, 1, 1, 4); + + restrict_to_standard_arithmetic_relation(keys[0]->proving_key.polynomials); + restrict_to_standard_arithmetic_relation(keys[1]->proving_key.polynomials); + + /* DeciderProvingKey 0 DeciderProvingKey 1 + w_l w_r w_o q_m q_l q_r q_o q_c w_l w_r w_o q_m q_l q_r q_o q_c + 1 2 3 0 1 1 -1 0 3 4 7 0 1 1 -1 0 + 0 4 4 0 1 1 -1 0 1 4 4 1 0 0 -1 0 */ + + /* Lagrange-combined values, row index 0 Lagrange-combined values, row index 1 + in 0 1 2 3 4 5 6 in 0 1 2 3 4 5 6 + w_l 1 3 5 7 9 11 13 w_l 0 1 2 3 4 5 6 + w_r 2 4 6 8 10 12 14 w_r 4 4 4 4 4 4 4 + w_o 3 7 11 15 19 23 27 w_o 4 4 4 4 4 4 0 + q_m 0 0 0 0 0 0 0 q_m 0 1 2 3 4 5 6 + q_l 1 1 1 1 1 1 1 q_l 1 0 -1 -2 -3 -4 -5 + q_r 1 1 1 1 1 1 1 q_r 1 0 -1 -2 -3 -4 -5 + q_o -1 -1 -1 -1 -1 -1 -1 q_o -1 -1 -1 -1 -1 -1 -1 + q_c 0 0 0 0 0 0 0 q_c 0 0 0 0 0 0 0 + + relation value: + 0 0 0 0 0 0 0 0 0 6 18 36 60 90 */ + + GateSeparatorPolynomial gate_separators({ 2 }, /*log_num_monomials=*/1); + PGInternal::UnivariateRelationParametersNoOptimisticSkipping univariate_relation_parameters_no_skpping; + PGInternal::UnivariateRelationParameters univariate_relation_parameters; + auto result_no_skipping = pg_internal.compute_combiner_no_optimistic_skipping( + keys, gate_separators, univariate_relation_parameters_no_skpping, alphas); + auto result_with_skipping = + pg_internal.compute_combiner(keys, gate_separators, univariate_relation_parameters, alphas); + auto expected_result = + Univariate(std::array{ 0, 0, 12, 36, 72, 120, 180, 252, 336, 432, 540, 660 }); + + EXPECT_EQ(result_no_skipping, expected_result); + EXPECT_EQ(result_with_skipping, expected_result); + } + }; + run_test(true); + run_test(false); +}; \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy.test.cpp b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy.test.cpp index 4264ef833144..bcbd70090d65 100644 --- a/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy.test.cpp +++ b/barretenberg/cpp/src/barretenberg/protogalaxy/protogalaxy.test.cpp @@ -104,12 +104,11 @@ template class ProtogalaxyTests : public testing::Test { } /** - * @brief For a valid circuit, ensures that computing the value of the full UH/MegaHonk relation at each row in - its - * execution trace (with the contribution of the linearly dependent one added tot he first row, in case of - * Goblin) will be 0. - * - */ + * @brief For a valid circuit, ensures that computing the value of the full UH/MegaHonk relation at each row in its + * execution trace (with the contribution of the linearly dependent one added tot he first row, in case of + * Goblin) will be 0. + * + */ static void test_full_honk_evaluations_valid_circuit() { auto builder = typename Flavor::CircuitBuilder(); @@ -219,86 +218,86 @@ template class ProtogalaxyTests : public testing::Test { * and check them against the evaluations returned by the function. * */ - // static void test_combiner_quotient() - // { - // auto perturbator_evaluation = FF(2); // F(\alpha) in the paper - // auto combiner = bb::Univariate(std::array{ 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 }); - // auto combiner_quotient = PGInternal::compute_combiner_quotient(perturbator_evaluation, combiner); - - // // K(i) = (G(i) - ( L_0(i) * F(\alpha)) / Z(i), i = {2,.., 13} for DeciderProvingKeys::NUM = 2 - // // K(i) = (G(i) - (1 - i) * F(\alpha)) / i * (i - 1) - // auto expected_evals = bb::Univariate(std::array{ - // (FF(22) - (FF(1) - FF(2)) * perturbator_evaluation) / (FF(2) * FF(2 - 1)), - // (FF(23) - (FF(1) - FF(3)) * perturbator_evaluation) / (FF(3) * FF(3 - 1)), - // (FF(24) - (FF(1) - FF(4)) * perturbator_evaluation) / (FF(4) * FF(4 - 1)), - // (FF(25) - (FF(1) - FF(5)) * perturbator_evaluation) / (FF(5) * FF(5 - 1)), - // (FF(26) - (FF(1) - FF(6)) * perturbator_evaluation) / (FF(6) * FF(6 - 1)), - // (FF(27) - (FF(1) - FF(7)) * perturbator_evaluation) / (FF(7) * FF(7 - 1)), - // (FF(28) - (FF(1) - FF(8)) * perturbator_evaluation) / (FF(8) * FF(8 - 1)), - // (FF(29) - (FF(1) - FF(9)) * perturbator_evaluation) / (FF(9) * FF(9 - 1)), - // (FF(30) - (FF(1) - FF(10)) * perturbator_evaluation) / (FF(10) * FF(10 - 1)), - // (FF(31) - (FF(1) - FF(11)) * perturbator_evaluation) / (FF(11) * FF(11 - 1)), - // }); - - // for (size_t idx = 2; idx < 7; idx++) { - // EXPECT_EQ(combiner_quotient.value_at(idx), expected_evals.value_at(idx)); - // } - // } + static void test_combiner_quotient() + { + auto perturbator_evaluation = FF(2); // F(\alpha) in the paper + auto combiner = bb::Univariate(std::array{ 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 }); + auto combiner_quotient = PGInternal::compute_combiner_quotient(perturbator_evaluation, combiner); + + // K(i) = (G(i) - ( L_0(i) * F(\alpha)) / Z(i), i = {2,.., 13} for DeciderProvingKeys::NUM = 2 + // K(i) = (G(i) - (1 - i) * F(\alpha)) / i * (i - 1) + auto expected_evals = bb::Univariate(std::array{ + (FF(22) - (FF(1) - FF(2)) * perturbator_evaluation) / (FF(2) * FF(2 - 1)), + (FF(23) - (FF(1) - FF(3)) * perturbator_evaluation) / (FF(3) * FF(3 - 1)), + (FF(24) - (FF(1) - FF(4)) * perturbator_evaluation) / (FF(4) * FF(4 - 1)), + (FF(25) - (FF(1) - FF(5)) * perturbator_evaluation) / (FF(5) * FF(5 - 1)), + (FF(26) - (FF(1) - FF(6)) * perturbator_evaluation) / (FF(6) * FF(6 - 1)), + (FF(27) - (FF(1) - FF(7)) * perturbator_evaluation) / (FF(7) * FF(7 - 1)), + (FF(28) - (FF(1) - FF(8)) * perturbator_evaluation) / (FF(8) * FF(8 - 1)), + (FF(29) - (FF(1) - FF(9)) * perturbator_evaluation) / (FF(9) * FF(9 - 1)), + (FF(30) - (FF(1) - FF(10)) * perturbator_evaluation) / (FF(10) * FF(10 - 1)), + (FF(31) - (FF(1) - FF(11)) * perturbator_evaluation) / (FF(11) * FF(11 - 1)), + }); + + for (size_t idx = 2; idx < 7; idx++) { + EXPECT_EQ(combiner_quotient.value_at(idx), expected_evals.value_at(idx)); + } + } /** * @brief For two dummy decider proving keys with their relation parameter η set, check that combining them in a * univariate, barycentrially extended to the desired number of evaluations, is performed correctly. * */ - // static void test_compute_extended_relation_parameters() - // { - // Builder builder1; - // auto pk_1 = std::make_shared(builder1); - // pk_1->relation_parameters.eta = 1; - - // Builder builder2; - // builder2.add_variable(3); - // auto pk_2 = std::make_shared(builder2); - // pk_2->relation_parameters.eta = 3; - - // DeciderProvingKeys pks{ { pk_1, pk_2 } }; - // auto relation_parameters_no_optimistic_skipping = PGInternal::template compute_extended_relation_parameters< - // typename PGInternal::UnivariateRelationParametersNoOptimisticSkipping>(pks); - // auto relation_parameters = PGInternal::template compute_extended_relation_parameters< - // typename FoldingProver::UnivariateRelationParameters>(pks); - - // bb::Univariate expected_eta{ { 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21 } }; - // EXPECT_EQ(relation_parameters_no_optimistic_skipping.eta, expected_eta); - // // Optimised relation parameters are the same, we just don't compute any values for non-used indices when - // // deriving values from them - // for (size_t i = 0; i < 11; i++) { - // EXPECT_EQ(relation_parameters.eta.evaluations[i], expected_eta.evaluations[i]); - // } - // } - - // /** - // * @brief Given two dummy decider proving_keys with the batching challenges alphas set (one for each subrelation) - // * ensure combining them in a univariate of desired length works as expected. - // */ - // static void test_compute_and_extend_alphas() - // { - // Builder builder1; - // auto pk_1 = std::make_shared(builder1); - // pk_1->alphas.fill(2); - - // Builder builder2; - // builder2.add_variable(3); - // auto pk_2 = std::make_shared(builder2); - // pk_2->alphas.fill(4); - - // DeciderProvingKeys pks{ { pk_1, pk_2 } }; - // auto alphas = PGInternal::compute_and_extend_alphas(pks); - - // bb::Univariate expected_alphas{ { 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24 } }; - // for (const auto& alpha : alphas) { - // EXPECT_EQ(alpha, expected_alphas); - // } - // } + static void test_compute_extended_relation_parameters() + { + Builder builder1; + auto pk_1 = std::make_shared(builder1); + pk_1->relation_parameters.eta = 1; + + Builder builder2; + builder2.add_variable(3); + auto pk_2 = std::make_shared(builder2); + pk_2->relation_parameters.eta = 3; + + DeciderProvingKeys pks{ { pk_1, pk_2 } }; + auto relation_parameters_no_optimistic_skipping = PGInternal::template compute_extended_relation_parameters< + typename PGInternal::UnivariateRelationParametersNoOptimisticSkipping>(pks); + auto relation_parameters = PGInternal::template compute_extended_relation_parameters< + typename FoldingProver::UnivariateRelationParameters>(pks); + + bb::Univariate expected_eta{ { 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21 } }; + EXPECT_EQ(relation_parameters_no_optimistic_skipping.eta, expected_eta); + // Optimised relation parameters are the same, we just don't compute any values for non-used indices when + // deriving values from them + for (size_t i = 0; i < 11; i++) { + EXPECT_EQ(relation_parameters.eta.evaluations[i], expected_eta.evaluations[i]); + } + } + + /** + * @brief Given two dummy decider proving_keys with the batching challenges alphas set (one for each subrelation) + * ensure combining them in a univariate of desired length works as expected. + */ + static void test_compute_and_extend_alphas() + { + Builder builder1; + auto pk_1 = std::make_shared(builder1); + pk_1->alphas.fill(2); + + Builder builder2; + builder2.add_variable(3); + auto pk_2 = std::make_shared(builder2); + pk_2->alphas.fill(4); + + DeciderProvingKeys pks{ { pk_1, pk_2 } }; + auto alphas = PGInternal::compute_and_extend_alphas(pks); + + bb::Univariate expected_alphas{ { 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24 } }; + for (const auto& alpha : alphas) { + EXPECT_EQ(alpha, expected_alphas); + } + } /** * @brief Testing one valid round of folding (plus decider) for two inhomogeneous circuits @@ -442,13 +441,12 @@ template class ProtogalaxyTests : public testing::Test { } /** - * @brief Testing folding a larger circuit into a smaller one by increasing the virtual size of the first. - * @details Fold two circuits using a structured trace, where the second overflows the trace such that the dyadic - * size is doubled. The virtual size of the polynomials in the first key is increased internally in the PG prover - to - * match the size of the second. - * - */ + * @brief Testing folding a larger circuit into a smaller one by increasing the virtual size of the first. + * @details Fold two circuits using a structured trace, where the second overflows the trace such that the dyadic + * size is doubled. The virtual size of the polynomials in the first key is increased internally in the PG prover to + * match the size of the second. + * + */ static void test_fold_with_virtual_size_expansion() { uint32_t overflow_capacity = 0; // consider the case where the overflow is not known until runtime @@ -607,20 +605,20 @@ TYPED_TEST(ProtogalaxyTests, PerturbatorPolynomial) TestFixture::test_pertubator_polynomial(); } -// TYPED_TEST(ProtogalaxyTests, CombinerQuotient) -// { -// TestFixture::test_combiner_quotient(); -// } +TYPED_TEST(ProtogalaxyTests, CombinerQuotient) +{ + TestFixture::test_combiner_quotient(); +} -// TYPED_TEST(ProtogalaxyTests, CombineRelationParameters) -// { -// TestFixture::test_compute_extended_relation_parameters(); -// } +TYPED_TEST(ProtogalaxyTests, CombineRelationParameters) +{ + TestFixture::test_compute_extended_relation_parameters(); +} -// TYPED_TEST(ProtogalaxyTests, CombineAlphas) -// { -// TestFixture::test_compute_and_extend_alphas(); -// } +TYPED_TEST(ProtogalaxyTests, CombineAlphas) +{ + TestFixture::test_compute_and_extend_alphas(); +} TYPED_TEST(ProtogalaxyTests, ProtogalaxyInhomogeneous) { @@ -662,8 +660,8 @@ TYPED_TEST(ProtogalaxyTests, BadLookupFailure) TestFixture::test_protogalaxy_bad_lookup_failure(); } -// We only fold one incoming decider key pair since this is all we plan to use, and compiling for higher values of k -// is a significant compilation time cost. +// We only fold one incoming decider key pair since this is all we plan to use, and compiling for higher values of k is +// a significant compilation time cost. TYPED_TEST(ProtogalaxyTests, Fold1) { TestFixture::template test_fold_k_key_pairs<1>(); diff --git a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp index 89ad3146e360..884281f464f7 100644 --- a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/mega_flavor.hpp @@ -78,7 +78,7 @@ class MegaFlavor { static constexpr size_t MAX_PARTIAL_RELATION_LENGTH = compute_max_partial_relation_length(); static constexpr size_t MAX_TOTAL_RELATION_LENGTH = compute_max_total_relation_length(); - // static_assert(MAX_TOTAL_RELATION_LENGTH == 11); + static_assert(MAX_TOTAL_RELATION_LENGTH == 11); // BATCHED_RELATION_PARTIAL_LENGTH = algebraic degree of sumcheck relation *after* multiplying by the `pow_zeta` // random polynomial e.g. For \sum(x) [A(x) * B(x) + C(x)] * PowZeta(X), relation length = 2 and random relation // length = 3 From a1d6483bf30eb4c948685f7ba19bcf7395c832d5 Mon Sep 17 00:00:00 2001 From: maramihali Date: Mon, 16 Dec 2024 18:16:48 +0000 Subject: [PATCH 06/18] cleanup --- .../execution_trace/execution_trace_usage_tracker.hpp | 11 ++++------- .../execution_trace/mega_execution_trace.hpp | 2 +- .../barretenberg/ultra_honk/decider_proving_key.cpp | 5 +++-- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index 2b1226f6ea4f..efbffaa3ea3e 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -88,15 +88,12 @@ struct ExecutionTraceUsageTracker { } // The active ranges must also include the rows where the actual databus and lookup table data are stored. - // (Note: lookup tables are constructed at the end of the trace; databus data is constructed at the start) so we - // need to determine the dyadic size for this. We call the size function on the current circuit which will have - // the same fixed block sizes but might also have an overflow block potentially influencing the dyadic circuit - // size. - // TODO(https://github.com/AztecProtocol/barretenberg/issues/1160) + // (Note: lookup tables are constructed from the beginning of the lookup block ; databus data is constructed at + // the start of the trace). // TODO(https://github.com/AztecProtocol/barretenberg/issues/1152): should be able to use simply Range{ 0, - // max_databus_size } but this breaks for certain choices of num_threads. - + // max_databus_size } but this breaks for certain choices of num_threads. It should also be possible to have the + // lookup table data be Range{lookup_start, max_tables_size} but that also breaks. size_t databus_end = std::max(max_databus_size, static_cast(fixed_sizes.busread.trace_offset + max_sizes.busread)); active_ranges.emplace_back(0, databus_end); diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp index 2afc8175e52d..e1d31a9fac1c 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/mega_execution_trace.hpp @@ -14,7 +14,7 @@ namespace bb { * * @details We instantiate this both to contain the actual gates of an execution trace, and also to describe different * trace structures (i.e., sets of capacities for each block type, which we use to optimize the folding prover). - * Note: the ecc_op has to be the first in the execution trace. + * Note: the ecc_op block has to be the first in the execution trace to not break the Goblin functionality. */ template struct MegaTraceBlockData { T ecc_op; diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.cpp b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.cpp index ee561dd78b72..823d412122e2 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.cpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.cpp @@ -100,7 +100,7 @@ void DeciderProvingKey_::allocate_table_lookup_polynomials(const Circuit size_t table_offset = circuit.blocks.lookup.trace_offset; const size_t max_tables_size = std::min(static_cast(MAX_LOOKUP_TABLES_SIZE), dyadic_circuit_size - table_offset); - // ASSERT(dyadic_circuit_size > max_tables_size); + ASSERT(dyadic_circuit_size > max_tables_size); // Allocate the polynomials containing the actual table data if constexpr (IsUltraFlavor) { @@ -156,7 +156,8 @@ void DeciderProvingKey_::allocate_databus_polynomials(const Circuit& cir proving_key.polynomials.return_data_read_counts = Polynomial(MAX_DATABUS_SIZE, proving_key.circuit_size); proving_key.polynomials.return_data_read_tags = Polynomial(MAX_DATABUS_SIZE, proving_key.circuit_size); - proving_key.polynomials.databus_id = Polynomial(proving_key.circuit_size, proving_key.circuit_size); + proving_key.polynomials.databus_id = Polynomial(MAX_DATABUS_SIZE, proving_key.circuit_size); + // Allocate log derivative lookup argument inverse polynomials const size_t q_busread_end = circuit.blocks.busread.trace_offset + circuit.blocks.busread.get_fixed_size(is_structured); From 337da04da7297ddaf1489feb9e43a52052037b9b Mon Sep 17 00:00:00 2001 From: maramihali Date: Mon, 16 Dec 2024 18:19:04 +0000 Subject: [PATCH 07/18] small fix --- .../cpp/src/barretenberg/protogalaxy/combiner.test.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp b/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp index 614a56388684..c280cf241f12 100644 --- a/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp +++ b/barretenberg/cpp/src/barretenberg/protogalaxy/combiner.test.cpp @@ -213,8 +213,8 @@ TEST(Protogalaxy, CombinerOptimizationConsistency) } // Get the result of the 0th subrelation of the arithmetic relation FF key_offset = std::get<0>(temporary_accumulator)[0]; - // Subtract it from q_c[0] (it directly affect the target sum, making it zero and enabling the - optimisation) keys_data[1]->proving_key.polynomials.q_c.at(0) -= key_offset; + // Subtract it from q_c[0] (it directly affect the target sum, making it zero and enabling the optimisation) + keys_data[1]->proving_key.polynomials.q_c.at(0) -= key_offset; std::vector extended_polynomials; // These hold the extensions of prover polynomials From da51f113166464f44f07ae2d5df355d19eedd3da Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 10:13:09 +0000 Subject: [PATCH 08/18] fixes from PR review --- .../client_ivc_bench/client_ivc.bench.cpp | 2 +- .../commitment_schemes/commitment_key.hpp | 17 +++++++---------- .../execution_trace_usage_tracker.hpp | 3 +-- .../ultra_honk/decider_proving_key.hpp | 1 - 4 files changed, 9 insertions(+), 14 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp index 6033648972c4..7aa1b8910d83 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp @@ -33,7 +33,7 @@ class ClientIVCBench : public benchmark::Fixture { */ BENCHMARK_DEFINE_F(ClientIVCBench, Full)(benchmark::State& state) { - ClientIVC ivc{ { CLIENT_IVC_BENCH_STRUCTURE } }; + ClientIVC ivc{ { EXAMPLE_20 } }; auto total_num_circuits = 2 * static_cast(state.range(0)); // 2x accounts for kernel circuits auto mocked_vkeys = mock_verification_keys(total_num_circuits); diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp index 4ba7fac1a1ba..dca262c5edc2 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp @@ -235,16 +235,13 @@ template class CommitmentKey { std::vector points; points.reserve(total_num_scalars * 2); for (const auto& [first, second] : active_ranges) { - { - auto start = &polynomial[first]; - auto end = &polynomial[second]; - scalars.insert(scalars.end(), start, end); - } - { - auto start = &point_table[2 * first]; - auto end = &point_table[2 * second]; - points.insert(points.end(), start, end); - } + auto poly_start = &polynomial[first]; + auto poly_end = &polynomial[second]; + scalars.insert(scalars.end(), poly_start, poly_end); + + auto pts_start = &point_table[2 * first]; + auto pts_end = &point_table[2 * second]; + points.insert(points.end(), pts_start, pts_end); } // Call pippenger diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index efbffaa3ea3e..13eb25f602e5 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -98,8 +98,7 @@ struct ExecutionTraceUsageTracker { std::max(max_databus_size, static_cast(fixed_sizes.busread.trace_offset + max_sizes.busread)); active_ranges.emplace_back(0, databus_end); size_t lookups_start = fixed_sizes.lookup.trace_offset; - size_t lookups_end = - std::max(lookups_start + max_tables_size, static_cast(lookups_start + max_sizes.lookup)); + size_t lookups_end = lookups_start + std::max(max_tables_size, static_cast(max_sizes.lookup)); active_ranges.emplace_back(lookups_start, lookups_end); } diff --git a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp index a5da25969e83..0fdfbfe7e162 100644 --- a/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp +++ b/barretenberg/cpp/src/barretenberg/ultra_honk/decider_proving_key.hpp @@ -91,7 +91,6 @@ template class DeciderProvingKey_ { final_active_wire_idx = block.trace_offset + block.size() - 1; } } - info("Final active wire idx: ", final_active_wire_idx); // TODO(https://github.com/AztecProtocol/barretenberg/issues/905): This is adding ops to the op queue but NOT to // the circuit, meaning the ECCVM/Translator will use different ops than the main circuit. This will lead to From b4b5cf563327247d27a196c140b1f0d0c584da13 Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 11:15:14 +0000 Subject: [PATCH 09/18] loookup block at the beginning of ultra trace to ensure ultra structured trace also works appropriately --- .../dsl/acir_format/acir_integration.test.cpp | 2 +- .../execution_trace/ultra_execution_trace.hpp | 28 ++++++++++--------- .../stdlib_circuit_builders/ultra_flavor.hpp | 25 +++++++++-------- 3 files changed, 29 insertions(+), 26 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/dsl/acir_format/acir_integration.test.cpp b/barretenberg/cpp/src/barretenberg/dsl/acir_format/acir_integration.test.cpp index 1a0d7b5b823a..4a5097a4dd46 100644 --- a/barretenberg/cpp/src/barretenberg/dsl/acir_format/acir_integration.test.cpp +++ b/barretenberg/cpp/src/barretenberg/dsl/acir_format/acir_integration.test.cpp @@ -142,7 +142,7 @@ class AcirIntegrationFoldingTest : public AcirIntegrationTest, public testing::W TEST_P(AcirIntegrationSingleTest, DISABLED_ProveAndVerifyProgram) { - using Flavor = MegaFlavor; + using Flavor = UltraFlavor; // using Flavor = bb::plonk::flavor::Ultra; using Builder = Flavor::CircuitBuilder; diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp index ccf81b1645c3..dd4b66107c11 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp @@ -15,25 +15,25 @@ namespace bb { * @tparam T */ template struct UltraTraceBlockData { + T lookup; T pub_inputs; T arithmetic; T delta_range; T elliptic; T aux; - T lookup; T poseidon2_external; T poseidon2_internal; T overflow; auto get() { - return RefArray{ pub_inputs, arithmetic, delta_range, elliptic, aux, - lookup, poseidon2_external, poseidon2_internal, overflow }; + return RefArray{ lookup, pub_inputs, arithmetic, delta_range, elliptic, + aux, poseidon2_external, poseidon2_internal, overflow }; } auto get_gate_blocks() const { - return RefArray{ arithmetic, delta_range, elliptic, aux, lookup, poseidon2_external, poseidon2_internal }; + return RefArray{ lookup, arithmetic, delta_range, elliptic, aux, poseidon2_external, poseidon2_internal }; } bool operator==(const UltraTraceBlockData& other) const = default; @@ -66,18 +66,20 @@ class UltraTraceBlock : public ExecutionTraceBlockselectors[3]; }; auto& q_3() { return this->selectors[4]; }; auto& q_4() { return this->selectors[5]; }; - auto& q_arith() { return this->selectors[6]; }; - auto& q_delta_range() { return this->selectors[7]; }; - auto& q_elliptic() { return this->selectors[8]; }; - auto& q_aux() { return this->selectors[9]; }; - auto& q_lookup_type() { return this->selectors[10]; }; + auto& q_lookup_type() { return this->selectors[6]; }; + auto& q_arith() { return this->selectors[7]; }; + auto& q_delta_range() { return this->selectors[8]; }; + auto& q_elliptic() { return this->selectors[9]; }; + auto& q_aux() { return this->selectors[10]; }; auto& q_poseidon2_external() { return this->selectors[11]; }; auto& q_poseidon2_internal() { return this->selectors[12]; }; RefVector get_gate_selectors() { - return { q_arith(), q_delta_range(), q_elliptic(), q_aux(), q_poseidon2_external(), q_poseidon2_internal(), - q_lookup_type() }; + return { + q_lookup_type(), q_arith(), q_delta_range(), q_elliptic(), q_aux(), q_poseidon2_external(), + q_poseidon2_internal(), + }; } }; @@ -112,12 +114,12 @@ class UltraExecutionTraceBlocks : public UltraTraceBlockData { void summarize() const { info("Gate blocks summary:"); + info("lookups :\t", this->lookup.size()); info("pub inputs :\t", this->pub_inputs.size()); info("arithmetic :\t", this->arithmetic.size()); info("delta range:\t", this->delta_range.size()); info("elliptic :\t", this->elliptic.size()); info("auxiliary :\t", this->aux.size()); - info("lookups :\t", this->lookup.size()); info("poseidon ext :\t", this->poseidon2_external.size()); info("poseidon int :\t", this->poseidon2_internal.size()); info("overflow :\t", this->overflow.size()); @@ -146,11 +148,11 @@ class UltraExecutionTraceBlocks : public UltraTraceBlockData { "q_2", "q_3", "q_4", + "table_type", "q_arith", "q_sort", "q_elliptic", "q_aux", - "table_type", "q_poseidon2_external", "q_poseidon2_internal" }; }; diff --git a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_flavor.hpp b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_flavor.hpp index f34d0b487330..65dc67b7f5dd 100644 --- a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_flavor.hpp @@ -129,11 +129,11 @@ class UltraFlavor { q_r, // column 3 q_o, // column 4 q_4, // column 5 - q_arith, // column 6 - q_delta_range, // column 7 - q_elliptic, // column 8 - q_aux, // column 9 - q_lookup, // column 10 + q_lookup, // column 6 + q_arith, // column 7 + q_delta_range, // column 8 + q_elliptic, // column 9 + q_aux, // column 10 q_poseidon2_external, // column 11 q_poseidon2_internal, // column 12 sigma_1, // column 13 @@ -156,8 +156,9 @@ class UltraFlavor { auto get_non_gate_selectors() { return RefArray{ q_m, q_c, q_l, q_r, q_o, q_4 }; } auto get_gate_selectors() { - return RefArray{ q_arith, q_delta_range, q_elliptic, q_aux, - q_lookup, q_poseidon2_external, q_poseidon2_internal }; + return RefArray{ + q_lookup, q_arith, q_delta_range, q_elliptic, q_aux, q_poseidon2_external, q_poseidon2_internal + }; } auto get_selectors() { return concatenate(get_non_gate_selectors(), get_gate_selectors()); } @@ -481,11 +482,11 @@ class UltraFlavor { const Commitment& q_r, const Commitment& q_o, const Commitment& q_4, + const Commitment& q_lookup, const Commitment& q_arith, const Commitment& q_delta_range, const Commitment& q_elliptic, const Commitment& q_aux, - const Commitment& q_lookup, const Commitment& q_poseidon2_external, const Commitment& q_poseidon2_internal, const Commitment& sigma_1, @@ -515,11 +516,11 @@ class UltraFlavor { this->q_r = q_r; this->q_o = q_o; this->q_4 = q_4; + this->q_lookup = q_lookup; this->q_arith = q_arith; this->q_delta_range = q_delta_range; this->q_elliptic = q_elliptic; this->q_aux = q_aux; - this->q_lookup = q_lookup; this->q_poseidon2_external = q_poseidon2_external; this->q_poseidon2_internal = q_poseidon2_internal; this->sigma_1 = sigma_1; @@ -551,11 +552,11 @@ class UltraFlavor { q_r, q_o, q_4, + q_lookup, q_arith, q_delta_range, q_elliptic, q_aux, - q_lookup, q_poseidon2_external, q_poseidon2_internal, sigma_1, @@ -641,11 +642,11 @@ class UltraFlavor { q_o = "Q_O"; q_4 = "Q_4"; q_m = "Q_M"; + q_lookup = "Q_LOOKUP"; q_arith = "Q_ARITH"; q_delta_range = "Q_SORT"; q_elliptic = "Q_ELLIPTIC"; q_aux = "Q_AUX"; - q_lookup = "Q_LOOKUP"; q_poseidon2_external = "Q_POSEIDON2_EXTERNAL"; q_poseidon2_internal = "Q_POSEIDON2_INTERNAL"; sigma_1 = "SIGMA_1"; @@ -682,11 +683,11 @@ class UltraFlavor { this->q_r = verification_key->q_r; this->q_o = verification_key->q_o; this->q_4 = verification_key->q_4; + this->q_lookup = verification_key->q_lookup; this->q_arith = verification_key->q_arith; this->q_delta_range = verification_key->q_delta_range; this->q_elliptic = verification_key->q_elliptic; this->q_aux = verification_key->q_aux; - this->q_lookup = verification_key->q_lookup; this->q_poseidon2_external = verification_key->q_poseidon2_external; this->q_poseidon2_internal = verification_key->q_poseidon2_internal; this->sigma_1 = verification_key->sigma_1; From d8015db15504cc67201beb4bd840d1a9bc0a7380 Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 11:45:28 +0000 Subject: [PATCH 10/18] add required modifications to solidity --- barretenberg/acir_tests/sol-test/yarn.lock | 34 +++--- .../dsl/acir_proofs/honk_contract.hpp | 12 +- .../ultra_keccak_flavor.hpp | 6 +- barretenberg/sol/src/honk/HonkTypes.sol | 4 +- barretenberg/sol/src/honk/Relations.sol | 1 + .../sol/src/honk/instance/Add2Honk.sol | 10 +- .../sol/src/honk/instance/BlakeHonk.sol | 10 +- .../sol/src/honk/instance/EcdsaHonk.sol | 10 +- .../src/honk/keys/Add2HonkVerificationKey.sol | 102 ++++++++-------- .../honk/keys/BlakeHonkVerificationKey.sol | 106 ++++++++-------- .../honk/keys/EcdsaHonkVerificationKey.sol | 114 +++++++++--------- .../ultra/keys/Add2UltraVerificationKey.sol | 24 ++-- .../ultra/keys/BlakeUltraVerificationKey.sol | 80 ++++++------ .../ultra/keys/EcdsaUltraVerificationKey.sol | 80 ++++++------ .../keys/RecursiveUltraVerificationKey.sol | 80 ++++++------ 15 files changed, 337 insertions(+), 336 deletions(-) diff --git a/barretenberg/acir_tests/sol-test/yarn.lock b/barretenberg/acir_tests/sol-test/yarn.lock index c0a909976543..f8410d95c1a3 100644 --- a/barretenberg/acir_tests/sol-test/yarn.lock +++ b/barretenberg/acir_tests/sol-test/yarn.lock @@ -4,44 +4,44 @@ "@adraffy/ens-normalize@1.10.0": version "1.10.0" - resolved "https://registry.yarnpkg.com/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz#d2a39395c587e092d77cbbc80acf956a54f38bf7" + resolved "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz" integrity sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q== "@noble/curves@1.2.0": version "1.2.0" - resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.2.0.tgz#92d7e12e4e49b23105a2555c6984d41733d65c35" + resolved "https://registry.npmjs.org/@noble/curves/-/curves-1.2.0.tgz" integrity sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw== dependencies: "@noble/hashes" "1.3.2" "@noble/hashes@1.3.2": version "1.3.2" - resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.2.tgz#6f26dbc8fbc7205873ce3cee2f690eba0d421b39" + resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.2.tgz" integrity sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ== "@types/node@18.15.13": version "18.15.13" - resolved "https://registry.yarnpkg.com/@types/node/-/node-18.15.13.tgz#f64277c341150c979e42b00e4ac289290c9df469" + resolved "https://registry.npmjs.org/@types/node/-/node-18.15.13.tgz" integrity sha512-N+0kuo9KgrUQ1Sn/ifDXsvg0TTleP7rIy4zOBGECxAljqvqfqpTfzx0Q1NUedOixRMBfe2Whhb056a42cWs26Q== aes-js@4.0.0-beta.5: version "4.0.0-beta.5" - resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-4.0.0-beta.5.tgz#8d2452c52adedebc3a3e28465d858c11ca315873" + resolved "https://registry.npmjs.org/aes-js/-/aes-js-4.0.0-beta.5.tgz" integrity sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q== command-exists@^1.2.8: version "1.2.9" - resolved "https://registry.yarnpkg.com/command-exists/-/command-exists-1.2.9.tgz#c50725af3808c8ab0260fd60b01fbfa25b954f69" + resolved "https://registry.npmjs.org/command-exists/-/command-exists-1.2.9.tgz" integrity sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w== commander@^8.1.0: version "8.3.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-8.3.0.tgz#4837ea1b2da67b9c616a67afbb0fafee567bca66" + resolved "https://registry.npmjs.org/commander/-/commander-8.3.0.tgz" integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== ethers@^6.8.1: version "6.8.1" - resolved "https://registry.yarnpkg.com/ethers/-/ethers-6.8.1.tgz#ee2a1a39b5f62a13678f90ccd879175391d0a2b4" + resolved "https://registry.npmjs.org/ethers/-/ethers-6.8.1.tgz" integrity sha512-iEKm6zox5h1lDn6scuRWdIdFJUCGg3+/aQWu0F4K0GVyEZiktFkqrJbRjTn1FlYEPz7RKA707D6g5Kdk6j7Ljg== dependencies: "@adraffy/ens-normalize" "1.10.0" @@ -54,32 +54,32 @@ ethers@^6.8.1: follow-redirects@^1.12.1: version "1.15.3" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.3.tgz#fe2f3ef2690afce7e82ed0b44db08165b207123a" + resolved "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.3.tgz" integrity sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q== js-sha3@0.8.0: version "0.8.0" - resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.8.0.tgz#b9b7a5da73afad7dedd0f8c463954cbde6818840" + resolved "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz" integrity sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q== memorystream@^0.3.1: version "0.3.1" - resolved "https://registry.yarnpkg.com/memorystream/-/memorystream-0.3.1.tgz#86d7090b30ce455d63fbae12dda51a47ddcaf9b2" + resolved "https://registry.npmjs.org/memorystream/-/memorystream-0.3.1.tgz" integrity sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw== os-tmpdir@~1.0.2: version "1.0.2" - resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" + resolved "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz" integrity sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g== semver@^5.5.0: version "5.7.2" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + resolved "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz" integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== solc@^0.8.27: version "0.8.27" - resolved "https://registry.yarnpkg.com/solc/-/solc-0.8.27.tgz#cb8e7246cceadad8df65ceccffe640e106106bb4" + resolved "https://registry.npmjs.org/solc/-/solc-0.8.27.tgz" integrity sha512-BNxMol2tUAbkH7HKlXBcBqrGi2aqgv+uMHz26mJyTtlVgWmBA4ktiw0qVKHfkjf2oaHbwtbtaSeE2dhn/gTAKw== dependencies: command-exists "^1.2.8" @@ -92,17 +92,17 @@ solc@^0.8.27: tmp@0.0.33: version "0.0.33" - resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + resolved "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz" integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== dependencies: os-tmpdir "~1.0.2" tslib@2.4.0: version "2.4.0" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.4.0.tgz#7cecaa7f073ce680a05847aa77be941098f36dc3" + resolved "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz" integrity sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ== ws@8.5.0: version "8.5.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.5.0.tgz#bfb4be96600757fe5382de12c670dab984a1ed4f" + resolved "https://registry.npmjs.org/ws/-/ws-8.5.0.tgz" integrity sha512-BWX0SWVgLPzYwF8lTzEy1egjhS4S4OEAHfsO8o65WOVsrnSRGaSiUaa9e0ggGlkMTtBlmOpEXiie9RUcBO86qg== diff --git a/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp b/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp index 95e37c1fbeb9..c0cc2040a2de 100644 --- a/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp +++ b/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp @@ -231,11 +231,11 @@ library Honk { G1Point qr; G1Point qo; G1Point q4; + G1Point qLookup; // Lookup G1Point qArith; // Arithmetic widget G1Point qDeltaRange; // Delta Range sort G1Point qAux; // Auxillary G1Point qElliptic; // Auxillary - G1Point qLookup; // Lookup G1Point qPoseidon2External; G1Point qPoseidon2Internal; // Copy cnstraints @@ -1658,11 +1658,11 @@ contract HonkVerifier is IVerifier commitments[4] = vk.qr; commitments[5] = vk.qo; commitments[6] = vk.q4; - commitments[7] = vk.qArith; - commitments[8] = vk.qDeltaRange; - commitments[9] = vk.qElliptic; - commitments[10] = vk.qAux; - commitments[11] = vk.qLookup; + commitments[7] = vk.qLookup; + commitments[8] = vk.qArith; + commitments[9] = vk.qDeltaRange; + commitments[10] = vk.qElliptic; + commitments[11] = vk.qAux; commitments[12] = vk.qPoseidon2External; commitments[13] = vk.qPoseidon2Internal; commitments[14] = vk.s1; diff --git a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_keccak_flavor.hpp b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_keccak_flavor.hpp index 8ca7f72b418f..e7b47f9235af 100644 --- a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_keccak_flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_keccak_flavor.hpp @@ -67,11 +67,11 @@ class UltraKeccakFlavor : public bb::UltraFlavor { const Commitment& q_r, const Commitment& q_o, const Commitment& q_4, + const Commitment& q_lookup, const Commitment& q_arith, const Commitment& q_delta_range, const Commitment& q_elliptic, const Commitment& q_aux, - const Commitment& q_lookup, const Commitment& q_poseidon2_external, const Commitment& q_poseidon2_internal, const Commitment& sigma_1, @@ -99,11 +99,11 @@ class UltraKeccakFlavor : public bb::UltraFlavor { this->q_r = q_r; this->q_o = q_o; this->q_4 = q_4; + this->q_lookup = q_lookup; this->q_arith = q_arith; this->q_delta_range = q_delta_range; this->q_elliptic = q_elliptic; this->q_aux = q_aux; - this->q_lookup = q_lookup; this->q_poseidon2_external = q_poseidon2_external; this->q_poseidon2_internal = q_poseidon2_internal; this->sigma_1 = sigma_1; @@ -133,11 +133,11 @@ class UltraKeccakFlavor : public bb::UltraFlavor { q_r, q_o, q_4, + q_lookup, q_arith, q_delta_range, q_elliptic, q_aux, - q_lookup, q_poseidon2_external, q_poseidon2_internal, sigma_1, diff --git a/barretenberg/sol/src/honk/HonkTypes.sol b/barretenberg/sol/src/honk/HonkTypes.sol index 55176738d07c..c7f3f2d9fbbb 100644 --- a/barretenberg/sol/src/honk/HonkTypes.sol +++ b/barretenberg/sol/src/honk/HonkTypes.sol @@ -25,11 +25,11 @@ enum WIRE { Q_R, Q_O, Q_4, + Q_LOOKUP, Q_ARITH, Q_RANGE, Q_ELLIPTIC, Q_AUX, - Q_LOOKUP, Q_POSEIDON2_EXTERNAL, Q_POSEIDON2_INTERNAL, SIGMA_1, @@ -91,11 +91,11 @@ library Honk { G1Point qr; G1Point qo; G1Point q4; + G1Point qLookup; // Lookup G1Point qArith; // Arithmetic widget G1Point qDeltaRange; // Delta Range sort G1Point qAux; // Auxillary G1Point qElliptic; // Auxillary - G1Point qLookup; // Lookup G1Point qPoseidon2External; G1Point qPoseidon2Internal; // Copy cnstraints diff --git a/barretenberg/sol/src/honk/Relations.sol b/barretenberg/sol/src/honk/Relations.sol index 9ca4868cc442..251dbe8245ae 100644 --- a/barretenberg/sol/src/honk/Relations.sol +++ b/barretenberg/sol/src/honk/Relations.sol @@ -57,6 +57,7 @@ library RelationsLib { * Ultra Arithmetic Relation * */ + function accumulateArithmeticRelation( Fr[NUMBER_OF_ENTITIES] memory p, Fr[NUMBER_OF_SUBRELATIONS] memory evals, diff --git a/barretenberg/sol/src/honk/instance/Add2Honk.sol b/barretenberg/sol/src/honk/instance/Add2Honk.sol index 00e26a8ca1b7..1f6e0af125ff 100644 --- a/barretenberg/sol/src/honk/instance/Add2Honk.sol +++ b/barretenberg/sol/src/honk/instance/Add2Honk.sol @@ -276,11 +276,11 @@ contract Add2HonkVerifier is IVerifier { commitments[4] = vk.qr; commitments[5] = vk.qo; commitments[6] = vk.q4; - commitments[7] = vk.qArith; - commitments[8] = vk.qDeltaRange; - commitments[9] = vk.qElliptic; - commitments[10] = vk.qAux; - commitments[11] = vk.qLookup; + commitments[7] = vk.qLookup; + commitments[8] = vk.qArith; + commitments[9] = vk.qDeltaRange; + commitments[10] = vk.qElliptic; + commitments[11] = vk.qAux; commitments[12] = vk.qPoseidon2External; commitments[13] = vk.qPoseidon2Internal; commitments[14] = vk.s1; diff --git a/barretenberg/sol/src/honk/instance/BlakeHonk.sol b/barretenberg/sol/src/honk/instance/BlakeHonk.sol index 6e617946e060..0e41152a9b64 100644 --- a/barretenberg/sol/src/honk/instance/BlakeHonk.sol +++ b/barretenberg/sol/src/honk/instance/BlakeHonk.sol @@ -277,11 +277,11 @@ contract BlakeHonkVerifier is IVerifier { commitments[4] = vk.qr; commitments[5] = vk.qo; commitments[6] = vk.q4; - commitments[7] = vk.qArith; - commitments[8] = vk.qDeltaRange; - commitments[9] = vk.qElliptic; - commitments[10] = vk.qAux; - commitments[11] = vk.qLookup; + commitments[7] = vk.qLookup; + commitments[8] = vk.qArith; + commitments[9] = vk.qDeltaRange; + commitments[10] = vk.qElliptic; + commitments[11] = vk.qAux; commitments[12] = vk.qPoseidon2External; commitments[13] = vk.qPoseidon2Internal; commitments[14] = vk.s1; diff --git a/barretenberg/sol/src/honk/instance/EcdsaHonk.sol b/barretenberg/sol/src/honk/instance/EcdsaHonk.sol index 6d8a4a39c021..4ad9afede8f6 100644 --- a/barretenberg/sol/src/honk/instance/EcdsaHonk.sol +++ b/barretenberg/sol/src/honk/instance/EcdsaHonk.sol @@ -279,11 +279,11 @@ contract EcdsaHonkVerifier is IVerifier { commitments[4] = vk.qr; commitments[5] = vk.qo; commitments[6] = vk.q4; - commitments[7] = vk.qArith; - commitments[8] = vk.qDeltaRange; - commitments[9] = vk.qElliptic; - commitments[10] = vk.qAux; - commitments[11] = vk.qLookup; + commitments[7] = vk.qLookup; + commitments[8] = vk.qArith; + commitments[9] = vk.qDeltaRange; + commitments[10] = vk.qElliptic; + commitments[11] = vk.qAux; commitments[12] = vk.qPoseidon2External; commitments[13] = vk.qPoseidon2Internal; commitments[14] = vk.s1; diff --git a/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol b/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol index 2402e0a4069f..c521dab7f689 100644 --- a/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol +++ b/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol @@ -14,49 +14,49 @@ library Add2HonkVerificationKey { circuitSize: uint256(32), logCircuitSize: uint256(5), publicInputsSize: uint256(3), + qm: Honk.G1Point({ + x: uint256(0x0cf9ec917690b1f3c5f1eeca422fd46fecedb7e285f730f04ffc950e10849b56), + y: uint256(0x0ba3c142aa26e5287a2c234b10bc87e843be79521006162193eda994ab7115e8) + }), + qc: Honk.G1Point({ + x: uint256(0x22cdd25966a6b790032ec0abcb6580bb0c0b16fc0451b1c049e875c591ba0290), + y: uint256(0x08ee89ab716f9c1a86eb455af26ea22b62b37322d38c4577e58d7afa0e4dec56) + }), ql: Honk.G1Point({ - x: uint256(0x043d063b130adfb37342af45d0155a28edd1a7e46c840d9c943fdf45521c64ce), - y: uint256(0x261522c4089330646aff96736194949330952ae74c573d1686d9cb4a00733854) + x: uint256(0x27456b3a666ff24c6452657437518f7b73e854ce6c763732122a3b923bc6797b), + y: uint256(0x2ecbc0db4ae72d05db96eb72034b26275a33325b05b2dd53c33662369bcdc4e0) }), qr: Honk.G1Point({ - x: uint256(0x291338e99e7857222c76c5e4ba8b954f5fde09fd2f05634d622ba379657cd501), - y: uint256(0x137030ce3236d7c12307adf650a73b87fc95a774ec43ac0a3a341ef26b7f56c9) + x: uint256(0x11d6feb82ca1a185806312498f81091e3f9bb74c4b7625b3ae8dd7cea4dc710f), + y: uint256(0x1649b8452a7577b1e16b23a2d05711c5e55a180853be8aac29fc4aa1d64f7b13) }), qo: Honk.G1Point({ - x: uint256(0x0f90f4bb16b330b82ef51e7ce3f70a9310ea2d3c5ef855f07b6f58081b5ef41f), - y: uint256(0x0e09412eea75978da57db1d3fa6b7d14c0e282c378be9a6d0efc5770863ed70b) + x: uint256(0x14dfdc022af1eca2f57e7d7420a9a3282a49254446bf39714d9ede31a2130728), + y: uint256(0x2b3ff801ccaf5061adb0321ebcc51710ff7b342916e51c1926ab0e6bb652cd44) }), q4: Honk.G1Point({ - x: uint256(0x1eec247154ced5c29b0836528d7c19eda11399dc21e23df4bee4b5cd0bec659f), - y: uint256(0x107cc382fdee2f6530d39b072a2bc50bdb0c0ac4b054a905b03b9d53bebef404) + x: uint256(0x1b87b4f288e37e4ff07f6a368177b9765eeccd1017bec74e98859fa3fbf201f3), + y: uint256(0x1d100498fbe5bd401d2eb9b77f1a887806c8251de6ccab14008a324357e5ddfb) }), - qm: Honk.G1Point({ - x: uint256(0x0c17b7ba3864cabe287a2b121b5cb3f8ee4ede87a7f656b8d9b470be025007c8), - y: uint256(0x09590397bf354089980bd40f5d84f4c12faa8b4646425fa660ab7c4c76fb4859) - }), - qc: Honk.G1Point({ - x: uint256(0x2ac1a00b4c9bb4e7deef8d7a6bf9e26e61f2b935409e41c5770c074303b6d142), - y: uint256(0x192d962de288fb26f3d68052b2f475e884ca47e595de1184171cd1500249fa66) + qLookup: Honk.G1Point({ + x: uint256(0x1d64341216e323f076ac53aa06192392677f44b67b6947dd6a0a1490fb32a083), + y: uint256(0x28d02cea9cc379ace2ae8779011e247ddc4213ef69895a8e634f425844107141) }), qArith: Honk.G1Point({ - x: uint256(0x1797e3e7ee9e4f42b42bd375f13f2ccb395b827e9079e999b6c128d9b083c395), - y: uint256(0x101a60efaab1c8564add45d41b9147efacf45941c3efe93c3568bde1e08e1919) + x: uint256(0x06d4ca88fe948f6b5f555d318feea69879457f1cf2b22f7d464fa8d4a8b5cd46), + y: uint256(0x155440972055e3134a5b514eccdd47b0cc217ff529b603700339d647b7e338d3) }), qDeltaRange: Honk.G1Point({ - x: uint256(0x0e84090add56f2500ab518c655cae63896ea793e6b3f6a14218d476534109610), - y: uint256(0x2b78a584bd6ae88cf4ec7c65c90e0b65df446fdddba972f3c4414ad3c901f4f9) - }), - qElliptic: Honk.G1Point({ x: uint256(0x1bd6129f9646aa21af0d77e7b1cc9794e611b5d59a27773f744710b476fbd30f), y: uint256(0x2f8d492d76a22b6834f0b88e2d4096139a9d1593d56e65e710b2f344756b721e) }), - qAux: Honk.G1Point({ + qElliptic: Honk.G1Point({ x: uint256(0x056ab50282da428d93b17cbd1c81267dcebcfbabdedb47b2d715b5baa6520bff), y: uint256(0x10b4e7bd9d6d91a57b0695be166ffd27cbeee602bcb5a9ed32c8d9440912cb72) }), - qLookup: Honk.G1Point({ - x: uint256(0x19e2d786ebad24caf1bef735441e58525a2f9b5807b2102f295c58cde00f5c97), - y: uint256(0x085713ce7bac807a084a66904ebc6e695840e8cf405a6fd0c325f8bfcf7c2dd8) + qAux: Honk.G1Point({ + x: uint256(0x024236bda126650fb5228cf424a0878775499e69e8bd2c39af33bd5fa0b4079a), + y: uint256(0x233cda9292be02cfa2da9d0fc7b0eab0eb1a867b06854066589b967455259b32) }), qPoseidon2External: Honk.G1Point({ x: uint256(0x0ca0bc4b1cd9eadbbf49eae56a99a4502ef13d965226a634d0981555e4a4da56), @@ -67,60 +67,60 @@ library Add2HonkVerificationKey { y: uint256(0x205f76eebda12f565c98c775c4e4f3534b5dcc29e57eed899b1a1a880534dcb9) }), s1: Honk.G1Point({ - x: uint256(0x19a07402ffcc103c3d8fbfbc7e9a660147d7380e65c34f64b75701b8d4868c11), - y: uint256(0x0b7ab8c749a4af75d6100dba9246d7f993748b326d23791a595e21a17653fe30) + x: uint256(0x1ee42e6792a78e6d972f2a5837543b9b633d5171cfba5818490542c8c44bf697), + y: uint256(0x12b9d322a38926ecb0d5362e2dc0889f3f1b60f424afe68c1725dd33d61c70ca) }), s2: Honk.G1Point({ - x: uint256(0x027234cb39eacbf2ebe98907cf433e429a37933e429d4f24df14274b5c4d2549), - y: uint256(0x2c1ea0996e3fd6cfabcfc6bbd4c86c65fb19c3dda2ded5c4f973af397e8e5c8b) + x: uint256(0x09771d3d9a9fd4387a98a4731629007be9e3c4fd2f786dd8ead41aa976f8bd28), + y: uint256(0x1703a6752c3cbaaf55de7ecb71deef7b8ba5dcafe25c771dedc5a80c45b06121) }), s3: Honk.G1Point({ - x: uint256(0x243daee8a40861aba1ef660929ee9e874e52cd8e8d75f8c0245852369a731491), - y: uint256(0x0a20f23c0697fb0698478f7a861dde5e18bf5aa34f4731178e74f7460df49a88) + x: uint256(0x0774598ea3282c98b6dd0ff5ae61cf2384c1575181b593bb51e437b3b3ddb7a7), + y: uint256(0x174770561e38591c022e00530c2ae0fce5743b6259eba4dcba60cfaed46fd0d1) }), s4: Honk.G1Point({ - x: uint256(0x18b8202abb615440b5544d88092245911d2b5ff3b5a4a80bb15dbabafdfb56a7), - y: uint256(0x096a6685f36b1ca09a62820ae3be7538128093440fa943ea7412617a6d927916) + x: uint256(0x0bad8aee68642460b84b30e981f86a1a27734580dbe886ba851d85bab1303088), + y: uint256(0x268fc1bbe998d39d31ab3878f86731bd9c087ebf37d6a4cd3e0d2d42eff776cc) }), t1: Honk.G1Point({ - x: uint256(0x2e0cddbc5712d79b59cb3b41ebbcdd494997477ab161763e46601d95844837ef), - y: uint256(0x303126892f664d8d505964d14315ec426db4c64531d350750df62dbbc41a1bd9) + x: uint256(0x1bf7da4add7c858eb94b75f2e78fbd89c84f5fa43824a0d5534173872ee099c2), + y: uint256(0x1b35fa2a35673699ee1cb260d9e6c4be79b26d488c26dc2531194e43c8f747ea) }), t2: Honk.G1Point({ - x: uint256(0x00874a5ad262eecc6b565e0b08507476a6b2c6040c0c62bd59acfe3e3e125672), - y: uint256(0x127b2a745a1b74968c3edc18982b9bef082fb517183c9c6841c2b8ef2ca1df04) + x: uint256(0x16bf79791869cec464180d5322eeaaef18fed6dc10c3e64e314c04d85c3faece), + y: uint256(0x2e2ec6341669b5b975e25e465af5d9e40533d5ac173554df19daed27f66c36ff) }), t3: Honk.G1Point({ - x: uint256(0x15a18748490ff4c2b1871081954e86c9efd4f8c3d56e1eb23d789a8f710d5be6), - y: uint256(0x2097c84955059442a95df075833071a0011ef987dc016ab110eacd554a1d8bbf) + x: uint256(0x15d6c249e181b368efd3ef2737f00833c9cafbfdb055118b7c45f2f84defa7bd), + y: uint256(0x169d45dda72090b85c888b40fdd546bbc4db3002b9ec68d3384d08181e54bf10) }), t4: Honk.G1Point({ - x: uint256(0x2aecd48089890ea0798eb952c66824d38e9426ad3085b68b00a93c17897c2877), - y: uint256(0x1216bdb2f0d961bb8a7a23331d215078d8a9ce405ce559f441f2e71477ff3ddb) + x: uint256(0x159f2541ce446c6d59ea3f06be91ec9f47c9c82f3e4fd10696511efaff4121fa), + y: uint256(0x15f873b33ec9467e1f0c4fb3a0b59a6fcd6f3480515f1ff5506c48f0c521f00f) }), id1: Honk.G1Point({ - x: uint256(0x292298ecab24d2b6f6999cac29848def2665a62342170311f44c08708db0fe1f), - y: uint256(0x277022c35d3145de166b139aa94609551122915366ba42ff7c5157b748fb7f9d) + x: uint256(0x2e286f771211f7466ea24e64484140bd5bcdcc759e88c2f4b2cc2fda221fb9c9), + y: uint256(0x21b150b35832343dd3988a32e15c404915b0cebfb762e47ad0a7ce18004bac27) }), id2: Honk.G1Point({ - x: uint256(0x2ddc6a05ccd584bdfc65d642b39a3be3075e7a370602112dbf9fc644789acace), - y: uint256(0x1a4167481d5f295af9921741bd0e32dda7a78cb391132b31ab4a77559c297c2e) + x: uint256(0x19b6d9ab601b2cecdac9c552eb9ddc17378cac2854e27a5fd6230183d584f0c9), + y: uint256(0x2f5c61226e06143579dcc1869c6a8cc1b1c87ea091b80cf0c848d279ebc23de8) }), id3: Honk.G1Point({ - x: uint256(0x19629b85ab2acf9713223ff4f758882af6247963bbf2f6ec4f9cbcde13675b87), - y: uint256(0x165063fe922948bf1d065a882242724c1bde5fdfd93be29586b45e1ce2cc750c) + x: uint256(0x1aa22165b655889dcf4c6c693d3c840c87d342b1469f112e58204590497a5d42), + y: uint256(0x082a1045cdfd4f7abbf565f51f70aab100a0d6e196570ec997b5e1525a220a58) }), id4: Honk.G1Point({ - x: uint256(0x2493c99a3d068b03f8f2b8d28b57cea3ee22dd60456277b86c32a18982dcb185), - y: uint256(0x1ded39c4c8366469843cd63f09ecacf6c3731486320082c20ec71bbdc92196c1) + x: uint256(0x26c4f2e833efa6045d057de69f4492fdfa11a6876a134967799e6c8a0d41915f), + y: uint256(0x07e11b7f5b6d537b5838ba8c6ce291b99a9346e83d8a75f57827fd2317fd6c3c) }), lagrangeFirst: Honk.G1Point({ x: uint256(0x0000000000000000000000000000000000000000000000000000000000000001), y: uint256(0x0000000000000000000000000000000000000000000000000000000000000002) }), lagrangeLast: Honk.G1Point({ - x: uint256(0x140b0936c323fd2471155617b6af56ee40d90bea71fba7a412dd61fcf34e8ceb), - y: uint256(0x2b6c10790a5f6631c87d652e059df42b90071823185c5ff8e440fd3d73b6fefc) + x: uint256(0x2d855b5b9eda31247e5c717ce51db5b7b0f74ed8027eddb28bb72f061415e49e), + y: uint256(0x1e857d997cc8bd0b6558b670690358ad63520266c81078227f33651c341b7704) }) }); return vk; diff --git a/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol b/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol index 0eaeba194f11..cbfe91c8f6ad 100644 --- a/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol +++ b/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol @@ -14,49 +14,49 @@ library BlakeHonkVerificationKey { circuitSize: uint256(32768), logCircuitSize: uint256(15), publicInputsSize: uint256(4), + qm: Honk.G1Point({ + x: uint256(0x2fb9700846f0022bed3187c1cf0b174090b058b98047194adf282db291debad0), + y: uint256(0x21ba20033e1857a24868122f7e25328d7062800999361b19364b7c62c5ede0cf) + }), + qc: Honk.G1Point({ + x: uint256(0x043c36b4a5721692349176680a658590a9d577c297e5f3d794fec1c880e8f051), + y: uint256(0x195c49156dbed8ea9891aed6df5feed06ff1f08380677e82fb2f4408a72cf186) + }), ql: Honk.G1Point({ - x: uint256(0x2e5f133c25f7e05bd6660196c892121f7fa686cb9a8717a5deea6cd0881e618e), - y: uint256(0x1189bba9eeea96ba8935052434f4b0a60b0a481e3464dd81dfcd89e23def001b) + x: uint256(0x259ccc124bd4cf494d50c802a2df9671c3a500ccc3e83b72ead3806a7e740675), + y: uint256(0x0fa82481afabca16ee5f23d7ea094b00ebbc578a716fdaf782e05fd726faf007) }), qr: Honk.G1Point({ - x: uint256(0x2a93ffb34002da94f5b156ba5a212ac3616c848bd9c44c9821bbdd64cfd848af), - y: uint256(0x015699dcc0b28766d45f5ddce8258393e84c40619d26034e76f778460a1e4d89) + x: uint256(0x0b11c50746a883e4383982e35a1936e9586028f380a1ec4cf7599426774e1f99), + y: uint256(0x2f79b36de7832b7666fcfc7feaf2bdff224db852fdd3b97bee6092ca8fd22dc2) }), qo: Honk.G1Point({ - x: uint256(0x2057928e8c5eb539c32c3025007b7be1e1663c358f59540c6f949794c274f886), - y: uint256(0x12bf0b15c3aa92792330f58b04512714c4a902e537fe87cc438293e1805eaabf) + x: uint256(0x2968918f9de631c93d45d84b220efa2ff7bdd7486a29b6ec8ac579a48651f0b8), + y: uint256(0x1b28988dc794be7111a947861ed773d6145760d0b420657ddf930845b843c197) }), q4: Honk.G1Point({ - x: uint256(0x304f47a08d4687afa0e2502a9782c32c458bf873ef50c169b732a367e567aaf3), - y: uint256(0x0bb37044594e7de200408a4db6bc46adf7790b06f17dce6f38b7deed480aa9f0) - }), - qm: Honk.G1Point({ - x: uint256(0x0aea5b04332ad8781411f7edde21266857ffe11e93af334b14a2b948429afaa4), - y: uint256(0x2bd2e3884d486b387122effa12e8698daef82e9b99d7d25b7d5df91a9d738495) + x: uint256(0x1ce127e531187e01b1ce284179977224b8f76fb470da6c61bf1791509a40d8b8), + y: uint256(0x22bdfdaabf4d8863c4a989a3345c7c9519af302fa6a1f67e4810d6589c2b5d6d) }), - qc: Honk.G1Point({ - x: uint256(0x0e3b418ea1924b4514d5009cd983b5a8074fa95cd1fb200f019fdebe944e4225), - y: uint256(0x1e6ef5bde7a9727f1c1d07c91461ae1b40524650b35fdd92ac7a129f263b1beb) + qLookup: Honk.G1Point({ + x: uint256(0x0740cda472d3e453a2fcd60f35d723e695aacb21ba04f9084afc52604b3bcc04), + y: uint256(0x0fb95f729baccab8238b16fbec6681f1166ad5a551e9b7946999502303819c7f) }), qArith: Honk.G1Point({ - x: uint256(0x096841bfa8ec2295a5af5bf69ec539c31a05b221c84ed1d24c702e31ce1cbc95), - y: uint256(0x10b14cca7e9ff05fcf1e3084f4fc9ab098cf379864b2e2e2e0d33fc5df9d9a50) + x: uint256(0x2ec15ed0cae4827b6c15a424b3409faea5a3b1488234f9970c12fe64dcd09915), + y: uint256(0x2f78d2844b0fff0faafdd1cd110d85ac77b2f7266dcbadc0e8bc6505f4248292) }), qDeltaRange: Honk.G1Point({ - x: uint256(0x2d27fd1a30a0ab04a05144c27ac41187d5cf89a6022e47b263d1ccb93b3cbea5), - y: uint256(0x238eb233e9aebc81285a2647f2598bab00a4367da47b12c2b0476afc2d94ab1d) + x: uint256(0x257905e6e6a095881dbf7de8c3a7dcff8742f161bc6ca50871aba6543e480cb8), + y: uint256(0x0cac0d52c83175f49f71af8e8bd9d6f943cd3b451b6a6683df582a0e46db170c) }), qElliptic: Honk.G1Point({ - x: uint256(0x1c6fc8e14453adf64e6d9643ef9f1fb55e3a307ac1ec84f86cd736fc866e05ab), - y: uint256(0x1bf8619b1704b99ab8820ed94dd760da2945e8e1c771c0bdeadbe40aa5700cdd) + x: uint256(0x08e2c3e7dcc34da5d0170141b5ed9144c9d7de8976e0e2c81ad74e3b9451f76e), + y: uint256(0x223e14628c0bb1ecd61b88d322fff7c2c2a572c3b3e16fca14fed906a65482cd) }), qAux: Honk.G1Point({ - x: uint256(0x023fe0703623b99c93358348d76eb620f26ceafa58df018e3a8f1d599a61e76f), - y: uint256(0x2ceb9c4c4ca12ea769157ef10cde9644f9f0549805e48d5fd5d73a634d2cdcb5) - }), - qLookup: Honk.G1Point({ - x: uint256(0x1375bbfbf5ed31b38460f46a43ac14e2cda93a3bc5cfd6e8a93cca356694a346), - y: uint256(0x204c5173892c19a97a04b5f8419898063df5136489809ddb9f7eabb58d6858ab) + x: uint256(0x1a3a5eb5a02862dc132e23eac87a937d4f9b4d3736b3d1ce2bf2aec5b8761283), + y: uint256(0x0e608d3de6c0adf6dfba886c110a388fc2059abe6f660caf3f901bd3dbe4d97d) }), qPoseidon2External: Honk.G1Point({ x: uint256(0x1fa8529236d7eacdab8dcd8169af30d334be103357577353e9ef08dfda841785), @@ -67,60 +67,60 @@ library BlakeHonkVerificationKey { y: uint256(0x0335bb595984ad38686009bca08f5f420e3b4cf888fad5af4a99eca08190a315) }), s1: Honk.G1Point({ - x: uint256(0x26cec5ff3eb1b803c52fa1fefaac7a2be5cd13c1a1cc20bb9f22049c7f8597d2), - y: uint256(0x07e80e74eb0e06d7c0c9a3fbbdea4e86e5934faa8142625f175320778bcba65f) + x: uint256(0x0b8540a7d4b9f68af310a209e665b9b96bc7176a013a1fd3bfa3e51be892b6f3), + y: uint256(0x222be999ebb657c7008ae403155f35eae26c2bbdb45f53ddf845694e5b33c0ed) }), s2: Honk.G1Point({ - x: uint256(0x140b2faaf30cb5fc528621f4a395943e7fab8198dc734ac13253dd249682dd2a), - y: uint256(0x12709c4a13428f4704d284c90a81cc83280680185ae6298187e86debcd3e00f7) + x: uint256(0x16cbd9680fda4d75023e1cbbc595d4e1a7330f8ef066011a4106893cba22fe06), + y: uint256(0x241412468b2cdd90d753b3aef54bc693f743f74958b63bf8b9e13b1e73b2b2e0) }), s3: Honk.G1Point({ - x: uint256(0x0aca5621e9f49279969497b3da0eb8a74c68c3513f4cf98e8b1d6f88567557a8), - y: uint256(0x2664811311f75057a16267bc0479eaeea2424156417cc4d3f8bd286fac9aa5d2) + x: uint256(0x13974139784cdfb86fde8cbed23e008b3d1ea8d35ec365247ce1e7fb1ac580e9), + y: uint256(0x2e98dfa8b653f9c285a746c524df84c5dbf54b962c070ca46fa21c293db5c68a) }), s4: Honk.G1Point({ - x: uint256(0x04417c606a41393e73113ec3f834883dbeb302889199b888c0f5ea58a008ff98), - y: uint256(0x0865670de7962d29b6a9012f28ea52113c4e2b55d7de44e829edec87dba1d5c2) + x: uint256(0x25bdfe71582a214364307f91949e89d8b555b8a806d541c5541852565bef3395), + y: uint256(0x0c1614865cac1586e703758c2ecb801dcfbd83fcd77a760e209b60abad700c42) }), t1: Honk.G1Point({ - x: uint256(0x1ec1b607634e31421b5047dc99d7674d6505fed978df0f42a3504f9771a8a7fa), - y: uint256(0x1da802c6dc2fe6cffc6f9ae983080c66690ceee40c181b4d51fdba6c5c360297) + x: uint256(0x2fc548524cb26d07674add2e538f77e84292737995faf9db61da7110dbde4ff5), + y: uint256(0x02bf9cd9e57b46e1713a23e2430c597c2ec1f500fc61245cad1485fa5e0d411a) }), t2: Honk.G1Point({ - x: uint256(0x1e38a0a482b7174f429a3bef25fb0a7656abc88cfd215b8e8404132601620784), - y: uint256(0x2e9ea07a995fa6d589e37fba2715f3f1fa338652ddf84d4e2e4f33dccadb9156) + x: uint256(0x21846645bb6d3785e1b2497d57be8ae0b6fba047cd837960f234ab2f5b693b4b), + y: uint256(0x2576207b872d79ffaac0c25adc2cf13ce2a26df47324e2efcab94da0dd52589d) }), t3: Honk.G1Point({ - x: uint256(0x211a0833bb3c6f9ae6c94519b6878ed6157c4a080df786a053d9a19796b9a7f8), - y: uint256(0x1a3a450e1a272aa1fe9f097acf359502ff69df617de4918b37a497def94db2b5) + x: uint256(0x2d66c44ccb0b5e4fa3e99524315370f3496c3af3c3393c9633d15c0bb487b6b9), + y: uint256(0x2620591fc497ef8b319c5123a91fb60ff96c3f9c983ff2471d30f4ecc73a5a0d) }), t4: Honk.G1Point({ - x: uint256(0x281a984aef14716cd5d8fc2759eb8ea2464909b5c57d97b6bc50e4dad74d92d3), - y: uint256(0x169160e1505685aabd5bd60e994bac45162c6868235cc4252c8b87d0f12603fd) + x: uint256(0x0b9637a36be3c944d247e8d4d93b3b3ff5e637913415e08b5c7c7b0c5101caaf), + y: uint256(0x1bbdffbd59b3f1a41ec403bf740e96799428eeff9a6e0ede9b880dc2108c8223) }), id1: Honk.G1Point({ - x: uint256(0x01c082a85908fea4c69c4e51436fba7d965e1d88e485da16e35d8f4e8af3b8bd), - y: uint256(0x11b0ada021468b059aa6c27f4d4950ef65b98d4d8808ae21718bd8b90f9bb365) + x: uint256(0x07450ae8309488b3fd48f09411c02fe478f4dcb4f6525be47a7bd89668c2aeea), + y: uint256(0x08a082a8eed2aef053393dbb78942f41985be06527c5460f41ce25e2dfdd9ef5) }), id2: Honk.G1Point({ - x: uint256(0x0b8667619755bd09c7970defeae2c920df2b17b41608303ae1d7393615dd04e4), - y: uint256(0x1c5419cd435c5516ac566a9d1dfecdb4e10190c63f2dbd8a1932785caf022e2c) + x: uint256(0x05987220adaeb7884ff44c4a83b7ae2828bfb6cad038ac363e8d27275da440a7), + y: uint256(0x1d5c5cde2ea4bb94d69dae858461471e34363fc094812f82dc368e7ba48db44e) }), id3: Honk.G1Point({ - x: uint256(0x110aee72793c4b4ede92c1375f058b4170fcf01bf18f8f1ee934f7ae0fa26da5), - y: uint256(0x15c4f6a01ff04ef6b5225c896dfb7060a7a2c320395bda410e756d6b507b7eb8) + x: uint256(0x2fc0df7490d5e4bf85beb3b7b0ba23699d1cfe39a3de758fd565f3c0f788842c), + y: uint256(0x001926cb363c3121a03e5cd867ead2f8736e4597c395a47b43e793cbdec2eb4f) }), id4: Honk.G1Point({ - x: uint256(0x2472aba130e7ed2aefad128109415ec2bdeb56e81e3cbeacc93e00c95f203579), - y: uint256(0x0c867d0f8e2f9c861574383b89020980358d898497f80c198a6c17c2f4daf9a4) + x: uint256(0x2608c589e60f7b806917df85cb737165dc8cf408a220dc144db14f85e42ad396), + y: uint256(0x1090f6af2524f0395c3e7d268d62e80157e09f0d60aaa5529ec0d45054f638c4) }), lagrangeFirst: Honk.G1Point({ x: uint256(0x0000000000000000000000000000000000000000000000000000000000000001), y: uint256(0x0000000000000000000000000000000000000000000000000000000000000002) }), lagrangeLast: Honk.G1Point({ - x: uint256(0x13b825e996cc8d600f363dca4481a54d6dd3da85900cd9f0a61fa02600851998), - y: uint256(0x151cb86205f2dc38a5651840c1a4b4928f3f3c98f77c2abd08336562986dc404) + x: uint256(0x2c3e8add0e69c3bb940ffe92b6d3bdbbe0c8ac0c95866da586d857c73a0556ba), + y: uint256(0x22ed2a9c8e4ee1ecde6e7285f21cb4fe0a23131c9ee50f22e367f7c8cc2ac84a) }) }); return vk; diff --git a/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol b/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol index 26207d04184b..49eb04488169 100644 --- a/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol +++ b/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol @@ -14,113 +14,113 @@ library EcdsaHonkVerificationKey { circuitSize: uint256(65536), logCircuitSize: uint256(16), publicInputsSize: uint256(6), + qm: Honk.G1Point({ + x: uint256(0x0ed1228aa376d3ac181b2e0b572d243615cf473b20645ac5914b7c7b20f54a10), + y: uint256(0x0a01d55e860a4d3a661395f9d17e1c44b6058b6099539cb1a4302fcd13b35d68) + }), + qc: Honk.G1Point({ + x: uint256(0x106bff91418858c329df3d01f467bb55688ebc343ebb65acd1e9664be358e993), + y: uint256(0x2d9cd9783c6dd8df242c78ba10fc3d0b8a05fecc5865e94c96d12566eed74561) + }), ql: Honk.G1Point({ - x: uint256(0x051ccdb8069f35f4ef85ad098e95681736a7bed10a7bee1b76a506235dc0b579), - y: uint256(0x05e168c2e4f90231545f5b24c1a84c1419b8798e4235cc2036c9e101e462b71d) + x: uint256(0x092e1a5431e67f41abd28c9b103ef1fb90a93ff2474f2f5bd2550387fac4b6d6), + y: uint256(0x272df56e1a1740f88fe789b1e63112068687fdc95ef7612024d550202bcbe41f) }), qr: Honk.G1Point({ - x: uint256(0x2c99eed1f855cd5152942cc090aabf15308eb00ac549e965eb3e1950479cce58), - y: uint256(0x170bf8541390153bf5807bc022c9369f99d8bc1fd87922a0627b144fec0414e2) + x: uint256(0x00ddad5b6f421b4dc6bb73ac297c784419ef94900740fe5dc2c0bd4f26e511e0), + y: uint256(0x0b415d844a10a6892cf8eedc6c6ad624f1ee5ee17fd5f0729d46917fdcac847f) }), qo: Honk.G1Point({ - x: uint256(0x1594abb7debcf41e3296178eeec941dbb6242ba13f50f4549734657ee5ebb8b1), - y: uint256(0x262e1469c56c719bdc4eaab93cc95868eed9fea1fa9ded03b46f2c061a341d4f) + x: uint256(0x11af45b67ecda10a79c68507c0487b6e1a8a8b71a5911059619afee17e0a57ca), + y: uint256(0x2974fd4439c12128eb399ba3b0c7a74b1c86c1ac16abb755083dc6f62e00f459) }), q4: Honk.G1Point({ - x: uint256(0x16b49bbcd37e15ed89b2f6f5b97d021abe440ba7cbc69904484991fa7e6058a9), - y: uint256(0x197b14cb5d037642b27ed7cd79b9568e5853ad1e3508453c0ed1f30c1962fd52) - }), - qm: Honk.G1Point({ - x: uint256(0x175280d74e116a82ad6ccc34f640a5b3dda74b17372c9a0941d57749e37068a6), - y: uint256(0x0827b11a78b8a625ba940983effbcf7354aa0388bd472481c0a8a088653b9769) + x: uint256(0x0a4e034f2d3b73ae4eb6ff0db3fe8e7b0357e6dd375a3107d1e4d9eb5ceb1e5b), + y: uint256(0x1266512c0da5b14ede1f1d5b80ad9dfa43b3c71b2c0bb11c9c123c70eabc62ad) }), - qc: Honk.G1Point({ - x: uint256(0x2a262a7189292da31f3f4a7926c4d9fcae883188aafe9cf3ba2a623f0004a67a), - y: uint256(0x0d90b8808180521422b90889592111434dd5bbc0e5deb27419c1f5e6d0bf9883) + qLookup: Honk.G1Point({ + x: uint256(0x09d9383bcfd22e2259f1c2a9a5c0d2c8f999f8f1c5750fe571a2ca9f827f6274), + y: uint256(0x0376fe8d56d38514322cdd2e4c0fb0aa9ccb4281a748b45adb055ca4b51b16bb) }), qArith: Honk.G1Point({ - x: uint256(0x2026f95bb8f7b6ed57287e4833e2789cce8ec9a95b829e6a2abbf5d13d681d22), - y: uint256(0x19cea5af7d9b39a4ad86a0ab52f8a358f7f35236561a50cdf6f2860f0b3426a8) + x: uint256(0x11ff48b12a216298b2f8efe8dc2f269c1e9f62917ae7ac83c92ff6aea3a2d2fc), + y: uint256(0x2df51751329a326d1374b05e3326d25e145fb20804d78127bf42146799959cd5) }), qDeltaRange: Honk.G1Point({ - x: uint256(0x02d0f736b422d74d9aa2ef26deedb67fdd2e798aae001c4292dabd2c5df31249), - y: uint256(0x0ae6265d6dcc9da8d3b23f088c6fb062c9be10bfa79e9d0463d4a7785ea4a5f9) + x: uint256(0x2c9fffb3a9f0da1f3f8f732cb0873b437cc1dc97a5d9730d19c31df4a1c1f540), + y: uint256(0x1118a1349f966cd8bb7b9557c059c3b936a5b189e8d56f75fffc6511adac2a09) }), qElliptic: Honk.G1Point({ - x: uint256(0x0ffa449a9d6e6c6f3e302eb3f16ce9d3d3711b9102ecf0e303ff91f3f9eb25f5), - y: uint256(0x095ef997439bccdd1234b2431a520823bcfe3e77f50190e66e70e2c51e906193) + x: uint256(0x2d05352c103814f8855acfda27603975ae3dcdb9b08592d4c999769d84047e0c), + y: uint256(0x15c7b3939f3108548006275aa6c62b4cc3095add5e1e463f2a3ab57eff4b9b3c) }), qAux: Honk.G1Point({ - x: uint256(0x09023d45c436e756762d8b3527cfcb3f694cdbafd192ccae59210740bdf03ad3), - y: uint256(0x020c9b591603814f1815038e25d1bb3fb85261bf699abfc8921f48954f0bc2b0) - }), - qLookup: Honk.G1Point({ - x: uint256(0x08c0d34ca72136661975f3b1ad658bfda38661b9ff320b60e2974496e03fd62e), - y: uint256(0x236caf48f4c3a7ca207f5c0ec75f304657e49780015cf40ff9be37f8ba3c6624) + x: uint256(0x1055198df3ec55ad61ff8c8f824bfc3cf74e459f46dd1c1d2ace45890e9b80fb), + y: uint256(0x07725ad2b53ee322b94db4b28baefdbd7239bf4d9c2e9e0d9565bfda8954a380) }), qPoseidon2External: Honk.G1Point({ - x: uint256(0x09d58ddd055d3d65b4f36a347c18c11956b7d43c4f15434ded62bdf1224ff37d), - y: uint256(0x3002f0782d68214149ae47ee94771a6509709499ca06a8421eeeae97ea37e2a9) + x: uint256(0x2c1c2ccda8b91666f7bd30eb4a992c3e4c729adcf73e008348e8c97083d56242), + y: uint256(0x2b418829be00d02f2e01a1fbf110420b328a44416e889990f1e81b735023ff1d) }), qPoseidon2Internal: Honk.G1Point({ - x: uint256(0x1d11dbf6b2ced628ad64ea9d8afef60b6ea2e246160b6525915eb0ab7bdc94aa), - y: uint256(0x1ecef8438441a2565ee641757bdc6739da7389d913453eee0aaac561fb08495c) + x: uint256(0x1f60a709d42d5e2c7b406365072a764300c610a5a8d2be21f9a0242dde7bd485), + y: uint256(0x2c5af44525879b9580e7687e6a93dd55fd6aa9251d90a5c2c4fc0ea971e1448b) }), s1: Honk.G1Point({ - x: uint256(0x105eb99bfd557812572f2a5ec5b6eff27375b4ed5ce4e7a9649fe3038cfacbac), - y: uint256(0x1efd910252f319f9c0dc21c7688b92d80fd0a8636f152e0d9c8e0afb5c9a6d2e) + x: uint256(0x26b2ad965e92409ddc7dc6f05eb2516a3d46556ee0fe42d3be9284f43c164268), + y: uint256(0x16604235232876ec81dcf3009e2a5511ff7deab5c8d5fc1688a01f70641cfa19) }), s2: Honk.G1Point({ - x: uint256(0x2bbbf5e8a2f7feb08ee64585bf3da54db0da09b211f726adda93020a2ae23e56), - y: uint256(0x2a9e8e1c3850c66da60224163dc4846ea6f37ed48f9d6dfd40b450fa61081484) + x: uint256(0x302fea7a6ae8b64fe8e117cd9450d8365a2854b3ae7ddba866274e072a33e3c9), + y: uint256(0x199f7fbb7597bf2aad7560b458c1d82b12b8dc403d52a5feb5d51f1980756c09) }), s3: Honk.G1Point({ - x: uint256(0x0d264ba46f4a7bafd0ba9d9f9f4827109e1da2cfdb11835b9fc65aaafe9f9f20), - y: uint256(0x0f9ff6e122bcacd091ffd98d8caf249ab216e9c784e667475e2184ed34892272) + x: uint256(0x2488536441f1c8d33ff3fb367eb57512b610cae764a88e062ed0ec73fba9e307), + y: uint256(0x146de607134bad0e3c2bde26e9e98317b71aa7389a4f5c2d28747f2bd6d4dade) }), s4: Honk.G1Point({ - x: uint256(0x2556809f13dc85764a5e4ea8fda1bbba54f36dad477124915fc8c198db16f496), - y: uint256(0x27461805fb3a7ee919331973984491c36cc83eee61d3664d5319922902327750) + x: uint256(0x25f8a81f0344b1784b8c04d29afaddb2c9fb75de95d819a6a319a30aac40d841), + y: uint256(0x16e87a99f0c181fdfe028986561ded38c218a4f3e6a4d919d36c32e4d6ab60db) }), t1: Honk.G1Point({ - x: uint256(0x1ddc9ef86584375e5998d9f6fc16a4e646dc315ab86b477abc2f18a723dc24f6), - y: uint256(0x03a3b132ca6590c4ffdf35e1acd932da680a4247a55c88dd2284af78cb047906) + x: uint256(0x00132b961b9e8baa0e250bed996c62a966f1b079b7e9816126c5b86bf9f1f075), + y: uint256(0x05d50d691281482fc032b4308517fec893094a6dcee7c45aaabfaf3505ef454e) }), t2: Honk.G1Point({ - x: uint256(0x1e4cde3e410660193bacdf1db498ffb6bf1618c4d7b355415858d7d996e8bd03), - y: uint256(0x18d7f0300f961521ead0cb3c81a2a43a2dea0fdcb17bd772aef6c7b908be4273) + x: uint256(0x0bcb7a54ae4377b41e9423a7804138aad684255df2369ed797a9b565e0b9c0b3), + y: uint256(0x03c0febe0892c50980262ab672f1fdd1a0d33bc3149ca1f62176c7e4384bea10) }), t3: Honk.G1Point({ - x: uint256(0x0e77f28b07af551fea1ad81b304fd41013850e8b3539309c20bb2fa115289642), - y: uint256(0x15f92fde2f0d7a77c27daeb397336220ffc07b99f710980253e84f8ae94afd4d) + x: uint256(0x2ca522e0da49dc12acb6203b8e863f54c76358fe6906643197470c3d5c1d85fc), + y: uint256(0x042538987110445b116e4c25ff0e28a55df6898de39f7f8ffaa933353ed36e93) }), t4: Honk.G1Point({ - x: uint256(0x2285ea4116ca00b673b2daadf596052b6d9ba6d231a4bea8af5a3c0f28c44aa4), - y: uint256(0x076bf1e1f682badebfca083e25d808e8dae96372631c0721a7ee238c333a862a) + x: uint256(0x25b80f778ed684cfc28daf11bf3e9d06c0a83fcef2c5b30ae3a58db8672ead3f), + y: uint256(0x17cb62830be2fc016aaed9d86aaee46777aa337d7dc7e6dce3f7a4b13935ef50) }), id1: Honk.G1Point({ - x: uint256(0x0b034b231d25a2e152b830397a59c97e02175212a6c5ce00129625cfb2e5c53d), - y: uint256(0x22e1842515d4569ca06477f4b2685d0a767bfa1eecca343c889840af8c086db9) + x: uint256(0x03b8602a4ad473e33cf7b8bcbf117818f01e940b5bec035fe7c441a040ad828e), + y: uint256(0x20437c04120868065a9644e26bd3c53646ede89246acf9bdbd23e8a6c8dba624) }), id2: Honk.G1Point({ - x: uint256(0x0e82a73cd55280503e70d5bdd855071d202ff65f31a65996955a7661775ff290), - y: uint256(0x1325a665dfee8e1247f3129ca943e12736f800afc1a9dcfa0476050b8e3c87f8) + x: uint256(0x101f5775ed011ef78a262c29eb0ced5ae3ef009e3f2a5c0071cd5c56b8ebec4d), + y: uint256(0x1e148e8c7f4f7f7a3f6638132838497eaafed827da5bcd09719f5d96884f3f79) }), id3: Honk.G1Point({ - x: uint256(0x2ad12a1238e051fba16108022b5e58bba1fc7966fe759016a93fae5397e8c403), - y: uint256(0x257cfc281b0135bb8dfb0df6a7b69ca39835af544007eb61ace84ce7014c1fea) + x: uint256(0x2197860a1b2fc4ab23077177ce37cc48e13f2a63ef8088b34f9942a7d0af5427), + y: uint256(0x2ab09ab203f3afea533223c1b903fa583bede76688ec0fbaf0b7287500303528) }), id4: Honk.G1Point({ - x: uint256(0x058bf4de2f71f4d2e11235d140d05db461fb50d8aef64c8c52e2c0f57438dcce), - y: uint256(0x1e90ce7ec8cca2e65d7deafb655e6c7b0c4b964cd2cb1e5b4ef5ad78ab2f4b46) + x: uint256(0x278337c91d91a449c73c10793a10795296b2de9b3e056f6163dc2aff872a981a), + y: uint256(0x0a2a57f0c362c6953fd99229fa066e006084c4b53e2e3b1012b53a1b46e97e45) }), lagrangeFirst: Honk.G1Point({ x: uint256(0x0000000000000000000000000000000000000000000000000000000000000001), y: uint256(0x0000000000000000000000000000000000000000000000000000000000000002) }), lagrangeLast: Honk.G1Point({ - x: uint256(0x28bf8c9eeae6946902ee08351768a3e4f67d812e6465f55f16bf69fad16cf46d), - y: uint256(0x12dab1c326b33ea63ec6651324077c0ea2cb0ddfafd63fb8f9fbcc70bd53d7e0) + x: uint256(0x27949ee1c2c701a8ee2e8c253ae9e3a429f03da04547f6e17fd7d0d27ae07689), + y: uint256(0x08e6579e77d56473d9b459c4265b407d29913310d4f155fd19348efe52bdd1d2) }) }); return vk; diff --git a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol index 2c7d7767d0b2..2bb221084bc3 100644 --- a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a +// Verification Key Hash: 06369cb2b9f7607c9fc040d75deeee716a787f9600a91196da912a204d0fd981 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library Add2UltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a; + return 0x06369cb2b9f7607c9fc040d75deeee716a787f9600a91196da912a204d0fd981; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -26,14 +26,14 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x1a0), 0x2e4e3e272c7b78ad894559812d7766e05615a8f7050a43d7ed1367adf30a9319) // vk.Q_M.y mstore(add(_vk, 0x1c0), 0x1798c37010a4285e1774c1ad35779886380ee5ceee0ba183927e2a2103301a68) // vk.Q_C.x mstore(add(_vk, 0x1e0), 0x2935f9e4d47a8e39aa0107f31a84584b47d903cfeb9690f6d850dc8ea7d2f4ea) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x205aff7186f2cedc99e9cadb7930ef25f296991e5a7b574a33d6249f0a5db1f9) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x0beadc757bee3a2be1f6425385547099fc1eeeb1fed5a8552b07e997251d7c45) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x2cbce7beee3076b78dace04943d69d0d9e28aa6d00e046852781a5f20816645c) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x2bc27ec2e1612ea284b08bcc55b6f2fd915d11bfedbdc0e59de09e5b28952080) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_AUX.y + mstore(add(_vk, 0x200), 0x098b323500f8c381b835917c5c1d37ed97bb714cfcd6d1c0c104542258027a43) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x204b44959b11e5893ed6100e102ee04d63a72bdd4c94490e01ecbbe72e32d853) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.Q_AUX.y mstore(add(_vk, 0x300), 0x01d8b8ff3b1674e57a7d30ce1d9e07c686174c643eb20d38e604eec7095248a9) // vk.SIGMA1.x mstore(add(_vk, 0x320), 0x261015d69327a58810e6eb1052ed694914b7a89034e1334c50b9e70a161489b7) // vk.SIGMA1.y mstore(add(_vk, 0x340), 0x1987df111730a8a6a650423757dbf048f3f43860a7d24a5e2e8bd67b6931ca67) // vk.SIGMA2.x @@ -50,8 +50,8 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x4a0), 0x0a5366266dd7b71a10b356030226a2de0cbf2edc8f085b16d73652b15eced8f5) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x136097d79e1b0ae373255e8760c49900a7588ec4d6809c90bb451005a3de3077) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x13dd7515ccac4095302d204f06f0bff2595d77bdf72e4acdb0b0b43969860d98) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x500), 0x0c40380c5013361cb7e57ed4591553791df4838037064da2b24cd3a7bd20b40e) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x0d86cca6e33b9d896c3ec46116eb0d80a5c849d10995938a71e4703090bc65f9) // vk.TABLE_TYPE.y mstore(add(_vk, 0x540), 0x1e44194e60f0ab4ee0f77adc50f4220944f94301aa6da3016a226de04de52f4c) // vk.ID1.x mstore(add(_vk, 0x560), 0x2a017d0d9f40d0aeb5c8152ffddec56c2c7bea37dfbd20be6bed19efd743397a) // vk.ID1.y mstore(add(_vk, 0x580), 0x0868357b28039385c5a5058b6d358ebb29f26f9890d6cc6401f4921d5884edca) // vk.ID2.x diff --git a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol index e5d1970c0e3a..cc6cfa51ce67 100644 --- a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3 +// Verification Key Hash: b632c420983f1811242cb44c30f8e6fb663c25f78a353865ed68f6e89d929ad7 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library BlakeUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3; + return 0xb632c420983f1811242cb44c30f8e6fb663c25f78a353865ed68f6e89d929ad7; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,34 +14,34 @@ library BlakeUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000004) // vk.num_inputs mstore(add(_vk, 0x40), 0x2d1ba66f5941dc91017171fa69ec2bd0022a2a2d4115a009a93458fd4e26ecfb) // vk.work_root mstore(add(_vk, 0x60), 0x3063edaa444bddc677fcd515f614555a777997e0a9287d1e62bf6dd004d82001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x260b63c5c404eba05c531b64a63c4f8752eb48b02d8d53910bbc22e7648b672b) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x0a84e4198292ba82e9ec6e130ebf86ff8513b8133501e8b7c625c322451cc17a) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x066bf08a2edd0ed02a5b2b4c72f512585b1816d943d06f4822219d37d28b88f7) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x18e0525744e594592f2ba6832df668c1424c920ebf1e2ec358558075df1fc906) // vk.Q2.y - mstore(add(_vk, 0x100), 0x25880f31af07e4d48de7be715bc3b63495b1ce16c3ce6233ad5ba832cf3330a5) // vk.Q3.x - mstore(add(_vk, 0x120), 0x190ab6675593f90dc404518e02369c97f0d736010033237073dfc5611cb4e0cc) // vk.Q3.y - mstore(add(_vk, 0x140), 0x1afd5ebe896054ba2812a94f5903a17aa5de0ffc7f1915259b4d9e01a24ceb44) // vk.Q4.x - mstore(add(_vk, 0x160), 0x03b445d3e75bd9ecf05703d2301157ccb3795adf7ddb3c0d03cbcc691772288e) // vk.Q4.y - mstore(add(_vk, 0x180), 0x00f612887aad4e61796d7948533fff40184bd1d00ba52e9201fea5b9b5a8258a) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x25bd9c5fec68e480ccf127be8b4bf7810c737a38f4d6a4379b3817d4d157a3f5) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x27e6361916a9c2a4f81501df8f6588c394f7ba0010e565fe9162e1456acb64fe) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x232d6f8f7582fc930a95c1d97e1cbe471935642ef95ac1457f953b92601a7f36) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x1344134626051322a90942b7cbd3a98227e7e192c8597604dea27f5eb49a1332) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x2c4782c37eb3e19589fc42e465f89cb3dd47ddcfce1a3a5f7e0e6423e9290f53) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x2ea84c6aebfa0d7b78e6f8344086d9a4ceabf599cdc3c8b8efaf937f78fa89f8) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x00fc4dc0688832477ed1b999b886307775590a5155ccfbe5e4a686cab3684fd9) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x21959276775cd4749236c8bf773a9b2403cecb45fbf70e6439f73d75442e8850) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x017714509f01d1a9ee7ebaf4d50745e33a14150b4fe9850a27e44de56d88cb14) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x16a04bedbbced0858d1cb768d5dee65d7a9e5eda5840f041a6b0c2d9a05a47e9) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x0f295c2f65406bd8aa6844f7a8c797da1ec69b048441e5926a0d11e515056af4) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x219f3919df06c1843bdcf405c9c6304c9affb6b5b075e25d9213cb9ca4177ad8) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x2a5acc53d574ddef7c44bc0d578d9371cecc89ab42a4b0bc6017eaecc68ebeb0) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x270efbcff761d452b5a3024f5a1b13b2108bfd126610f7c6580acfc8a3eadc43) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x052330edc9afc72fdaa4d7c5df4617631634c46a7132ece7ec56286647f66a77) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x1a07bea503dbfd8375d3cd35b79187516326c0a96af71418b8004e863d2126d7) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x1601a5ddea012bc53cf9633d99e704caa30b017e3e81e935a8d791030be559c3) // vk.SIGMA4.y + mstore(add(_vk, 0x80), 0x22703f0804e127ca3a084222bea6ea437cfbb6f2bef6581817eeb6be4b83a6bf) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x2854b842cd7bf05afeb768c5f8e95b7b51fc42334c2e370f94b7e06b0e8a6faa) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x1632a45613f6dd7155fe6056d33bcc96bb62840af313a1af5d0790c25fd64de0) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x09f2d38f64d24454fb39f47f44d17bd2b6d8a261fc7a8d3eea7148e420431db2) // vk.Q2.y + mstore(add(_vk, 0x100), 0x04a64347e55659ca18291c2340c55969817a0ab48511bba8c49393dc242e4057) // vk.Q3.x + mstore(add(_vk, 0x120), 0x175f4cd4cc9846d4bc902a4a44e156e1731c8899bcb64fece3c69f1ed5b3732f) // vk.Q3.y + mstore(add(_vk, 0x140), 0x1445e7776943b45e9fade0e56f63665277911d10748b7d5aec6e51730d49b6ed) // vk.Q4.x + mstore(add(_vk, 0x160), 0x21470dba7fa9b659baf7691e03a896767ea29659154ccf758ff92727412a126c) // vk.Q4.y + mstore(add(_vk, 0x180), 0x2d3306f68ef5e9f6d9867117a2eba1c5bcb15692edc5481b53dfe752e421dc0c) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x00a9d1b18ef9ef8e14063047fcdca03baf0c09c2ab292ec2fe8f6d56300958c6) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x0ec6a488608586384ffc6ee074116ba87bb32bfca3dd6db592c559bc8369a0ec) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x2fc3d28b016ff05ef3251dee6df4ddbf2b98bff9b498c05cbae7501f21fa3528) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x181f212f403b221c0805d11a8998bbf41ef81409ee3a019ae7775f39d692cee2) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x18bb52801779b80fbdb803cbb416bdfb20a286f62e43006c5f4bb430c0e0bbc2) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x00a76d339bdc6e030de531fc51322f06e35e0db2c71d02705cbc87497c1dcc86) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x12435124c05dc87a5aa6a57b7c213c0a3653f8cfe92a568a50d1e580ae73936d) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x254c7c79f29e6f05184889d52a7c01375832d53ea8dd60b93162a5805d715657) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x23558713233600d8847c983db3c2771210aad83fc39e33f4821c4b483fe579c1) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x28614b03e80d285e00deac31455ad2859a33627f4c150583f48a35cc890d1f8f) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x1864deb43e02b113184078e981dd524a4bac2267b46898d3204d074db7854879) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x1cb221e63e0cce3882bcc1bcf59378a8761dcf9c60dddbfb9916462b0c472fbc) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x0b6468629d32faf01306b8c70cb9658540afe95cacb2b74e7c7e6ff02de6aedd) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x035ba693d1e275dfc9508002e255623c03824f3da3b7d167889c4bed952f6d8f) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x10371645f3f56ad1d3aa29f3bd8ecd9c57132e898f731d65558430cea98aa12b) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x00edfa2e2de551d0b473d6171756f3ea741cad84eb1492fb7a185d70dd0a7221) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x2a41f9db2b8bc905df6a26e1f47f6d4b14a9739ab3d0fa35be5953af70c633b3) // vk.SIGMA4.y mstore(add(_vk, 0x400), 0x06c5d3c2a64587cf9dc278c6892854fc8f1aba4183115224cb2eda4c1aab64b8) // vk.TABLE1.x mstore(add(_vk, 0x420), 0x132622df9222e04fa9c4cf2895212a49556038d4fdc6d0d7a15b1067bb446efa) // vk.TABLE1.y mstore(add(_vk, 0x440), 0x2dbc1ac72b2f0c530b3bdbef307395e6059f82ce9f3beea34ff6c3a04ca112bc) // vk.TABLE2.x @@ -50,16 +50,16 @@ library BlakeUltraVerificationKey { mstore(add(_vk, 0x4a0), 0x1bb16a4d3b60d47e572e02fac8bf861df5ba5f96942054e0896c7d4d602dc5c7) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x1f5976fc145f0524228ca90c221a21228ff9be92d487b56890a39c3bc0d22bf2) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x0f43d83a0d9eb36476e05c8d1280df98ec46ce93ae238597a687a4937ebec6cc) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x239c09880dcbafee7caf9fb8460d1ca62e86b42b8724e350f01a12ddd4f08add) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x14dd9f4bba78075eb5bdb7d401281b01d9e88f8827fab15f6b718bfed5b6a598) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x0059fbc7f6f474f8a602db54e7aeb9b7072081bfb31d4831562003e8c5804177) // vk.ID1.x - mstore(add(_vk, 0x560), 0x01e2a561adf9c7843fd4e9acab18137656dbef06f22c9d2f05a68eae8576bd6b) // vk.ID1.y - mstore(add(_vk, 0x580), 0x205ed43983566317600b8324e02262240b23d6caa751e53360fe9410deb876b3) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x29ca9b6ba6da40ef21d62321d81594b449185bde9f071a3619731444a3cc30a2) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x0e633257c8c686bbe65fbf5792b8c944747838fd385d3b02eb7900dad50f6f4c) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x1bfda6b7d38472e9418a8eb55f4c1d372642b5819fde074d4fe62c29f843b566) // vk.ID3.y - mstore(add(_vk, 0x600), 0x1dab0d03d72afa6328933a39b05c764bc713f67606fa016ebf532deb2b4bc105) // vk.ID4.x - mstore(add(_vk, 0x620), 0x24bef3bbfed9cfcedabed6d61d289ae44ce360aa38fd022886fd22bc75fd5980) // vk.ID4.y + mstore(add(_vk, 0x500), 0x24ff9219ef37bf7b09f7159eecd91a04575de2f08ed1a4e5f12de29f88c09ca6) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x1c106354cc55938c81bb295784363c019517952fb7f4a6faaeca2910a687162b) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x266915a4cb91120dc75382cd9b3af13c67ce63227f7d6ea4ad04d903fb2434c5) // vk.ID1.x + mstore(add(_vk, 0x560), 0x053b66a3b7f8ea2ae35e2f4cf2ac23b9b6c434f9d9617628a334e5c18f11b8dd) // vk.ID1.y + mstore(add(_vk, 0x580), 0x0b07f09aee58678c763bb446191e58bd072ed87bb5bcdd6da0f76546b40a85fc) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x08e5120d71bedb26ebcd213d34d8c5875d27c10b52cc953b352cfe1a335e76e2) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x2f596b35c5f6b84a87aaa9c55b8024eb568c6b781684354dc01dfc8fc796ddde) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x1cf6cc14989803314cac6a750a7abfa08a866a849c2c93ecaffdf17a39c7018a) // vk.ID3.y + mstore(add(_vk, 0x600), 0x1e2b1d906c54b8522800ce716458f499958b648b5c7272a1af0acf52eb2551a4) // vk.ID4.x + mstore(add(_vk, 0x620), 0x268cb932de375fcdf382490bbbe55519e68d78c23a426673f7c56e8ea97fd6a3) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol index 7f65f07afa57..5cc4fee1d8a0 100644 --- a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105 +// Verification Key Hash: 47c4d766a5ca40358461d3f1848edc7cac6b144856961ad4b72be7dae0c22c21 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library EcdsaUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105; + return 0x47c4d766a5ca40358461d3f1848edc7cac6b144856961ad4b72be7dae0c22c21; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,34 +14,34 @@ library EcdsaUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000006) // vk.num_inputs mstore(add(_vk, 0x40), 0x00eeb2cb5981ed45649abebde081dcff16c8601de4347e7dd1628ba2daac43b7) // vk.work_root mstore(add(_vk, 0x60), 0x30641e0e92bebef818268d663bcad6dbcfd6c0149170f6d7d350b1b1fa6c1001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x1cc85a07fb1009e23540957b29121dc57aaae5b1e89a22a932a1bdf7ccac1af2) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x19a1a4fa6d8781abbcb696097c1817f54da296348a292954e2aa9856f2fa3b6a) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x0409f05fe2901e7e339b3aaf0d7af7b5d4023e416da923321b15aae633b18fee) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x0ae6cc44e9024c190ab310d7ad110226c5c76f15d158b60fc9acd98f2e1f1aa3) // vk.Q2.y - mstore(add(_vk, 0x100), 0x20e3b4e35df25ba02ac2a9be26bc6fe74640355e57455598e69922b8d3fd0939) // vk.Q3.x - mstore(add(_vk, 0x120), 0x1f49d18bdb86a449e676558c6d6349f123372641187e33e12128ee7468431942) // vk.Q3.y - mstore(add(_vk, 0x140), 0x00e95627d4db555ccf3b1ee6def34fab1a815f0482cb6a745a363940d3163831) // vk.Q4.x - mstore(add(_vk, 0x160), 0x19fe011a8a139da323b5ce5abebe54bf4c105acd6045d7b2b5df40a34411f44b) // vk.Q4.y - mstore(add(_vk, 0x180), 0x04b41648960da31317eff66b5ca9be0a6c81ebeead27e70b3c5b28d4aba11081) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x1bff2df21a3fd9c49c29b7f7c153dd0bc331d75afc6a35fb7155c17bb0f67a63) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x15faa2ea86a6a66cd9b969d6305f863595a73b9215c1ae442969f4993a8e5230) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x26391cc92544b485d90313d3396b53d9207db8f84ead11bcf45467fa7eb38b94) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x01a0d650b65d29965e4ae2a8cfb69470d7560f0826268da59c6e72e684a06c9b) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x2248d4a02e68036c8d0a4a6725ba0e5e8e95950a5285a3a7daa1a1726cc8ec6b) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x01afcbad715a0c382971311ad6fe4ff8b6e99200162aeb6245b585c99c8748a9) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x18bf352081d1ba2ffe8088d34ce6471e4cf6d2ee63f006ea9a5e31cc41b6587c) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x21245d6c0a4d2ff12b21a825f39f30e8f8cf9b259448d111183e975828539576) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x16a409532c8a1693536e93b6ce9920bfc2e6796e8dfe404675a0cdf6ee77ee7a) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x2d455f287e41544fd3744bab412640fd6916b01aa2163c84071eb47f0306a473) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x09dea8e2b5e382a1c4a37bc4e60f5e8380688310b855c249d64153478d25e223) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x09671927e293b22a3fb9fa8ea1680fcc4570bb2f312cb88004ff7fd4474e2109) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x1c6442d9a49b3b93a928ef6ba2f348bc4c8cb778a59345faf7d173129f22b5a3) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x0337d84b45a5abc701edbdc1a1d878178c23496b39ccddcc3f0f6199e3f97df6) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x1c744f7be93d40c96d15fdf9d81c9502b7018573ad23e51dea7b065fdeb6f13a) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x23a975cfb71f0c0d46ef9c0b01e6482e780b5e3af1a63547f7d01c46c1911699) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x0d5a0be212cb2c7d3bba8c2406a9d2c4b04d4e64b0acef2681eb7c6aa490a7cb) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x1ca2d0cca80bb16eab28d06c5c175e862a8ef14bceb6da79e65236a8a6a36838) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x0555fe3dbd2ba2d7db2b5f740bf32fb57f4c5ac9d9f2e59e9a5a2cc2d84dae05) // vk.SIGMA4.y + mstore(add(_vk, 0x80), 0x0d03a55e1c08f638bec6b3b6726ec4e8b4a2445fb898001c5cc59d90747265e1) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x28f5aaa22aae66726d58d5e1dd57733badd7577f842cafbef590b563688d3057) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x01ad27a5f461c70403ce6f694c448da777487d43b58a0e4e6cd1cad813ad90f4) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x0e02f03282ea9e987e16152483daba0d48545880bd3f0d171264f16c3de01de1) // vk.Q2.y + mstore(add(_vk, 0x100), 0x2331cfe626ebde7cd5c53d392b3cefe49b0763d3ad40e4c83a028a78ae2bfdf3) // vk.Q3.x + mstore(add(_vk, 0x120), 0x1f9bc26b884c0d494656412ea9c95a4d32955f3cb19e47db0c2143b231e97860) // vk.Q3.y + mstore(add(_vk, 0x140), 0x2839198a3ce970ca0a0fafe33d2ca8ffe50d70be7e613eb710c08ca95115998e) // vk.Q4.x + mstore(add(_vk, 0x160), 0x0da0e1c3eb107528a589868e34ae65114de290ddd45ff23fc5f637c0da23c1a2) // vk.Q4.y + mstore(add(_vk, 0x180), 0x29e22617fc67ce5065539da1ba4e8a733e8e42738f2b579b07fcdacbc4ea541c) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x280fb591b4cc7695bf75168a0327aa70aa82fdadc1b00ebc0ed8ca1deb45e093) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x2ae855c250cd7b84e59b16bd038785b3c0a474ce4e80cbc59b33846c2f7445d9) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x013ec37a92162385e03976dfbf07bd494be99740f6e598d79cd771e821a8fd60) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x13db96945a09894dddfa79d2b9f9e9e1eb6204065f662a17d7dbf6d257590d33) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x00d9af8f917935b1836f17dcdf1d44a1fa4e3655777f8ddca39905b38b80ab48) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x1a66842ed11152b8ccd1ffe548414be7dadbb956ae828c47cb32c449fb9a2a21) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x0b4304dfa9379f11f9387befd9522dde481e04d359a511e543b9c9fcfd4c8e70) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x2f213c7a4c064a63d6a07366df0ea85aef9ad2125a188c3e656f95471e416a0a) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x067a270bed55e72ffb3cfa39af3e5b8bcb4961d72bb301978af13c4ddc73e5df) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x27b10524a99f00d9c59cc15ff3b7dfc34975b6f18e06b9c6c3a6136bf3b56f32) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x071a9bf80d112c32482178ff02f855436cf6fb4b4376ef7e2f03381c2e6da379) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x23904a6dcee70f3275bc323178df29575a8042333388123d808922a4ac14d66c) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x18b9c021b795ee06660c1a4fee630dc0e6aa605408c2662e0f5d54648f7ebb3c) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x2b222d8ae83eaec10db010cfec35d326df64053dcb4a1ecde1fbdeb2b312912d) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x2e1e70c7600abea70257dbd6f05838bcb881646e06f3df5acb105b7a1a509c26) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x1b324b63bf3864aab4d796e5095563f7e4ef6af0e8499cb91f1da90be847a7d7) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x16e5682a54699b4a3ee4255aa372cc3b5262300b3684dba139cb98bb01ac9faa) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x1e6167376510d37e4d267058578f15e79141c4ee5aa38f479ab58f469e82a608) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x16e147005ca23abea5055000d5505f4813e28c303e3656b66cf7a4cd647c98fd) // vk.SIGMA4.y mstore(add(_vk, 0x400), 0x18f7cf965339d9c9d190296fa92f915767b0a8da455975f3e03fa98439fd7110) // vk.TABLE1.x mstore(add(_vk, 0x420), 0x0eecc02f9d44125407adbf00d56b086afd1adc5de536450afe05de382761b32f) // vk.TABLE1.y mstore(add(_vk, 0x440), 0x0bdfe662ea9f40f125ca5f7e99a8c6ba09b87ba8313864316745df862946c5c4) // vk.TABLE2.x @@ -50,16 +50,16 @@ library EcdsaUltraVerificationKey { mstore(add(_vk, 0x4a0), 0x1fda66dfb58273345f2471dff55c51b6856241460272e64b4cc67cde65231e89) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x024ccc0fcff3b515cdc97dde2fae5c516bf3c97207891801707142af02538a83) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x27827250d02b7b67d084bfc52b26c722f33f75ae5098c109573bfe92b782e559) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x22b1d6b9827d6d03049f76dc9dc219ae6de93abe52d4d7de8677d961d3408c77) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x10ebc6be9f74e0367276028c613ab3efe0f2ed546c05339b36d5165d009c833a) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x2aa2e5247ce6524fecba0a2de9f383353096665f3ae8082fe7017fbf6d6572d8) // vk.ID1.x - mstore(add(_vk, 0x560), 0x1db802f61a6194bea68f7d5ec697facf26f1c1336b09e382801e8b773f0e116f) // vk.ID1.y - mstore(add(_vk, 0x580), 0x1aa955e508f3c2fbf55a36719eb666a45239935c4af10b8a1f4580d5cd614236) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x2bc21aa51420951a10a39d5c5242101d2207c47a0077852acb7d3fd6a16e1c58) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x245c89c4cf7c7e297b4db8e2625f5abd56398c351256a39aece0a36a940aaf62) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x01bd6e61d801d895c7edfee071518761f3c8c0e10bec5f0fb0b25ae430a2c91e) // vk.ID3.y - mstore(add(_vk, 0x600), 0x30223d4653291c03019e96bd716769c7c6d6520fddf2e633a75f94b08bee86dd) // vk.ID4.x - mstore(add(_vk, 0x620), 0x2e389428afa291855039f1b4af22e70d469f4e20116b85889737d624a2d27fef) // vk.ID4.y + mstore(add(_vk, 0x500), 0x15985385d1aa90674122e82725090452dfa93457b5dde13c8b33efef98fff114) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x2c2899d602af17f7248199a7654118b9d17f7927ea4b3ba57bdb9ac4fb2c160f) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x21efa829ce91cdd4263a3ff0853f05818eab4ad41c9b0e997003fe894f449e32) // vk.ID1.x + mstore(add(_vk, 0x560), 0x0c047b4340c66fc18ecaebb454059bb5fffbac7c9f1fe1e5335bd17b6de47bd6) // vk.ID1.y + mstore(add(_vk, 0x580), 0x08bed3e3394706c35d7a63be542bba01b2b7887dd862206b354141e882981745) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x1b74c9bd464f4540853ca869206f47d44aa2ba3bd68dafcc82765c0bd0933420) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x22ef220782674f44cdb2604dd3eaecfd36c729c463a4c92204a620d07e1416b9) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x087e275bd5d63aba524e0e8b43915a91d2496df9b1bf961d4dde6ae7d4e222d2) // vk.ID3.y + mstore(add(_vk, 0x600), 0x27a4c598d505372d7c03681cf5720438e17e6ffab22d0a85f480f5ceb7e50926) // vk.ID4.x + mstore(add(_vk, 0x620), 0x2cc881edb02565957ea2797c16ae8e2a77eaef5e9d9a98e55a12e9349d158f2c) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol index 45d50fe15dd2..adf2df91d589 100644 --- a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: a52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9 +// Verification Key Hash: ddb343afc65263c7c9009910e035f96f50b0827580c10fd882bce1f58e633e62 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library RecursiveUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0xa52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9; + return 0xddb343afc65263c7c9009910e035f96f50b0827580c10fd882bce1f58e633e62; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,34 +14,34 @@ library RecursiveUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000010) // vk.num_inputs mstore(add(_vk, 0x40), 0x2260e724844bca5251829353968e4915305258418357473a5c1d597f613f6cbd) // vk.work_root mstore(add(_vk, 0x60), 0x3064486657634403844b0eac78ca882cfd284341fcb0615a15cfcd17b14d8201) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x05104b486160545badec11f151e7c70b87050871da5653387ab4ab2ad0eef5ca) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x2672c7fb298fce83f510eb6e1b851a5bb2daf8fc43c7771e96c56c8a09ddfeae) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x2c019acf99c5663da83cec224bd32570ee90f45c4486a54dec3ca4552d8ab07a) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x0fb7a3385ab42cafb0e104ac17ac2dacfb161d292c00fca102b1e780e86ccaf3) // vk.Q2.y - mstore(add(_vk, 0x100), 0x273ca9c29ef10864f4c9c053c336776a71ca5ebbf4bec1cb381e431943f9b5d7) // vk.Q3.x - mstore(add(_vk, 0x120), 0x2a94f00fe384ab945a8f5e3c97194a425a4d2109e5b113f059e42ee232659436) // vk.Q3.y - mstore(add(_vk, 0x140), 0x0e8b5c127c8a3ec285c2ac80d9046528051387878802203988a60650a0a960ab) // vk.Q4.x - mstore(add(_vk, 0x160), 0x17efdb659ae0d26aa78db132f9be9130460c0fce0c2a8e9b726de68247f76891) // vk.Q4.y - mstore(add(_vk, 0x180), 0x2f668d8a50bdb5c366e39433892f903262a04b6473ba3468c12057d58ad3bbfb) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x2397c6171bc6d084e98297690441c9da9f011d18b3ea0bb58ee4d47227feb6b4) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x1dafbfb4d30fcf880ef839ecc7fda9a97c315c5fa1713d08f7cdf6dba53ffb17) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x099fa3de9ce0cc28085739745582b53bf7939e3d97928afd491392053c1c0a68) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x028912be5d0accd4edf4949f89be1c1a2fcf4f59559ba03114da00ec3bf643ac) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x2428952bfba8ba44830fb0ae6fcdeb9bf17d611add9432450ebbe3d928e2f431) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x2b40c900824bcca193d402e0ef7f78792deaccd99743a78e5330abe8886ac989) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x102a7a02bc1a7317702c09560636e991b856f26f88ee8f0b33da3dd7fe222dbb) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x2bcf00433471db2be265df28ba2e70c36ca52f2932a4de25c0d60868703a0726) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x2f225b86590c67ae48360cb41d5b291ba94ce2dbae850afd9a6854122341b5ba) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x2eaee34d8508092cc4e19bc3f27ffa7dfc72230710e220f228f48906fae21e56) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x0c503c5d6245b99bbc056925e96abd20feaed6507707311092b3ed87eadb3874) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x021ba851cec3aedfbf1d9944907ae721f0d3e8fa3548513b6f108d101067ae85) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x24eef378da346c4f9eededc5dc519d35b14fec46412c8fcf7564cafb9843d761) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x0492b2fed8a158177dd3e825fb34ca7481bfead06bc01f308dc81fcd852ef3bc) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x289bf1bcc6a9cb19b102c7fb9dba839e1817a24257194cad404b393ce77e66b5) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x05d2a9c66d5c142b254b4f7d09f0eb837d95d8ec002e0644f51d455041403ca5) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x2434b76f470965c85363ff15b3f37c7b4be4fb2741451dc33943879f1e4cbba4) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x2f4bcc93500665a87a8f959e1636fe88cb1f17688b8c286fe930ccf934a49ac2) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x243f7b4ae1d483c99523b6a2999f404ab744017c8f43080c3582c38ea8ea3d1a) // vk.SIGMA4.y + mstore(add(_vk, 0x80), 0x272fae13335cda7794aeee75c0d41e52cc626b07106135805edc8538ab41f6e8) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x266e1501fe1a3d602bbfb1bd408ac9b329686552d0578d8fa1a7d37444632eed) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x022635cac72d16d7a0175bea90ffd678d3d3681f97e64ccc9f399ac8a5da390f) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x1abe686aad406be6d8c4326713c4f134d8db7d8c1c57aaba22f593e132996636) // vk.Q2.y + mstore(add(_vk, 0x100), 0x0ec435019f6a618bb2db375a5d1b9f2d0981df21b996bc488897e9bff237fdac) // vk.Q3.x + mstore(add(_vk, 0x120), 0x1059e50efe134dff75de467d46b0b2363e2cc8a5b9f48aa758f5c895cf1e9685) // vk.Q3.y + mstore(add(_vk, 0x140), 0x1b5ece1f2b6578612eca0fbc1f45742c440ee5246070152406d8ab66d2fe82c2) // vk.Q4.x + mstore(add(_vk, 0x160), 0x25669e07536131b086ce8a414333b5ab214fea376e52fca87ed9ac7c4d26cbbc) // vk.Q4.y + mstore(add(_vk, 0x180), 0x013c1867e784bae04da012ee7d227e0f920b31dae793d5da38ae999b4622c4a8) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x1ca9e804bffcd6403981d319a74f67c17c267e9ce077434d46b8cbadb2cb6748) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x30447104bc7eaf34835557b8412d1220076eec127c7277d7d144d05ee10a4c82) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x0990dafa12cf826c986537955e488e025f11674b56dd87e543f532d80b529b75) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x1ae04aa3fc4f2ee6afa525cbd6502819eb3e7572b59363323cc978af71eeb25b) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x3031230737a7dad62b9fd25b9b9eb2a8f386bcbb2bde2f67e678dfd718deef7b) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x070799795a4b36746d6bac7b3248a9f80dd83ae93c1d1108b621f869b78542ff) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x2acc6c19c519877bdf4f8f759b8f5c82dc6ff3790445120840418f782fe458d4) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x21f55b7e9b4c5cbf21301019074c0a0eab41c8e637f8787e72f9f745c6979b3c) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x02e336c35d840241a188ffc7ad2c687f16ddd91356e9db9cc470af08db1ef180) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x00b7eec617e68065a1071a17d8e92cf99add525ec3fc6f5823c3907c4ffd99f0) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x2d9f0066732a3c01f1cd02f728f0a812dc501e14cf04cfeaffc21c1a3022b33e) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x0c5fa25121f65b37bb77aec0bf0f4d2aab431783f4b91ba0dd317933f2e17f89) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x1309d7fda24de7944e3001a2d6b76bf26907f88266a9e4d421e4fe8b44ddb1a0) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x18b0a6981df715dd568928124d6391b5c3eb2ed5ea81398e4bfcc8145b472ae2) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x1de52e7527cd79cc104730bb8e0eed4e8ceb9d7329fcff263c462799031f6393) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x06bf8ffad5944fd5c2050fc6fbc13986c15d8119a137abfdb1a7b28226449fe5) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x0b57fba979288b60f6ebcfc420898525a14cf47686f0cef811624e023bd80588) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x127368c110772e90b135520c13c04a3c1233e57a1790139ceeb67ee15a5d7a29) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x2aef30ba9eea240feeac22cc8d97e9254d9575af9a19c66806235365556706c6) // vk.SIGMA4.y mstore(add(_vk, 0x400), 0x0ddc3b6d8e59cf0996ca71ad4132ca9d618ffd933cf58a8a0953dc76f97cf108) // vk.TABLE1.x mstore(add(_vk, 0x420), 0x153193287060386695f4f2d0d3525dec4c6a253f431d3f3fc06aa0e5b0448b8c) // vk.TABLE1.y mstore(add(_vk, 0x440), 0x1170f0ece62f8c572bca96b141d27f4bd25585edb9319128045c005d48491b1e) // vk.TABLE2.x @@ -50,16 +50,16 @@ library RecursiveUltraVerificationKey { mstore(add(_vk, 0x4a0), 0x189da022421fbd8dfd7973084d978e555388ad9364679246b07992f84b4e91b2) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x285311c5e9a4cbb56a3f04f29d5443e8c0f9753e2a5a35acec051fafe2cecce5) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x2436400260c9d3180beedd0bf49fec92d2d0ac76a1be7f1fad96cbd997175312) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x139bb66456d96a4e2dad361f7949a6b8c6739650965ae729788162fbb0382399) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x098fad1329e1765863f8ac829332168359901da71702e5119ce4b89a7ae6f017) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x14fc4c6c2521387172a6b801e2b6c8a2308d725695d3f49a57151c2a0a8af0fe) // vk.ID1.x - mstore(add(_vk, 0x560), 0x2ce0c2c73ded7bcf19c1208f134b67ed74f77ef717db1c05c010bc8df7bed39e) // vk.ID1.y - mstore(add(_vk, 0x580), 0x0e2455a361f4a3741dab6a03b8186996a5a9873a3b62b3fa8eb5a551cb46bb7a) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x29a288b84aeabb0421861492256c6ea82530b5b14c0e01e5b7b2553cf197a2e7) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x01fbecd3bc90ad298a27bf4f9aa071746c30b5af932a1ba8d5b04394f85e0370) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x0b21c924fc2b44729ff84deeae724c68dd1636e847b0f7cdd92ad203af7cf0d5) // vk.ID3.y - mstore(add(_vk, 0x600), 0x12f7ebb5e50b429b766b1dc5e8b32b7727593641e4f976b72a7046d0a3ff8dea) // vk.ID4.x - mstore(add(_vk, 0x620), 0x2d45226edb0f8338bb5fa88ecefeeaa9bbb72232a2e842f8c7f37cd11f7065ed) // vk.ID4.y + mstore(add(_vk, 0x500), 0x1d76b979d3cdb568e4405b3125fdaf66d08713915ae51817ee645a588e9762a6) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x2622ec83dd99999d8f14cb98cdee282c94e8ee6e662e6593e4e5400bd38b1cf5) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x132cdcc3d715b32d30d688af15b5031fbeee02123092861e87b0598e4f71fb48) // vk.ID1.x + mstore(add(_vk, 0x560), 0x2d128dd3f102e376cac4e8ff680a448a9d63e91de1db1fdd1b95f1de8564cb45) // vk.ID1.y + mstore(add(_vk, 0x580), 0x0c3fe2f3b45a6677b4660e3121beb449edffa632dc6fb849879e2b11c955b004) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x0b88923b3a9a7d1aa171a93866d809d293093c8123ff8ee7247aeb17c88bdb1c) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x2ce478ea2b0fd325510c4219ae7c41c48ab83492826ff06813cdf261377997ed) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x04a50f2694a401ab75d1786f887767daf01f79d28a068081a746ed182c4b3caf) // vk.ID3.y + mstore(add(_vk, 0x600), 0x062d732ebc9718167a29d3f6de8a1e4d8d0fa59b7bcd7a77f6a37a25ec159b4c) // vk.ID4.x + mstore(add(_vk, 0x620), 0x1774cf6438fbbc70c8ec7013a37a4450fef3515f4d954ed26aee520a8aad261d) // vk.ID4.y mstore(add(_vk, 0x640), 0x01) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 From 0dfaaee4adf8252304cde2b87aa6d6a4482fce77 Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 11:47:52 +0000 Subject: [PATCH 11/18] cleanup --- .../ultra/keys/Add2UltraVerificationKey.sol | 24 +++--- .../ultra/keys/BlakeUltraVerificationKey.sol | 80 +++++++++---------- .../ultra/keys/EcdsaUltraVerificationKey.sol | 80 +++++++++---------- .../keys/RecursiveUltraVerificationKey.sol | 80 +++++++++---------- 4 files changed, 132 insertions(+), 132 deletions(-) diff --git a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol index 2bb221084bc3..2c7d7767d0b2 100644 --- a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 06369cb2b9f7607c9fc040d75deeee716a787f9600a91196da912a204d0fd981 +// Verification Key Hash: 40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library Add2UltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x06369cb2b9f7607c9fc040d75deeee716a787f9600a91196da912a204d0fd981; + return 0x40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -26,14 +26,14 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x1a0), 0x2e4e3e272c7b78ad894559812d7766e05615a8f7050a43d7ed1367adf30a9319) // vk.Q_M.y mstore(add(_vk, 0x1c0), 0x1798c37010a4285e1774c1ad35779886380ee5ceee0ba183927e2a2103301a68) // vk.Q_C.x mstore(add(_vk, 0x1e0), 0x2935f9e4d47a8e39aa0107f31a84584b47d903cfeb9690f6d850dc8ea7d2f4ea) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x098b323500f8c381b835917c5c1d37ed97bb714cfcd6d1c0c104542258027a43) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x204b44959b11e5893ed6100e102ee04d63a72bdd4c94490e01ecbbe72e32d853) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.Q_AUX.y + mstore(add(_vk, 0x200), 0x205aff7186f2cedc99e9cadb7930ef25f296991e5a7b574a33d6249f0a5db1f9) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x0beadc757bee3a2be1f6425385547099fc1eeeb1fed5a8552b07e997251d7c45) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x2cbce7beee3076b78dace04943d69d0d9e28aa6d00e046852781a5f20816645c) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x2bc27ec2e1612ea284b08bcc55b6f2fd915d11bfedbdc0e59de09e5b28952080) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_AUX.y mstore(add(_vk, 0x300), 0x01d8b8ff3b1674e57a7d30ce1d9e07c686174c643eb20d38e604eec7095248a9) // vk.SIGMA1.x mstore(add(_vk, 0x320), 0x261015d69327a58810e6eb1052ed694914b7a89034e1334c50b9e70a161489b7) // vk.SIGMA1.y mstore(add(_vk, 0x340), 0x1987df111730a8a6a650423757dbf048f3f43860a7d24a5e2e8bd67b6931ca67) // vk.SIGMA2.x @@ -50,8 +50,8 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x4a0), 0x0a5366266dd7b71a10b356030226a2de0cbf2edc8f085b16d73652b15eced8f5) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x136097d79e1b0ae373255e8760c49900a7588ec4d6809c90bb451005a3de3077) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x13dd7515ccac4095302d204f06f0bff2595d77bdf72e4acdb0b0b43969860d98) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x0c40380c5013361cb7e57ed4591553791df4838037064da2b24cd3a7bd20b40e) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x0d86cca6e33b9d896c3ec46116eb0d80a5c849d10995938a71e4703090bc65f9) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x500), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.TABLE_TYPE.y mstore(add(_vk, 0x540), 0x1e44194e60f0ab4ee0f77adc50f4220944f94301aa6da3016a226de04de52f4c) // vk.ID1.x mstore(add(_vk, 0x560), 0x2a017d0d9f40d0aeb5c8152ffddec56c2c7bea37dfbd20be6bed19efd743397a) // vk.ID1.y mstore(add(_vk, 0x580), 0x0868357b28039385c5a5058b6d358ebb29f26f9890d6cc6401f4921d5884edca) // vk.ID2.x diff --git a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol index cc6cfa51ce67..e5d1970c0e3a 100644 --- a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: b632c420983f1811242cb44c30f8e6fb663c25f78a353865ed68f6e89d929ad7 +// Verification Key Hash: 3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library BlakeUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0xb632c420983f1811242cb44c30f8e6fb663c25f78a353865ed68f6e89d929ad7; + return 0x3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,34 +14,34 @@ library BlakeUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000004) // vk.num_inputs mstore(add(_vk, 0x40), 0x2d1ba66f5941dc91017171fa69ec2bd0022a2a2d4115a009a93458fd4e26ecfb) // vk.work_root mstore(add(_vk, 0x60), 0x3063edaa444bddc677fcd515f614555a777997e0a9287d1e62bf6dd004d82001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x22703f0804e127ca3a084222bea6ea437cfbb6f2bef6581817eeb6be4b83a6bf) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x2854b842cd7bf05afeb768c5f8e95b7b51fc42334c2e370f94b7e06b0e8a6faa) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x1632a45613f6dd7155fe6056d33bcc96bb62840af313a1af5d0790c25fd64de0) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x09f2d38f64d24454fb39f47f44d17bd2b6d8a261fc7a8d3eea7148e420431db2) // vk.Q2.y - mstore(add(_vk, 0x100), 0x04a64347e55659ca18291c2340c55969817a0ab48511bba8c49393dc242e4057) // vk.Q3.x - mstore(add(_vk, 0x120), 0x175f4cd4cc9846d4bc902a4a44e156e1731c8899bcb64fece3c69f1ed5b3732f) // vk.Q3.y - mstore(add(_vk, 0x140), 0x1445e7776943b45e9fade0e56f63665277911d10748b7d5aec6e51730d49b6ed) // vk.Q4.x - mstore(add(_vk, 0x160), 0x21470dba7fa9b659baf7691e03a896767ea29659154ccf758ff92727412a126c) // vk.Q4.y - mstore(add(_vk, 0x180), 0x2d3306f68ef5e9f6d9867117a2eba1c5bcb15692edc5481b53dfe752e421dc0c) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x00a9d1b18ef9ef8e14063047fcdca03baf0c09c2ab292ec2fe8f6d56300958c6) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x0ec6a488608586384ffc6ee074116ba87bb32bfca3dd6db592c559bc8369a0ec) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x2fc3d28b016ff05ef3251dee6df4ddbf2b98bff9b498c05cbae7501f21fa3528) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x181f212f403b221c0805d11a8998bbf41ef81409ee3a019ae7775f39d692cee2) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x18bb52801779b80fbdb803cbb416bdfb20a286f62e43006c5f4bb430c0e0bbc2) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x00a76d339bdc6e030de531fc51322f06e35e0db2c71d02705cbc87497c1dcc86) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x12435124c05dc87a5aa6a57b7c213c0a3653f8cfe92a568a50d1e580ae73936d) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x254c7c79f29e6f05184889d52a7c01375832d53ea8dd60b93162a5805d715657) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x23558713233600d8847c983db3c2771210aad83fc39e33f4821c4b483fe579c1) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x28614b03e80d285e00deac31455ad2859a33627f4c150583f48a35cc890d1f8f) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x1864deb43e02b113184078e981dd524a4bac2267b46898d3204d074db7854879) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x1cb221e63e0cce3882bcc1bcf59378a8761dcf9c60dddbfb9916462b0c472fbc) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x0b6468629d32faf01306b8c70cb9658540afe95cacb2b74e7c7e6ff02de6aedd) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x035ba693d1e275dfc9508002e255623c03824f3da3b7d167889c4bed952f6d8f) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x10371645f3f56ad1d3aa29f3bd8ecd9c57132e898f731d65558430cea98aa12b) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x00edfa2e2de551d0b473d6171756f3ea741cad84eb1492fb7a185d70dd0a7221) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x2a41f9db2b8bc905df6a26e1f47f6d4b14a9739ab3d0fa35be5953af70c633b3) // vk.SIGMA4.y + mstore(add(_vk, 0x80), 0x260b63c5c404eba05c531b64a63c4f8752eb48b02d8d53910bbc22e7648b672b) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x0a84e4198292ba82e9ec6e130ebf86ff8513b8133501e8b7c625c322451cc17a) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x066bf08a2edd0ed02a5b2b4c72f512585b1816d943d06f4822219d37d28b88f7) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x18e0525744e594592f2ba6832df668c1424c920ebf1e2ec358558075df1fc906) // vk.Q2.y + mstore(add(_vk, 0x100), 0x25880f31af07e4d48de7be715bc3b63495b1ce16c3ce6233ad5ba832cf3330a5) // vk.Q3.x + mstore(add(_vk, 0x120), 0x190ab6675593f90dc404518e02369c97f0d736010033237073dfc5611cb4e0cc) // vk.Q3.y + mstore(add(_vk, 0x140), 0x1afd5ebe896054ba2812a94f5903a17aa5de0ffc7f1915259b4d9e01a24ceb44) // vk.Q4.x + mstore(add(_vk, 0x160), 0x03b445d3e75bd9ecf05703d2301157ccb3795adf7ddb3c0d03cbcc691772288e) // vk.Q4.y + mstore(add(_vk, 0x180), 0x00f612887aad4e61796d7948533fff40184bd1d00ba52e9201fea5b9b5a8258a) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x25bd9c5fec68e480ccf127be8b4bf7810c737a38f4d6a4379b3817d4d157a3f5) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x27e6361916a9c2a4f81501df8f6588c394f7ba0010e565fe9162e1456acb64fe) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x232d6f8f7582fc930a95c1d97e1cbe471935642ef95ac1457f953b92601a7f36) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x1344134626051322a90942b7cbd3a98227e7e192c8597604dea27f5eb49a1332) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x2c4782c37eb3e19589fc42e465f89cb3dd47ddcfce1a3a5f7e0e6423e9290f53) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x2ea84c6aebfa0d7b78e6f8344086d9a4ceabf599cdc3c8b8efaf937f78fa89f8) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x00fc4dc0688832477ed1b999b886307775590a5155ccfbe5e4a686cab3684fd9) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x21959276775cd4749236c8bf773a9b2403cecb45fbf70e6439f73d75442e8850) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x017714509f01d1a9ee7ebaf4d50745e33a14150b4fe9850a27e44de56d88cb14) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x16a04bedbbced0858d1cb768d5dee65d7a9e5eda5840f041a6b0c2d9a05a47e9) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x0f295c2f65406bd8aa6844f7a8c797da1ec69b048441e5926a0d11e515056af4) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x219f3919df06c1843bdcf405c9c6304c9affb6b5b075e25d9213cb9ca4177ad8) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x2a5acc53d574ddef7c44bc0d578d9371cecc89ab42a4b0bc6017eaecc68ebeb0) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x270efbcff761d452b5a3024f5a1b13b2108bfd126610f7c6580acfc8a3eadc43) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x052330edc9afc72fdaa4d7c5df4617631634c46a7132ece7ec56286647f66a77) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x1a07bea503dbfd8375d3cd35b79187516326c0a96af71418b8004e863d2126d7) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x1601a5ddea012bc53cf9633d99e704caa30b017e3e81e935a8d791030be559c3) // vk.SIGMA4.y mstore(add(_vk, 0x400), 0x06c5d3c2a64587cf9dc278c6892854fc8f1aba4183115224cb2eda4c1aab64b8) // vk.TABLE1.x mstore(add(_vk, 0x420), 0x132622df9222e04fa9c4cf2895212a49556038d4fdc6d0d7a15b1067bb446efa) // vk.TABLE1.y mstore(add(_vk, 0x440), 0x2dbc1ac72b2f0c530b3bdbef307395e6059f82ce9f3beea34ff6c3a04ca112bc) // vk.TABLE2.x @@ -50,16 +50,16 @@ library BlakeUltraVerificationKey { mstore(add(_vk, 0x4a0), 0x1bb16a4d3b60d47e572e02fac8bf861df5ba5f96942054e0896c7d4d602dc5c7) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x1f5976fc145f0524228ca90c221a21228ff9be92d487b56890a39c3bc0d22bf2) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x0f43d83a0d9eb36476e05c8d1280df98ec46ce93ae238597a687a4937ebec6cc) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x24ff9219ef37bf7b09f7159eecd91a04575de2f08ed1a4e5f12de29f88c09ca6) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x1c106354cc55938c81bb295784363c019517952fb7f4a6faaeca2910a687162b) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x266915a4cb91120dc75382cd9b3af13c67ce63227f7d6ea4ad04d903fb2434c5) // vk.ID1.x - mstore(add(_vk, 0x560), 0x053b66a3b7f8ea2ae35e2f4cf2ac23b9b6c434f9d9617628a334e5c18f11b8dd) // vk.ID1.y - mstore(add(_vk, 0x580), 0x0b07f09aee58678c763bb446191e58bd072ed87bb5bcdd6da0f76546b40a85fc) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x08e5120d71bedb26ebcd213d34d8c5875d27c10b52cc953b352cfe1a335e76e2) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x2f596b35c5f6b84a87aaa9c55b8024eb568c6b781684354dc01dfc8fc796ddde) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x1cf6cc14989803314cac6a750a7abfa08a866a849c2c93ecaffdf17a39c7018a) // vk.ID3.y - mstore(add(_vk, 0x600), 0x1e2b1d906c54b8522800ce716458f499958b648b5c7272a1af0acf52eb2551a4) // vk.ID4.x - mstore(add(_vk, 0x620), 0x268cb932de375fcdf382490bbbe55519e68d78c23a426673f7c56e8ea97fd6a3) // vk.ID4.y + mstore(add(_vk, 0x500), 0x239c09880dcbafee7caf9fb8460d1ca62e86b42b8724e350f01a12ddd4f08add) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x14dd9f4bba78075eb5bdb7d401281b01d9e88f8827fab15f6b718bfed5b6a598) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x0059fbc7f6f474f8a602db54e7aeb9b7072081bfb31d4831562003e8c5804177) // vk.ID1.x + mstore(add(_vk, 0x560), 0x01e2a561adf9c7843fd4e9acab18137656dbef06f22c9d2f05a68eae8576bd6b) // vk.ID1.y + mstore(add(_vk, 0x580), 0x205ed43983566317600b8324e02262240b23d6caa751e53360fe9410deb876b3) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x29ca9b6ba6da40ef21d62321d81594b449185bde9f071a3619731444a3cc30a2) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x0e633257c8c686bbe65fbf5792b8c944747838fd385d3b02eb7900dad50f6f4c) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x1bfda6b7d38472e9418a8eb55f4c1d372642b5819fde074d4fe62c29f843b566) // vk.ID3.y + mstore(add(_vk, 0x600), 0x1dab0d03d72afa6328933a39b05c764bc713f67606fa016ebf532deb2b4bc105) // vk.ID4.x + mstore(add(_vk, 0x620), 0x24bef3bbfed9cfcedabed6d61d289ae44ce360aa38fd022886fd22bc75fd5980) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol index 5cc4fee1d8a0..7f65f07afa57 100644 --- a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 47c4d766a5ca40358461d3f1848edc7cac6b144856961ad4b72be7dae0c22c21 +// Verification Key Hash: 2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library EcdsaUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x47c4d766a5ca40358461d3f1848edc7cac6b144856961ad4b72be7dae0c22c21; + return 0x2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,34 +14,34 @@ library EcdsaUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000006) // vk.num_inputs mstore(add(_vk, 0x40), 0x00eeb2cb5981ed45649abebde081dcff16c8601de4347e7dd1628ba2daac43b7) // vk.work_root mstore(add(_vk, 0x60), 0x30641e0e92bebef818268d663bcad6dbcfd6c0149170f6d7d350b1b1fa6c1001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x0d03a55e1c08f638bec6b3b6726ec4e8b4a2445fb898001c5cc59d90747265e1) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x28f5aaa22aae66726d58d5e1dd57733badd7577f842cafbef590b563688d3057) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x01ad27a5f461c70403ce6f694c448da777487d43b58a0e4e6cd1cad813ad90f4) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x0e02f03282ea9e987e16152483daba0d48545880bd3f0d171264f16c3de01de1) // vk.Q2.y - mstore(add(_vk, 0x100), 0x2331cfe626ebde7cd5c53d392b3cefe49b0763d3ad40e4c83a028a78ae2bfdf3) // vk.Q3.x - mstore(add(_vk, 0x120), 0x1f9bc26b884c0d494656412ea9c95a4d32955f3cb19e47db0c2143b231e97860) // vk.Q3.y - mstore(add(_vk, 0x140), 0x2839198a3ce970ca0a0fafe33d2ca8ffe50d70be7e613eb710c08ca95115998e) // vk.Q4.x - mstore(add(_vk, 0x160), 0x0da0e1c3eb107528a589868e34ae65114de290ddd45ff23fc5f637c0da23c1a2) // vk.Q4.y - mstore(add(_vk, 0x180), 0x29e22617fc67ce5065539da1ba4e8a733e8e42738f2b579b07fcdacbc4ea541c) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x280fb591b4cc7695bf75168a0327aa70aa82fdadc1b00ebc0ed8ca1deb45e093) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x2ae855c250cd7b84e59b16bd038785b3c0a474ce4e80cbc59b33846c2f7445d9) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x013ec37a92162385e03976dfbf07bd494be99740f6e598d79cd771e821a8fd60) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x13db96945a09894dddfa79d2b9f9e9e1eb6204065f662a17d7dbf6d257590d33) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x00d9af8f917935b1836f17dcdf1d44a1fa4e3655777f8ddca39905b38b80ab48) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x1a66842ed11152b8ccd1ffe548414be7dadbb956ae828c47cb32c449fb9a2a21) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x0b4304dfa9379f11f9387befd9522dde481e04d359a511e543b9c9fcfd4c8e70) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x2f213c7a4c064a63d6a07366df0ea85aef9ad2125a188c3e656f95471e416a0a) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x067a270bed55e72ffb3cfa39af3e5b8bcb4961d72bb301978af13c4ddc73e5df) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x27b10524a99f00d9c59cc15ff3b7dfc34975b6f18e06b9c6c3a6136bf3b56f32) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x071a9bf80d112c32482178ff02f855436cf6fb4b4376ef7e2f03381c2e6da379) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x23904a6dcee70f3275bc323178df29575a8042333388123d808922a4ac14d66c) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x18b9c021b795ee06660c1a4fee630dc0e6aa605408c2662e0f5d54648f7ebb3c) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x2b222d8ae83eaec10db010cfec35d326df64053dcb4a1ecde1fbdeb2b312912d) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x2e1e70c7600abea70257dbd6f05838bcb881646e06f3df5acb105b7a1a509c26) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x1b324b63bf3864aab4d796e5095563f7e4ef6af0e8499cb91f1da90be847a7d7) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x16e5682a54699b4a3ee4255aa372cc3b5262300b3684dba139cb98bb01ac9faa) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x1e6167376510d37e4d267058578f15e79141c4ee5aa38f479ab58f469e82a608) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x16e147005ca23abea5055000d5505f4813e28c303e3656b66cf7a4cd647c98fd) // vk.SIGMA4.y + mstore(add(_vk, 0x80), 0x1cc85a07fb1009e23540957b29121dc57aaae5b1e89a22a932a1bdf7ccac1af2) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x19a1a4fa6d8781abbcb696097c1817f54da296348a292954e2aa9856f2fa3b6a) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x0409f05fe2901e7e339b3aaf0d7af7b5d4023e416da923321b15aae633b18fee) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x0ae6cc44e9024c190ab310d7ad110226c5c76f15d158b60fc9acd98f2e1f1aa3) // vk.Q2.y + mstore(add(_vk, 0x100), 0x20e3b4e35df25ba02ac2a9be26bc6fe74640355e57455598e69922b8d3fd0939) // vk.Q3.x + mstore(add(_vk, 0x120), 0x1f49d18bdb86a449e676558c6d6349f123372641187e33e12128ee7468431942) // vk.Q3.y + mstore(add(_vk, 0x140), 0x00e95627d4db555ccf3b1ee6def34fab1a815f0482cb6a745a363940d3163831) // vk.Q4.x + mstore(add(_vk, 0x160), 0x19fe011a8a139da323b5ce5abebe54bf4c105acd6045d7b2b5df40a34411f44b) // vk.Q4.y + mstore(add(_vk, 0x180), 0x04b41648960da31317eff66b5ca9be0a6c81ebeead27e70b3c5b28d4aba11081) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x1bff2df21a3fd9c49c29b7f7c153dd0bc331d75afc6a35fb7155c17bb0f67a63) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x15faa2ea86a6a66cd9b969d6305f863595a73b9215c1ae442969f4993a8e5230) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x26391cc92544b485d90313d3396b53d9207db8f84ead11bcf45467fa7eb38b94) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x01a0d650b65d29965e4ae2a8cfb69470d7560f0826268da59c6e72e684a06c9b) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x2248d4a02e68036c8d0a4a6725ba0e5e8e95950a5285a3a7daa1a1726cc8ec6b) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x01afcbad715a0c382971311ad6fe4ff8b6e99200162aeb6245b585c99c8748a9) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x18bf352081d1ba2ffe8088d34ce6471e4cf6d2ee63f006ea9a5e31cc41b6587c) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x21245d6c0a4d2ff12b21a825f39f30e8f8cf9b259448d111183e975828539576) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x16a409532c8a1693536e93b6ce9920bfc2e6796e8dfe404675a0cdf6ee77ee7a) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x2d455f287e41544fd3744bab412640fd6916b01aa2163c84071eb47f0306a473) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x09dea8e2b5e382a1c4a37bc4e60f5e8380688310b855c249d64153478d25e223) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x09671927e293b22a3fb9fa8ea1680fcc4570bb2f312cb88004ff7fd4474e2109) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x1c6442d9a49b3b93a928ef6ba2f348bc4c8cb778a59345faf7d173129f22b5a3) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x0337d84b45a5abc701edbdc1a1d878178c23496b39ccddcc3f0f6199e3f97df6) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x1c744f7be93d40c96d15fdf9d81c9502b7018573ad23e51dea7b065fdeb6f13a) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x23a975cfb71f0c0d46ef9c0b01e6482e780b5e3af1a63547f7d01c46c1911699) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x0d5a0be212cb2c7d3bba8c2406a9d2c4b04d4e64b0acef2681eb7c6aa490a7cb) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x1ca2d0cca80bb16eab28d06c5c175e862a8ef14bceb6da79e65236a8a6a36838) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x0555fe3dbd2ba2d7db2b5f740bf32fb57f4c5ac9d9f2e59e9a5a2cc2d84dae05) // vk.SIGMA4.y mstore(add(_vk, 0x400), 0x18f7cf965339d9c9d190296fa92f915767b0a8da455975f3e03fa98439fd7110) // vk.TABLE1.x mstore(add(_vk, 0x420), 0x0eecc02f9d44125407adbf00d56b086afd1adc5de536450afe05de382761b32f) // vk.TABLE1.y mstore(add(_vk, 0x440), 0x0bdfe662ea9f40f125ca5f7e99a8c6ba09b87ba8313864316745df862946c5c4) // vk.TABLE2.x @@ -50,16 +50,16 @@ library EcdsaUltraVerificationKey { mstore(add(_vk, 0x4a0), 0x1fda66dfb58273345f2471dff55c51b6856241460272e64b4cc67cde65231e89) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x024ccc0fcff3b515cdc97dde2fae5c516bf3c97207891801707142af02538a83) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x27827250d02b7b67d084bfc52b26c722f33f75ae5098c109573bfe92b782e559) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x15985385d1aa90674122e82725090452dfa93457b5dde13c8b33efef98fff114) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x2c2899d602af17f7248199a7654118b9d17f7927ea4b3ba57bdb9ac4fb2c160f) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x21efa829ce91cdd4263a3ff0853f05818eab4ad41c9b0e997003fe894f449e32) // vk.ID1.x - mstore(add(_vk, 0x560), 0x0c047b4340c66fc18ecaebb454059bb5fffbac7c9f1fe1e5335bd17b6de47bd6) // vk.ID1.y - mstore(add(_vk, 0x580), 0x08bed3e3394706c35d7a63be542bba01b2b7887dd862206b354141e882981745) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x1b74c9bd464f4540853ca869206f47d44aa2ba3bd68dafcc82765c0bd0933420) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x22ef220782674f44cdb2604dd3eaecfd36c729c463a4c92204a620d07e1416b9) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x087e275bd5d63aba524e0e8b43915a91d2496df9b1bf961d4dde6ae7d4e222d2) // vk.ID3.y - mstore(add(_vk, 0x600), 0x27a4c598d505372d7c03681cf5720438e17e6ffab22d0a85f480f5ceb7e50926) // vk.ID4.x - mstore(add(_vk, 0x620), 0x2cc881edb02565957ea2797c16ae8e2a77eaef5e9d9a98e55a12e9349d158f2c) // vk.ID4.y + mstore(add(_vk, 0x500), 0x22b1d6b9827d6d03049f76dc9dc219ae6de93abe52d4d7de8677d961d3408c77) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x10ebc6be9f74e0367276028c613ab3efe0f2ed546c05339b36d5165d009c833a) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x2aa2e5247ce6524fecba0a2de9f383353096665f3ae8082fe7017fbf6d6572d8) // vk.ID1.x + mstore(add(_vk, 0x560), 0x1db802f61a6194bea68f7d5ec697facf26f1c1336b09e382801e8b773f0e116f) // vk.ID1.y + mstore(add(_vk, 0x580), 0x1aa955e508f3c2fbf55a36719eb666a45239935c4af10b8a1f4580d5cd614236) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x2bc21aa51420951a10a39d5c5242101d2207c47a0077852acb7d3fd6a16e1c58) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x245c89c4cf7c7e297b4db8e2625f5abd56398c351256a39aece0a36a940aaf62) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x01bd6e61d801d895c7edfee071518761f3c8c0e10bec5f0fb0b25ae430a2c91e) // vk.ID3.y + mstore(add(_vk, 0x600), 0x30223d4653291c03019e96bd716769c7c6d6520fddf2e633a75f94b08bee86dd) // vk.ID4.x + mstore(add(_vk, 0x620), 0x2e389428afa291855039f1b4af22e70d469f4e20116b85889737d624a2d27fef) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol index adf2df91d589..45d50fe15dd2 100644 --- a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: ddb343afc65263c7c9009910e035f96f50b0827580c10fd882bce1f58e633e62 +// Verification Key Hash: a52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library RecursiveUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0xddb343afc65263c7c9009910e035f96f50b0827580c10fd882bce1f58e633e62; + return 0xa52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,34 +14,34 @@ library RecursiveUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000010) // vk.num_inputs mstore(add(_vk, 0x40), 0x2260e724844bca5251829353968e4915305258418357473a5c1d597f613f6cbd) // vk.work_root mstore(add(_vk, 0x60), 0x3064486657634403844b0eac78ca882cfd284341fcb0615a15cfcd17b14d8201) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x272fae13335cda7794aeee75c0d41e52cc626b07106135805edc8538ab41f6e8) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x266e1501fe1a3d602bbfb1bd408ac9b329686552d0578d8fa1a7d37444632eed) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x022635cac72d16d7a0175bea90ffd678d3d3681f97e64ccc9f399ac8a5da390f) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x1abe686aad406be6d8c4326713c4f134d8db7d8c1c57aaba22f593e132996636) // vk.Q2.y - mstore(add(_vk, 0x100), 0x0ec435019f6a618bb2db375a5d1b9f2d0981df21b996bc488897e9bff237fdac) // vk.Q3.x - mstore(add(_vk, 0x120), 0x1059e50efe134dff75de467d46b0b2363e2cc8a5b9f48aa758f5c895cf1e9685) // vk.Q3.y - mstore(add(_vk, 0x140), 0x1b5ece1f2b6578612eca0fbc1f45742c440ee5246070152406d8ab66d2fe82c2) // vk.Q4.x - mstore(add(_vk, 0x160), 0x25669e07536131b086ce8a414333b5ab214fea376e52fca87ed9ac7c4d26cbbc) // vk.Q4.y - mstore(add(_vk, 0x180), 0x013c1867e784bae04da012ee7d227e0f920b31dae793d5da38ae999b4622c4a8) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x1ca9e804bffcd6403981d319a74f67c17c267e9ce077434d46b8cbadb2cb6748) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x30447104bc7eaf34835557b8412d1220076eec127c7277d7d144d05ee10a4c82) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x0990dafa12cf826c986537955e488e025f11674b56dd87e543f532d80b529b75) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x1ae04aa3fc4f2ee6afa525cbd6502819eb3e7572b59363323cc978af71eeb25b) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x3031230737a7dad62b9fd25b9b9eb2a8f386bcbb2bde2f67e678dfd718deef7b) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x070799795a4b36746d6bac7b3248a9f80dd83ae93c1d1108b621f869b78542ff) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x2acc6c19c519877bdf4f8f759b8f5c82dc6ff3790445120840418f782fe458d4) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x21f55b7e9b4c5cbf21301019074c0a0eab41c8e637f8787e72f9f745c6979b3c) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x02e336c35d840241a188ffc7ad2c687f16ddd91356e9db9cc470af08db1ef180) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x00b7eec617e68065a1071a17d8e92cf99add525ec3fc6f5823c3907c4ffd99f0) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x2d9f0066732a3c01f1cd02f728f0a812dc501e14cf04cfeaffc21c1a3022b33e) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x0c5fa25121f65b37bb77aec0bf0f4d2aab431783f4b91ba0dd317933f2e17f89) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x1309d7fda24de7944e3001a2d6b76bf26907f88266a9e4d421e4fe8b44ddb1a0) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x18b0a6981df715dd568928124d6391b5c3eb2ed5ea81398e4bfcc8145b472ae2) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x1de52e7527cd79cc104730bb8e0eed4e8ceb9d7329fcff263c462799031f6393) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x06bf8ffad5944fd5c2050fc6fbc13986c15d8119a137abfdb1a7b28226449fe5) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x0b57fba979288b60f6ebcfc420898525a14cf47686f0cef811624e023bd80588) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x127368c110772e90b135520c13c04a3c1233e57a1790139ceeb67ee15a5d7a29) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x2aef30ba9eea240feeac22cc8d97e9254d9575af9a19c66806235365556706c6) // vk.SIGMA4.y + mstore(add(_vk, 0x80), 0x05104b486160545badec11f151e7c70b87050871da5653387ab4ab2ad0eef5ca) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x2672c7fb298fce83f510eb6e1b851a5bb2daf8fc43c7771e96c56c8a09ddfeae) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x2c019acf99c5663da83cec224bd32570ee90f45c4486a54dec3ca4552d8ab07a) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x0fb7a3385ab42cafb0e104ac17ac2dacfb161d292c00fca102b1e780e86ccaf3) // vk.Q2.y + mstore(add(_vk, 0x100), 0x273ca9c29ef10864f4c9c053c336776a71ca5ebbf4bec1cb381e431943f9b5d7) // vk.Q3.x + mstore(add(_vk, 0x120), 0x2a94f00fe384ab945a8f5e3c97194a425a4d2109e5b113f059e42ee232659436) // vk.Q3.y + mstore(add(_vk, 0x140), 0x0e8b5c127c8a3ec285c2ac80d9046528051387878802203988a60650a0a960ab) // vk.Q4.x + mstore(add(_vk, 0x160), 0x17efdb659ae0d26aa78db132f9be9130460c0fce0c2a8e9b726de68247f76891) // vk.Q4.y + mstore(add(_vk, 0x180), 0x2f668d8a50bdb5c366e39433892f903262a04b6473ba3468c12057d58ad3bbfb) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x2397c6171bc6d084e98297690441c9da9f011d18b3ea0bb58ee4d47227feb6b4) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x1dafbfb4d30fcf880ef839ecc7fda9a97c315c5fa1713d08f7cdf6dba53ffb17) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x099fa3de9ce0cc28085739745582b53bf7939e3d97928afd491392053c1c0a68) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x028912be5d0accd4edf4949f89be1c1a2fcf4f59559ba03114da00ec3bf643ac) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x2428952bfba8ba44830fb0ae6fcdeb9bf17d611add9432450ebbe3d928e2f431) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x2b40c900824bcca193d402e0ef7f78792deaccd99743a78e5330abe8886ac989) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x102a7a02bc1a7317702c09560636e991b856f26f88ee8f0b33da3dd7fe222dbb) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x2bcf00433471db2be265df28ba2e70c36ca52f2932a4de25c0d60868703a0726) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x2f225b86590c67ae48360cb41d5b291ba94ce2dbae850afd9a6854122341b5ba) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x2eaee34d8508092cc4e19bc3f27ffa7dfc72230710e220f228f48906fae21e56) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x0c503c5d6245b99bbc056925e96abd20feaed6507707311092b3ed87eadb3874) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x021ba851cec3aedfbf1d9944907ae721f0d3e8fa3548513b6f108d101067ae85) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x24eef378da346c4f9eededc5dc519d35b14fec46412c8fcf7564cafb9843d761) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x0492b2fed8a158177dd3e825fb34ca7481bfead06bc01f308dc81fcd852ef3bc) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x289bf1bcc6a9cb19b102c7fb9dba839e1817a24257194cad404b393ce77e66b5) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x05d2a9c66d5c142b254b4f7d09f0eb837d95d8ec002e0644f51d455041403ca5) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x2434b76f470965c85363ff15b3f37c7b4be4fb2741451dc33943879f1e4cbba4) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x2f4bcc93500665a87a8f959e1636fe88cb1f17688b8c286fe930ccf934a49ac2) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x243f7b4ae1d483c99523b6a2999f404ab744017c8f43080c3582c38ea8ea3d1a) // vk.SIGMA4.y mstore(add(_vk, 0x400), 0x0ddc3b6d8e59cf0996ca71ad4132ca9d618ffd933cf58a8a0953dc76f97cf108) // vk.TABLE1.x mstore(add(_vk, 0x420), 0x153193287060386695f4f2d0d3525dec4c6a253f431d3f3fc06aa0e5b0448b8c) // vk.TABLE1.y mstore(add(_vk, 0x440), 0x1170f0ece62f8c572bca96b141d27f4bd25585edb9319128045c005d48491b1e) // vk.TABLE2.x @@ -50,16 +50,16 @@ library RecursiveUltraVerificationKey { mstore(add(_vk, 0x4a0), 0x189da022421fbd8dfd7973084d978e555388ad9364679246b07992f84b4e91b2) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x285311c5e9a4cbb56a3f04f29d5443e8c0f9753e2a5a35acec051fafe2cecce5) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x2436400260c9d3180beedd0bf49fec92d2d0ac76a1be7f1fad96cbd997175312) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x1d76b979d3cdb568e4405b3125fdaf66d08713915ae51817ee645a588e9762a6) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x2622ec83dd99999d8f14cb98cdee282c94e8ee6e662e6593e4e5400bd38b1cf5) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x132cdcc3d715b32d30d688af15b5031fbeee02123092861e87b0598e4f71fb48) // vk.ID1.x - mstore(add(_vk, 0x560), 0x2d128dd3f102e376cac4e8ff680a448a9d63e91de1db1fdd1b95f1de8564cb45) // vk.ID1.y - mstore(add(_vk, 0x580), 0x0c3fe2f3b45a6677b4660e3121beb449edffa632dc6fb849879e2b11c955b004) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x0b88923b3a9a7d1aa171a93866d809d293093c8123ff8ee7247aeb17c88bdb1c) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x2ce478ea2b0fd325510c4219ae7c41c48ab83492826ff06813cdf261377997ed) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x04a50f2694a401ab75d1786f887767daf01f79d28a068081a746ed182c4b3caf) // vk.ID3.y - mstore(add(_vk, 0x600), 0x062d732ebc9718167a29d3f6de8a1e4d8d0fa59b7bcd7a77f6a37a25ec159b4c) // vk.ID4.x - mstore(add(_vk, 0x620), 0x1774cf6438fbbc70c8ec7013a37a4450fef3515f4d954ed26aee520a8aad261d) // vk.ID4.y + mstore(add(_vk, 0x500), 0x139bb66456d96a4e2dad361f7949a6b8c6739650965ae729788162fbb0382399) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x098fad1329e1765863f8ac829332168359901da71702e5119ce4b89a7ae6f017) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x14fc4c6c2521387172a6b801e2b6c8a2308d725695d3f49a57151c2a0a8af0fe) // vk.ID1.x + mstore(add(_vk, 0x560), 0x2ce0c2c73ded7bcf19c1208f134b67ed74f77ef717db1c05c010bc8df7bed39e) // vk.ID1.y + mstore(add(_vk, 0x580), 0x0e2455a361f4a3741dab6a03b8186996a5a9873a3b62b3fa8eb5a551cb46bb7a) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x29a288b84aeabb0421861492256c6ea82530b5b14c0e01e5b7b2553cf197a2e7) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x01fbecd3bc90ad298a27bf4f9aa071746c30b5af932a1ba8d5b04394f85e0370) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x0b21c924fc2b44729ff84deeae724c68dd1636e847b0f7cdd92ad203af7cf0d5) // vk.ID3.y + mstore(add(_vk, 0x600), 0x12f7ebb5e50b429b766b1dc5e8b32b7727593641e4f976b72a7046d0a3ff8dea) // vk.ID4.x + mstore(add(_vk, 0x620), 0x2d45226edb0f8338bb5fa88ecefeeaa9bbb72232a2e842f8c7f37cd11f7065ed) // vk.ID4.y mstore(add(_vk, 0x640), 0x01) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 From 3fa5b505da711c562cbd247394c8672a945b187e Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 11:49:18 +0000 Subject: [PATCH 12/18] package-lock.json files --- .../acir_tests/sol-test/package-lock.json | 198 ++++++++++++++++++ barretenberg/sol/package-lock.json | 6 + 2 files changed, 204 insertions(+) create mode 100644 barretenberg/acir_tests/sol-test/package-lock.json create mode 100644 barretenberg/sol/package-lock.json diff --git a/barretenberg/acir_tests/sol-test/package-lock.json b/barretenberg/acir_tests/sol-test/package-lock.json new file mode 100644 index 000000000000..020ba3eed748 --- /dev/null +++ b/barretenberg/acir_tests/sol-test/package-lock.json @@ -0,0 +1,198 @@ +{ + "name": "headless-test", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "headless-test", + "version": "1.0.0", + "license": "MIT", + "dependencies": { + "ethers": "^6.8.1", + "solc": "^0.8.27" + } + }, + "node_modules/@adraffy/ens-normalize": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz", + "integrity": "sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==" + }, + "node_modules/@noble/curves": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.2.0.tgz", + "integrity": "sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==", + "dependencies": { + "@noble/hashes": "1.3.2" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.2.tgz", + "integrity": "sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==", + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@types/node": { + "version": "18.15.13", + "resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.13.tgz", + "integrity": "sha512-N+0kuo9KgrUQ1Sn/ifDXsvg0TTleP7rIy4zOBGECxAljqvqfqpTfzx0Q1NUedOixRMBfe2Whhb056a42cWs26Q==" + }, + "node_modules/aes-js": { + "version": "4.0.0-beta.5", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-4.0.0-beta.5.tgz", + "integrity": "sha512-G965FqalsNyrPqgEGON7nIx1e/OVENSgiEIzyC63haUMuvNnwIgIjMs52hlTCKhkBny7A2ORNlfY9Zu+jmGk1Q==" + }, + "node_modules/command-exists": { + "version": "1.2.9", + "resolved": "https://registry.npmjs.org/command-exists/-/command-exists-1.2.9.tgz", + "integrity": "sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==" + }, + "node_modules/commander": { + "version": "8.3.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-8.3.0.tgz", + "integrity": "sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww==", + "engines": { + "node": ">= 12" + } + }, + "node_modules/ethers": { + "version": "6.8.1", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.8.1.tgz", + "integrity": "sha512-iEKm6zox5h1lDn6scuRWdIdFJUCGg3+/aQWu0F4K0GVyEZiktFkqrJbRjTn1FlYEPz7RKA707D6g5Kdk6j7Ljg==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/ethers-io/" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@adraffy/ens-normalize": "1.10.0", + "@noble/curves": "1.2.0", + "@noble/hashes": "1.3.2", + "@types/node": "18.15.13", + "aes-js": "4.0.0-beta.5", + "tslib": "2.4.0", + "ws": "8.5.0" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.3", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.3.tgz", + "integrity": "sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "node_modules/memorystream": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/memorystream/-/memorystream-0.3.1.tgz", + "integrity": "sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw==", + "engines": { + "node": ">= 0.10.0" + } + }, + "node_modules/os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/semver": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/solc": { + "version": "0.8.27", + "resolved": "https://registry.npmjs.org/solc/-/solc-0.8.27.tgz", + "integrity": "sha512-BNxMol2tUAbkH7HKlXBcBqrGi2aqgv+uMHz26mJyTtlVgWmBA4ktiw0qVKHfkjf2oaHbwtbtaSeE2dhn/gTAKw==", + "dependencies": { + "command-exists": "^1.2.8", + "commander": "^8.1.0", + "follow-redirects": "^1.12.1", + "js-sha3": "0.8.0", + "memorystream": "^0.3.1", + "semver": "^5.5.0", + "tmp": "0.0.33" + }, + "bin": { + "solcjs": "solc.js" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/tmp": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", + "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", + "dependencies": { + "os-tmpdir": "~1.0.2" + }, + "engines": { + "node": ">=0.6.0" + } + }, + "node_modules/tslib": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz", + "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==" + }, + "node_modules/ws": { + "version": "8.5.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.5.0.tgz", + "integrity": "sha512-BWX0SWVgLPzYwF8lTzEy1egjhS4S4OEAHfsO8o65WOVsrnSRGaSiUaa9e0ggGlkMTtBlmOpEXiie9RUcBO86qg==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + } + } +} diff --git a/barretenberg/sol/package-lock.json b/barretenberg/sol/package-lock.json new file mode 100644 index 000000000000..dab5c8abab12 --- /dev/null +++ b/barretenberg/sol/package-lock.json @@ -0,0 +1,6 @@ +{ + "name": "sol", + "lockfileVersion": 3, + "requires": true, + "packages": {} +} From 73843c301652f82cc6032b7724af392fa108e64c Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 13:45:19 +0000 Subject: [PATCH 13/18] make plonk happy and fix tests --- .../examples/join_split/join_split.test.cpp | 2 +- .../composer/composer_lib.hpp | 20 +++++++++---------- .../execution_trace/ultra_execution_trace.hpp | 8 ++++---- .../ultra_rollup_flavor.hpp | 6 +++--- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp b/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp index 677e30f198cb..16c02210cfa7 100644 --- a/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp +++ b/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp @@ -703,7 +703,7 @@ TEST_F(join_split_tests, test_0_input_notes_and_detect_circuit_change) // The below part detects any changes in the join-split circuit constexpr size_t DYADIC_CIRCUIT_SIZE = 1 << 16; - constexpr uint256_t CIRCUIT_HASH("0xe833d0ffaa99f39ca31ef79ded0089b0ec614eb4a528c4e1c4af6221a003fa6e"); + constexpr uint256_t CIRCUIT_HASH("0x4493cd42ee7e54ca5ee77ff0833c98c4f9a5ee79762cb86c8cb3d40c22eddfbd"); const uint256_t circuit_hash = circuit.hash_circuit(); // circuit is finalized now diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp index 399c7b0d7f60..dc438b405f03 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp @@ -11,7 +11,7 @@ namespace bb { template void construct_lookup_table_polynomials(const RefArray& table_polynomials, const typename Flavor::CircuitBuilder& circuit, - const size_t dyadic_circuit_size, + [[maybe_unused]] const size_t dyadic_circuit_size, const size_t additional_offset = 0) { // Create lookup selector polynomials which interpolate each table column. @@ -22,12 +22,12 @@ void construct_lookup_table_polynomials(const RefArray tables_size + additional_offset); + // const size_t tables_size = circuit.get_tables_size(); + // ASSERT(tables_size <= MAX_LOOKUP_TABLES_SIZE); // if false, may need to increase constant + // ASSERT(dyadic_circuit_size > tables_size + additional_offset); size_t offset = circuit.blocks.lookup.trace_offset; if constexpr (IsPlonkFlavor) { - offset = dyadic_circuit_size - tables_size - additional_offset; + offset = circuit.blocks.lookup.trace_offset + additional_offset; } for (const auto& table : circuit.lookup_tables) { @@ -54,14 +54,14 @@ template void construct_lookup_read_counts(typename Flavor::Polynomial& read_counts, typename Flavor::Polynomial& read_tags, typename Flavor::CircuitBuilder& circuit, - const size_t dyadic_circuit_size) + [[maybe_unused]] const size_t dyadic_circuit_size) { - const size_t tables_size = circuit.get_tables_size(); + // const size_t tables_size = circuit.get_tables_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace size_t table_offset = circuit.blocks.lookup.trace_offset; - if constexpr (IsPlonkFlavor) { - table_offset = dyadic_circuit_size - tables_size; - } + // if constexpr (IsPlonkFlavor) { + // table_offset = dyadic_circuit_size - tables_size; + // } // loop over all tables used in the circuit; each table contains data about the lookups made on it for (auto& table : circuit.lookup_tables) { diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp index dd4b66107c11..0bed250dc39c 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/ultra_execution_trace.hpp @@ -15,8 +15,8 @@ namespace bb { * @tparam T */ template struct UltraTraceBlockData { + T pub_inputs; // Has to be the first block otherwise Plonk breaks T lookup; - T pub_inputs; T arithmetic; T delta_range; T elliptic; @@ -27,8 +27,8 @@ template struct UltraTraceBlockData { auto get() { - return RefArray{ lookup, pub_inputs, arithmetic, delta_range, elliptic, - aux, poseidon2_external, poseidon2_internal, overflow }; + return RefArray{ pub_inputs, lookup, arithmetic, delta_range, elliptic, aux, poseidon2_external, + poseidon2_internal, overflow }; } auto get_gate_blocks() const @@ -114,8 +114,8 @@ class UltraExecutionTraceBlocks : public UltraTraceBlockData { void summarize() const { info("Gate blocks summary:"); - info("lookups :\t", this->lookup.size()); info("pub inputs :\t", this->pub_inputs.size()); + info("lookups :\t", this->lookup.size()); info("arithmetic :\t", this->arithmetic.size()); info("delta range:\t", this->delta_range.size()); info("elliptic :\t", this->elliptic.size()); diff --git a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_rollup_flavor.hpp b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_rollup_flavor.hpp index 6deb40b7020d..440d1051834b 100644 --- a/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_rollup_flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/stdlib_circuit_builders/ultra_rollup_flavor.hpp @@ -99,11 +99,11 @@ class UltraRollupFlavor : public bb::UltraFlavor { const Commitment& q_r, const Commitment& q_o, const Commitment& q_4, + const Commitment& q_lookup, const Commitment& q_arith, const Commitment& q_delta_range, const Commitment& q_elliptic, const Commitment& q_aux, - const Commitment& q_lookup, const Commitment& q_poseidon2_external, const Commitment& q_poseidon2_internal, const Commitment& sigma_1, @@ -135,11 +135,11 @@ class UltraRollupFlavor : public bb::UltraFlavor { this->q_r = q_r; this->q_o = q_o; this->q_4 = q_4; + this->q_lookup = q_lookup; this->q_arith = q_arith; this->q_delta_range = q_delta_range; this->q_elliptic = q_elliptic; this->q_aux = q_aux; - this->q_lookup = q_lookup; this->q_poseidon2_external = q_poseidon2_external; this->q_poseidon2_internal = q_poseidon2_internal; this->sigma_1 = sigma_1; @@ -173,11 +173,11 @@ class UltraRollupFlavor : public bb::UltraFlavor { q_r, q_o, q_4, + q_lookup, q_arith, q_delta_range, q_elliptic, q_aux, - q_lookup, q_poseidon2_external, q_poseidon2_internal, sigma_1, From b0a6b053f8eb81f569fe1a9edfd289a47afcd01c Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 14:27:09 +0000 Subject: [PATCH 14/18] fix circuit hash --- .../src/barretenberg/examples/join_split/join_split.test.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp b/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp index 16c02210cfa7..1c516b7ae9d5 100644 --- a/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp +++ b/barretenberg/cpp/src/barretenberg/examples/join_split/join_split.test.cpp @@ -703,7 +703,7 @@ TEST_F(join_split_tests, test_0_input_notes_and_detect_circuit_change) // The below part detects any changes in the join-split circuit constexpr size_t DYADIC_CIRCUIT_SIZE = 1 << 16; - constexpr uint256_t CIRCUIT_HASH("0x4493cd42ee7e54ca5ee77ff0833c98c4f9a5ee79762cb86c8cb3d40c22eddfbd"); + constexpr uint256_t CIRCUIT_HASH("0x9ffbbd2c3ebd45cba861d3da6f75e2f73c448cc5747c9e34b44d6bc8a90b4a9c"); const uint256_t circuit_hash = circuit.hash_circuit(); // circuit is finalized now From b253f1b4f01bb9129ad095ea2ad405625406653f Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 17:39:57 +0000 Subject: [PATCH 15/18] fix honk_contract.hpp --- .../client_ivc_bench/client_ivc.bench.cpp | 2 +- .../dsl/acir_proofs/honk_contract.hpp | 2 +- .../composer/composer_lib.hpp | 10 +- .../src/honk/keys/Add2HonkVerificationKey.sol | 74 +++++++------- .../honk/keys/BlakeHonkVerificationKey.sol | 78 +++++++-------- .../honk/keys/EcdsaHonkVerificationKey.sol | 78 +++++++-------- .../ultra/keys/Add2UltraVerificationKey.sol | 24 ++--- .../ultra/keys/BlakeUltraVerificationKey.sol | 96 +++++++++---------- .../ultra/keys/EcdsaUltraVerificationKey.sol | 96 +++++++++---------- .../keys/RecursiveUltraVerificationKey.sol | 96 +++++++++---------- 10 files changed, 276 insertions(+), 280 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp index 25fb38a63e6c..2acbb568272f 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/client_ivc_bench/client_ivc.bench.cpp @@ -33,7 +33,7 @@ class ClientIVCBench : public benchmark::Fixture { */ BENCHMARK_DEFINE_F(ClientIVCBench, Full)(benchmark::State& state) { - ClientIVC ivc{ { EXAMPLE_20 } }; + ClientIVC ivc{ { CLIENT_IVC_BENCH_STRUCTURE } }; auto total_num_circuits = 2 * static_cast(state.range(0)); // 2x accounts for kernel circuits auto mocked_vkeys = mock_verification_keys(total_num_circuits); diff --git a/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp b/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp index c0cc2040a2de..f62c0c7d8761 100644 --- a/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp +++ b/barretenberg/cpp/src/barretenberg/dsl/acir_proofs/honk_contract.hpp @@ -166,11 +166,11 @@ enum WIRE { Q_R, Q_O, Q_4, + Q_LOOKUP, Q_ARITH, Q_RANGE, Q_ELLIPTIC, Q_AUX, - Q_LOOKUP, Q_POSEIDON2_EXTERNAL, Q_POSEIDON2_INTERNAL, SIGMA_1, diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp index dc438b405f03..3942a291231a 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp @@ -22,9 +22,9 @@ void construct_lookup_table_polynomials(const RefArray tables_size + additional_offset); + const size_t tables_size = circuit.get_tables_size(); + ASSERT(tables_size <= MAX_LOOKUP_TABLES_SIZE); // if false, may need to increase constant + ASSERT(dyadic_circuit_size > tables_size + additional_offset); size_t offset = circuit.blocks.lookup.trace_offset; if constexpr (IsPlonkFlavor) { offset = circuit.blocks.lookup.trace_offset + additional_offset; @@ -56,12 +56,8 @@ void construct_lookup_read_counts(typename Flavor::Polynomial& read_counts, typename Flavor::CircuitBuilder& circuit, [[maybe_unused]] const size_t dyadic_circuit_size) { - // const size_t tables_size = circuit.get_tables_size(); // TODO(https://github.com/AztecProtocol/barretenberg/issues/1033): construct tables and counts at top of trace size_t table_offset = circuit.blocks.lookup.trace_offset; - // if constexpr (IsPlonkFlavor) { - // table_offset = dyadic_circuit_size - tables_size; - // } // loop over all tables used in the circuit; each table contains data about the lookups made on it for (auto& table : circuit.lookup_tables) { diff --git a/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol b/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol index c521dab7f689..1c246dc4d6b1 100644 --- a/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol +++ b/barretenberg/sol/src/honk/keys/Add2HonkVerificationKey.sol @@ -14,33 +14,29 @@ library Add2HonkVerificationKey { circuitSize: uint256(32), logCircuitSize: uint256(5), publicInputsSize: uint256(3), - qm: Honk.G1Point({ - x: uint256(0x0cf9ec917690b1f3c5f1eeca422fd46fecedb7e285f730f04ffc950e10849b56), - y: uint256(0x0ba3c142aa26e5287a2c234b10bc87e843be79521006162193eda994ab7115e8) - }), - qc: Honk.G1Point({ - x: uint256(0x22cdd25966a6b790032ec0abcb6580bb0c0b16fc0451b1c049e875c591ba0290), - y: uint256(0x08ee89ab716f9c1a86eb455af26ea22b62b37322d38c4577e58d7afa0e4dec56) - }), ql: Honk.G1Point({ x: uint256(0x27456b3a666ff24c6452657437518f7b73e854ce6c763732122a3b923bc6797b), y: uint256(0x2ecbc0db4ae72d05db96eb72034b26275a33325b05b2dd53c33662369bcdc4e0) }), qr: Honk.G1Point({ - x: uint256(0x11d6feb82ca1a185806312498f81091e3f9bb74c4b7625b3ae8dd7cea4dc710f), - y: uint256(0x1649b8452a7577b1e16b23a2d05711c5e55a180853be8aac29fc4aa1d64f7b13) + x: uint256(0x274db2ddab5fc87804dcb835027d293547d5fc2b6cde27990e5577a3d77aa4b0), + y: uint256(0x29d2c716e45fccb7b1d8a3fb384854408392a74a4e4fb4d3cfab460efbfdb87d) }), qo: Honk.G1Point({ - x: uint256(0x14dfdc022af1eca2f57e7d7420a9a3282a49254446bf39714d9ede31a2130728), - y: uint256(0x2b3ff801ccaf5061adb0321ebcc51710ff7b342916e51c1926ab0e6bb652cd44) + x: uint256(0x26da077296ea89f2b0caef070f7c380bedee8f4137d8e15972888cb873b6a849), + y: uint256(0x01028d4966e7b172aca7f9c56d169a449b2326bc0293d54f3708482a8fd09d26) }), q4: Honk.G1Point({ x: uint256(0x1b87b4f288e37e4ff07f6a368177b9765eeccd1017bec74e98859fa3fbf201f3), y: uint256(0x1d100498fbe5bd401d2eb9b77f1a887806c8251de6ccab14008a324357e5ddfb) }), - qLookup: Honk.G1Point({ - x: uint256(0x1d64341216e323f076ac53aa06192392677f44b67b6947dd6a0a1490fb32a083), - y: uint256(0x28d02cea9cc379ace2ae8779011e247ddc4213ef69895a8e634f425844107141) + qm: Honk.G1Point({ + x: uint256(0x12dda3f2df2c6774290c833772e87ec75c9a658559506fcd1d743e0e98b6e0ad), + y: uint256(0x2df9dc1c291b41624c0ae46e40238467771572731402b64d664ed641c5078105) + }), + qc: Honk.G1Point({ + x: uint256(0x0963fc084e9f28db0ad8f6d9cc0fd9dfdf2704140bb42debece9b98ed4e6915b), + y: uint256(0x1e81fc7c58c0d8ae1233acb9d57c1d69a82c4c1a418494558b735fba505f6877) }), qArith: Honk.G1Point({ x: uint256(0x06d4ca88fe948f6b5f555d318feea69879457f1cf2b22f7d464fa8d4a8b5cd46), @@ -58,6 +54,10 @@ library Add2HonkVerificationKey { x: uint256(0x024236bda126650fb5228cf424a0878775499e69e8bd2c39af33bd5fa0b4079a), y: uint256(0x233cda9292be02cfa2da9d0fc7b0eab0eb1a867b06854066589b967455259b32) }), + qLookup: Honk.G1Point({ + x: uint256(0x2594d00a131b347f472a021eac09e25eacba35749a9ba8f8c7f4a726ff63a910), + y: uint256(0x2499be5abe1cf5463534a1d0613f82449f1989f1186f2d0b67295bda7f8a0f55) + }), qPoseidon2External: Honk.G1Point({ x: uint256(0x0ca0bc4b1cd9eadbbf49eae56a99a4502ef13d965226a634d0981555e4a4da56), y: uint256(0x1a8a818e6c61f68cefa329f2fabc95c80ad56a538d852f75eda858ed1a616c74) @@ -67,52 +67,52 @@ library Add2HonkVerificationKey { y: uint256(0x205f76eebda12f565c98c775c4e4f3534b5dcc29e57eed899b1a1a880534dcb9) }), s1: Honk.G1Point({ - x: uint256(0x1ee42e6792a78e6d972f2a5837543b9b633d5171cfba5818490542c8c44bf697), - y: uint256(0x12b9d322a38926ecb0d5362e2dc0889f3f1b60f424afe68c1725dd33d61c70ca) + x: uint256(0x2183ad847a1249f41cbd3a87f40c2f430eec8e15078ebf4294072495293f623a), + y: uint256(0x18f03d44febf5942b0325bd60625eb1d407adb20bdc51e770aa1f4ca1daf767c) }), s2: Honk.G1Point({ - x: uint256(0x09771d3d9a9fd4387a98a4731629007be9e3c4fd2f786dd8ead41aa976f8bd28), - y: uint256(0x1703a6752c3cbaaf55de7ecb71deef7b8ba5dcafe25c771dedc5a80c45b06121) + x: uint256(0x2d6764e48b62f11fa745090dbc582712f8a0a16ef81cc7da6fba8b1ec52d23a1), + y: uint256(0x0289e7980be1c71d3e91a117b1d062b27bf4d711e9ab3a8ee82a64eaf4c5ac45) }), s3: Honk.G1Point({ - x: uint256(0x0774598ea3282c98b6dd0ff5ae61cf2384c1575181b593bb51e437b3b3ddb7a7), - y: uint256(0x174770561e38591c022e00530c2ae0fce5743b6259eba4dcba60cfaed46fd0d1) + x: uint256(0x16e299d4076387afc2add98ca386b3ff7ef29b7e87bb492a02e820b6404da3de), + y: uint256(0x2b11799049c80302774a11e05c57c8f614aecbc1c9a524e48328466195f35eaf) }), s4: Honk.G1Point({ - x: uint256(0x0bad8aee68642460b84b30e981f86a1a27734580dbe886ba851d85bab1303088), - y: uint256(0x268fc1bbe998d39d31ab3878f86731bd9c087ebf37d6a4cd3e0d2d42eff776cc) + x: uint256(0x27c8607e808c4a94be60e9fa6e4263ab2d4b41bd866add287affd942f5879b79), + y: uint256(0x25584de7b2b270f792e86e4ca403dc6fbf31f16b1da4d3f95ed9b8231e1a7e31) }), t1: Honk.G1Point({ - x: uint256(0x1bf7da4add7c858eb94b75f2e78fbd89c84f5fa43824a0d5534173872ee099c2), - y: uint256(0x1b35fa2a35673699ee1cb260d9e6c4be79b26d488c26dc2531194e43c8f747ea) + x: uint256(0x1fb7c5d789d32e42a08e41296286139f603c7607ce186d0cce6e472dfe021473), + y: uint256(0x09d80a7c25410f51739aadc54ad122874e4551efc35bd23807ecf23a79ef418a) }), t2: Honk.G1Point({ - x: uint256(0x16bf79791869cec464180d5322eeaaef18fed6dc10c3e64e314c04d85c3faece), - y: uint256(0x2e2ec6341669b5b975e25e465af5d9e40533d5ac173554df19daed27f66c36ff) + x: uint256(0x108788a192d4d3c38e445629bb550acf212f9b2049b6fb1cc76900bd482fb5b0), + y: uint256(0x195266ac0788c227762333892ad282a4679450ae72e8e8b4a1ead0e63d4f4e04) }), t3: Honk.G1Point({ - x: uint256(0x15d6c249e181b368efd3ef2737f00833c9cafbfdb055118b7c45f2f84defa7bd), - y: uint256(0x169d45dda72090b85c888b40fdd546bbc4db3002b9ec68d3384d08181e54bf10) + x: uint256(0x1eb529bdb867a986cca8b8c0119e679b5712f4503e5d00698de6b6ae49092404), + y: uint256(0x20886f9e098437ea65110f5591661e37ac720779a376a6155f132dcd6c301a52) }), t4: Honk.G1Point({ - x: uint256(0x159f2541ce446c6d59ea3f06be91ec9f47c9c82f3e4fd10696511efaff4121fa), - y: uint256(0x15f873b33ec9467e1f0c4fb3a0b59a6fcd6f3480515f1ff5506c48f0c521f00f) + x: uint256(0x1a552bd8d3265d1f23e7ff166cf20fffa5c0688c867cfd3a2ea65452d8ad60a4), + y: uint256(0x1cb1414f7b9f8edb7c7a0d61f66e24e632a4050d9b3be0d6c35109aa99693039) }), id1: Honk.G1Point({ x: uint256(0x2e286f771211f7466ea24e64484140bd5bcdcc759e88c2f4b2cc2fda221fb9c9), y: uint256(0x21b150b35832343dd3988a32e15c404915b0cebfb762e47ad0a7ce18004bac27) }), id2: Honk.G1Point({ - x: uint256(0x19b6d9ab601b2cecdac9c552eb9ddc17378cac2854e27a5fd6230183d584f0c9), - y: uint256(0x2f5c61226e06143579dcc1869c6a8cc1b1c87ea091b80cf0c848d279ebc23de8) + x: uint256(0x18eff4656b9f83aaf418fb251334d580bc6d247b19bb2438d4c4e71ffc3db1df), + y: uint256(0x1f859be892b830da65325a465f711a12a0b777997bbbfa5baebcb9f9a0eae3f1) }), id3: Honk.G1Point({ - x: uint256(0x1aa22165b655889dcf4c6c693d3c840c87d342b1469f112e58204590497a5d42), - y: uint256(0x082a1045cdfd4f7abbf565f51f70aab100a0d6e196570ec997b5e1525a220a58) + x: uint256(0x0a0ae72496a2b188d803fb33078c15cbd3d6874f3d1dd71eeb6ff7d8f4542ed5), + y: uint256(0x15314a39e87cc4d8274dc773f73f20ec712c0fc7216fc00b016fadca84dbf785) }), id4: Honk.G1Point({ - x: uint256(0x26c4f2e833efa6045d057de69f4492fdfa11a6876a134967799e6c8a0d41915f), - y: uint256(0x07e11b7f5b6d537b5838ba8c6ce291b99a9346e83d8a75f57827fd2317fd6c3c) + x: uint256(0x2493c99a3d068b03f8f2b8d28b57cea3ee22dd60456277b86c32a18982dcb185), + y: uint256(0x1ded39c4c8366469843cd63f09ecacf6c3731486320082c20ec71bbdc92196c1) }), lagrangeFirst: Honk.G1Point({ x: uint256(0x0000000000000000000000000000000000000000000000000000000000000001), diff --git a/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol b/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol index cbfe91c8f6ad..fe39ba379287 100644 --- a/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol +++ b/barretenberg/sol/src/honk/keys/BlakeHonkVerificationKey.sol @@ -14,33 +14,29 @@ library BlakeHonkVerificationKey { circuitSize: uint256(32768), logCircuitSize: uint256(15), publicInputsSize: uint256(4), - qm: Honk.G1Point({ - x: uint256(0x2fb9700846f0022bed3187c1cf0b174090b058b98047194adf282db291debad0), - y: uint256(0x21ba20033e1857a24868122f7e25328d7062800999361b19364b7c62c5ede0cf) - }), - qc: Honk.G1Point({ - x: uint256(0x043c36b4a5721692349176680a658590a9d577c297e5f3d794fec1c880e8f051), - y: uint256(0x195c49156dbed8ea9891aed6df5feed06ff1f08380677e82fb2f4408a72cf186) - }), ql: Honk.G1Point({ x: uint256(0x259ccc124bd4cf494d50c802a2df9671c3a500ccc3e83b72ead3806a7e740675), y: uint256(0x0fa82481afabca16ee5f23d7ea094b00ebbc578a716fdaf782e05fd726faf007) }), qr: Honk.G1Point({ - x: uint256(0x0b11c50746a883e4383982e35a1936e9586028f380a1ec4cf7599426774e1f99), - y: uint256(0x2f79b36de7832b7666fcfc7feaf2bdff224db852fdd3b97bee6092ca8fd22dc2) + x: uint256(0x14ff9e75f0777269c7e1788b0c22a4995ee7aa86b57f1df85daad5dc5394c64d), + y: uint256(0x2459bcedd7bd75b357c9e5feb11de3cd8da023ce6a386b2449cd5f93758a6a3b) }), qo: Honk.G1Point({ - x: uint256(0x2968918f9de631c93d45d84b220efa2ff7bdd7486a29b6ec8ac579a48651f0b8), - y: uint256(0x1b28988dc794be7111a947861ed773d6145760d0b420657ddf930845b843c197) + x: uint256(0x2d45d3ef650bc8242021c0b5c7c458abbe387b5697fd64f82c07527f7d1de8c6), + y: uint256(0x0267edd43123342fda564babb7c89110ba206a7b36500e88bb7c485448e97913) }), q4: Honk.G1Point({ x: uint256(0x1ce127e531187e01b1ce284179977224b8f76fb470da6c61bf1791509a40d8b8), y: uint256(0x22bdfdaabf4d8863c4a989a3345c7c9519af302fa6a1f67e4810d6589c2b5d6d) }), - qLookup: Honk.G1Point({ - x: uint256(0x0740cda472d3e453a2fcd60f35d723e695aacb21ba04f9084afc52604b3bcc04), - y: uint256(0x0fb95f729baccab8238b16fbec6681f1166ad5a551e9b7946999502303819c7f) + qm: Honk.G1Point({ + x: uint256(0x0951790dc5ec21ff7bd1054fbc6c3024120f848605d10edcabbd81924ef14404), + y: uint256(0x0715c7ce615280c7629a43891bf15a2194bd659483b15333d6bc66697c59e39e) + }), + qc: Honk.G1Point({ + x: uint256(0x021f1c4697f49682d5b22a39cab4b196a822c7279551d3c86de39eecef6ee491), + y: uint256(0x170cf597b1d291c41d59d76f852fba1a7def57d9d031daf7bb0061b6b45be5b6) }), qArith: Honk.G1Point({ x: uint256(0x2ec15ed0cae4827b6c15a424b3409faea5a3b1488234f9970c12fe64dcd09915), @@ -58,6 +54,10 @@ library BlakeHonkVerificationKey { x: uint256(0x1a3a5eb5a02862dc132e23eac87a937d4f9b4d3736b3d1ce2bf2aec5b8761283), y: uint256(0x0e608d3de6c0adf6dfba886c110a388fc2059abe6f660caf3f901bd3dbe4d97d) }), + qLookup: Honk.G1Point({ + x: uint256(0x22ef6b48ceec28053e1ec5bc4f0a91ae22d287d86044f15672c167ec1af91d8b), + y: uint256(0x11b828a2435dfaaa173ec009381bcd95b76c41adee995ac0c716b82879cab160) + }), qPoseidon2External: Honk.G1Point({ x: uint256(0x1fa8529236d7eacdab8dcd8169af30d334be103357577353e9ef08dfda841785), y: uint256(0x055251b013746385e921b4620e55ef4f08b4d8afc4dbca7e6c3ca0f1b52c5a2b) @@ -67,52 +67,52 @@ library BlakeHonkVerificationKey { y: uint256(0x0335bb595984ad38686009bca08f5f420e3b4cf888fad5af4a99eca08190a315) }), s1: Honk.G1Point({ - x: uint256(0x0b8540a7d4b9f68af310a209e665b9b96bc7176a013a1fd3bfa3e51be892b6f3), - y: uint256(0x222be999ebb657c7008ae403155f35eae26c2bbdb45f53ddf845694e5b33c0ed) + x: uint256(0x259bede7c068653c0e2a16bd986e1ca97757315d3b973a494c6ca022cea60447), + y: uint256(0x2a93cb60e983030c470c044e1f156a25fe5e1941d38f4d8c91594e0eaa8858ae) }), s2: Honk.G1Point({ - x: uint256(0x16cbd9680fda4d75023e1cbbc595d4e1a7330f8ef066011a4106893cba22fe06), - y: uint256(0x241412468b2cdd90d753b3aef54bc693f743f74958b63bf8b9e13b1e73b2b2e0) + x: uint256(0x11df397e5ad916749343c5be9797f2b6e3c0450714a1d5fa8a3f55ef32586940), + y: uint256(0x046a6da96359bd452f9f3c3ccc15b9f59c26bab349a02faa1f1d34517282ef6c) }), s3: Honk.G1Point({ - x: uint256(0x13974139784cdfb86fde8cbed23e008b3d1ea8d35ec365247ce1e7fb1ac580e9), - y: uint256(0x2e98dfa8b653f9c285a746c524df84c5dbf54b962c070ca46fa21c293db5c68a) + x: uint256(0x1ed35d2fd753212e17554522ac3d692ae25cb581f54adf02f99a5d6f71969d5d), + y: uint256(0x08352d3f6a0fb619cfd1a960514fe3394d9018f0388f631df9f5af9fcfd0efbe) }), s4: Honk.G1Point({ - x: uint256(0x25bdfe71582a214364307f91949e89d8b555b8a806d541c5541852565bef3395), - y: uint256(0x0c1614865cac1586e703758c2ecb801dcfbd83fcd77a760e209b60abad700c42) + x: uint256(0x15365aa0c1d6bce15408f45f0251c9472f78297ec2cc5ab508f5c568980a893d), + y: uint256(0x2385c2920ad544f0be29c68152bc7ae98031aee831ddad561a45a95b31ae6ef5) }), t1: Honk.G1Point({ - x: uint256(0x2fc548524cb26d07674add2e538f77e84292737995faf9db61da7110dbde4ff5), - y: uint256(0x02bf9cd9e57b46e1713a23e2430c597c2ec1f500fc61245cad1485fa5e0d411a) + x: uint256(0x25bdb78d4e315a031ab7b6cb0dfdee32d86f4845ef1f837cdafa6c45f9ccae56), + y: uint256(0x0e68860fb89d3a366d4b7244a172f5a7e79147d8f09d3249b1555df77ef64ac9) }), t2: Honk.G1Point({ - x: uint256(0x21846645bb6d3785e1b2497d57be8ae0b6fba047cd837960f234ab2f5b693b4b), - y: uint256(0x2576207b872d79ffaac0c25adc2cf13ce2a26df47324e2efcab94da0dd52589d) + x: uint256(0x0c0b5c83cfca189b7560979cbb59e4450d970a226e703fa090fc0fba87094c82), + y: uint256(0x290a615d73d77f18f3a7483bd4f7d9ba22ad1c1e28980012e5bb3c9660b96086) }), t3: Honk.G1Point({ - x: uint256(0x2d66c44ccb0b5e4fa3e99524315370f3496c3af3c3393c9633d15c0bb487b6b9), - y: uint256(0x2620591fc497ef8b319c5123a91fb60ff96c3f9c983ff2471d30f4ecc73a5a0d) + x: uint256(0x09d24c7501264da486f4ddbe6fee4a104edbfbcc8b3b7ea185db69c5e1a6c38b), + y: uint256(0x132e749bb80fdc19494cec612ce529b810d672d471253ffb5ab0ada355163fd3) }), t4: Honk.G1Point({ - x: uint256(0x0b9637a36be3c944d247e8d4d93b3b3ff5e637913415e08b5c7c7b0c5101caaf), - y: uint256(0x1bbdffbd59b3f1a41ec403bf740e96799428eeff9a6e0ede9b880dc2108c8223) + x: uint256(0x044ff357ea1fbf33738fc570145106a3f6acc496c748b0b58f4615e1b0626e10), + y: uint256(0x2816e550d752b97bd0a5c2ed5369a652088981b3e92e3d6238b0c63b203aa3f4) }), id1: Honk.G1Point({ - x: uint256(0x07450ae8309488b3fd48f09411c02fe478f4dcb4f6525be47a7bd89668c2aeea), - y: uint256(0x08a082a8eed2aef053393dbb78942f41985be06527c5460f41ce25e2dfdd9ef5) + x: uint256(0x2a2b95a34bb20d564d0b1ba33afdfe5ad95a8128ddfd8faec40b7bc2faf642e2), + y: uint256(0x1355384c7b2deba5fb394e25d297d5f37ccfaacfacd57aac61259bc1e87ea6ed) }), id2: Honk.G1Point({ - x: uint256(0x05987220adaeb7884ff44c4a83b7ae2828bfb6cad038ac363e8d27275da440a7), - y: uint256(0x1d5c5cde2ea4bb94d69dae858461471e34363fc094812f82dc368e7ba48db44e) + x: uint256(0x279ce3dbe9564e5fd66014fbedb03f538e23b5effe8bf1c3ca394eba651d25fc), + y: uint256(0x0d130ad41878eba2d8da55ed688de58a3b8edf7b237e4ead56deebd56d11344c) }), id3: Honk.G1Point({ - x: uint256(0x2fc0df7490d5e4bf85beb3b7b0ba23699d1cfe39a3de758fd565f3c0f788842c), - y: uint256(0x001926cb363c3121a03e5cd867ead2f8736e4597c395a47b43e793cbdec2eb4f) + x: uint256(0x1f3ca856540e150992ef85a64d5bb2ddc643a53f15dad567e08fc5a61307a2c3), + y: uint256(0x0f44b87f30b55235f069ad5d06f23915c19bf6194c0e6f54e2a4b41ef357e214) }), id4: Honk.G1Point({ - x: uint256(0x2608c589e60f7b806917df85cb737165dc8cf408a220dc144db14f85e42ad396), - y: uint256(0x1090f6af2524f0395c3e7d268d62e80157e09f0d60aaa5529ec0d45054f638c4) + x: uint256(0x2b85159a22ab90cb83642950f0240a403dac1dc50a970d1113be0cf8a8b5d63d), + y: uint256(0x1287b2e8e4ee3f0a9afbf798230ea32388a6e90924f13d7c78d5aed275095c79) }), lagrangeFirst: Honk.G1Point({ x: uint256(0x0000000000000000000000000000000000000000000000000000000000000001), diff --git a/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol b/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol index 49eb04488169..bd19e3682490 100644 --- a/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol +++ b/barretenberg/sol/src/honk/keys/EcdsaHonkVerificationKey.sol @@ -14,33 +14,29 @@ library EcdsaHonkVerificationKey { circuitSize: uint256(65536), logCircuitSize: uint256(16), publicInputsSize: uint256(6), - qm: Honk.G1Point({ - x: uint256(0x0ed1228aa376d3ac181b2e0b572d243615cf473b20645ac5914b7c7b20f54a10), - y: uint256(0x0a01d55e860a4d3a661395f9d17e1c44b6058b6099539cb1a4302fcd13b35d68) - }), - qc: Honk.G1Point({ - x: uint256(0x106bff91418858c329df3d01f467bb55688ebc343ebb65acd1e9664be358e993), - y: uint256(0x2d9cd9783c6dd8df242c78ba10fc3d0b8a05fecc5865e94c96d12566eed74561) - }), ql: Honk.G1Point({ x: uint256(0x092e1a5431e67f41abd28c9b103ef1fb90a93ff2474f2f5bd2550387fac4b6d6), y: uint256(0x272df56e1a1740f88fe789b1e63112068687fdc95ef7612024d550202bcbe41f) }), qr: Honk.G1Point({ - x: uint256(0x00ddad5b6f421b4dc6bb73ac297c784419ef94900740fe5dc2c0bd4f26e511e0), - y: uint256(0x0b415d844a10a6892cf8eedc6c6ad624f1ee5ee17fd5f0729d46917fdcac847f) + x: uint256(0x1d22d883b1f1bb07cbc1339682a92e3d96cf09e1c53a881fa283045587ce00fe), + y: uint256(0x12fdb565b8d174d018dede5197be30c94835fa581ed969f40433f65a84222a4a) }), qo: Honk.G1Point({ - x: uint256(0x11af45b67ecda10a79c68507c0487b6e1a8a8b71a5911059619afee17e0a57ca), - y: uint256(0x2974fd4439c12128eb399ba3b0c7a74b1c86c1ac16abb755083dc6f62e00f459) + x: uint256(0x2d928f55abc1f8f5f9e29011fa8c802eb5a94989042b3d5560f013a779e5d193), + y: uint256(0x1086b7bcf22b95fc94f063af74498dd4bac214e0459d68379a1008261358ddd7) }), q4: Honk.G1Point({ x: uint256(0x0a4e034f2d3b73ae4eb6ff0db3fe8e7b0357e6dd375a3107d1e4d9eb5ceb1e5b), y: uint256(0x1266512c0da5b14ede1f1d5b80ad9dfa43b3c71b2c0bb11c9c123c70eabc62ad) }), - qLookup: Honk.G1Point({ - x: uint256(0x09d9383bcfd22e2259f1c2a9a5c0d2c8f999f8f1c5750fe571a2ca9f827f6274), - y: uint256(0x0376fe8d56d38514322cdd2e4c0fb0aa9ccb4281a748b45adb055ca4b51b16bb) + qm: Honk.G1Point({ + x: uint256(0x1279a8faed8a7d782856985a20218fbcd73a8e8fb2574622210169b3b4eec159), + y: uint256(0x063271b597aa97880532cff9e2ccea5a6bf13d947f4c310c39be452010d59cb9) + }), + qc: Honk.G1Point({ + x: uint256(0x1892791334caee5906d99a8c6dc6dc8636e0c667893b8cdd8067ee565028e396), + y: uint256(0x2f86193c2778a4c33d144fbf2803260b1df44d4ad82390dea131bc2b11ad1855) }), qArith: Honk.G1Point({ x: uint256(0x11ff48b12a216298b2f8efe8dc2f269c1e9f62917ae7ac83c92ff6aea3a2d2fc), @@ -58,6 +54,10 @@ library EcdsaHonkVerificationKey { x: uint256(0x1055198df3ec55ad61ff8c8f824bfc3cf74e459f46dd1c1d2ace45890e9b80fb), y: uint256(0x07725ad2b53ee322b94db4b28baefdbd7239bf4d9c2e9e0d9565bfda8954a380) }), + qLookup: Honk.G1Point({ + x: uint256(0x0a15b7287881191263af5654587121b7c5db6c7fe8d390ab0454d0996a0b184b), + y: uint256(0x2b5b0486da55ab0a673f7ca8d0fb5400a5462bef7a98730f34fe266bcf8b63ae) + }), qPoseidon2External: Honk.G1Point({ x: uint256(0x2c1c2ccda8b91666f7bd30eb4a992c3e4c729adcf73e008348e8c97083d56242), y: uint256(0x2b418829be00d02f2e01a1fbf110420b328a44416e889990f1e81b735023ff1d) @@ -67,52 +67,52 @@ library EcdsaHonkVerificationKey { y: uint256(0x2c5af44525879b9580e7687e6a93dd55fd6aa9251d90a5c2c4fc0ea971e1448b) }), s1: Honk.G1Point({ - x: uint256(0x26b2ad965e92409ddc7dc6f05eb2516a3d46556ee0fe42d3be9284f43c164268), - y: uint256(0x16604235232876ec81dcf3009e2a5511ff7deab5c8d5fc1688a01f70641cfa19) + x: uint256(0x1d9253a09df46bec5da04d4ef7839fd41bd2e97ae43ccfa143dc0d657fa85553), + y: uint256(0x12eba500137049f38ecfef8f8a8f061abfedbf4f832169375aafd290b8920667) }), s2: Honk.G1Point({ - x: uint256(0x302fea7a6ae8b64fe8e117cd9450d8365a2854b3ae7ddba866274e072a33e3c9), - y: uint256(0x199f7fbb7597bf2aad7560b458c1d82b12b8dc403d52a5feb5d51f1980756c09) + x: uint256(0x108fa66ffac071a9a79c3798a54074139931be05a5b8c88596e354ff0c7977b9), + y: uint256(0x2ee653942fe48118b22616ff96b698dc5232a49ae5aaf33196af01d8cd783895) }), s3: Honk.G1Point({ - x: uint256(0x2488536441f1c8d33ff3fb367eb57512b610cae764a88e062ed0ec73fba9e307), - y: uint256(0x146de607134bad0e3c2bde26e9e98317b71aa7389a4f5c2d28747f2bd6d4dade) + x: uint256(0x0e5e0e66b8d82ab97c3a4101da87d1457dfe38d8d781cd54d6a51fc4ed80fb5f), + y: uint256(0x1247d037ee1a73c1772120a83c697906102abd709365442c3057ad2f640e015f) }), s4: Honk.G1Point({ - x: uint256(0x25f8a81f0344b1784b8c04d29afaddb2c9fb75de95d819a6a319a30aac40d841), - y: uint256(0x16e87a99f0c181fdfe028986561ded38c218a4f3e6a4d919d36c32e4d6ab60db) + x: uint256(0x1cf115e956940f5beeb730452473c79f981e974cc1fd2dd4811f4de693860f24), + y: uint256(0x1a64f5ff7c28626ff23e5ae82e45f30158fc7dfd23487ad97ea9bb8b5b66e18d) }), t1: Honk.G1Point({ - x: uint256(0x00132b961b9e8baa0e250bed996c62a966f1b079b7e9816126c5b86bf9f1f075), - y: uint256(0x05d50d691281482fc032b4308517fec893094a6dcee7c45aaabfaf3505ef454e) + x: uint256(0x2467210c5e67f86104a38488eff67d1252b8dc1de9c1f589ff66bfd5a4de1ed6), + y: uint256(0x2126dbe4e3ee0d2240507870a9d85f0d90490efd7c69070f65a31dbff731889f) }), t2: Honk.G1Point({ - x: uint256(0x0bcb7a54ae4377b41e9423a7804138aad684255df2369ed797a9b565e0b9c0b3), - y: uint256(0x03c0febe0892c50980262ab672f1fdd1a0d33bc3149ca1f62176c7e4384bea10) + x: uint256(0x0c6e576e4ea74b4a4b2c70c36633e7c2d25222fa692417d283831aa00a578825), + y: uint256(0x061c370923246a520c238c6cc2442ce9c0790350438fc20d0371682e92fda4e7) }), t3: Honk.G1Point({ - x: uint256(0x2ca522e0da49dc12acb6203b8e863f54c76358fe6906643197470c3d5c1d85fc), - y: uint256(0x042538987110445b116e4c25ff0e28a55df6898de39f7f8ffaa933353ed36e93) + x: uint256(0x10e110ee17259e7746e26e882567409aad3fda44ea148dc6195eadfb80dc3884), + y: uint256(0x23ac2d72dddf2f686d55cacac3d5503003d8a19acaab8d6cf00e3850600bf729) }), t4: Honk.G1Point({ - x: uint256(0x25b80f778ed684cfc28daf11bf3e9d06c0a83fcef2c5b30ae3a58db8672ead3f), - y: uint256(0x17cb62830be2fc016aaed9d86aaee46777aa337d7dc7e6dce3f7a4b13935ef50) + x: uint256(0x299f1dfcb8b0b56691dd560e5ee9f73c4d07fac967de3ecbbd0769128209cb9f), + y: uint256(0x01598d24dc1b7a351ac26c8ca4d1d7539ef9b9252f7e664648f36adc1deed9ca) }), id1: Honk.G1Point({ - x: uint256(0x03b8602a4ad473e33cf7b8bcbf117818f01e940b5bec035fe7c441a040ad828e), - y: uint256(0x20437c04120868065a9644e26bd3c53646ede89246acf9bdbd23e8a6c8dba624) + x: uint256(0x1a0412e7de1e53ce0c0ccefc666cac1ae83945594a7aaf807e964415a11f00db), + y: uint256(0x2526a8a84a5f7d557379a155d0a8d9dade32a096cd81914029722c685fe420a9) }), id2: Honk.G1Point({ - x: uint256(0x101f5775ed011ef78a262c29eb0ced5ae3ef009e3f2a5c0071cd5c56b8ebec4d), - y: uint256(0x1e148e8c7f4f7f7a3f6638132838497eaafed827da5bcd09719f5d96884f3f79) + x: uint256(0x2158c8dcf92c304cd203397b9868e636c7bde65e68883364c458f067acb8c2b4), + y: uint256(0x08ba19108eabee284eccb6e86b4a8837fb36841af7da73e7979eea7d4f2dbe0b) }), id3: Honk.G1Point({ - x: uint256(0x2197860a1b2fc4ab23077177ce37cc48e13f2a63ef8088b34f9942a7d0af5427), - y: uint256(0x2ab09ab203f3afea533223c1b903fa583bede76688ec0fbaf0b7287500303528) + x: uint256(0x211a0d1167642ab55fa62b879782796fb8cd2809c658b45f62d528b5d5b34311), + y: uint256(0x05dab9a3e4d2f01fb9d44a9aefd0fc4565111bb73d25417bc00e0f7969b5e9a0) }), id4: Honk.G1Point({ - x: uint256(0x278337c91d91a449c73c10793a10795296b2de9b3e056f6163dc2aff872a981a), - y: uint256(0x0a2a57f0c362c6953fd99229fa066e006084c4b53e2e3b1012b53a1b46e97e45) + x: uint256(0x0a53a26d1390a734dd02a7b004ef88102974600e3baa15ec2e461c79ff9b8ca2), + y: uint256(0x21c24911108ee0462b6033b27d7a6acf2c85cf766eaada84575d92e98c103446) }), lagrangeFirst: Honk.G1Point({ x: uint256(0x0000000000000000000000000000000000000000000000000000000000000001), diff --git a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol index 2c7d7767d0b2..0b42ce77bdf0 100644 --- a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a +// Verification Key Hash: 35075d72ebcadda27f270f249615b163ee9b368feb3e481a43da7d265d3882aa // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library Add2UltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a; + return 0x35075d72ebcadda27f270f249615b163ee9b368feb3e481a43da7d265d3882aa; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -26,14 +26,14 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x1a0), 0x2e4e3e272c7b78ad894559812d7766e05615a8f7050a43d7ed1367adf30a9319) // vk.Q_M.y mstore(add(_vk, 0x1c0), 0x1798c37010a4285e1774c1ad35779886380ee5ceee0ba183927e2a2103301a68) // vk.Q_C.x mstore(add(_vk, 0x1e0), 0x2935f9e4d47a8e39aa0107f31a84584b47d903cfeb9690f6d850dc8ea7d2f4ea) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x205aff7186f2cedc99e9cadb7930ef25f296991e5a7b574a33d6249f0a5db1f9) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x0beadc757bee3a2be1f6425385547099fc1eeeb1fed5a8552b07e997251d7c45) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x2cbce7beee3076b78dace04943d69d0d9e28aa6d00e046852781a5f20816645c) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x2bc27ec2e1612ea284b08bcc55b6f2fd915d11bfedbdc0e59de09e5b28952080) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_AUX.y + mstore(add(_vk, 0x200), 0x098b323500f8c381b835917c5c1d37ed97bb714cfcd6d1c0c104542258027a43) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x204b44959b11e5893ed6100e102ee04d63a72bdd4c94490e01ecbbe72e32d853) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.Q_AUX.y mstore(add(_vk, 0x300), 0x01d8b8ff3b1674e57a7d30ce1d9e07c686174c643eb20d38e604eec7095248a9) // vk.SIGMA1.x mstore(add(_vk, 0x320), 0x261015d69327a58810e6eb1052ed694914b7a89034e1334c50b9e70a161489b7) // vk.SIGMA1.y mstore(add(_vk, 0x340), 0x1987df111730a8a6a650423757dbf048f3f43860a7d24a5e2e8bd67b6931ca67) // vk.SIGMA2.x @@ -50,8 +50,8 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x4a0), 0x0a5366266dd7b71a10b356030226a2de0cbf2edc8f085b16d73652b15eced8f5) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x136097d79e1b0ae373255e8760c49900a7588ec4d6809c90bb451005a3de3077) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x13dd7515ccac4095302d204f06f0bff2595d77bdf72e4acdb0b0b43969860d98) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x500), 0x0c40380c5013361cb7e57ed4591553791df4838037064da2b24cd3a7bd20b40e) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x0d86cca6e33b9d896c3ec46116eb0d80a5c849d10995938a71e4703090bc65f9) // vk.TABLE_TYPE.y mstore(add(_vk, 0x540), 0x1e44194e60f0ab4ee0f77adc50f4220944f94301aa6da3016a226de04de52f4c) // vk.ID1.x mstore(add(_vk, 0x560), 0x2a017d0d9f40d0aeb5c8152ffddec56c2c7bea37dfbd20be6bed19efd743397a) // vk.ID1.y mstore(add(_vk, 0x580), 0x0868357b28039385c5a5058b6d358ebb29f26f9890d6cc6401f4921d5884edca) // vk.ID2.x diff --git a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol index e5d1970c0e3a..13a1fbca74c0 100644 --- a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3 +// Verification Key Hash: 48e4d8be8860ebe4dfb033c9c425c0c8fde31ecaa5dec6e9c4f1d862cbc643d4 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library BlakeUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3; + return 0x48e4d8be8860ebe4dfb033c9c425c0c8fde31ecaa5dec6e9c4f1d862cbc643d4; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,52 +14,52 @@ library BlakeUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000004) // vk.num_inputs mstore(add(_vk, 0x40), 0x2d1ba66f5941dc91017171fa69ec2bd0022a2a2d4115a009a93458fd4e26ecfb) // vk.work_root mstore(add(_vk, 0x60), 0x3063edaa444bddc677fcd515f614555a777997e0a9287d1e62bf6dd004d82001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x260b63c5c404eba05c531b64a63c4f8752eb48b02d8d53910bbc22e7648b672b) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x0a84e4198292ba82e9ec6e130ebf86ff8513b8133501e8b7c625c322451cc17a) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x066bf08a2edd0ed02a5b2b4c72f512585b1816d943d06f4822219d37d28b88f7) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x18e0525744e594592f2ba6832df668c1424c920ebf1e2ec358558075df1fc906) // vk.Q2.y - mstore(add(_vk, 0x100), 0x25880f31af07e4d48de7be715bc3b63495b1ce16c3ce6233ad5ba832cf3330a5) // vk.Q3.x - mstore(add(_vk, 0x120), 0x190ab6675593f90dc404518e02369c97f0d736010033237073dfc5611cb4e0cc) // vk.Q3.y - mstore(add(_vk, 0x140), 0x1afd5ebe896054ba2812a94f5903a17aa5de0ffc7f1915259b4d9e01a24ceb44) // vk.Q4.x - mstore(add(_vk, 0x160), 0x03b445d3e75bd9ecf05703d2301157ccb3795adf7ddb3c0d03cbcc691772288e) // vk.Q4.y - mstore(add(_vk, 0x180), 0x00f612887aad4e61796d7948533fff40184bd1d00ba52e9201fea5b9b5a8258a) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x25bd9c5fec68e480ccf127be8b4bf7810c737a38f4d6a4379b3817d4d157a3f5) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x27e6361916a9c2a4f81501df8f6588c394f7ba0010e565fe9162e1456acb64fe) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x232d6f8f7582fc930a95c1d97e1cbe471935642ef95ac1457f953b92601a7f36) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x1344134626051322a90942b7cbd3a98227e7e192c8597604dea27f5eb49a1332) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x2c4782c37eb3e19589fc42e465f89cb3dd47ddcfce1a3a5f7e0e6423e9290f53) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x2ea84c6aebfa0d7b78e6f8344086d9a4ceabf599cdc3c8b8efaf937f78fa89f8) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x00fc4dc0688832477ed1b999b886307775590a5155ccfbe5e4a686cab3684fd9) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x21959276775cd4749236c8bf773a9b2403cecb45fbf70e6439f73d75442e8850) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x017714509f01d1a9ee7ebaf4d50745e33a14150b4fe9850a27e44de56d88cb14) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x16a04bedbbced0858d1cb768d5dee65d7a9e5eda5840f041a6b0c2d9a05a47e9) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x0f295c2f65406bd8aa6844f7a8c797da1ec69b048441e5926a0d11e515056af4) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x219f3919df06c1843bdcf405c9c6304c9affb6b5b075e25d9213cb9ca4177ad8) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x2a5acc53d574ddef7c44bc0d578d9371cecc89ab42a4b0bc6017eaecc68ebeb0) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x270efbcff761d452b5a3024f5a1b13b2108bfd126610f7c6580acfc8a3eadc43) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x052330edc9afc72fdaa4d7c5df4617631634c46a7132ece7ec56286647f66a77) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x1a07bea503dbfd8375d3cd35b79187516326c0a96af71418b8004e863d2126d7) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x1601a5ddea012bc53cf9633d99e704caa30b017e3e81e935a8d791030be559c3) // vk.SIGMA4.y - mstore(add(_vk, 0x400), 0x06c5d3c2a64587cf9dc278c6892854fc8f1aba4183115224cb2eda4c1aab64b8) // vk.TABLE1.x - mstore(add(_vk, 0x420), 0x132622df9222e04fa9c4cf2895212a49556038d4fdc6d0d7a15b1067bb446efa) // vk.TABLE1.y - mstore(add(_vk, 0x440), 0x2dbc1ac72b2f0c530b3bdbef307395e6059f82ce9f3beea34ff6c3a04ca112bc) // vk.TABLE2.x - mstore(add(_vk, 0x460), 0x23e9676a2c36926b3e10b1102f06aa3a9828d1422ae9e6ea77203025cd18ada0) // vk.TABLE2.y - mstore(add(_vk, 0x480), 0x298b6eb4baf5c75d4542a2089226886cc3ef984af332cae76356af6da70820fe) // vk.TABLE3.x - mstore(add(_vk, 0x4a0), 0x1bb16a4d3b60d47e572e02fac8bf861df5ba5f96942054e0896c7d4d602dc5c7) // vk.TABLE3.y - mstore(add(_vk, 0x4c0), 0x1f5976fc145f0524228ca90c221a21228ff9be92d487b56890a39c3bc0d22bf2) // vk.TABLE4.x - mstore(add(_vk, 0x4e0), 0x0f43d83a0d9eb36476e05c8d1280df98ec46ce93ae238597a687a4937ebec6cc) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x239c09880dcbafee7caf9fb8460d1ca62e86b42b8724e350f01a12ddd4f08add) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x14dd9f4bba78075eb5bdb7d401281b01d9e88f8827fab15f6b718bfed5b6a598) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x0059fbc7f6f474f8a602db54e7aeb9b7072081bfb31d4831562003e8c5804177) // vk.ID1.x - mstore(add(_vk, 0x560), 0x01e2a561adf9c7843fd4e9acab18137656dbef06f22c9d2f05a68eae8576bd6b) // vk.ID1.y - mstore(add(_vk, 0x580), 0x205ed43983566317600b8324e02262240b23d6caa751e53360fe9410deb876b3) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x29ca9b6ba6da40ef21d62321d81594b449185bde9f071a3619731444a3cc30a2) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x0e633257c8c686bbe65fbf5792b8c944747838fd385d3b02eb7900dad50f6f4c) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x1bfda6b7d38472e9418a8eb55f4c1d372642b5819fde074d4fe62c29f843b566) // vk.ID3.y - mstore(add(_vk, 0x600), 0x1dab0d03d72afa6328933a39b05c764bc713f67606fa016ebf532deb2b4bc105) // vk.ID4.x - mstore(add(_vk, 0x620), 0x24bef3bbfed9cfcedabed6d61d289ae44ce360aa38fd022886fd22bc75fd5980) // vk.ID4.y + mstore(add(_vk, 0x80), 0x22703f0804e127ca3a084222bea6ea437cfbb6f2bef6581817eeb6be4b83a6bf) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x2854b842cd7bf05afeb768c5f8e95b7b51fc42334c2e370f94b7e06b0e8a6faa) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x01b9ab9db48dcf1490197b002f8306f6400058fd707b912117fbf9defafaed38) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x159c02920661db84558f3ff397de7280e05c4032c338a0317bd6a36a5867d460) // vk.Q2.y + mstore(add(_vk, 0x100), 0x0c7bcbd9b06018c903394f7be92205dc28fade0e0b01789a26efa2d37068dfea) // vk.Q3.x + mstore(add(_vk, 0x120), 0x286bb4e38192fdf477cad8748e582982284bf46b17cb9101cfcd65180d8dd384) // vk.Q3.y + mstore(add(_vk, 0x140), 0x1445e7776943b45e9fade0e56f63665277911d10748b7d5aec6e51730d49b6ed) // vk.Q4.x + mstore(add(_vk, 0x160), 0x21470dba7fa9b659baf7691e03a896767ea29659154ccf758ff92727412a126c) // vk.Q4.y + mstore(add(_vk, 0x180), 0x1d8d78c44e9d05815dc4d85c0b9467f6a6b0c8959c1ad41c6aa30aeff9459626) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x22cd2d1ef4401b091c64a3bb10aa81f4c40ae66cdcfee409677f37b9276227e6) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x1a8d3d1c3a2c6382e522560c184f1dd2fc1ff8ec9eafdb8dd04037c3d862e5dd) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x2bc490fc2cbe9fdf87ce2e4404144a938577b4f059c2496c93f51b73fc825292) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x181f212f403b221c0805d11a8998bbf41ef81409ee3a019ae7775f39d692cee2) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x18bb52801779b80fbdb803cbb416bdfb20a286f62e43006c5f4bb430c0e0bbc2) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x00a76d339bdc6e030de531fc51322f06e35e0db2c71d02705cbc87497c1dcc86) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x12435124c05dc87a5aa6a57b7c213c0a3653f8cfe92a568a50d1e580ae73936d) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x254c7c79f29e6f05184889d52a7c01375832d53ea8dd60b93162a5805d715657) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x23558713233600d8847c983db3c2771210aad83fc39e33f4821c4b483fe579c1) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x1b1751d2a40ad3926fc75524b92f198668630bcc50f9d9bca991b5a46400f301) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x011ab25916819ad44ab3b3a735ecc9f0bf837e600467017a3cb12c40842b57ef) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x1a0d27d21e4c23edee9346716d3f495951d1741f43da4871bd2674dfde8178bd) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x1dee5edf353bbeebde3c56137bf81e4bdccf1ae09c842a0ed85f17fd709daf53) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x2be8b6566855f9d4b42835780532cb76621459237d20536e0eb3bf76dadcd2c3) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x0188ecfe49edb152eff1ac0e4ce3747797a6cc2ec33ec7f253c563adda84a824) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x0dde6de09527d57a1b0d10f8390d3bc64db03719756733354638dd261ba22b16) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x159c9f851883d75654853022db92c0df214854759c6e19f03f6fd5f6869b8d18) // vk.SIGMA4.y + mstore(add(_vk, 0x400), 0x2c9323a1f1a4497d7a2da4e7f051ae2bd3e79fa5129b9e839ed92e2724fa4dd4) // vk.TABLE1.x + mstore(add(_vk, 0x420), 0x1da5adafa0b2e605fae3a5b5f38f5320452c443e0cdbb9146847b621c6582595) // vk.TABLE1.y + mstore(add(_vk, 0x440), 0x049ad18a8303ae13fc27eb803bd1e4ab0843d7ea0c8da3e9de4069d7d124c35d) // vk.TABLE2.x + mstore(add(_vk, 0x460), 0x208d3a7f02e894bea3809a5a03f4d93fc4ffd3012ba21d785ebf6e29c79f84eb) // vk.TABLE2.y + mstore(add(_vk, 0x480), 0x008d6cbc3467442b0c8cfecb879705164b1a375d5b692c1a19968ad14ced51f1) // vk.TABLE3.x + mstore(add(_vk, 0x4a0), 0x01a4630460cf19d3744f57323ed8e95c711b1f35dc4be35136105afb64bca1be) // vk.TABLE3.y + mstore(add(_vk, 0x4c0), 0x2a32902c477f3c4e5d636886d58e6e92787d6835719aff2124de11661a931e5f) // vk.TABLE4.x + mstore(add(_vk, 0x4e0), 0x02bd52e022a279775cc203ef117ff464ce803b128e12d7d9e4906527ccc0d179) // vk.TABLE4.y + mstore(add(_vk, 0x500), 0x002158853758e7f671a63197c33f09025895ec819f33a69942ce3ad3874792c5) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x2c56d9309c085c8e74d2252c50dff9c735589e431073c699d16663c010c27f12) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x18f0be507e453236eecc41e29ba9e575027f2a22dc508ce0be79701ab0760328) // vk.ID1.x + mstore(add(_vk, 0x560), 0x2cc55fb77d81238a9659604ecbf38c322c3e93a25716b44e08877583c99eb52f) // vk.ID1.y + mstore(add(_vk, 0x580), 0x02fe9855b35527cf14bfeaba70ee83ff36db3ef35a549677ceb95076cf95f0b4) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x2987a64728505b1ec90f04ecf38b0f3bf18dbd50d379c686fe35ac2005932343) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x0559edf459c36c8579d3448de7897258db197c8e3e69e8d9cdc5ee13adeb1b06) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x27ee1775cd9f7a365f2f5d76aa37dd4f197ee8a90a846efddd84f0a255ddebed) // vk.ID3.y + mstore(add(_vk, 0x600), 0x0fa8737adffd19981969fe6891f2cf783a63277dd469a8f64805510c78f1ebbb) // vk.ID4.x + mstore(add(_vk, 0x620), 0x1d02caa8a2bc3aa1e96a61fcbe75298b9e365402cff9188cf942c3393331e1a8) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol index 7f65f07afa57..e2cbc907bc60 100644 --- a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105 +// Verification Key Hash: 04925e4f94fd295a931d988e6fd9ef882b3dbd4df75d762be3183c66bfefa055 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library EcdsaUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105; + return 0x04925e4f94fd295a931d988e6fd9ef882b3dbd4df75d762be3183c66bfefa055; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,52 +14,52 @@ library EcdsaUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000006) // vk.num_inputs mstore(add(_vk, 0x40), 0x00eeb2cb5981ed45649abebde081dcff16c8601de4347e7dd1628ba2daac43b7) // vk.work_root mstore(add(_vk, 0x60), 0x30641e0e92bebef818268d663bcad6dbcfd6c0149170f6d7d350b1b1fa6c1001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x1cc85a07fb1009e23540957b29121dc57aaae5b1e89a22a932a1bdf7ccac1af2) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x19a1a4fa6d8781abbcb696097c1817f54da296348a292954e2aa9856f2fa3b6a) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x0409f05fe2901e7e339b3aaf0d7af7b5d4023e416da923321b15aae633b18fee) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x0ae6cc44e9024c190ab310d7ad110226c5c76f15d158b60fc9acd98f2e1f1aa3) // vk.Q2.y - mstore(add(_vk, 0x100), 0x20e3b4e35df25ba02ac2a9be26bc6fe74640355e57455598e69922b8d3fd0939) // vk.Q3.x - mstore(add(_vk, 0x120), 0x1f49d18bdb86a449e676558c6d6349f123372641187e33e12128ee7468431942) // vk.Q3.y - mstore(add(_vk, 0x140), 0x00e95627d4db555ccf3b1ee6def34fab1a815f0482cb6a745a363940d3163831) // vk.Q4.x - mstore(add(_vk, 0x160), 0x19fe011a8a139da323b5ce5abebe54bf4c105acd6045d7b2b5df40a34411f44b) // vk.Q4.y - mstore(add(_vk, 0x180), 0x04b41648960da31317eff66b5ca9be0a6c81ebeead27e70b3c5b28d4aba11081) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x1bff2df21a3fd9c49c29b7f7c153dd0bc331d75afc6a35fb7155c17bb0f67a63) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x15faa2ea86a6a66cd9b969d6305f863595a73b9215c1ae442969f4993a8e5230) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x26391cc92544b485d90313d3396b53d9207db8f84ead11bcf45467fa7eb38b94) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x01a0d650b65d29965e4ae2a8cfb69470d7560f0826268da59c6e72e684a06c9b) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x2248d4a02e68036c8d0a4a6725ba0e5e8e95950a5285a3a7daa1a1726cc8ec6b) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x01afcbad715a0c382971311ad6fe4ff8b6e99200162aeb6245b585c99c8748a9) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x18bf352081d1ba2ffe8088d34ce6471e4cf6d2ee63f006ea9a5e31cc41b6587c) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x21245d6c0a4d2ff12b21a825f39f30e8f8cf9b259448d111183e975828539576) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x16a409532c8a1693536e93b6ce9920bfc2e6796e8dfe404675a0cdf6ee77ee7a) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x2d455f287e41544fd3744bab412640fd6916b01aa2163c84071eb47f0306a473) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x09dea8e2b5e382a1c4a37bc4e60f5e8380688310b855c249d64153478d25e223) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x09671927e293b22a3fb9fa8ea1680fcc4570bb2f312cb88004ff7fd4474e2109) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x1c6442d9a49b3b93a928ef6ba2f348bc4c8cb778a59345faf7d173129f22b5a3) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x0337d84b45a5abc701edbdc1a1d878178c23496b39ccddcc3f0f6199e3f97df6) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x1c744f7be93d40c96d15fdf9d81c9502b7018573ad23e51dea7b065fdeb6f13a) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x23a975cfb71f0c0d46ef9c0b01e6482e780b5e3af1a63547f7d01c46c1911699) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x0d5a0be212cb2c7d3bba8c2406a9d2c4b04d4e64b0acef2681eb7c6aa490a7cb) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x1ca2d0cca80bb16eab28d06c5c175e862a8ef14bceb6da79e65236a8a6a36838) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x0555fe3dbd2ba2d7db2b5f740bf32fb57f4c5ac9d9f2e59e9a5a2cc2d84dae05) // vk.SIGMA4.y - mstore(add(_vk, 0x400), 0x18f7cf965339d9c9d190296fa92f915767b0a8da455975f3e03fa98439fd7110) // vk.TABLE1.x - mstore(add(_vk, 0x420), 0x0eecc02f9d44125407adbf00d56b086afd1adc5de536450afe05de382761b32f) // vk.TABLE1.y - mstore(add(_vk, 0x440), 0x0bdfe662ea9f40f125ca5f7e99a8c6ba09b87ba8313864316745df862946c5c4) // vk.TABLE2.x - mstore(add(_vk, 0x460), 0x0c5313c5b17634332920f54081fd46464a5ce9399e507c8fece9df28bff19033) // vk.TABLE2.y - mstore(add(_vk, 0x480), 0x232ab86409f60c50fd5f04e879fbcbe60e358eb0337c5d0db1934277e1d8b1f2) // vk.TABLE3.x - mstore(add(_vk, 0x4a0), 0x1fda66dfb58273345f2471dff55c51b6856241460272e64b4cc67cde65231e89) // vk.TABLE3.y - mstore(add(_vk, 0x4c0), 0x024ccc0fcff3b515cdc97dde2fae5c516bf3c97207891801707142af02538a83) // vk.TABLE4.x - mstore(add(_vk, 0x4e0), 0x27827250d02b7b67d084bfc52b26c722f33f75ae5098c109573bfe92b782e559) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x22b1d6b9827d6d03049f76dc9dc219ae6de93abe52d4d7de8677d961d3408c77) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x10ebc6be9f74e0367276028c613ab3efe0f2ed546c05339b36d5165d009c833a) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x2aa2e5247ce6524fecba0a2de9f383353096665f3ae8082fe7017fbf6d6572d8) // vk.ID1.x - mstore(add(_vk, 0x560), 0x1db802f61a6194bea68f7d5ec697facf26f1c1336b09e382801e8b773f0e116f) // vk.ID1.y - mstore(add(_vk, 0x580), 0x1aa955e508f3c2fbf55a36719eb666a45239935c4af10b8a1f4580d5cd614236) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x2bc21aa51420951a10a39d5c5242101d2207c47a0077852acb7d3fd6a16e1c58) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x245c89c4cf7c7e297b4db8e2625f5abd56398c351256a39aece0a36a940aaf62) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x01bd6e61d801d895c7edfee071518761f3c8c0e10bec5f0fb0b25ae430a2c91e) // vk.ID3.y - mstore(add(_vk, 0x600), 0x30223d4653291c03019e96bd716769c7c6d6520fddf2e633a75f94b08bee86dd) // vk.ID4.x - mstore(add(_vk, 0x620), 0x2e389428afa291855039f1b4af22e70d469f4e20116b85889737d624a2d27fef) // vk.ID4.y + mstore(add(_vk, 0x80), 0x0d03a55e1c08f638bec6b3b6726ec4e8b4a2445fb898001c5cc59d90747265e1) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x28f5aaa22aae66726d58d5e1dd57733badd7577f842cafbef590b563688d3057) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x28e3095ae72fd2889ead6c3a95cf8592392c1d3546222ff15638ba280c161f31) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x27cda145ab9d0a13dae8bcab74ad6901f656c76ba1605d068a005dc4efd14ea9) // vk.Q2.y + mstore(add(_vk, 0x100), 0x29e0d8172946a5fdd2998f57cf3814ee55393d265a7f0bd4765687fe0aa72181) // vk.Q3.x + mstore(add(_vk, 0x120), 0x21d649dcdd6a1182f4ba7b2a42e26992774cb9743d6520defe56c582d6b8d7f0) // vk.Q3.y + mstore(add(_vk, 0x140), 0x2839198a3ce970ca0a0fafe33d2ca8ffe50d70be7e613eb710c08ca95115998e) // vk.Q4.x + mstore(add(_vk, 0x160), 0x0da0e1c3eb107528a589868e34ae65114de290ddd45ff23fc5f637c0da23c1a2) // vk.Q4.y + mstore(add(_vk, 0x180), 0x303ab526aeb8130ef858a97def955fd10c9b528ab3667415b8bfe279e507186d) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x1db1e82067093af3ba5cd78460f538b9d84c45bca6b3f6731d1072def1f031b6) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x24cc5a478a5ffd79cba3cbb6d2db878fc339abe56a63440384afb38ee0e95731) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x1e540a5249a2d3e326b0c9be362173e6a734afa900bac9859310ca018328e66a) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x13db96945a09894dddfa79d2b9f9e9e1eb6204065f662a17d7dbf6d257590d33) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x00d9af8f917935b1836f17dcdf1d44a1fa4e3655777f8ddca39905b38b80ab48) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x1a66842ed11152b8ccd1ffe548414be7dadbb956ae828c47cb32c449fb9a2a21) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x0b4304dfa9379f11f9387befd9522dde481e04d359a511e543b9c9fcfd4c8e70) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x2f213c7a4c064a63d6a07366df0ea85aef9ad2125a188c3e656f95471e416a0a) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x067a270bed55e72ffb3cfa39af3e5b8bcb4961d72bb301978af13c4ddc73e5df) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x27b10524a99f00d9c59cc15ff3b7dfc34975b6f18e06b9c6c3a6136bf3b56f32) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x071a9bf80d112c32482178ff02f855436cf6fb4b4376ef7e2f03381c2e6da379) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x11f8a90324450819709f17508ffaf140d17a949487af44e2f169c7371343411b) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x18db987ab3b02b830aace8661d0012170892e6b8f234d844f981e0c5b3e6e7c0) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x2df70bc7a4644eea4a21ff8e974eb3d624e311bc148b316fe25cd9486e9540ed) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x23e182a4495ff2abe1295260edaa7f3a205d8e4de69f783c7c66c0ba9859917b) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x10e03c5fc02493f4b37a58bfee7c6fa50bb3977477279a3f7623668e35305f75) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x2b2bc0c7955e6b99f93a62e2e1955a76d4bff3795985e9e70d64497052a93024) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x0c68404f1fb46097dfc1deabcaece7a47112489fd3cba333fd4ba985a4291b2d) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x186dd99ca6e71d8e125f30ea6c9d4093cc7bb4149fc9c50490618a0fc92ee7a3) // vk.SIGMA4.y + mstore(add(_vk, 0x400), 0x1a55dc1a642e0833b27de2085de8a8bf1e54f3409fdf6d955eec6bf73ba3c93e) // vk.TABLE1.x + mstore(add(_vk, 0x420), 0x2bdf5828e5a0e064d777710204eec800295f987905043ac054acbc038ba0d0dd) // vk.TABLE1.y + mstore(add(_vk, 0x440), 0x03a621c8d74670ed1b06ddb06644a04b11e4d77148be631c5a1daba27625ec83) // vk.TABLE2.x + mstore(add(_vk, 0x460), 0x2b9287b3d040871b3f97a6b1f33024317ac9f86adfe80f75f27296b36bd333c4) // vk.TABLE2.y + mstore(add(_vk, 0x480), 0x1c233efa3cbfff821f0fe636f12451241dbee781de362da405cd2b08e06ac820) // vk.TABLE3.x + mstore(add(_vk, 0x4a0), 0x238cdd74317e34461f06d04474eaa3b08fbeaf42bebad8402b51f00c892df46f) // vk.TABLE3.y + mstore(add(_vk, 0x4c0), 0x08aa2e3e45c14179616cc69685e1bd257ce49503b425e0bdbf4010c7be859fbc) // vk.TABLE4.x + mstore(add(_vk, 0x4e0), 0x2fd83c0e339172d2315a24dfd4aad276e5e860f3849b111b62723febdb3ee286) // vk.TABLE4.y + mstore(add(_vk, 0x500), 0x171e700abccc3b9764a2d27e09b3208941a0b8ac7299c2580e6b24d56b6139a7) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x151a058305194c4e68972296ddda0fd23359c1aaeb864bf8e273bbd6405b9718) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x0b6d6d86b0a3e81f2f146f798e63d0ee99e4594fbd0a826910461ccae434bfd3) // vk.ID1.x + mstore(add(_vk, 0x560), 0x0f4bc8f33eb6afed895ab21c4c5c80c741b7565607280ec2fe4c4f2e70ea6e6e) // vk.ID1.y + mstore(add(_vk, 0x580), 0x03c52afd7bf4066c19ef0b9c4bbd5cd3edbeebcd8cfb9de47b3199c4888fdc31) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x20923fb0fd3790a6e995640b803825c0dec8bc7da64203e55c69b26efee636bd) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x2cbc9f464c22cdc38a834fdb3810d0e8d4d927dbcf55cdfee347895e838f5e03) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x23e178dd197bd1ea0db8b76d597fb7bc5a7ae675b1496b7ccaff0722489795c4) // vk.ID3.y + mstore(add(_vk, 0x600), 0x124c5ef3a8d659717f89077b3f814fe4a575ad77acce9953af915a64569e94a5) // vk.ID4.x + mstore(add(_vk, 0x620), 0x04733238e5caa04c7cd0d154988171f8ac3e492ef48ada642007220a4fdc4703) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol index 45d50fe15dd2..67fb9125aa42 100644 --- a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: a52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9 +// Verification Key Hash: adf7fcbdc3ab90920764d05aac762984b6f80e3dbc9cfdcef33d5d400525eb24 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library RecursiveUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0xa52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9; + return 0xadf7fcbdc3ab90920764d05aac762984b6f80e3dbc9cfdcef33d5d400525eb24; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,52 +14,52 @@ library RecursiveUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000010) // vk.num_inputs mstore(add(_vk, 0x40), 0x2260e724844bca5251829353968e4915305258418357473a5c1d597f613f6cbd) // vk.work_root mstore(add(_vk, 0x60), 0x3064486657634403844b0eac78ca882cfd284341fcb0615a15cfcd17b14d8201) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x05104b486160545badec11f151e7c70b87050871da5653387ab4ab2ad0eef5ca) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x2672c7fb298fce83f510eb6e1b851a5bb2daf8fc43c7771e96c56c8a09ddfeae) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x2c019acf99c5663da83cec224bd32570ee90f45c4486a54dec3ca4552d8ab07a) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x0fb7a3385ab42cafb0e104ac17ac2dacfb161d292c00fca102b1e780e86ccaf3) // vk.Q2.y - mstore(add(_vk, 0x100), 0x273ca9c29ef10864f4c9c053c336776a71ca5ebbf4bec1cb381e431943f9b5d7) // vk.Q3.x - mstore(add(_vk, 0x120), 0x2a94f00fe384ab945a8f5e3c97194a425a4d2109e5b113f059e42ee232659436) // vk.Q3.y - mstore(add(_vk, 0x140), 0x0e8b5c127c8a3ec285c2ac80d9046528051387878802203988a60650a0a960ab) // vk.Q4.x - mstore(add(_vk, 0x160), 0x17efdb659ae0d26aa78db132f9be9130460c0fce0c2a8e9b726de68247f76891) // vk.Q4.y - mstore(add(_vk, 0x180), 0x2f668d8a50bdb5c366e39433892f903262a04b6473ba3468c12057d58ad3bbfb) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x2397c6171bc6d084e98297690441c9da9f011d18b3ea0bb58ee4d47227feb6b4) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x1dafbfb4d30fcf880ef839ecc7fda9a97c315c5fa1713d08f7cdf6dba53ffb17) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x099fa3de9ce0cc28085739745582b53bf7939e3d97928afd491392053c1c0a68) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x028912be5d0accd4edf4949f89be1c1a2fcf4f59559ba03114da00ec3bf643ac) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x2428952bfba8ba44830fb0ae6fcdeb9bf17d611add9432450ebbe3d928e2f431) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x2b40c900824bcca193d402e0ef7f78792deaccd99743a78e5330abe8886ac989) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x102a7a02bc1a7317702c09560636e991b856f26f88ee8f0b33da3dd7fe222dbb) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x2bcf00433471db2be265df28ba2e70c36ca52f2932a4de25c0d60868703a0726) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x2f225b86590c67ae48360cb41d5b291ba94ce2dbae850afd9a6854122341b5ba) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x2eaee34d8508092cc4e19bc3f27ffa7dfc72230710e220f228f48906fae21e56) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x0c503c5d6245b99bbc056925e96abd20feaed6507707311092b3ed87eadb3874) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x021ba851cec3aedfbf1d9944907ae721f0d3e8fa3548513b6f108d101067ae85) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x24eef378da346c4f9eededc5dc519d35b14fec46412c8fcf7564cafb9843d761) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x0492b2fed8a158177dd3e825fb34ca7481bfead06bc01f308dc81fcd852ef3bc) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x289bf1bcc6a9cb19b102c7fb9dba839e1817a24257194cad404b393ce77e66b5) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x05d2a9c66d5c142b254b4f7d09f0eb837d95d8ec002e0644f51d455041403ca5) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x2434b76f470965c85363ff15b3f37c7b4be4fb2741451dc33943879f1e4cbba4) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x2f4bcc93500665a87a8f959e1636fe88cb1f17688b8c286fe930ccf934a49ac2) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x243f7b4ae1d483c99523b6a2999f404ab744017c8f43080c3582c38ea8ea3d1a) // vk.SIGMA4.y - mstore(add(_vk, 0x400), 0x0ddc3b6d8e59cf0996ca71ad4132ca9d618ffd933cf58a8a0953dc76f97cf108) // vk.TABLE1.x - mstore(add(_vk, 0x420), 0x153193287060386695f4f2d0d3525dec4c6a253f431d3f3fc06aa0e5b0448b8c) // vk.TABLE1.y - mstore(add(_vk, 0x440), 0x1170f0ece62f8c572bca96b141d27f4bd25585edb9319128045c005d48491b1e) // vk.TABLE2.x - mstore(add(_vk, 0x460), 0x246cd041690f653f88ed0c56ad282a3dd2e37b8edb1f56b785809d7710bf1c88) // vk.TABLE2.y - mstore(add(_vk, 0x480), 0x26153c937447356a0c6d6be09d85eb34bc8a00ce9d452888e5fc2b5a7e14fed7) // vk.TABLE3.x - mstore(add(_vk, 0x4a0), 0x189da022421fbd8dfd7973084d978e555388ad9364679246b07992f84b4e91b2) // vk.TABLE3.y - mstore(add(_vk, 0x4c0), 0x285311c5e9a4cbb56a3f04f29d5443e8c0f9753e2a5a35acec051fafe2cecce5) // vk.TABLE4.x - mstore(add(_vk, 0x4e0), 0x2436400260c9d3180beedd0bf49fec92d2d0ac76a1be7f1fad96cbd997175312) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x139bb66456d96a4e2dad361f7949a6b8c6739650965ae729788162fbb0382399) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x098fad1329e1765863f8ac829332168359901da71702e5119ce4b89a7ae6f017) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x14fc4c6c2521387172a6b801e2b6c8a2308d725695d3f49a57151c2a0a8af0fe) // vk.ID1.x - mstore(add(_vk, 0x560), 0x2ce0c2c73ded7bcf19c1208f134b67ed74f77ef717db1c05c010bc8df7bed39e) // vk.ID1.y - mstore(add(_vk, 0x580), 0x0e2455a361f4a3741dab6a03b8186996a5a9873a3b62b3fa8eb5a551cb46bb7a) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x29a288b84aeabb0421861492256c6ea82530b5b14c0e01e5b7b2553cf197a2e7) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x01fbecd3bc90ad298a27bf4f9aa071746c30b5af932a1ba8d5b04394f85e0370) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x0b21c924fc2b44729ff84deeae724c68dd1636e847b0f7cdd92ad203af7cf0d5) // vk.ID3.y - mstore(add(_vk, 0x600), 0x12f7ebb5e50b429b766b1dc5e8b32b7727593641e4f976b72a7046d0a3ff8dea) // vk.ID4.x - mstore(add(_vk, 0x620), 0x2d45226edb0f8338bb5fa88ecefeeaa9bbb72232a2e842f8c7f37cd11f7065ed) // vk.ID4.y + mstore(add(_vk, 0x80), 0x272fae13335cda7794aeee75c0d41e52cc626b07106135805edc8538ab41f6e8) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x266e1501fe1a3d602bbfb1bd408ac9b329686552d0578d8fa1a7d37444632eed) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x24800dd2d472844c3afd10284239c30707c9eb16192a65ab28eb79f59aff2943) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x2ae2c84daa90e63075555a436f030a9d8ae62780ec3b2a5f568627a214e53994) // vk.Q2.y + mstore(add(_vk, 0x100), 0x1226970a5f06cfb38da166d6004e3d512ed6728a51f937b3073fcb396aa7372e) // vk.Q3.x + mstore(add(_vk, 0x120), 0x0769098bf5dc607b7d6cd29a9b97db48f7703294d84754e48d1bc677c8c1f979) // vk.Q3.y + mstore(add(_vk, 0x140), 0x1b5ece1f2b6578612eca0fbc1f45742c440ee5246070152406d8ab66d2fe82c2) // vk.Q4.x + mstore(add(_vk, 0x160), 0x25669e07536131b086ce8a414333b5ab214fea376e52fca87ed9ac7c4d26cbbc) // vk.Q4.y + mstore(add(_vk, 0x180), 0x013c1867e784bae04da012ee7d227e0f920b31dae793d5da38ae999b4622c4a8) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x1ca9e804bffcd6403981d319a74f67c17c267e9ce077434d46b8cbadb2cb6748) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x30447104bc7eaf34835557b8412d1220076eec127c7277d7d144d05ee10a4c82) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x0990dafa12cf826c986537955e488e025f11674b56dd87e543f532d80b529b75) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x1ae04aa3fc4f2ee6afa525cbd6502819eb3e7572b59363323cc978af71eeb25b) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x3031230737a7dad62b9fd25b9b9eb2a8f386bcbb2bde2f67e678dfd718deef7b) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x070799795a4b36746d6bac7b3248a9f80dd83ae93c1d1108b621f869b78542ff) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x2acc6c19c519877bdf4f8f759b8f5c82dc6ff3790445120840418f782fe458d4) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x21f55b7e9b4c5cbf21301019074c0a0eab41c8e637f8787e72f9f745c6979b3c) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x02e336c35d840241a188ffc7ad2c687f16ddd91356e9db9cc470af08db1ef180) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x00b7eec617e68065a1071a17d8e92cf99add525ec3fc6f5823c3907c4ffd99f0) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x2d9f0066732a3c01f1cd02f728f0a812dc501e14cf04cfeaffc21c1a3022b33e) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x20fa82863a6691e5e1d8b2b76fc7ea07fa5a91e81c313034a0baf1c059f16ed8) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x0b293e34397d00906293da08044b03d3923213ecb97932f1a7b693d7be591d26) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x09c74bb84de88d366afe6926889f5e60c6405fa393dbf3e65ac0405b8dc09162) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x235f8afe67a54eeb1b507a933e8f6602a18722258f69b811d5f10d2bdc67e40a) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x24d36ac3e040bba91e88393b6d87b98bd839aa4e72c4fe82f151a547220cdb87) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x2e19a2cf0df47c94ea8f443eaf781ab325a3a31f53c2cd47158b96cab77b4c26) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x299b063fd348d02720572abe377ec7267d5317a37201c1f9b79c8c6ee8597b97) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x04dd6ccd06bf4c458c06f0a839a703c76bf2c809a2b2df3f37227e2e345a47fc) // vk.SIGMA4.y + mstore(add(_vk, 0x400), 0x11c514df4405308bdface3553201db9535ce40f1cceb593355737a2c0e1809c4) // vk.TABLE1.x + mstore(add(_vk, 0x420), 0x23730ae1d6b51c53e9f341638ad156f217277de48f9cc50a19f4399a50e7c9b1) // vk.TABLE1.y + mstore(add(_vk, 0x440), 0x14a7d7dd7a61a9fee9df1579e5c7a497f363ef06b373eaeef19745008e808935) // vk.TABLE2.x + mstore(add(_vk, 0x460), 0x12b20d74592a31252375201ad5cfb6b91ada920288c6211aa61745cb1827142f) // vk.TABLE2.y + mstore(add(_vk, 0x480), 0x0de228c86fdaae2337277757704862abc3968ebcdf3c66a4b4fe0e1452b04cfe) // vk.TABLE3.x + mstore(add(_vk, 0x4a0), 0x2c01fc8d1605cdd5325bee69dd0a869cf94f6a48f0f322b16ac00dd1f58165d0) // vk.TABLE3.y + mstore(add(_vk, 0x4c0), 0x1b3600e51a06913d585471e94f198abe613a4b6194247a3233c7a26b6fdb5447) // vk.TABLE4.x + mstore(add(_vk, 0x4e0), 0x15eb45af241222240bc8446a0410ff960dd88b8d9720bc13e8eb57be89be891b) // vk.TABLE4.y + mstore(add(_vk, 0x500), 0x0221ee1e654253fcaa3ffdd7ccca0cce2c8c25bd391e4a6f26fe21f15853a06f) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x29c6259ed3ff4e54d067340ec91ec5185f741622fb2a0a5432f06777f6158fdb) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x2611a5db278d94912ccee81a829f45895a7444c2d084506d0d1f0ecdfccdc758) // vk.ID1.x + mstore(add(_vk, 0x560), 0x0134f8df4f1f8b8058266bb3f83b001810fd520577fbdbb738dae189be463b05) // vk.ID1.y + mstore(add(_vk, 0x580), 0x09cf92cea1bef8594f4c76cc9ef8a05b05310cce7863ad5fc25ceddfc70e3d31) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x2e1ffaf9dcceb1d647c48f30083ec38a2cf10f90c972762a552a939dbcd9a0be) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x0edaab035bd27f0f4b32aee13aa3177ddaabede322c351d0372a5d34eaa02bcb) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x17f7c240033409c394ae8c3b0fde30166e005566108852aec3b32206b96a68dc) // vk.ID3.y + mstore(add(_vk, 0x600), 0x1b032411cf6636fb43b3dfa8960a2aee106cea208de111f4d512cd88d640fe79) // vk.ID4.x + mstore(add(_vk, 0x620), 0x11e4ec47b80d1ee3c51058086e553098c2959807e0ec3365e848214a8cd4e05b) // vk.ID4.y mstore(add(_vk, 0x640), 0x01) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 From 6d76a8a865e2dd25bf4adef5bc9d4c2300485aa9 Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 17:43:11 +0000 Subject: [PATCH 16/18] revert changes to ultra keys --- .../ultra/keys/Add2UltraVerificationKey.sol | 24 ++--- .../ultra/keys/BlakeUltraVerificationKey.sol | 96 +++++++++---------- .../ultra/keys/EcdsaUltraVerificationKey.sol | 96 +++++++++---------- .../keys/RecursiveUltraVerificationKey.sol | 96 +++++++++---------- 4 files changed, 156 insertions(+), 156 deletions(-) diff --git a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol index 0b42ce77bdf0..2c7d7767d0b2 100644 --- a/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/Add2UltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 35075d72ebcadda27f270f249615b163ee9b368feb3e481a43da7d265d3882aa +// Verification Key Hash: 40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library Add2UltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x35075d72ebcadda27f270f249615b163ee9b368feb3e481a43da7d265d3882aa; + return 0x40bb22daf923fbfe17fb0be06e0fa50474e40302c1af031f1aaf5f521998ad3a; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -26,14 +26,14 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x1a0), 0x2e4e3e272c7b78ad894559812d7766e05615a8f7050a43d7ed1367adf30a9319) // vk.Q_M.y mstore(add(_vk, 0x1c0), 0x1798c37010a4285e1774c1ad35779886380ee5ceee0ba183927e2a2103301a68) // vk.Q_C.x mstore(add(_vk, 0x1e0), 0x2935f9e4d47a8e39aa0107f31a84584b47d903cfeb9690f6d850dc8ea7d2f4ea) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x098b323500f8c381b835917c5c1d37ed97bb714cfcd6d1c0c104542258027a43) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x204b44959b11e5893ed6100e102ee04d63a72bdd4c94490e01ecbbe72e32d853) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.Q_AUX.y + mstore(add(_vk, 0x200), 0x205aff7186f2cedc99e9cadb7930ef25f296991e5a7b574a33d6249f0a5db1f9) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x0beadc757bee3a2be1f6425385547099fc1eeeb1fed5a8552b07e997251d7c45) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x2cbce7beee3076b78dace04943d69d0d9e28aa6d00e046852781a5f20816645c) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x2bc27ec2e1612ea284b08bcc55b6f2fd915d11bfedbdc0e59de09e5b28952080) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x0ad34b5e8db72a5acf4427546c7294be6ed4f4d252a79059e505f9abc1bdf3ed) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x1e5b26790a26eb340217dd9ad28dbf90a049f42a3852acd45e6f521f24b4900e) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x155a0f51fec78c33ffceb7364d69d7ac27e570ae50bc180509764eb3fef94815) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x1c1c4720bed44a591d97cbc72b6e44b644999713a8d3c66e9054aa5726324c76) // vk.Q_AUX.y mstore(add(_vk, 0x300), 0x01d8b8ff3b1674e57a7d30ce1d9e07c686174c643eb20d38e604eec7095248a9) // vk.SIGMA1.x mstore(add(_vk, 0x320), 0x261015d69327a58810e6eb1052ed694914b7a89034e1334c50b9e70a161489b7) // vk.SIGMA1.y mstore(add(_vk, 0x340), 0x1987df111730a8a6a650423757dbf048f3f43860a7d24a5e2e8bd67b6931ca67) // vk.SIGMA2.x @@ -50,8 +50,8 @@ library Add2UltraVerificationKey { mstore(add(_vk, 0x4a0), 0x0a5366266dd7b71a10b356030226a2de0cbf2edc8f085b16d73652b15eced8f5) // vk.TABLE3.y mstore(add(_vk, 0x4c0), 0x136097d79e1b0ae373255e8760c49900a7588ec4d6809c90bb451005a3de3077) // vk.TABLE4.x mstore(add(_vk, 0x4e0), 0x13dd7515ccac4095302d204f06f0bff2595d77bdf72e4acdb0b0b43969860d98) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x0c40380c5013361cb7e57ed4591553791df4838037064da2b24cd3a7bd20b40e) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x0d86cca6e33b9d896c3ec46116eb0d80a5c849d10995938a71e4703090bc65f9) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x500), 0x16ff3501369121d410b445929239ba057fe211dad1b706e49a3b55920fac20ec) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x1e190987ebd9cf480f608b82134a00eb8007673c1ed10b834a695adf0068522a) // vk.TABLE_TYPE.y mstore(add(_vk, 0x540), 0x1e44194e60f0ab4ee0f77adc50f4220944f94301aa6da3016a226de04de52f4c) // vk.ID1.x mstore(add(_vk, 0x560), 0x2a017d0d9f40d0aeb5c8152ffddec56c2c7bea37dfbd20be6bed19efd743397a) // vk.ID1.y mstore(add(_vk, 0x580), 0x0868357b28039385c5a5058b6d358ebb29f26f9890d6cc6401f4921d5884edca) // vk.ID2.x diff --git a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol index 13a1fbca74c0..e5d1970c0e3a 100644 --- a/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/BlakeUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 48e4d8be8860ebe4dfb033c9c425c0c8fde31ecaa5dec6e9c4f1d862cbc643d4 +// Verification Key Hash: 3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library BlakeUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x48e4d8be8860ebe4dfb033c9c425c0c8fde31ecaa5dec6e9c4f1d862cbc643d4; + return 0x3963021515adf584e49a665edcbb8f92b252b66554a7a9f6b880ae6d76c013c3; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,52 +14,52 @@ library BlakeUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000004) // vk.num_inputs mstore(add(_vk, 0x40), 0x2d1ba66f5941dc91017171fa69ec2bd0022a2a2d4115a009a93458fd4e26ecfb) // vk.work_root mstore(add(_vk, 0x60), 0x3063edaa444bddc677fcd515f614555a777997e0a9287d1e62bf6dd004d82001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x22703f0804e127ca3a084222bea6ea437cfbb6f2bef6581817eeb6be4b83a6bf) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x2854b842cd7bf05afeb768c5f8e95b7b51fc42334c2e370f94b7e06b0e8a6faa) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x01b9ab9db48dcf1490197b002f8306f6400058fd707b912117fbf9defafaed38) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x159c02920661db84558f3ff397de7280e05c4032c338a0317bd6a36a5867d460) // vk.Q2.y - mstore(add(_vk, 0x100), 0x0c7bcbd9b06018c903394f7be92205dc28fade0e0b01789a26efa2d37068dfea) // vk.Q3.x - mstore(add(_vk, 0x120), 0x286bb4e38192fdf477cad8748e582982284bf46b17cb9101cfcd65180d8dd384) // vk.Q3.y - mstore(add(_vk, 0x140), 0x1445e7776943b45e9fade0e56f63665277911d10748b7d5aec6e51730d49b6ed) // vk.Q4.x - mstore(add(_vk, 0x160), 0x21470dba7fa9b659baf7691e03a896767ea29659154ccf758ff92727412a126c) // vk.Q4.y - mstore(add(_vk, 0x180), 0x1d8d78c44e9d05815dc4d85c0b9467f6a6b0c8959c1ad41c6aa30aeff9459626) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x22cd2d1ef4401b091c64a3bb10aa81f4c40ae66cdcfee409677f37b9276227e6) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x1a8d3d1c3a2c6382e522560c184f1dd2fc1ff8ec9eafdb8dd04037c3d862e5dd) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x2bc490fc2cbe9fdf87ce2e4404144a938577b4f059c2496c93f51b73fc825292) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x181f212f403b221c0805d11a8998bbf41ef81409ee3a019ae7775f39d692cee2) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x18bb52801779b80fbdb803cbb416bdfb20a286f62e43006c5f4bb430c0e0bbc2) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x00a76d339bdc6e030de531fc51322f06e35e0db2c71d02705cbc87497c1dcc86) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x12435124c05dc87a5aa6a57b7c213c0a3653f8cfe92a568a50d1e580ae73936d) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x254c7c79f29e6f05184889d52a7c01375832d53ea8dd60b93162a5805d715657) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x23558713233600d8847c983db3c2771210aad83fc39e33f4821c4b483fe579c1) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x1b1751d2a40ad3926fc75524b92f198668630bcc50f9d9bca991b5a46400f301) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x011ab25916819ad44ab3b3a735ecc9f0bf837e600467017a3cb12c40842b57ef) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x1a0d27d21e4c23edee9346716d3f495951d1741f43da4871bd2674dfde8178bd) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x1dee5edf353bbeebde3c56137bf81e4bdccf1ae09c842a0ed85f17fd709daf53) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x2be8b6566855f9d4b42835780532cb76621459237d20536e0eb3bf76dadcd2c3) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x0188ecfe49edb152eff1ac0e4ce3747797a6cc2ec33ec7f253c563adda84a824) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x0dde6de09527d57a1b0d10f8390d3bc64db03719756733354638dd261ba22b16) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x159c9f851883d75654853022db92c0df214854759c6e19f03f6fd5f6869b8d18) // vk.SIGMA4.y - mstore(add(_vk, 0x400), 0x2c9323a1f1a4497d7a2da4e7f051ae2bd3e79fa5129b9e839ed92e2724fa4dd4) // vk.TABLE1.x - mstore(add(_vk, 0x420), 0x1da5adafa0b2e605fae3a5b5f38f5320452c443e0cdbb9146847b621c6582595) // vk.TABLE1.y - mstore(add(_vk, 0x440), 0x049ad18a8303ae13fc27eb803bd1e4ab0843d7ea0c8da3e9de4069d7d124c35d) // vk.TABLE2.x - mstore(add(_vk, 0x460), 0x208d3a7f02e894bea3809a5a03f4d93fc4ffd3012ba21d785ebf6e29c79f84eb) // vk.TABLE2.y - mstore(add(_vk, 0x480), 0x008d6cbc3467442b0c8cfecb879705164b1a375d5b692c1a19968ad14ced51f1) // vk.TABLE3.x - mstore(add(_vk, 0x4a0), 0x01a4630460cf19d3744f57323ed8e95c711b1f35dc4be35136105afb64bca1be) // vk.TABLE3.y - mstore(add(_vk, 0x4c0), 0x2a32902c477f3c4e5d636886d58e6e92787d6835719aff2124de11661a931e5f) // vk.TABLE4.x - mstore(add(_vk, 0x4e0), 0x02bd52e022a279775cc203ef117ff464ce803b128e12d7d9e4906527ccc0d179) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x002158853758e7f671a63197c33f09025895ec819f33a69942ce3ad3874792c5) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x2c56d9309c085c8e74d2252c50dff9c735589e431073c699d16663c010c27f12) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x18f0be507e453236eecc41e29ba9e575027f2a22dc508ce0be79701ab0760328) // vk.ID1.x - mstore(add(_vk, 0x560), 0x2cc55fb77d81238a9659604ecbf38c322c3e93a25716b44e08877583c99eb52f) // vk.ID1.y - mstore(add(_vk, 0x580), 0x02fe9855b35527cf14bfeaba70ee83ff36db3ef35a549677ceb95076cf95f0b4) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x2987a64728505b1ec90f04ecf38b0f3bf18dbd50d379c686fe35ac2005932343) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x0559edf459c36c8579d3448de7897258db197c8e3e69e8d9cdc5ee13adeb1b06) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x27ee1775cd9f7a365f2f5d76aa37dd4f197ee8a90a846efddd84f0a255ddebed) // vk.ID3.y - mstore(add(_vk, 0x600), 0x0fa8737adffd19981969fe6891f2cf783a63277dd469a8f64805510c78f1ebbb) // vk.ID4.x - mstore(add(_vk, 0x620), 0x1d02caa8a2bc3aa1e96a61fcbe75298b9e365402cff9188cf942c3393331e1a8) // vk.ID4.y + mstore(add(_vk, 0x80), 0x260b63c5c404eba05c531b64a63c4f8752eb48b02d8d53910bbc22e7648b672b) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x0a84e4198292ba82e9ec6e130ebf86ff8513b8133501e8b7c625c322451cc17a) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x066bf08a2edd0ed02a5b2b4c72f512585b1816d943d06f4822219d37d28b88f7) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x18e0525744e594592f2ba6832df668c1424c920ebf1e2ec358558075df1fc906) // vk.Q2.y + mstore(add(_vk, 0x100), 0x25880f31af07e4d48de7be715bc3b63495b1ce16c3ce6233ad5ba832cf3330a5) // vk.Q3.x + mstore(add(_vk, 0x120), 0x190ab6675593f90dc404518e02369c97f0d736010033237073dfc5611cb4e0cc) // vk.Q3.y + mstore(add(_vk, 0x140), 0x1afd5ebe896054ba2812a94f5903a17aa5de0ffc7f1915259b4d9e01a24ceb44) // vk.Q4.x + mstore(add(_vk, 0x160), 0x03b445d3e75bd9ecf05703d2301157ccb3795adf7ddb3c0d03cbcc691772288e) // vk.Q4.y + mstore(add(_vk, 0x180), 0x00f612887aad4e61796d7948533fff40184bd1d00ba52e9201fea5b9b5a8258a) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x25bd9c5fec68e480ccf127be8b4bf7810c737a38f4d6a4379b3817d4d157a3f5) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x27e6361916a9c2a4f81501df8f6588c394f7ba0010e565fe9162e1456acb64fe) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x232d6f8f7582fc930a95c1d97e1cbe471935642ef95ac1457f953b92601a7f36) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x1344134626051322a90942b7cbd3a98227e7e192c8597604dea27f5eb49a1332) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x2c4782c37eb3e19589fc42e465f89cb3dd47ddcfce1a3a5f7e0e6423e9290f53) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x2ea84c6aebfa0d7b78e6f8344086d9a4ceabf599cdc3c8b8efaf937f78fa89f8) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x00fc4dc0688832477ed1b999b886307775590a5155ccfbe5e4a686cab3684fd9) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x21959276775cd4749236c8bf773a9b2403cecb45fbf70e6439f73d75442e8850) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x017714509f01d1a9ee7ebaf4d50745e33a14150b4fe9850a27e44de56d88cb14) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x2e76c4474fcb457db84fb273ccc10a4647a1a37444369f2f275bb74540f5e2d0) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x209035caddd02a78acd0ed617a85d782533bd142c6cad8e3338f3142b919c3a4) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x16a04bedbbced0858d1cb768d5dee65d7a9e5eda5840f041a6b0c2d9a05a47e9) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x0f295c2f65406bd8aa6844f7a8c797da1ec69b048441e5926a0d11e515056af4) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x219f3919df06c1843bdcf405c9c6304c9affb6b5b075e25d9213cb9ca4177ad8) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x2a5acc53d574ddef7c44bc0d578d9371cecc89ab42a4b0bc6017eaecc68ebeb0) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x270efbcff761d452b5a3024f5a1b13b2108bfd126610f7c6580acfc8a3eadc43) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x052330edc9afc72fdaa4d7c5df4617631634c46a7132ece7ec56286647f66a77) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x1a07bea503dbfd8375d3cd35b79187516326c0a96af71418b8004e863d2126d7) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x1601a5ddea012bc53cf9633d99e704caa30b017e3e81e935a8d791030be559c3) // vk.SIGMA4.y + mstore(add(_vk, 0x400), 0x06c5d3c2a64587cf9dc278c6892854fc8f1aba4183115224cb2eda4c1aab64b8) // vk.TABLE1.x + mstore(add(_vk, 0x420), 0x132622df9222e04fa9c4cf2895212a49556038d4fdc6d0d7a15b1067bb446efa) // vk.TABLE1.y + mstore(add(_vk, 0x440), 0x2dbc1ac72b2f0c530b3bdbef307395e6059f82ce9f3beea34ff6c3a04ca112bc) // vk.TABLE2.x + mstore(add(_vk, 0x460), 0x23e9676a2c36926b3e10b1102f06aa3a9828d1422ae9e6ea77203025cd18ada0) // vk.TABLE2.y + mstore(add(_vk, 0x480), 0x298b6eb4baf5c75d4542a2089226886cc3ef984af332cae76356af6da70820fe) // vk.TABLE3.x + mstore(add(_vk, 0x4a0), 0x1bb16a4d3b60d47e572e02fac8bf861df5ba5f96942054e0896c7d4d602dc5c7) // vk.TABLE3.y + mstore(add(_vk, 0x4c0), 0x1f5976fc145f0524228ca90c221a21228ff9be92d487b56890a39c3bc0d22bf2) // vk.TABLE4.x + mstore(add(_vk, 0x4e0), 0x0f43d83a0d9eb36476e05c8d1280df98ec46ce93ae238597a687a4937ebec6cc) // vk.TABLE4.y + mstore(add(_vk, 0x500), 0x239c09880dcbafee7caf9fb8460d1ca62e86b42b8724e350f01a12ddd4f08add) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x14dd9f4bba78075eb5bdb7d401281b01d9e88f8827fab15f6b718bfed5b6a598) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x0059fbc7f6f474f8a602db54e7aeb9b7072081bfb31d4831562003e8c5804177) // vk.ID1.x + mstore(add(_vk, 0x560), 0x01e2a561adf9c7843fd4e9acab18137656dbef06f22c9d2f05a68eae8576bd6b) // vk.ID1.y + mstore(add(_vk, 0x580), 0x205ed43983566317600b8324e02262240b23d6caa751e53360fe9410deb876b3) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x29ca9b6ba6da40ef21d62321d81594b449185bde9f071a3619731444a3cc30a2) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x0e633257c8c686bbe65fbf5792b8c944747838fd385d3b02eb7900dad50f6f4c) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x1bfda6b7d38472e9418a8eb55f4c1d372642b5819fde074d4fe62c29f843b566) // vk.ID3.y + mstore(add(_vk, 0x600), 0x1dab0d03d72afa6328933a39b05c764bc713f67606fa016ebf532deb2b4bc105) // vk.ID4.x + mstore(add(_vk, 0x620), 0x24bef3bbfed9cfcedabed6d61d289ae44ce360aa38fd022886fd22bc75fd5980) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol index e2cbc907bc60..7f65f07afa57 100644 --- a/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/EcdsaUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: 04925e4f94fd295a931d988e6fd9ef882b3dbd4df75d762be3183c66bfefa055 +// Verification Key Hash: 2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library EcdsaUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0x04925e4f94fd295a931d988e6fd9ef882b3dbd4df75d762be3183c66bfefa055; + return 0x2f843a63de8da557c6caf7abb57a3110d0c057892dd42037b7ed109d1a7b6105; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,52 +14,52 @@ library EcdsaUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000006) // vk.num_inputs mstore(add(_vk, 0x40), 0x00eeb2cb5981ed45649abebde081dcff16c8601de4347e7dd1628ba2daac43b7) // vk.work_root mstore(add(_vk, 0x60), 0x30641e0e92bebef818268d663bcad6dbcfd6c0149170f6d7d350b1b1fa6c1001) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x0d03a55e1c08f638bec6b3b6726ec4e8b4a2445fb898001c5cc59d90747265e1) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x28f5aaa22aae66726d58d5e1dd57733badd7577f842cafbef590b563688d3057) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x28e3095ae72fd2889ead6c3a95cf8592392c1d3546222ff15638ba280c161f31) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x27cda145ab9d0a13dae8bcab74ad6901f656c76ba1605d068a005dc4efd14ea9) // vk.Q2.y - mstore(add(_vk, 0x100), 0x29e0d8172946a5fdd2998f57cf3814ee55393d265a7f0bd4765687fe0aa72181) // vk.Q3.x - mstore(add(_vk, 0x120), 0x21d649dcdd6a1182f4ba7b2a42e26992774cb9743d6520defe56c582d6b8d7f0) // vk.Q3.y - mstore(add(_vk, 0x140), 0x2839198a3ce970ca0a0fafe33d2ca8ffe50d70be7e613eb710c08ca95115998e) // vk.Q4.x - mstore(add(_vk, 0x160), 0x0da0e1c3eb107528a589868e34ae65114de290ddd45ff23fc5f637c0da23c1a2) // vk.Q4.y - mstore(add(_vk, 0x180), 0x303ab526aeb8130ef858a97def955fd10c9b528ab3667415b8bfe279e507186d) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x1db1e82067093af3ba5cd78460f538b9d84c45bca6b3f6731d1072def1f031b6) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x24cc5a478a5ffd79cba3cbb6d2db878fc339abe56a63440384afb38ee0e95731) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x1e540a5249a2d3e326b0c9be362173e6a734afa900bac9859310ca018328e66a) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x13db96945a09894dddfa79d2b9f9e9e1eb6204065f662a17d7dbf6d257590d33) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x00d9af8f917935b1836f17dcdf1d44a1fa4e3655777f8ddca39905b38b80ab48) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x1a66842ed11152b8ccd1ffe548414be7dadbb956ae828c47cb32c449fb9a2a21) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x0b4304dfa9379f11f9387befd9522dde481e04d359a511e543b9c9fcfd4c8e70) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x2f213c7a4c064a63d6a07366df0ea85aef9ad2125a188c3e656f95471e416a0a) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x067a270bed55e72ffb3cfa39af3e5b8bcb4961d72bb301978af13c4ddc73e5df) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x27b10524a99f00d9c59cc15ff3b7dfc34975b6f18e06b9c6c3a6136bf3b56f32) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x071a9bf80d112c32482178ff02f855436cf6fb4b4376ef7e2f03381c2e6da379) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x11f8a90324450819709f17508ffaf140d17a949487af44e2f169c7371343411b) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x18db987ab3b02b830aace8661d0012170892e6b8f234d844f981e0c5b3e6e7c0) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x2df70bc7a4644eea4a21ff8e974eb3d624e311bc148b316fe25cd9486e9540ed) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x23e182a4495ff2abe1295260edaa7f3a205d8e4de69f783c7c66c0ba9859917b) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x10e03c5fc02493f4b37a58bfee7c6fa50bb3977477279a3f7623668e35305f75) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x2b2bc0c7955e6b99f93a62e2e1955a76d4bff3795985e9e70d64497052a93024) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x0c68404f1fb46097dfc1deabcaece7a47112489fd3cba333fd4ba985a4291b2d) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x186dd99ca6e71d8e125f30ea6c9d4093cc7bb4149fc9c50490618a0fc92ee7a3) // vk.SIGMA4.y - mstore(add(_vk, 0x400), 0x1a55dc1a642e0833b27de2085de8a8bf1e54f3409fdf6d955eec6bf73ba3c93e) // vk.TABLE1.x - mstore(add(_vk, 0x420), 0x2bdf5828e5a0e064d777710204eec800295f987905043ac054acbc038ba0d0dd) // vk.TABLE1.y - mstore(add(_vk, 0x440), 0x03a621c8d74670ed1b06ddb06644a04b11e4d77148be631c5a1daba27625ec83) // vk.TABLE2.x - mstore(add(_vk, 0x460), 0x2b9287b3d040871b3f97a6b1f33024317ac9f86adfe80f75f27296b36bd333c4) // vk.TABLE2.y - mstore(add(_vk, 0x480), 0x1c233efa3cbfff821f0fe636f12451241dbee781de362da405cd2b08e06ac820) // vk.TABLE3.x - mstore(add(_vk, 0x4a0), 0x238cdd74317e34461f06d04474eaa3b08fbeaf42bebad8402b51f00c892df46f) // vk.TABLE3.y - mstore(add(_vk, 0x4c0), 0x08aa2e3e45c14179616cc69685e1bd257ce49503b425e0bdbf4010c7be859fbc) // vk.TABLE4.x - mstore(add(_vk, 0x4e0), 0x2fd83c0e339172d2315a24dfd4aad276e5e860f3849b111b62723febdb3ee286) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x171e700abccc3b9764a2d27e09b3208941a0b8ac7299c2580e6b24d56b6139a7) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x151a058305194c4e68972296ddda0fd23359c1aaeb864bf8e273bbd6405b9718) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x0b6d6d86b0a3e81f2f146f798e63d0ee99e4594fbd0a826910461ccae434bfd3) // vk.ID1.x - mstore(add(_vk, 0x560), 0x0f4bc8f33eb6afed895ab21c4c5c80c741b7565607280ec2fe4c4f2e70ea6e6e) // vk.ID1.y - mstore(add(_vk, 0x580), 0x03c52afd7bf4066c19ef0b9c4bbd5cd3edbeebcd8cfb9de47b3199c4888fdc31) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x20923fb0fd3790a6e995640b803825c0dec8bc7da64203e55c69b26efee636bd) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x2cbc9f464c22cdc38a834fdb3810d0e8d4d927dbcf55cdfee347895e838f5e03) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x23e178dd197bd1ea0db8b76d597fb7bc5a7ae675b1496b7ccaff0722489795c4) // vk.ID3.y - mstore(add(_vk, 0x600), 0x124c5ef3a8d659717f89077b3f814fe4a575ad77acce9953af915a64569e94a5) // vk.ID4.x - mstore(add(_vk, 0x620), 0x04733238e5caa04c7cd0d154988171f8ac3e492ef48ada642007220a4fdc4703) // vk.ID4.y + mstore(add(_vk, 0x80), 0x1cc85a07fb1009e23540957b29121dc57aaae5b1e89a22a932a1bdf7ccac1af2) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x19a1a4fa6d8781abbcb696097c1817f54da296348a292954e2aa9856f2fa3b6a) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x0409f05fe2901e7e339b3aaf0d7af7b5d4023e416da923321b15aae633b18fee) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x0ae6cc44e9024c190ab310d7ad110226c5c76f15d158b60fc9acd98f2e1f1aa3) // vk.Q2.y + mstore(add(_vk, 0x100), 0x20e3b4e35df25ba02ac2a9be26bc6fe74640355e57455598e69922b8d3fd0939) // vk.Q3.x + mstore(add(_vk, 0x120), 0x1f49d18bdb86a449e676558c6d6349f123372641187e33e12128ee7468431942) // vk.Q3.y + mstore(add(_vk, 0x140), 0x00e95627d4db555ccf3b1ee6def34fab1a815f0482cb6a745a363940d3163831) // vk.Q4.x + mstore(add(_vk, 0x160), 0x19fe011a8a139da323b5ce5abebe54bf4c105acd6045d7b2b5df40a34411f44b) // vk.Q4.y + mstore(add(_vk, 0x180), 0x04b41648960da31317eff66b5ca9be0a6c81ebeead27e70b3c5b28d4aba11081) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x1bff2df21a3fd9c49c29b7f7c153dd0bc331d75afc6a35fb7155c17bb0f67a63) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x15faa2ea86a6a66cd9b969d6305f863595a73b9215c1ae442969f4993a8e5230) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x26391cc92544b485d90313d3396b53d9207db8f84ead11bcf45467fa7eb38b94) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x01a0d650b65d29965e4ae2a8cfb69470d7560f0826268da59c6e72e684a06c9b) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x2248d4a02e68036c8d0a4a6725ba0e5e8e95950a5285a3a7daa1a1726cc8ec6b) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x01afcbad715a0c382971311ad6fe4ff8b6e99200162aeb6245b585c99c8748a9) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x18bf352081d1ba2ffe8088d34ce6471e4cf6d2ee63f006ea9a5e31cc41b6587c) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x21245d6c0a4d2ff12b21a825f39f30e8f8cf9b259448d111183e975828539576) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x16a409532c8a1693536e93b6ce9920bfc2e6796e8dfe404675a0cdf6ee77ee7a) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x2d455f287e41544fd3744bab412640fd6916b01aa2163c84071eb47f0306a473) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x09dea8e2b5e382a1c4a37bc4e60f5e8380688310b855c249d64153478d25e223) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x09671927e293b22a3fb9fa8ea1680fcc4570bb2f312cb88004ff7fd4474e2109) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x1c6442d9a49b3b93a928ef6ba2f348bc4c8cb778a59345faf7d173129f22b5a3) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x0337d84b45a5abc701edbdc1a1d878178c23496b39ccddcc3f0f6199e3f97df6) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x1c744f7be93d40c96d15fdf9d81c9502b7018573ad23e51dea7b065fdeb6f13a) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x23a975cfb71f0c0d46ef9c0b01e6482e780b5e3af1a63547f7d01c46c1911699) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x0d5a0be212cb2c7d3bba8c2406a9d2c4b04d4e64b0acef2681eb7c6aa490a7cb) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x1ca2d0cca80bb16eab28d06c5c175e862a8ef14bceb6da79e65236a8a6a36838) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x0555fe3dbd2ba2d7db2b5f740bf32fb57f4c5ac9d9f2e59e9a5a2cc2d84dae05) // vk.SIGMA4.y + mstore(add(_vk, 0x400), 0x18f7cf965339d9c9d190296fa92f915767b0a8da455975f3e03fa98439fd7110) // vk.TABLE1.x + mstore(add(_vk, 0x420), 0x0eecc02f9d44125407adbf00d56b086afd1adc5de536450afe05de382761b32f) // vk.TABLE1.y + mstore(add(_vk, 0x440), 0x0bdfe662ea9f40f125ca5f7e99a8c6ba09b87ba8313864316745df862946c5c4) // vk.TABLE2.x + mstore(add(_vk, 0x460), 0x0c5313c5b17634332920f54081fd46464a5ce9399e507c8fece9df28bff19033) // vk.TABLE2.y + mstore(add(_vk, 0x480), 0x232ab86409f60c50fd5f04e879fbcbe60e358eb0337c5d0db1934277e1d8b1f2) // vk.TABLE3.x + mstore(add(_vk, 0x4a0), 0x1fda66dfb58273345f2471dff55c51b6856241460272e64b4cc67cde65231e89) // vk.TABLE3.y + mstore(add(_vk, 0x4c0), 0x024ccc0fcff3b515cdc97dde2fae5c516bf3c97207891801707142af02538a83) // vk.TABLE4.x + mstore(add(_vk, 0x4e0), 0x27827250d02b7b67d084bfc52b26c722f33f75ae5098c109573bfe92b782e559) // vk.TABLE4.y + mstore(add(_vk, 0x500), 0x22b1d6b9827d6d03049f76dc9dc219ae6de93abe52d4d7de8677d961d3408c77) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x10ebc6be9f74e0367276028c613ab3efe0f2ed546c05339b36d5165d009c833a) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x2aa2e5247ce6524fecba0a2de9f383353096665f3ae8082fe7017fbf6d6572d8) // vk.ID1.x + mstore(add(_vk, 0x560), 0x1db802f61a6194bea68f7d5ec697facf26f1c1336b09e382801e8b773f0e116f) // vk.ID1.y + mstore(add(_vk, 0x580), 0x1aa955e508f3c2fbf55a36719eb666a45239935c4af10b8a1f4580d5cd614236) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x2bc21aa51420951a10a39d5c5242101d2207c47a0077852acb7d3fd6a16e1c58) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x245c89c4cf7c7e297b4db8e2625f5abd56398c351256a39aece0a36a940aaf62) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x01bd6e61d801d895c7edfee071518761f3c8c0e10bec5f0fb0b25ae430a2c91e) // vk.ID3.y + mstore(add(_vk, 0x600), 0x30223d4653291c03019e96bd716769c7c6d6520fddf2e633a75f94b08bee86dd) // vk.ID4.x + mstore(add(_vk, 0x620), 0x2e389428afa291855039f1b4af22e70d469f4e20116b85889737d624a2d27fef) // vk.ID4.y mstore(add(_vk, 0x640), 0x00) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 diff --git a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol index 67fb9125aa42..45d50fe15dd2 100644 --- a/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol +++ b/barretenberg/sol/src/ultra/keys/RecursiveUltraVerificationKey.sol @@ -1,11 +1,11 @@ -// Verification Key Hash: adf7fcbdc3ab90920764d05aac762984b6f80e3dbc9cfdcef33d5d400525eb24 +// Verification Key Hash: a52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9 // SPDX-License-Identifier: Apache-2.0 // Copyright 2022 Aztec pragma solidity >=0.8.4; library RecursiveUltraVerificationKey { function verificationKeyHash() internal pure returns (bytes32) { - return 0xadf7fcbdc3ab90920764d05aac762984b6f80e3dbc9cfdcef33d5d400525eb24; + return 0xa52397545a883471ee94e8a27e184be64d21640d76712b1e6fba67f3546503c9; } function loadVerificationKey(uint256 _vk, uint256 _omegaInverseLoc) internal pure { @@ -14,52 +14,52 @@ library RecursiveUltraVerificationKey { mstore(add(_vk, 0x20), 0x0000000000000000000000000000000000000000000000000000000000000010) // vk.num_inputs mstore(add(_vk, 0x40), 0x2260e724844bca5251829353968e4915305258418357473a5c1d597f613f6cbd) // vk.work_root mstore(add(_vk, 0x60), 0x3064486657634403844b0eac78ca882cfd284341fcb0615a15cfcd17b14d8201) // vk.domain_inverse - mstore(add(_vk, 0x80), 0x272fae13335cda7794aeee75c0d41e52cc626b07106135805edc8538ab41f6e8) // vk.Q1.x - mstore(add(_vk, 0xa0), 0x266e1501fe1a3d602bbfb1bd408ac9b329686552d0578d8fa1a7d37444632eed) // vk.Q1.y - mstore(add(_vk, 0xc0), 0x24800dd2d472844c3afd10284239c30707c9eb16192a65ab28eb79f59aff2943) // vk.Q2.x - mstore(add(_vk, 0xe0), 0x2ae2c84daa90e63075555a436f030a9d8ae62780ec3b2a5f568627a214e53994) // vk.Q2.y - mstore(add(_vk, 0x100), 0x1226970a5f06cfb38da166d6004e3d512ed6728a51f937b3073fcb396aa7372e) // vk.Q3.x - mstore(add(_vk, 0x120), 0x0769098bf5dc607b7d6cd29a9b97db48f7703294d84754e48d1bc677c8c1f979) // vk.Q3.y - mstore(add(_vk, 0x140), 0x1b5ece1f2b6578612eca0fbc1f45742c440ee5246070152406d8ab66d2fe82c2) // vk.Q4.x - mstore(add(_vk, 0x160), 0x25669e07536131b086ce8a414333b5ab214fea376e52fca87ed9ac7c4d26cbbc) // vk.Q4.y - mstore(add(_vk, 0x180), 0x013c1867e784bae04da012ee7d227e0f920b31dae793d5da38ae999b4622c4a8) // vk.Q_M.x - mstore(add(_vk, 0x1a0), 0x1ca9e804bffcd6403981d319a74f67c17c267e9ce077434d46b8cbadb2cb6748) // vk.Q_M.y - mstore(add(_vk, 0x1c0), 0x30447104bc7eaf34835557b8412d1220076eec127c7277d7d144d05ee10a4c82) // vk.Q_C.x - mstore(add(_vk, 0x1e0), 0x0990dafa12cf826c986537955e488e025f11674b56dd87e543f532d80b529b75) // vk.Q_C.y - mstore(add(_vk, 0x200), 0x1ae04aa3fc4f2ee6afa525cbd6502819eb3e7572b59363323cc978af71eeb25b) // vk.Q_ARITHMETIC.x - mstore(add(_vk, 0x220), 0x3031230737a7dad62b9fd25b9b9eb2a8f386bcbb2bde2f67e678dfd718deef7b) // vk.Q_ARITHMETIC.y - mstore(add(_vk, 0x240), 0x070799795a4b36746d6bac7b3248a9f80dd83ae93c1d1108b621f869b78542ff) // vk.QSORT.x - mstore(add(_vk, 0x260), 0x2acc6c19c519877bdf4f8f759b8f5c82dc6ff3790445120840418f782fe458d4) // vk.QSORT.y - mstore(add(_vk, 0x280), 0x21f55b7e9b4c5cbf21301019074c0a0eab41c8e637f8787e72f9f745c6979b3c) // vk.Q_ELLIPTIC.x - mstore(add(_vk, 0x2a0), 0x02e336c35d840241a188ffc7ad2c687f16ddd91356e9db9cc470af08db1ef180) // vk.Q_ELLIPTIC.y - mstore(add(_vk, 0x2c0), 0x00b7eec617e68065a1071a17d8e92cf99add525ec3fc6f5823c3907c4ffd99f0) // vk.Q_AUX.x - mstore(add(_vk, 0x2e0), 0x2d9f0066732a3c01f1cd02f728f0a812dc501e14cf04cfeaffc21c1a3022b33e) // vk.Q_AUX.y - mstore(add(_vk, 0x300), 0x20fa82863a6691e5e1d8b2b76fc7ea07fa5a91e81c313034a0baf1c059f16ed8) // vk.SIGMA1.x - mstore(add(_vk, 0x320), 0x0b293e34397d00906293da08044b03d3923213ecb97932f1a7b693d7be591d26) // vk.SIGMA1.y - mstore(add(_vk, 0x340), 0x09c74bb84de88d366afe6926889f5e60c6405fa393dbf3e65ac0405b8dc09162) // vk.SIGMA2.x - mstore(add(_vk, 0x360), 0x235f8afe67a54eeb1b507a933e8f6602a18722258f69b811d5f10d2bdc67e40a) // vk.SIGMA2.y - mstore(add(_vk, 0x380), 0x24d36ac3e040bba91e88393b6d87b98bd839aa4e72c4fe82f151a547220cdb87) // vk.SIGMA3.x - mstore(add(_vk, 0x3a0), 0x2e19a2cf0df47c94ea8f443eaf781ab325a3a31f53c2cd47158b96cab77b4c26) // vk.SIGMA3.y - mstore(add(_vk, 0x3c0), 0x299b063fd348d02720572abe377ec7267d5317a37201c1f9b79c8c6ee8597b97) // vk.SIGMA4.x - mstore(add(_vk, 0x3e0), 0x04dd6ccd06bf4c458c06f0a839a703c76bf2c809a2b2df3f37227e2e345a47fc) // vk.SIGMA4.y - mstore(add(_vk, 0x400), 0x11c514df4405308bdface3553201db9535ce40f1cceb593355737a2c0e1809c4) // vk.TABLE1.x - mstore(add(_vk, 0x420), 0x23730ae1d6b51c53e9f341638ad156f217277de48f9cc50a19f4399a50e7c9b1) // vk.TABLE1.y - mstore(add(_vk, 0x440), 0x14a7d7dd7a61a9fee9df1579e5c7a497f363ef06b373eaeef19745008e808935) // vk.TABLE2.x - mstore(add(_vk, 0x460), 0x12b20d74592a31252375201ad5cfb6b91ada920288c6211aa61745cb1827142f) // vk.TABLE2.y - mstore(add(_vk, 0x480), 0x0de228c86fdaae2337277757704862abc3968ebcdf3c66a4b4fe0e1452b04cfe) // vk.TABLE3.x - mstore(add(_vk, 0x4a0), 0x2c01fc8d1605cdd5325bee69dd0a869cf94f6a48f0f322b16ac00dd1f58165d0) // vk.TABLE3.y - mstore(add(_vk, 0x4c0), 0x1b3600e51a06913d585471e94f198abe613a4b6194247a3233c7a26b6fdb5447) // vk.TABLE4.x - mstore(add(_vk, 0x4e0), 0x15eb45af241222240bc8446a0410ff960dd88b8d9720bc13e8eb57be89be891b) // vk.TABLE4.y - mstore(add(_vk, 0x500), 0x0221ee1e654253fcaa3ffdd7ccca0cce2c8c25bd391e4a6f26fe21f15853a06f) // vk.TABLE_TYPE.x - mstore(add(_vk, 0x520), 0x29c6259ed3ff4e54d067340ec91ec5185f741622fb2a0a5432f06777f6158fdb) // vk.TABLE_TYPE.y - mstore(add(_vk, 0x540), 0x2611a5db278d94912ccee81a829f45895a7444c2d084506d0d1f0ecdfccdc758) // vk.ID1.x - mstore(add(_vk, 0x560), 0x0134f8df4f1f8b8058266bb3f83b001810fd520577fbdbb738dae189be463b05) // vk.ID1.y - mstore(add(_vk, 0x580), 0x09cf92cea1bef8594f4c76cc9ef8a05b05310cce7863ad5fc25ceddfc70e3d31) // vk.ID2.x - mstore(add(_vk, 0x5a0), 0x2e1ffaf9dcceb1d647c48f30083ec38a2cf10f90c972762a552a939dbcd9a0be) // vk.ID2.y - mstore(add(_vk, 0x5c0), 0x0edaab035bd27f0f4b32aee13aa3177ddaabede322c351d0372a5d34eaa02bcb) // vk.ID3.x - mstore(add(_vk, 0x5e0), 0x17f7c240033409c394ae8c3b0fde30166e005566108852aec3b32206b96a68dc) // vk.ID3.y - mstore(add(_vk, 0x600), 0x1b032411cf6636fb43b3dfa8960a2aee106cea208de111f4d512cd88d640fe79) // vk.ID4.x - mstore(add(_vk, 0x620), 0x11e4ec47b80d1ee3c51058086e553098c2959807e0ec3365e848214a8cd4e05b) // vk.ID4.y + mstore(add(_vk, 0x80), 0x05104b486160545badec11f151e7c70b87050871da5653387ab4ab2ad0eef5ca) // vk.Q1.x + mstore(add(_vk, 0xa0), 0x2672c7fb298fce83f510eb6e1b851a5bb2daf8fc43c7771e96c56c8a09ddfeae) // vk.Q1.y + mstore(add(_vk, 0xc0), 0x2c019acf99c5663da83cec224bd32570ee90f45c4486a54dec3ca4552d8ab07a) // vk.Q2.x + mstore(add(_vk, 0xe0), 0x0fb7a3385ab42cafb0e104ac17ac2dacfb161d292c00fca102b1e780e86ccaf3) // vk.Q2.y + mstore(add(_vk, 0x100), 0x273ca9c29ef10864f4c9c053c336776a71ca5ebbf4bec1cb381e431943f9b5d7) // vk.Q3.x + mstore(add(_vk, 0x120), 0x2a94f00fe384ab945a8f5e3c97194a425a4d2109e5b113f059e42ee232659436) // vk.Q3.y + mstore(add(_vk, 0x140), 0x0e8b5c127c8a3ec285c2ac80d9046528051387878802203988a60650a0a960ab) // vk.Q4.x + mstore(add(_vk, 0x160), 0x17efdb659ae0d26aa78db132f9be9130460c0fce0c2a8e9b726de68247f76891) // vk.Q4.y + mstore(add(_vk, 0x180), 0x2f668d8a50bdb5c366e39433892f903262a04b6473ba3468c12057d58ad3bbfb) // vk.Q_M.x + mstore(add(_vk, 0x1a0), 0x2397c6171bc6d084e98297690441c9da9f011d18b3ea0bb58ee4d47227feb6b4) // vk.Q_M.y + mstore(add(_vk, 0x1c0), 0x1dafbfb4d30fcf880ef839ecc7fda9a97c315c5fa1713d08f7cdf6dba53ffb17) // vk.Q_C.x + mstore(add(_vk, 0x1e0), 0x099fa3de9ce0cc28085739745582b53bf7939e3d97928afd491392053c1c0a68) // vk.Q_C.y + mstore(add(_vk, 0x200), 0x028912be5d0accd4edf4949f89be1c1a2fcf4f59559ba03114da00ec3bf643ac) // vk.Q_ARITHMETIC.x + mstore(add(_vk, 0x220), 0x2428952bfba8ba44830fb0ae6fcdeb9bf17d611add9432450ebbe3d928e2f431) // vk.Q_ARITHMETIC.y + mstore(add(_vk, 0x240), 0x2b40c900824bcca193d402e0ef7f78792deaccd99743a78e5330abe8886ac989) // vk.QSORT.x + mstore(add(_vk, 0x260), 0x102a7a02bc1a7317702c09560636e991b856f26f88ee8f0b33da3dd7fe222dbb) // vk.QSORT.y + mstore(add(_vk, 0x280), 0x2bcf00433471db2be265df28ba2e70c36ca52f2932a4de25c0d60868703a0726) // vk.Q_ELLIPTIC.x + mstore(add(_vk, 0x2a0), 0x2f225b86590c67ae48360cb41d5b291ba94ce2dbae850afd9a6854122341b5ba) // vk.Q_ELLIPTIC.y + mstore(add(_vk, 0x2c0), 0x2eaee34d8508092cc4e19bc3f27ffa7dfc72230710e220f228f48906fae21e56) // vk.Q_AUX.x + mstore(add(_vk, 0x2e0), 0x0c503c5d6245b99bbc056925e96abd20feaed6507707311092b3ed87eadb3874) // vk.Q_AUX.y + mstore(add(_vk, 0x300), 0x021ba851cec3aedfbf1d9944907ae721f0d3e8fa3548513b6f108d101067ae85) // vk.SIGMA1.x + mstore(add(_vk, 0x320), 0x24eef378da346c4f9eededc5dc519d35b14fec46412c8fcf7564cafb9843d761) // vk.SIGMA1.y + mstore(add(_vk, 0x340), 0x0492b2fed8a158177dd3e825fb34ca7481bfead06bc01f308dc81fcd852ef3bc) // vk.SIGMA2.x + mstore(add(_vk, 0x360), 0x289bf1bcc6a9cb19b102c7fb9dba839e1817a24257194cad404b393ce77e66b5) // vk.SIGMA2.y + mstore(add(_vk, 0x380), 0x05d2a9c66d5c142b254b4f7d09f0eb837d95d8ec002e0644f51d455041403ca5) // vk.SIGMA3.x + mstore(add(_vk, 0x3a0), 0x2434b76f470965c85363ff15b3f37c7b4be4fb2741451dc33943879f1e4cbba4) // vk.SIGMA3.y + mstore(add(_vk, 0x3c0), 0x2f4bcc93500665a87a8f959e1636fe88cb1f17688b8c286fe930ccf934a49ac2) // vk.SIGMA4.x + mstore(add(_vk, 0x3e0), 0x243f7b4ae1d483c99523b6a2999f404ab744017c8f43080c3582c38ea8ea3d1a) // vk.SIGMA4.y + mstore(add(_vk, 0x400), 0x0ddc3b6d8e59cf0996ca71ad4132ca9d618ffd933cf58a8a0953dc76f97cf108) // vk.TABLE1.x + mstore(add(_vk, 0x420), 0x153193287060386695f4f2d0d3525dec4c6a253f431d3f3fc06aa0e5b0448b8c) // vk.TABLE1.y + mstore(add(_vk, 0x440), 0x1170f0ece62f8c572bca96b141d27f4bd25585edb9319128045c005d48491b1e) // vk.TABLE2.x + mstore(add(_vk, 0x460), 0x246cd041690f653f88ed0c56ad282a3dd2e37b8edb1f56b785809d7710bf1c88) // vk.TABLE2.y + mstore(add(_vk, 0x480), 0x26153c937447356a0c6d6be09d85eb34bc8a00ce9d452888e5fc2b5a7e14fed7) // vk.TABLE3.x + mstore(add(_vk, 0x4a0), 0x189da022421fbd8dfd7973084d978e555388ad9364679246b07992f84b4e91b2) // vk.TABLE3.y + mstore(add(_vk, 0x4c0), 0x285311c5e9a4cbb56a3f04f29d5443e8c0f9753e2a5a35acec051fafe2cecce5) // vk.TABLE4.x + mstore(add(_vk, 0x4e0), 0x2436400260c9d3180beedd0bf49fec92d2d0ac76a1be7f1fad96cbd997175312) // vk.TABLE4.y + mstore(add(_vk, 0x500), 0x139bb66456d96a4e2dad361f7949a6b8c6739650965ae729788162fbb0382399) // vk.TABLE_TYPE.x + mstore(add(_vk, 0x520), 0x098fad1329e1765863f8ac829332168359901da71702e5119ce4b89a7ae6f017) // vk.TABLE_TYPE.y + mstore(add(_vk, 0x540), 0x14fc4c6c2521387172a6b801e2b6c8a2308d725695d3f49a57151c2a0a8af0fe) // vk.ID1.x + mstore(add(_vk, 0x560), 0x2ce0c2c73ded7bcf19c1208f134b67ed74f77ef717db1c05c010bc8df7bed39e) // vk.ID1.y + mstore(add(_vk, 0x580), 0x0e2455a361f4a3741dab6a03b8186996a5a9873a3b62b3fa8eb5a551cb46bb7a) // vk.ID2.x + mstore(add(_vk, 0x5a0), 0x29a288b84aeabb0421861492256c6ea82530b5b14c0e01e5b7b2553cf197a2e7) // vk.ID2.y + mstore(add(_vk, 0x5c0), 0x01fbecd3bc90ad298a27bf4f9aa071746c30b5af932a1ba8d5b04394f85e0370) // vk.ID3.x + mstore(add(_vk, 0x5e0), 0x0b21c924fc2b44729ff84deeae724c68dd1636e847b0f7cdd92ad203af7cf0d5) // vk.ID3.y + mstore(add(_vk, 0x600), 0x12f7ebb5e50b429b766b1dc5e8b32b7727593641e4f976b72a7046d0a3ff8dea) // vk.ID4.x + mstore(add(_vk, 0x620), 0x2d45226edb0f8338bb5fa88ecefeeaa9bbb72232a2e842f8c7f37cd11f7065ed) // vk.ID4.y mstore(add(_vk, 0x640), 0x01) // vk.contains_pairing_point_accumulator mstore(add(_vk, 0x660), 0) // vk.pairing_point_accumulator_public_input_indices mstore(add(_vk, 0x680), 0x260e01b251f6f1c7e7ff4e580791dee8ea51d87a358e038b4efe30fac09383c1) // vk.g2_x.X.c1 From d17c7e234650b14fd46f9822c4d18ae5fb3e9578 Mon Sep 17 00:00:00 2001 From: maramihali Date: Tue, 17 Dec 2024 18:34:24 +0000 Subject: [PATCH 17/18] ensure mac build runs --- .../execution_trace/execution_trace_usage_tracker.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index 13eb25f602e5..d15aeb6f3295 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -84,7 +84,7 @@ struct ExecutionTraceUsageTracker { for (auto [max_size, fixed_block] : zip_view(max_sizes.get(), fixed_sizes.get())) { size_t start_idx = fixed_block.trace_offset; size_t end_idx = start_idx + max_size; - active_ranges.emplace_back(start_idx, end_idx); + active_ranges.push_back(Range{ start_idx, end_idx }); } // The active ranges must also include the rows where the actual databus and lookup table data are stored. @@ -96,10 +96,10 @@ struct ExecutionTraceUsageTracker { // lookup table data be Range{lookup_start, max_tables_size} but that also breaks. size_t databus_end = std::max(max_databus_size, static_cast(fixed_sizes.busread.trace_offset + max_sizes.busread)); - active_ranges.emplace_back(0, databus_end); + active_ranges.push_back(Range{ 0, databus_end }); size_t lookups_start = fixed_sizes.lookup.trace_offset; size_t lookups_end = lookups_start + std::max(max_tables_size, static_cast(max_sizes.lookup)); - active_ranges.emplace_back(lookups_start, lookups_end); + active_ranges.emplace_back(Range{ lookups_start, lookups_end }); } // Check whether an index is contained within the active ranges (or previous active ranges; needed for perturbator) From e453e9f19e9ad23f5ce43045337cc2892b7d3537 Mon Sep 17 00:00:00 2001 From: maramihali Date: Wed, 18 Dec 2024 09:13:26 +0000 Subject: [PATCH 18/18] fix label ordering --- .../barretenberg/plonk_honk_shared/composer/composer_lib.hpp | 2 +- .../execution_trace/execution_trace_usage_tracker.hpp | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp index 3942a291231a..e4aa58724332 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/composer/composer_lib.hpp @@ -11,7 +11,7 @@ namespace bb { template void construct_lookup_table_polynomials(const RefArray& table_polynomials, const typename Flavor::CircuitBuilder& circuit, - [[maybe_unused]] const size_t dyadic_circuit_size, + const size_t dyadic_circuit_size, const size_t additional_offset = 0) { // Create lookup selector polynomials which interpolate each table column. diff --git a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp index d15aeb6f3295..a8bb7e892dac 100644 --- a/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp +++ b/barretenberg/cpp/src/barretenberg/plonk_honk_shared/execution_trace/execution_trace_usage_tracker.hpp @@ -33,9 +33,10 @@ struct ExecutionTraceUsageTracker { size_t max_tables_size = 0; // For printing only. Must match the order of the members in the arithmetization - static constexpr std::array block_labels{ "busread", + + static constexpr std::array block_labels{ "ecc_op", + "busread", "lookup", - "ecc_op", "pub_inputs", "arithmetic", "delta_range",