Skip to content

Commit

Permalink
Revert "fix: revert "feat: sol shplemini in acir tests + contract_gen" (
Browse files Browse the repository at this point in the history
#9505)"

This reverts commit 3351217.
  • Loading branch information
Maddiaa0 authored Oct 29, 2024
1 parent 74bcfab commit 619a9ad
Show file tree
Hide file tree
Showing 16 changed files with 676 additions and 559 deletions.
2 changes: 1 addition & 1 deletion barretenberg/acir_tests/sol-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
},
"dependencies": {
"ethers": "^6.8.1",
"solc": "^0.8.22"
"solc": "^0.8.27"
}
}
4 changes: 1 addition & 3 deletions barretenberg/acir_tests/sol-test/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@ import { ethers } from "ethers";
import solc from "solc";

const NUMBER_OF_FIELDS_IN_PLONK_PROOF = 93;
// TODO(https://github.com/AztecProtocol/barretenberg/issues/1093): This is the size of the proof up to Sumcheck, without public inputs, as the Honk contract does not currently have a PCS.
// This needs to be changed once Shplemini is implemented in the smart contract.
const NUMBER_OF_FIELDS_IN_HONK_PROOF = 303;
const NUMBER_OF_FIELDS_IN_HONK_PROOF = 447;

// We use the solcjs compiler version in this test, although it is slower than foundry, to run the test end to end
// it simplifies of parallelising the test suite
Expand Down
8 changes: 4 additions & 4 deletions barretenberg/acir_tests/sol-test/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,10 @@ semver@^5.5.0:
resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8"
integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==

solc@^0.8.22:
version "0.8.22"
resolved "https://registry.yarnpkg.com/solc/-/solc-0.8.22.tgz#6df0bb688b9a58bbf10932730301374a6ccfb862"
integrity sha512-bA2tMZXx93R8L5LUH7TlB/f+QhkVyxrrY6LmgJnFFZlRknrhYVlBK1e3uHIdKybwoFabOFSzeaZjPeL/GIpFGQ==
solc@^0.8.27:
version "0.8.27"
resolved "https://registry.yarnpkg.com/solc/-/solc-0.8.27.tgz#cb8e7246cceadad8df65ceccffe640e106106bb4"
integrity sha512-BNxMol2tUAbkH7HKlXBcBqrGi2aqgv+uMHz26mJyTtlVgWmBA4ktiw0qVKHfkjf2oaHbwtbtaSeE2dhn/gTAKw==
dependencies:
command-exists "^1.2.8"
commander "^8.1.0"
Expand Down
7 changes: 0 additions & 7 deletions barretenberg/cpp/src/barretenberg/bb/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1110,13 +1110,6 @@ void prove_honk(const std::string& bytecodePath, const std::string& witnessPath,
// Construct Honk proof
Prover prover = compute_valid_prover<Flavor>(bytecodePath, witnessPath);
auto proof = prover.construct_proof();
// TODO(https://github.com/AztecProtocol/barretenberg/issues/1093): As the Smart contract doesn't verify the PCS and
// Shplemini is not constant size, we slice the proof up to sumcheck so calculation of public inputs is correct.
// This hack will be subsequently removed.
if constexpr (std::same_as<Flavor, UltraKeccakFlavor>) {
auto num_public_inputs = static_cast<uint32_t>(prover.proving_key->proving_key.num_public_inputs);
proof.erase(proof.begin() + num_public_inputs + 303, proof.end());
}
if (outputPath == "-") {
writeRawBytesToStdout(to_buffer</*include_size=*/true>(proof));
vinfo("proof written to stdout");
Expand Down
Loading

0 comments on commit 619a9ad

Please sign in to comment.