Conversation
Changes to circuit sizes
🧾 Summary (100% most significant diffs)
Full diff report 👇
|
There was a problem hiding this comment.
⚠️ Performance Alert ⚠️
Possible performance regression was detected for benchmark 'C++ Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.05.
| Benchmark suite | Current: bd0f782 | Previous: 199faca | Ratio |
|---|---|---|---|
nativeClientIVCBench/Full/6 |
14119.553545999992 ms/iter |
13343.767048000018 ms/iter |
1.06 |
wasmClientIVCBench/Full/6 |
42536.842025000005 ms/iter |
39779.408566 ms/iter |
1.07 |
commit(t) |
4754440779 ns/iter |
3669937899 ns/iter |
1.30 |
commit(t) |
3911801016 ns/iter |
3669937899 ns/iter |
1.07 |
This comment was automatically generated by workflow using github-action-benchmark.
CC: @ludamad @codygunton
| assert(item.public_inputs.call_context.is_delegate_call == is_delegate_call); | ||
| assert(item.public_inputs.call_context.is_static_call == is_static_call); | ||
|
|
||
| if (is_delegate_call) { |
There was a problem hiding this comment.
The same checks for (non_)delegate call is done in the kernel and must be done there. It's not necessary to check them here in the app circuit. If we want to abort early before executing kernel circuits, can check and throw from the simulator.
| assert_eq(request.hash, hash, "call stack hash does not match call request hash"); | ||
| assert_eq(request.caller_contract_address, caller.contract_address, "invalid caller contract address"); | ||
| validate_caller_context(request.caller_context, caller.public_inputs.call_context) | ||
| fn validate_call_context( |
There was a problem hiding this comment.
This is checked on all the private call requests emitted from a private call.
We've replaced the caller context with call context in the call request, and check the addresses in the call context instead.
Which means we don't have to check the addresses again in a nested call (in validate_against_call_request), it's legit as long as the call context in the request matches the one in the call stack item.
| } | ||
|
|
||
| assert_eq( | ||
| call_context.function_selector, self.data.call_stack_item.function_data.selector, "function selector in call context does not match call stack item" |
There was a problem hiding this comment.
I don't think we checked this before. We need to ensure that a nested call's function selector is what the caller expects.
| PackedReturns::new(returns_hash) | ||
| } | ||
|
|
||
| pub fn call_public_function<let ARGS_COUNT: u32>( |
There was a problem hiding this comment.
With the changes, it's 5k less to call/enqueue a public function.
| previous_kernel.end.unencrypted_logs_hashes, | ||
| array_lengths.unencrypted_logs_hashes | ||
| ); | ||
| validate_array_prepended( |
There was a problem hiding this comment.
Unfortunately this has increased 4k gate counts, contributing most part of the increment of init (3471) and inner (6489).
I think there's some unreasonably heavy stuffs going on and we should be able to reduce it a bit. (Will refactor in another pr!)
| storage_contract_address | ||
| ); | ||
| validate_array_appended_reversed_scoped( | ||
| validate_array_appended( |
There was a problem hiding this comment.
This adds another 3k to inner :(
Same as above, will investigate and try to reduce it in the next pr.
Benchmark resultsMetrics with a significant change:
Detailed resultsAll benchmarks are run on txs on the This benchmark source data is available in JSON format on S3 here. Proof generationEach column represents the number of threads used in proof generation.
L2 block published to L1Each column represents the number of txs on an L2 block published to L1.
L2 chain processingEach column represents the number of blocks on the L2 chain where each block has 8 txs.
Circuits statsStats on running time and I/O sizes collected for every kernel circuit run across all benchmarks.
Stats on running time collected for app circuits
AVM SimulationTime to simulate various public functions in the AVM.
Public DB AccessTime to access various public DBs.
Tree insertion statsThe duration to insert a fixed batch of leaves into each tree type.
MiscellaneousTransaction sizes based on how many contract classes are registered in the tx.
Transaction size based on fee payment method | Metric | | |
...ir-protocol-circuits/crates/private-kernel-lib/src/components/private_call_data_validator.nr
Show resolved
Hide resolved
🤖 I have created a release *beep* *boop* --- <details><summary>aztec-package: 0.47.1</summary> ## [0.47.1](aztec-package-v0.47.0...aztec-package-v0.47.1) (2024-07-30) ### Features * Do not evict tx objects from p2p tx pool immediately ([#7652](#7652)) ([96492dc](96492dc)) * Min and max block times for sequencer ([#7630](#7630)) ([2a013b8](2a013b8)) * Transaction sender bot ([#7586](#7586)) ([176fd08](176fd08)), closes [#7562](#7562) ### Bug Fixes * Aztec start --prover ([#7617](#7617)) ([ac206a6](ac206a6)) ### Miscellaneous * Add tx bot to terraform ([#7609](#7609)) ([6caa914](6caa914)) * Merge Devnet back to Master ([#7611](#7611)) ([112961c](112961c)) </details> <details><summary>barretenberg.js: 0.47.1</summary> ## [0.47.1](barretenberg.js-v0.47.0...barretenberg.js-v0.47.1) (2024-07-30) ### Miscellaneous * **barretenberg.js:** Synchronize aztec-packages versions </details> <details><summary>aztec-packages: 0.47.1</summary> ## [0.47.1](aztec-packages-v0.47.0...aztec-packages-v0.47.1) (2024-07-30) ### Features * Add recursive aggregation object to proving/verification keys ([#6770](#6770)) ([f48b069](f48b069)) * Adding aggregation to honk and rollup ([#7466](#7466)) ([2633aa9](2633aa9)) * Allow get_notes to return zero notes ([#7621](#7621)) ([e16452a](e16452a)) * **avm:** Pedersen commit in avm ([#7634](#7634)) ([45e7867](45e7867)) * **avm:** Pedersen commitment sim ([#7632](#7632)) ([cc420a0](cc420a0)) * Do not evict tx objects from p2p tx pool immediately ([#7652](#7652)) ([96492dc](96492dc)) * Handle L1toL2 msgs in prover-node ([#7654](#7654)) ([f35bac5](f35bac5)) * Leonidas ([#7597](#7597)) ([eda498a](eda498a)) * Min and max block times for sequencer ([#7630](#7630)) ([2a013b8](2a013b8)) * **sol-honk:** Integrate solidity honk verifier with bb and acir tests ([#7573](#7573)) ([344ca6f](344ca6f)) * **sol-honk:** Test verifying recursive proof ([#7576](#7576)) ([26408c1](26408c1)) * Static.aztec.network ([#7649](#7649)) ([9dffef5](9dffef5)) * Transaction sender bot ([#7586](#7586)) ([176fd08](176fd08)), closes [#7562](#7562) ### Bug Fixes * Aztec start --prover ([#7617](#7617)) ([ac206a6](ac206a6)) * Bb mac build ([#7619](#7619)) ([e3c5602](e3c5602)) * Faucet correctly derives its account ([#7645](#7645)) ([921773f](921773f)) * Uniswap e2e test "nonce too low" ([#7633](#7633)) ([e9e2318](e9e2318)) ### Miscellaneous * Add tx bot to terraform ([#7609](#7609)) ([6caa914](6caa914)) * **bb readme:** Add installation instructions and TODOs ([#7601](#7601)) ([1a97698](1a97698)) * **bb readme:** Update versioning instructions and add Honk Solidity verifier commands ([#7608](#7608)) ([9dd9195](9dd9195)) * Bench client ivc proof verification ([#7553](#7553)) ([b060309](b060309)) * Call requests ([#7483](#7483)) ([ffedf39](ffedf39)) * Constant inputs for most blackboxes ([#7613](#7613)) ([3247058](3247058)) * **docs:** Fix links ([#7602](#7602)) ([f2029be](f2029be)) * Merge Devnet back to Master ([#7611](#7611)) ([112961c](112961c)) * **p2p:** Tx serialization cleanup ([#7620](#7620)) ([022a899](022a899)) * Replace relative paths to noir-protocol-circuits ([ebaafc7](ebaafc7)) * Replace relative paths to noir-protocol-circuits ([d3b818d](d3b818d)) * Replace relative paths to noir-protocol-circuits ([4a26a19](4a26a19)) </details> <details><summary>barretenberg: 0.47.1</summary> ## [0.47.1](barretenberg-v0.47.0...barretenberg-v0.47.1) (2024-07-30) ### Features * Add recursive aggregation object to proving/verification keys ([#6770](#6770)) ([f48b069](f48b069)) * Adding aggregation to honk and rollup ([#7466](#7466)) ([2633aa9](2633aa9)) * **avm:** Pedersen commit in avm ([#7634](#7634)) ([45e7867](45e7867)) * **avm:** Pedersen commitment sim ([#7632](#7632)) ([cc420a0](cc420a0)) * **sol-honk:** Integrate solidity honk verifier with bb and acir tests ([#7573](#7573)) ([344ca6f](344ca6f)) * **sol-honk:** Test verifying recursive proof ([#7576](#7576)) ([26408c1](26408c1)) ### Bug Fixes * Bb mac build ([#7619](#7619)) ([e3c5602](e3c5602)) ### Miscellaneous * **bb readme:** Add installation instructions and TODOs ([#7601](#7601)) ([1a97698](1a97698)) * **bb readme:** Update versioning instructions and add Honk Solidity verifier commands ([#7608](#7608)) ([9dd9195](9dd9195)) * Call requests ([#7483](#7483)) ([ffedf39](ffedf39)) * Constant inputs for most blackboxes ([#7613](#7613)) ([3247058](3247058)) * Merge Devnet back to Master ([#7611](#7611)) ([112961c](112961c)) </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
🤖 I have created a release *beep* *boop* --- <details><summary>aztec-package: 0.47.1</summary> ## [0.47.1](AztecProtocol/aztec-packages@aztec-package-v0.47.0...aztec-package-v0.47.1) (2024-07-30) ### Features * Do not evict tx objects from p2p tx pool immediately ([#7652](AztecProtocol/aztec-packages#7652)) ([96492dc](AztecProtocol/aztec-packages@96492dc)) * Min and max block times for sequencer ([#7630](AztecProtocol/aztec-packages#7630)) ([2a013b8](AztecProtocol/aztec-packages@2a013b8)) * Transaction sender bot ([#7586](AztecProtocol/aztec-packages#7586)) ([176fd08](AztecProtocol/aztec-packages@176fd08)), closes [#7562](AztecProtocol/aztec-packages#7562) ### Bug Fixes * Aztec start --prover ([#7617](AztecProtocol/aztec-packages#7617)) ([ac206a6](AztecProtocol/aztec-packages@ac206a6)) ### Miscellaneous * Add tx bot to terraform ([#7609](AztecProtocol/aztec-packages#7609)) ([6caa914](AztecProtocol/aztec-packages@6caa914)) * Merge Devnet back to Master ([#7611](AztecProtocol/aztec-packages#7611)) ([112961c](AztecProtocol/aztec-packages@112961c)) </details> <details><summary>barretenberg.js: 0.47.1</summary> ## [0.47.1](AztecProtocol/aztec-packages@barretenberg.js-v0.47.0...barretenberg.js-v0.47.1) (2024-07-30) ### Miscellaneous * **barretenberg.js:** Synchronize aztec-packages versions </details> <details><summary>aztec-packages: 0.47.1</summary> ## [0.47.1](AztecProtocol/aztec-packages@aztec-packages-v0.47.0...aztec-packages-v0.47.1) (2024-07-30) ### Features * Add recursive aggregation object to proving/verification keys ([#6770](AztecProtocol/aztec-packages#6770)) ([f48b069](AztecProtocol/aztec-packages@f48b069)) * Adding aggregation to honk and rollup ([#7466](AztecProtocol/aztec-packages#7466)) ([2633aa9](AztecProtocol/aztec-packages@2633aa9)) * Allow get_notes to return zero notes ([#7621](AztecProtocol/aztec-packages#7621)) ([e16452a](AztecProtocol/aztec-packages@e16452a)) * **avm:** Pedersen commit in avm ([#7634](AztecProtocol/aztec-packages#7634)) ([45e7867](AztecProtocol/aztec-packages@45e7867)) * **avm:** Pedersen commitment sim ([#7632](AztecProtocol/aztec-packages#7632)) ([cc420a0](AztecProtocol/aztec-packages@cc420a0)) * Do not evict tx objects from p2p tx pool immediately ([#7652](AztecProtocol/aztec-packages#7652)) ([96492dc](AztecProtocol/aztec-packages@96492dc)) * Handle L1toL2 msgs in prover-node ([#7654](AztecProtocol/aztec-packages#7654)) ([f35bac5](AztecProtocol/aztec-packages@f35bac5)) * Leonidas ([#7597](AztecProtocol/aztec-packages#7597)) ([eda498a](AztecProtocol/aztec-packages@eda498a)) * Min and max block times for sequencer ([#7630](AztecProtocol/aztec-packages#7630)) ([2a013b8](AztecProtocol/aztec-packages@2a013b8)) * **sol-honk:** Integrate solidity honk verifier with bb and acir tests ([#7573](AztecProtocol/aztec-packages#7573)) ([344ca6f](AztecProtocol/aztec-packages@344ca6f)) * **sol-honk:** Test verifying recursive proof ([#7576](AztecProtocol/aztec-packages#7576)) ([26408c1](AztecProtocol/aztec-packages@26408c1)) * Static.aztec.network ([#7649](AztecProtocol/aztec-packages#7649)) ([9dffef5](AztecProtocol/aztec-packages@9dffef5)) * Transaction sender bot ([#7586](AztecProtocol/aztec-packages#7586)) ([176fd08](AztecProtocol/aztec-packages@176fd08)), closes [#7562](AztecProtocol/aztec-packages#7562) ### Bug Fixes * Aztec start --prover ([#7617](AztecProtocol/aztec-packages#7617)) ([ac206a6](AztecProtocol/aztec-packages@ac206a6)) * Bb mac build ([#7619](AztecProtocol/aztec-packages#7619)) ([e3c5602](AztecProtocol/aztec-packages@e3c5602)) * Faucet correctly derives its account ([#7645](AztecProtocol/aztec-packages#7645)) ([921773f](AztecProtocol/aztec-packages@921773f)) * Uniswap e2e test "nonce too low" ([#7633](AztecProtocol/aztec-packages#7633)) ([e9e2318](AztecProtocol/aztec-packages@e9e2318)) ### Miscellaneous * Add tx bot to terraform ([#7609](AztecProtocol/aztec-packages#7609)) ([6caa914](AztecProtocol/aztec-packages@6caa914)) * **bb readme:** Add installation instructions and TODOs ([#7601](AztecProtocol/aztec-packages#7601)) ([1a97698](AztecProtocol/aztec-packages@1a97698)) * **bb readme:** Update versioning instructions and add Honk Solidity verifier commands ([#7608](AztecProtocol/aztec-packages#7608)) ([9dd9195](AztecProtocol/aztec-packages@9dd9195)) * Bench client ivc proof verification ([#7553](AztecProtocol/aztec-packages#7553)) ([b060309](AztecProtocol/aztec-packages@b060309)) * Call requests ([#7483](AztecProtocol/aztec-packages#7483)) ([ffedf39](AztecProtocol/aztec-packages@ffedf39)) * Constant inputs for most blackboxes ([#7613](AztecProtocol/aztec-packages#7613)) ([3247058](AztecProtocol/aztec-packages@3247058)) * **docs:** Fix links ([#7602](AztecProtocol/aztec-packages#7602)) ([f2029be](AztecProtocol/aztec-packages@f2029be)) * Merge Devnet back to Master ([#7611](AztecProtocol/aztec-packages#7611)) ([112961c](AztecProtocol/aztec-packages@112961c)) * **p2p:** Tx serialization cleanup ([#7620](AztecProtocol/aztec-packages#7620)) ([022a899](AztecProtocol/aztec-packages@022a899)) * Replace relative paths to noir-protocol-circuits ([ebaafc7](AztecProtocol/aztec-packages@ebaafc7)) * Replace relative paths to noir-protocol-circuits ([d3b818d](AztecProtocol/aztec-packages@d3b818d)) * Replace relative paths to noir-protocol-circuits ([4a26a19](AztecProtocol/aztec-packages@4a26a19)) </details> <details><summary>barretenberg: 0.47.1</summary> ## [0.47.1](AztecProtocol/aztec-packages@barretenberg-v0.47.0...barretenberg-v0.47.1) (2024-07-30) ### Features * Add recursive aggregation object to proving/verification keys ([#6770](AztecProtocol/aztec-packages#6770)) ([f48b069](AztecProtocol/aztec-packages@f48b069)) * Adding aggregation to honk and rollup ([#7466](AztecProtocol/aztec-packages#7466)) ([2633aa9](AztecProtocol/aztec-packages@2633aa9)) * **avm:** Pedersen commit in avm ([#7634](AztecProtocol/aztec-packages#7634)) ([45e7867](AztecProtocol/aztec-packages@45e7867)) * **avm:** Pedersen commitment sim ([#7632](AztecProtocol/aztec-packages#7632)) ([cc420a0](AztecProtocol/aztec-packages@cc420a0)) * **sol-honk:** Integrate solidity honk verifier with bb and acir tests ([#7573](AztecProtocol/aztec-packages#7573)) ([344ca6f](AztecProtocol/aztec-packages@344ca6f)) * **sol-honk:** Test verifying recursive proof ([#7576](AztecProtocol/aztec-packages#7576)) ([26408c1](AztecProtocol/aztec-packages@26408c1)) ### Bug Fixes * Bb mac build ([#7619](AztecProtocol/aztec-packages#7619)) ([e3c5602](AztecProtocol/aztec-packages@e3c5602)) ### Miscellaneous * **bb readme:** Add installation instructions and TODOs ([#7601](AztecProtocol/aztec-packages#7601)) ([1a97698](AztecProtocol/aztec-packages@1a97698)) * **bb readme:** Update versioning instructions and add Honk Solidity verifier commands ([#7608](AztecProtocol/aztec-packages#7608)) ([9dd9195](AztecProtocol/aztec-packages@9dd9195)) * Call requests ([#7483](AztecProtocol/aztec-packages#7483)) ([ffedf39](AztecProtocol/aztec-packages@ffedf39)) * Constant inputs for most blackboxes ([#7613](AztecProtocol/aztec-packages#7613)) ([3247058](AztecProtocol/aztec-packages@3247058)) * Merge Devnet back to Master ([#7611](AztecProtocol/aztec-packages#7611)) ([112961c](AztecProtocol/aztec-packages@112961c)) </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Uh oh!
There was an error while loading. Please reload this page.