Skip to content
This repository was archived by the owner on Jul 10, 2026. It is now read-only.

feat: replace vault deployer with generic cyclic deployer - #352

Closed
ilpepepig wants to merge 3 commits into
devfrom
feat/generic-cyclic-deployer
Closed

feat: replace vault deployer with generic cyclic deployer#352
ilpepepig wants to merge 3 commits into
devfrom
feat/generic-cyclic-deployer

Conversation

@ilpepepig

Copy link
Copy Markdown
Contributor

🤖 Linear

Closes AZT-XXX

Description

@github-actions

This comment has been minimized.

@github-actions

Copy link
Copy Markdown

Benchmark Comparison

CPU Cores RAM Arch
AMD EPYC 9V74 80-Core Processor 16 63 GiB x64

Contract: escrow

🚦 Function Gates DA Gas L2 Gas Proving Time (ms)
Base PR Diff Base PR Diff Base PR Diff Base PR Diff
(partial) withdraw 532,162 532,162 1,312 1,312 495,400 495,400 6,933 7,348 +415 (+6.0%)
withdraw 532,162 532,162 736 736 483,700 483,700 6,966 7,349 +383 (+5.5%)
withdraw_nft 503,323 503,323 736 736 483,700 483,700 6,814 7,200 +386 (+5.7%)

Contract: logic

🚦 Function Gates DA Gas L2 Gas Proving Time (ms)
Base PR Diff Base PR Diff Base PR Diff Base PR Diff
get_escrow 488,339 488,339 128 128 456,000 456,000 6,666 7,065 +399 (+6.0%)
secret_key_to_public_keys 483,417 483,417 128 128 456,000 456,000 6,622 7,088 +466 (+7.0%)
share_escrow 387,745 387,745 704 704 474,500 474,500 5,839 6,227 +388 (+6.6%)

Contract: nft

🚦 Function Gates DA Gas L2 Gas Proving Time (ms)
Base PR Diff Base PR Diff Base PR Diff Base PR Diff
burn_private 422,217 422,217 416 416 661,169 661,169 6,128 6,489 +361 (+5.9%)
burn_public 308,698 308,698 448 448 670,145 670,145 5,239 5,507 +268 (+5.1%)
mint_to_private 439,895 439,895 960 960 652,042 652,042 6,242 6,623 +381 (+6.1%)
mint_to_public 308,698 308,698 448 448 670,790 670,790 5,205 5,516 +311 (+6.0%)
transfer_private_to_private 394,899 394,899 736 736 483,700 483,700 5,898 6,293 +395 (+6.7%)
transfer_private_to_public 422,293 422,293 416 416 659,249 659,249 6,100 6,465 +365 (+6.0%)
transfer_public_to_private 436,536 436,536 960 960 652,459 652,459 6,201 6,609 +408 (+6.6%)
transfer_public_to_public 308,698 308,698 384 384 633,270 633,270 5,202 5,554 +352 (+6.8%)

Contract: token

🚦 Function Gates DA Gas L2 Gas Proving Time (ms)
Base PR Diff Base PR Diff Base PR Diff Base PR Diff
burn_private 447,046 447,046 992 992 682,815 682,815 6,293 6,699 +406 (+6.5%)
burn_public 308,698 308,698 448 448 668,939 668,939 5,193 5,517 +324 (+6.2%)
initialize_transfer_commitment 371,233 371,233 704 704 474,500 474,500 5,741 6,111 +370 (+6.4%)
mint_to_private 440,787 440,787 960 960 651,853 651,853 6,252 6,622 +370 (+5.9%)
mint_to_public 308,698 308,698 448 448 671,882 671,882 5,177 5,520 +343 (+6.6%)
transfer_private_to_commitment 404,209 404,209 896 896 495,400 495,400 5,984 6,358 +374 (+6.3%)
transfer_private_to_private 423,732 423,732 1,312 1,312 495,400 495,400 6,081 6,434 +353 (+5.8%)
transfer_private_to_public 447,122 447,122 992 992 683,040 683,040 6,285 6,646 +361 (+5.7%)
transfer_private_to_public_with_commitment 450,566 450,566 1,568 1,568 716,340 716,340 6,310 6,687 +377 (+6.0%)
transfer_public_to_commitment 308,698 308,698 576 576 658,995 658,995 5,204 5,532 +328 (+6.3%)
transfer_public_to_private 437,430 437,430 960 960 652,321 652,321 6,240 6,617 +377 (+6.0%)
transfer_public_to_public 308,698 308,698 448 448 669,014 669,014 5,211 5,517 +306 (+5.9%)

Contract: vault

🚦 Function Gates DA Gas L2 Gas Proving Time (ms)
Base PR Diff Base PR Diff Base PR Diff Base PR Diff
deposit_private_to_private 856,726 856,726 1,280 1,280 846,413 846,440 +27 (+0.0%) 9,712 10,265 +553 (+5.7%)
deposit_private_to_private_exact 965,570 965,570 1,856 1,856 883,247 883,274 +27 (+0.0%) 10,614 11,254 +640 (+6.0%)
deposit_private_to_public 674,318 674,318 768 768 861,235 861,262 +27 (+0.0%) 8,220 8,664 +444 (+5.4%)
deposit_public_to_private 554,293 554,293 1,344 1,344 885,660 885,687 +27 (+0.0%) 7,222 7,587 +365 (+5.1%)
deposit_public_to_private_exact 709,509 709,509 1,920 1,920 922,656 922,683 +27 (+0.0%) 8,529 9,023 +494 (+5.8%)
deposit_public_to_public 308,698 308,698 832 832 901,550 901,577 +27 (+0.0%) 5,254 5,550 +296 (+5.6%)
issue_private_to_private_exact 965,570 965,570 1,856 1,856 883,904 883,931 +27 (+0.0%) 10,593 11,262 +669 (+6.3%)
issue_private_to_public_exact 783,172 783,172 1,344 1,344 898,951 898,978 +27 (+0.0%) 9,120 9,668 +548 (+6.0%)
issue_public_to_private 604,635 604,635 1,344 1,344 894,854 894,881 +27 (+0.0%) 7,630 8,040 +410 (+5.4%)
issue_public_to_public 308,698 308,698 832 832 902,237 902,264 +27 (+0.0%) 5,204 5,521 +317 (+6.1%)
redeem_private_to_private_exact 962,210 962,210 1,856 1,856 883,751 883,778 +27 (+0.0%) 10,622 11,320 +698 (+6.6%)
redeem_private_to_public 674,241 674,241 768 768 858,328 858,355 +27 (+0.0%) 8,152 8,667 +515 (+6.3%)
redeem_public_to_private_exact 659,929 659,929 1,920 1,920 922,980 923,007 +27 (+0.0%) 8,029 8,541 +512 (+6.4%)
redeem_public_to_public 308,698 308,698 832 832 898,727 898,754 +27 (+0.0%) 5,170 5,540 +370 (+7.2%)
withdraw_private_to_private 853,366 853,366 1,280 1,280 846,623 846,650 +27 (+0.0%) 9,625 10,252 +627 (+6.5%)
withdraw_private_to_private_exact 962,210 962,210 1,856 1,856 883,700 883,727 +27 (+0.0%) 10,600 11,229 +629 (+5.9%)
withdraw_private_to_public_exact 783,094 783,094 1,344 1,344 895,837 895,864 +27 (+0.0%) 9,131 9,593 +462 (+5.1%)
withdraw_public_to_private 551,001 551,001 1,344 1,344 885,480 885,507 +27 (+0.0%) 7,159 7,560 +401 (+5.6%)
withdraw_public_to_public 308,698 308,698 832 832 899,030 899,057 +27 (+0.0%) 5,228 5,547 +319 (+6.1%)

Comment thread src/ts/test/utils.ts
Comment on lines +436 to +437
{ calldata_hash: Fr.ZERO },
{ calldata_hash: Fr.ZERO },

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how's this working?

Comment on lines 85 to -88
#[external("public")]
fn set_shares_token_with_initial_deposit(
shares: AztecAddress,
initial_deposit: u128,
depositor: AztecAddress,
nonce: Field,
) {
fn initial_deposit(initial_deposit: u128, depositor: AztecAddress, nonce: Field) {
assert(initial_deposit > 0, "initial_deposit must be greater than 0");
let deployer = get_contract_instance_deployer_avm(self.address).unwrap();
assert(self.msg_sender().eq(deployer), "caller is not deployer");
self.storage.shares.initialize(shares);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i thought set_shares_token_with_initial_deposit got deprecated already

@zkfrov zkfrov closed this Jul 9, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants