diff --git a/.circleci/config.yml b/.circleci/config.yml index 75cf2b955ce2..81eb7344f1f5 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -996,6 +996,11 @@ jobs: command: | should_release || exit 0 yarn-project/deploy_npm.sh canary + - run: + name: "Release latest to NPM: bb.js" + command: | + should_release || exit 0 + deploy_npm bb.js latest - run: name: "Release latest to NPM: yarn-project" command: | diff --git a/.github/workflows/mirror_repos.yml b/.github/workflows/mirror_repos.yml index aeac37b85c27..508887fd79d7 100644 --- a/.github/workflows/mirror_repos.yml +++ b/.github/workflows/mirror_repos.yml @@ -12,31 +12,8 @@ on: - cron: "0 2 * * *" jobs: - mirror-to-build-system-repo: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v3 - with: - fetch-depth: 0 - token: ${{ secrets.AZTEC_BOT_GITHUB_TOKEN }} - - name: Push to build-system repo - run: | - SUBREPO_PATH=build-system - git config --global user.name AztecBot - git config --global user.email tech@aztecprotocol.com - - if ./scripts/git_subrepo.sh push $SUBREPO_PATH --branch=master; then - git fetch # in case a commit came after this - git rebase origin/master - git commit --amend -m "$(git log -1 --pretty=%B) [skip ci]" - git push - fi - mirror-to-barretenberg-repo: runs-on: ubuntu-latest - # Force sequential. - needs: mirror-to-build-system-repo steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/publish-bb.yml b/.github/workflows/publish-bb.yml index 85c074131764..27c345b34e67 100644 --- a/.github/workflows/publish-bb.yml +++ b/.github/workflows/publish-bb.yml @@ -93,7 +93,7 @@ jobs: sudo cp -r clang+llvm-16.0.0-x86_64-linux-gnu-ubuntu-18.04/lib/* /usr/local/lib/ sudo cp -r clang+llvm-16.0.0-x86_64-linux-gnu-ubuntu-18.04/share/* /usr/local/share/ - - name: Install yarn + - name: Install yarn # Needed to call 'yarn build' on barretenberg/ts run: | curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list @@ -104,7 +104,7 @@ jobs: ./scripts/install-wasi-sdk.sh - - name: Compile Typescript + - name: Compile Typescript # Compiles bb.js and wasms run: | cd barretenberg/ts yarn install && yarn && yarn build @@ -117,19 +117,19 @@ jobs: working-directory: barretenberg/cpp/build-wasm/bin run: tar -cvzf acvm_backend.wasm.tar.gz acvm_backend.wasm - - name: Setup Node.js - uses: actions/setup-node@v2 - with: - node-version: "18" - registry-url: "https://registry.npmjs.org" - - - name: Deploy Typescript to NPM - if: github.event.inputs.tag != 'nightly' && github.event.inputs.tag != '' # Do not deploy to npm if it is a nightly build - run: | - cd barretenberg/ts - yarn deploy - env: - NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} + # - name: Setup Node.js + # uses: actions/setup-node@v2 + # with: + # node-version: "18" + # registry-url: "https://registry.npmjs.org" + + # - name: Deploy Typescript to NPM + # if: github.event.inputs.tag != 'nightly' && github.event.inputs.tag != '' # Do not deploy to npm if it is a nightly build + # run: | + # cd barretenberg/ts + # yarn deploy + # env: + # NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} - name: Upload artifacts uses: actions/upload-artifact@v2 diff --git a/README.md b/README.md index 8926ba967636..dc4c5d8cf62b 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ All the packages that make up [Aztec](https://docs.aztec.network). ## Issues Board -All issues being worked on are tracked on the [Aztec Github Project](https://github.com/orgs/AztecProtocol/projects/22). For a higher-level roadmap, check the [milestones overview](https://docs.aztec.network/aztec/milestones) section of our docs. +All issues being worked on are tracked on the [Aztec Github Project](https://github.com/orgs/AztecProtocol/projects/22). For a higher-level roadmap, check the [milestones overview](https://docs.aztec.network/about_aztec/roadmap/main) section of our docs. ## Development Setup diff --git a/barretenberg/.gitrepo b/barretenberg/.gitrepo index 7eb6dba2c412..f0f2d9349891 100644 --- a/barretenberg/.gitrepo +++ b/barretenberg/.gitrepo @@ -6,7 +6,7 @@ [subrepo] remote = https://github.com/AztecProtocol/barretenberg branch = master - commit = 4f7bac9189d6b75b9591ecad688f964646783e2b - parent = 50b4a728b4c20503f6ab56c07feaa29d767cec10 + commit = f01329ccb7a07c8828a06a19d0a4d77d3f89087a + parent = b77afb14c609cfc04663a318eecaa8cbd3b2fa85 method = merge cmdver = 0.4.6 diff --git a/barretenberg/cpp/scripts/ci/upload_benchmarks_to_s3.sh b/barretenberg/cpp/scripts/ci/upload_benchmarks_to_s3.sh index dc5d890704b3..03603d20c03d 100755 --- a/barretenberg/cpp/scripts/ci/upload_benchmarks_to_s3.sh +++ b/barretenberg/cpp/scripts/ci/upload_benchmarks_to_s3.sh @@ -14,6 +14,7 @@ elif [ -n "${PULL_REQUEST:-}" ]; then TARGET_FOLDER="barretenberg-bench-v1/pulls/${PULL_REQUEST##*/}" else echo Skipping upload since no target folder was defined + exit fi echo "Uploading to s3://$BUCKET_NAME/$TARGET_FOLDER" -aws s3 cp extracted-repo/src/barretenberg/cpp/build/ultra_honk_rounds_bench.json "s3://$BUCKET_NAME/$TARGET_FOLDER/ultra_honk_rounds_bench.json" \ No newline at end of file +aws s3 cp extracted-repo/src/barretenberg/cpp/build/ultra_honk_rounds_bench.json "s3://$BUCKET_NAME/$TARGET_FOLDER/ultra_honk_rounds_bench.json" diff --git a/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/eccvm.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/eccvm.bench.cpp index 59e793ce187d..630484837e11 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/eccvm.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/eccvm.bench.cpp @@ -5,7 +5,7 @@ #include "barretenberg/proof_system/circuit_builder/eccvm/eccvm_circuit_builder.hpp" using namespace benchmark; -using namespace proof_system; +using namespace bb; using Flavor = honk::flavor::ECCVM; using Builder = ECCVMCircuitBuilder; diff --git a/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/goblin.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/goblin.bench.cpp index 44fe8180c9c9..40b95b7a7d2d 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/goblin.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/goblin_bench/goblin.bench.cpp @@ -9,7 +9,7 @@ using namespace benchmark; using namespace bb; -using namespace proof_system; +using namespace bb; namespace { void goblin_full(State& state) noexcept diff --git a/barretenberg/cpp/src/barretenberg/benchmark/ipa_bench/ipa.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/ipa_bench/ipa.bench.cpp index ff0c24b72c8a..e3da4560115d 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/ipa_bench/ipa.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/ipa_bench/ipa.bench.cpp @@ -3,8 +3,8 @@ using namespace benchmark; using namespace bb; -using namespace proof_system; -using namespace proof_system::honk::pcs::ipa; +using namespace bb; +using namespace bb::honk::pcs::ipa; namespace { using Curve = curve::Grumpkin; using Fr = Curve::ScalarField; diff --git a/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/plonk.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/plonk.bench.cpp index 8b62462e8844..167f5baf01a3 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/plonk.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/plonk.bench.cpp @@ -12,8 +12,8 @@ constexpr size_t START = (MAX_GATES) >> (NUM_CIRCUITS - 1); // constexpr size_t MAX_HASH_ROUNDS = 8192; // constexpr size_t START_HASH_ROUNDS = 64; -using Builder = proof_system::StandardCircuitBuilder; -using Composer = proof_system::plonk::StandardComposer; +using Builder = bb::StandardCircuitBuilder; +using Composer = bb::plonk::StandardComposer; void generate_test_plonk_circuit(Builder& builder, size_t num_gates) { diff --git a/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/standard_plonk.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/standard_plonk.bench.cpp index 403367d9159a..71d790519c0b 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/standard_plonk.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/plonk_bench/standard_plonk.bench.cpp @@ -4,8 +4,8 @@ using namespace benchmark; -using StandardBuilder = proof_system::StandardCircuitBuilder; -using StandardPlonk = proof_system::plonk::StandardComposer; +using StandardBuilder = bb::StandardCircuitBuilder; +using StandardPlonk = bb::plonk::StandardComposer; /** * @brief Benchmark: Construction of a Standard proof for a circuit determined by the provided circuit function @@ -13,8 +13,8 @@ using StandardPlonk = proof_system::plonk::StandardComposer; static void construct_proof_standard_power_of_2(State& state) noexcept { auto log2_of_gates = static_cast(state.range(0)); - bench_utils::construct_proof_with_specified_num_iterations( - state, &bench_utils::generate_basic_arithmetic_circuit, log2_of_gates); + bench_utils::construct_proof_with_specified_num_iterations( + state, &bench_utils::generate_basic_arithmetic_circuit, log2_of_gates); } BENCHMARK(construct_proof_standard_power_of_2) diff --git a/barretenberg/cpp/src/barretenberg/benchmark/protogalaxy_bench/protogalaxy.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/protogalaxy_bench/protogalaxy.bench.cpp index 348b05d17564..7b53cfe26941 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/protogalaxy_bench/protogalaxy.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/protogalaxy_bench/protogalaxy.bench.cpp @@ -6,7 +6,7 @@ using namespace benchmark; -namespace proof_system::honk { +namespace bb::honk { using Flavor = flavor::Ultra; using Instance = ProverInstance_; using Instances = ProverInstances_; @@ -38,4 +38,4 @@ void fold_one(State& state) noexcept } BENCHMARK(fold_one)->/* vary the circuit size */ DenseRange(14, 20)->Unit(kMillisecond); -} // namespace proof_system::honk \ No newline at end of file +} // namespace bb::honk \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/barycentric.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/barycentric.bench.cpp index 3c731e49652b..19572fe6a0ea 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/barycentric.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/barycentric.bench.cpp @@ -12,7 +12,7 @@ using FF = bb::fr; using bb::BarycentricData; using bb::Univariate; -namespace proof_system::benchmark { +namespace bb::benchmark { void extend_2_to_6(State& state) noexcept { @@ -23,4 +23,4 @@ void extend_2_to_6(State& state) noexcept } BENCHMARK(extend_2_to_6); -} // namespace proof_system::benchmark \ No newline at end of file +} // namespace bb::benchmark \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/relations.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/relations.bench.cpp index c88167a4c975..e683523a7e3f 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/relations.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/relations_bench/relations.bench.cpp @@ -8,9 +8,9 @@ namespace { auto& engine = numeric::random::get_debug_engine(); } -using namespace proof_system::honk::sumcheck; +using namespace bb::honk::sumcheck; -namespace proof_system::benchmark::relations { +namespace bb::benchmark::relations { using Fr = bb::fr; using Fq = grumpkin::fr; @@ -21,7 +21,7 @@ template void execute_relation(::benchmark: using AllValues = typename Flavor::AllValues; using SumcheckArrayOfValuesOverSubrelations = typename Relation::SumcheckArrayOfValuesOverSubrelations; - auto params = proof_system::RelationParameters::get_random(); + auto params = bb::RelationParameters::get_random(); // Extract an array containing all the polynomial evaluations at a given row i AllValues new_value{}; @@ -56,4 +56,4 @@ BENCHMARK(execute_relation>); BENCHMARK(execute_relation>); BENCHMARK(execute_relation>); -} // namespace proof_system::benchmark::relations +} // namespace bb::benchmark::relations diff --git a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/benchmark_utilities.hpp b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/benchmark_utilities.hpp index e1419a591e94..3b7bf8034550 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/benchmark_utilities.hpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/benchmark_utilities.hpp @@ -32,9 +32,9 @@ namespace bench_utils { */ template void generate_basic_arithmetic_circuit(Builder& builder, size_t log2_num_gates) { - proof_system::plonk::stdlib::field_t a(proof_system::plonk::stdlib::witness_t(&builder, bb::fr::random_element())); - proof_system::plonk::stdlib::field_t b(proof_system::plonk::stdlib::witness_t(&builder, bb::fr::random_element())); - proof_system::plonk::stdlib::field_t c(&builder); + bb::plonk::stdlib::field_t a(bb::plonk::stdlib::witness_t(&builder, bb::fr::random_element())); + bb::plonk::stdlib::field_t b(bb::plonk::stdlib::witness_t(&builder, bb::fr::random_element())); + bb::plonk::stdlib::field_t c(&builder); size_t passes = (1UL << log2_num_gates) / 4 - 4; if (static_cast(passes) <= 0) { throw std::runtime_error("too few gates"); @@ -58,9 +58,9 @@ template void generate_sha256_test_circuit(Builder& builder, { std::string in; in.resize(32); - proof_system::plonk::stdlib::packed_byte_array input(&builder, in); + bb::plonk::stdlib::packed_byte_array input(&builder, in); for (size_t i = 0; i < num_iterations; i++) { - input = proof_system::plonk::stdlib::sha256(input); + input = bb::plonk::stdlib::sha256(input); } } @@ -74,9 +74,9 @@ template void generate_keccak_test_circuit(Builder& builder, { std::string in = "abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz01"; - proof_system::plonk::stdlib::byte_array input(&builder, in); + bb::plonk::stdlib::byte_array input(&builder, in); for (size_t i = 0; i < num_iterations; i++) { - input = proof_system::plonk::stdlib::keccak::hash(input); + input = bb::plonk::stdlib::keccak::hash(input); } } @@ -88,7 +88,7 @@ template void generate_keccak_test_circuit(Builder& builder, */ template void generate_ecdsa_verification_test_circuit(Builder& builder, size_t num_iterations) { - using curve = proof_system::plonk::stdlib::secp256k1; + using curve = bb::plonk::stdlib::secp256k1; using fr = typename curve::fr; using fq = typename curve::fq; using g1 = typename curve::g1; @@ -114,19 +114,18 @@ template void generate_ecdsa_verification_test_circuit(Builde typename curve::g1_bigfr_ct public_key = curve::g1_bigfr_ct::from_witness(&builder, account.public_key); - proof_system::plonk::stdlib::ecdsa::signature sig{ typename curve::byte_array_ct(&builder, rr), - typename curve::byte_array_ct(&builder, ss), - proof_system::plonk::stdlib::uint8( - &builder, vv) }; + bb::plonk::stdlib::ecdsa::signature sig{ typename curve::byte_array_ct(&builder, rr), + typename curve::byte_array_ct(&builder, ss), + bb::plonk::stdlib::uint8(&builder, vv) }; typename curve::byte_array_ct message(&builder, message_string); // Verify ecdsa signature - proof_system::plonk::stdlib::ecdsa::verify_signature(message, public_key, sig); + bb::plonk::stdlib::ecdsa::verify_signature(message, public_key, sig); } } @@ -138,7 +137,7 @@ template void generate_ecdsa_verification_test_circuit(Builde */ template void generate_merkle_membership_test_circuit(Builder& builder, size_t num_iterations) { - using namespace proof_system::plonk::stdlib; + using namespace bb::plonk::stdlib; using field_ct = field_t; using witness_ct = witness_t; using witness_ct = witness_t; @@ -165,35 +164,33 @@ template void generate_merkle_membership_test_circuit(Builder } // ultrahonk -inline proof_system::honk::UltraProver get_prover( - proof_system::honk::UltraComposer& composer, - void (*test_circuit_function)(proof_system::honk::UltraComposer::CircuitBuilder&, size_t), - size_t num_iterations) +inline bb::honk::UltraProver get_prover(bb::honk::UltraComposer& composer, + void (*test_circuit_function)(bb::honk::UltraComposer::CircuitBuilder&, size_t), + size_t num_iterations) { - proof_system::honk::UltraComposer::CircuitBuilder builder; + bb::honk::UltraComposer::CircuitBuilder builder; test_circuit_function(builder, num_iterations); - std::shared_ptr instance = composer.create_instance(builder); + std::shared_ptr instance = composer.create_instance(builder); return composer.create_prover(instance); } // standard plonk -inline proof_system::plonk::Prover get_prover(proof_system::plonk::StandardComposer& composer, - void (*test_circuit_function)(proof_system::StandardCircuitBuilder&, - size_t), - size_t num_iterations) +inline bb::plonk::Prover get_prover(bb::plonk::StandardComposer& composer, + void (*test_circuit_function)(bb::StandardCircuitBuilder&, size_t), + size_t num_iterations) { - proof_system::StandardCircuitBuilder builder; + bb::StandardCircuitBuilder builder; test_circuit_function(builder, num_iterations); return composer.create_prover(builder); } // ultraplonk -inline proof_system::plonk::UltraProver get_prover( - proof_system::plonk::UltraComposer& composer, - void (*test_circuit_function)(proof_system::honk::UltraComposer::CircuitBuilder&, size_t), - size_t num_iterations) +inline bb::plonk::UltraProver get_prover(bb::plonk::UltraComposer& composer, + void (*test_circuit_function)(bb::honk::UltraComposer::CircuitBuilder&, + size_t), + size_t num_iterations) { - proof_system::plonk::UltraComposer::CircuitBuilder builder; + bb::plonk::UltraComposer::CircuitBuilder builder; test_circuit_function(builder, num_iterations); return composer.create_prover(builder); } diff --git a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk.bench.cpp index 610f968157fc..1109a928f4ce 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk.bench.cpp @@ -5,7 +5,7 @@ #include "barretenberg/ultra_honk/ultra_composer.hpp" using namespace benchmark; -using namespace proof_system; +using namespace bb; /** * @brief Benchmark: Construction of a Ultra Honk proof for a circuit determined by the provided circuit function diff --git a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk_rounds.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk_rounds.bench.cpp index 333b6ddcc86b..b36e168b446f 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk_rounds.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_honk_rounds.bench.cpp @@ -6,7 +6,7 @@ #include "barretenberg/ultra_honk/ultra_prover.hpp" using namespace benchmark; -using namespace proof_system; +using namespace bb; // The rounds to measure enum { diff --git a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk.bench.cpp index c9fc158c532c..0f16f152d2ce 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk.bench.cpp @@ -3,7 +3,7 @@ #include "barretenberg/proof_system/circuit_builder/ultra_circuit_builder.hpp" using namespace benchmark; -using namespace proof_system; +using namespace bb; /** * @brief Benchmark: Construction of a Ultra Plonk proof for a circuit determined by the provided circuit function diff --git a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk_rounds.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk_rounds.bench.cpp index ecc086303b97..8565dd96fbee 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk_rounds.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/ultra_bench/ultra_plonk_rounds.bench.cpp @@ -4,7 +4,7 @@ #include "barretenberg/proof_system/circuit_builder/ultra_circuit_builder.hpp" using namespace benchmark; -using namespace proof_system; +using namespace bb; // The rounds to measure enum { diff --git a/barretenberg/cpp/src/barretenberg/benchmark/widgets_bench/widget.bench.cpp b/barretenberg/cpp/src/barretenberg/benchmark/widgets_bench/widget.bench.cpp index 0ec974da527d..b96f9f6ce78c 100644 --- a/barretenberg/cpp/src/barretenberg/benchmark/widgets_bench/widget.bench.cpp +++ b/barretenberg/cpp/src/barretenberg/benchmark/widgets_bench/widget.bench.cpp @@ -22,7 +22,7 @@ namespace { auto& engine = numeric::random::get_debug_engine(); } -namespace proof_system::plonk { +namespace bb::plonk { #ifdef GET_PER_ROW_TIME constexpr size_t LARGE_DOMAIN_SIZE = 4; @@ -113,4 +113,4 @@ BENCHMARK(accumulate_contribution>); BENCHMARK(accumulate_contribution>); BENCHMARK(accumulate_contribution>); -} // namespace proof_system::plonk +} // namespace bb::plonk diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/claim.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/claim.hpp index 27dea27d3582..2ef8c69637ed 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/claim.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/claim.hpp @@ -3,7 +3,7 @@ #include "barretenberg/commitment_schemes/commitment_key.hpp" #include "barretenberg/polynomials/polynomial.hpp" -namespace proof_system::honk::pcs { +namespace bb::honk::pcs { /** * @brief Opening pair (r,v) for some witness polynomial p(X) such that p(r) = v * @@ -72,4 +72,4 @@ template class OpeningClaim { bool operator==(const OpeningClaim& other) const = default; }; -} // namespace proof_system::honk::pcs +} // namespace bb::honk::pcs diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp index c820054558a9..201a022fdb57 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.hpp @@ -19,7 +19,7 @@ #include #include -namespace proof_system::honk::pcs { +namespace bb::honk::pcs { /** * @brief CommitmentKey object over a pairing group 𝔾₁. @@ -74,4 +74,4 @@ template class CommitmentKey { std::shared_ptr> srs; }; -} // namespace proof_system::honk::pcs +} // namespace bb::honk::pcs diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.test.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.test.hpp index 27d8e2ed93fc..df031f7404dc 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.test.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/commitment_key.test.hpp @@ -13,7 +13,7 @@ #include -namespace proof_system::honk::pcs { +namespace bb::honk::pcs { template inline std::shared_ptr CreateCommitmentKey(); @@ -206,4 +206,4 @@ using IpaCommitmentSchemeParams = ::testing::Types; // using CommitmentSchemeParams = // ::testing::Types, fake::Params, kzg::Params>; -} // namespace proof_system::honk::pcs +} // namespace bb::honk::pcs diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.cpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.cpp index 72705c516db7..0d1890abd669 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.cpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.cpp @@ -42,7 +42,7 @@ * The verifier is able to computed the simulated commitments to A₀₊(X) and A₀₋(X) * since they are linear-combinations of the commitments [fⱼ] and [gⱼ]. */ -namespace proof_system::honk::pcs::gemini { +namespace bb::honk::pcs::gemini { /** * @brief Computes d-1 fold polynomials Fold_i, i = 1, ..., d-1 @@ -188,4 +188,4 @@ ProverOutput GeminiProver_::compute_fold_polynomial_evaluations( template class GeminiProver_; template class GeminiProver_; -}; // namespace proof_system::honk::pcs::gemini +}; // namespace bb::honk::pcs::gemini diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.hpp index 03b77e9645f1..c417b4b76b35 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.hpp @@ -42,7 +42,7 @@ * The verifier is able to computed the simulated commitments to A₀₊(X) and A₀₋(X) * since they are linear-combinations of the commitments [fⱼ] and [gⱼ]. */ -namespace proof_system::honk::pcs::gemini { +namespace bb::honk::pcs::gemini { /** * @brief Prover output (evalutation pair, witness) that can be passed on to Shplonk batch opening. @@ -109,7 +109,7 @@ template class GeminiProver_ { static ProverOutput compute_fold_polynomial_evaluations(std::span mle_opening_point, std::vector&& gemini_polynomials, const Fr& r_challenge); -}; // namespace proof_system::honk::pcs::gemini +}; // namespace bb::honk::pcs::gemini template class GeminiVerifier_ { using Fr = typename Curve::ScalarField; @@ -262,6 +262,6 @@ template class GeminiVerifier_ { return { C0_r_pos, C0_r_neg }; } -}; // namespace proof_system::honk::pcs::gemini +}; // namespace bb::honk::pcs::gemini -} // namespace proof_system::honk::pcs::gemini +} // namespace bb::honk::pcs::gemini diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.test.cpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.test.cpp index 80b93ed89e3c..1d6dd6779c21 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.test.cpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/gemini/gemini.test.cpp @@ -7,7 +7,7 @@ #include #include -namespace proof_system::honk::pcs::gemini { +namespace bb::honk::pcs::gemini { template class GeminiTest : public CommitmentTest { using GeminiProver = GeminiProver_; @@ -238,4 +238,4 @@ TYPED_TEST(GeminiTest, DoubleWithShift) multilinear_commitments_to_be_shifted); } -} // namespace proof_system::honk::pcs::gemini +} // namespace bb::honk::pcs::gemini diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.hpp index b4b2a405187a..9a254f347402 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.hpp @@ -14,7 +14,7 @@ * https://hackmd.io/q-A8y6aITWyWJrvsGGMWNA?view. * */ -namespace proof_system::honk::pcs::ipa { +namespace bb::honk::pcs::ipa { template class IPA { using Fr = typename Curve::ScalarField; using GroupElement = typename Curve::Element; @@ -280,4 +280,4 @@ template class IPA { } }; -} // namespace proof_system::honk::pcs::ipa \ No newline at end of file +} // namespace bb::honk::pcs::ipa \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.test.cpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.test.cpp index 6abfce080c67..3a9c26d1961d 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.test.cpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/ipa/ipa.test.cpp @@ -9,7 +9,7 @@ #include "barretenberg/polynomials/polynomial_arithmetic.hpp" #include using namespace bb; -namespace proof_system::honk::pcs::ipa::test { +namespace bb::honk::pcs::ipa::test { using Curve = curve::Grumpkin; @@ -176,4 +176,4 @@ TEST_F(IPATest, GeminiShplonkIPAWithShift) EXPECT_EQ(verified, true); } -} // namespace proof_system::honk::pcs::ipa::test +} // namespace bb::honk::pcs::ipa::test diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.hpp index 940cefd30e85..3780b10ef85d 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.hpp @@ -9,7 +9,7 @@ #include #include -namespace proof_system::honk::pcs::kzg { +namespace bb::honk::pcs::kzg { template class KZG { using CK = CommitmentKey; @@ -101,4 +101,4 @@ template class KZG { return { P_0, P_1 }; }; }; -} // namespace proof_system::honk::pcs::kzg +} // namespace bb::honk::pcs::kzg diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.test.cpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.test.cpp index e55633c575ce..5e933bb7d6cd 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.test.cpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/kzg/kzg.test.cpp @@ -12,7 +12,7 @@ #include #include -namespace proof_system::honk::pcs::kzg { +namespace bb::honk::pcs::kzg { template class KZGTest : public CommitmentTest { public: @@ -177,4 +177,4 @@ TYPED_TEST(KZGTest, GeminiShplonkKzgWithShift) EXPECT_EQ(verified, true); } -} // namespace proof_system::honk::pcs::kzg +} // namespace bb::honk::pcs::kzg diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.hpp index fd61cf431913..7f0f53093a47 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.hpp @@ -18,7 +18,7 @@ * The challenges are ρ (batching) and r (random evaluation). * */ -namespace proof_system::honk::pcs::shplonk { +namespace bb::honk::pcs::shplonk { /** * @brief Polynomial G(X) = Q(X) - ∑ₖ ẑₖ(r)⋅( Bₖ(X) − Tₖ(z) ), where Q(X) = ∑ₖ ( Bₖ(X) − Tₖ(X) ) / zₖ(X) @@ -271,4 +271,4 @@ template class ShplonkVerifier_ { return { { z_challenge, Fr(0) }, G_commitment }; }; }; -} // namespace proof_system::honk::pcs::shplonk +} // namespace bb::honk::pcs::shplonk diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.test.cpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.test.cpp index fbf01d10f5d0..6e754ae127b1 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.test.cpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/shplonk/shplonk.test.cpp @@ -10,7 +10,7 @@ #include "../commitment_key.test.hpp" #include "barretenberg/commitment_schemes/claim.hpp" #include "barretenberg/polynomials/polynomial.hpp" -namespace proof_system::honk::pcs::shplonk { +namespace bb::honk::pcs::shplonk { template class ShplonkTest : public CommitmentTest {}; using CurveTypes = ::testing::Types; @@ -71,4 +71,4 @@ TYPED_TEST(ShplonkTest, ShplonkSimple) this->verify_opening_claim(verifier_claim, shplonk_prover_witness); } -} // namespace proof_system::honk::pcs::shplonk +} // namespace bb::honk::pcs::shplonk diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/verification_key.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/verification_key.hpp index b9bcb636d11b..3d6429875bc5 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/verification_key.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/verification_key.hpp @@ -20,7 +20,7 @@ #include #include -namespace proof_system::honk::pcs { +namespace bb::honk::pcs { template class VerifierCommitmentKey; @@ -98,4 +98,4 @@ template <> class VerifierCommitmentKey { std::shared_ptr> srs; }; -} // namespace proof_system::honk::pcs +} // namespace bb::honk::pcs diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/wrapper.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/wrapper.hpp index 0fb5d130875a..a79d42e5f1f4 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/wrapper.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/wrapper.hpp @@ -3,7 +3,7 @@ #include "barretenberg/ecc/curves/bn254/g1.hpp" #include "gemini/gemini.hpp" -namespace proof_system::honk { +namespace bb::honk { struct OpeningProof { std::vector gemini; @@ -11,4 +11,4 @@ struct OpeningProof { bb::g1::affine_element kzg; }; -} // namespace proof_system::honk +} // namespace bb::honk diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.hpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.hpp index 562f90cf3554..9878925c2361 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.hpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.hpp @@ -5,7 +5,7 @@ #include "barretenberg/polynomials/polynomial.hpp" #include "barretenberg/transcript/transcript.hpp" -namespace proof_system::honk::pcs::zeromorph { +namespace bb::honk::pcs::zeromorph { /** * @brief Compute powers of a given challenge @@ -728,4 +728,4 @@ template class ZeroMorphVerifier_ { } }; -} // namespace proof_system::honk::pcs::zeromorph +} // namespace bb::honk::pcs::zeromorph diff --git a/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.test.cpp b/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.test.cpp index dcc5e39bed1a..e933aaa07faf 100644 --- a/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.test.cpp +++ b/barretenberg/cpp/src/barretenberg/commitment_schemes/zeromorph/zeromorph.test.cpp @@ -4,7 +4,7 @@ #include -namespace proof_system::honk::pcs::zeromorph { +namespace bb::honk::pcs::zeromorph { template class ZeroMorphTest : public CommitmentTest { public: @@ -532,4 +532,4 @@ TYPED_TEST(ZeroMorphWithConcatenationTest, ProveAndVerify) auto verified = this->execute_zeromorph_protocol(num_unshifted, num_shifted, num_concatenated); EXPECT_TRUE(verified); } -} // namespace proof_system::honk::pcs::zeromorph +} // namespace bb::honk::pcs::zeromorph diff --git a/barretenberg/cpp/src/barretenberg/common/fuzzer.hpp b/barretenberg/cpp/src/barretenberg/common/fuzzer.hpp index 2e56c71afa98..9ffa30975f04 100644 --- a/barretenberg/cpp/src/barretenberg/common/fuzzer.hpp +++ b/barretenberg/cpp/src/barretenberg/common/fuzzer.hpp @@ -690,7 +690,7 @@ template