Skip to content

Contract class entrypoints#608

Draft
nielstron wants to merge 19 commits intodevfrom
contract-class-entrypoints
Draft

Contract class entrypoints#608
nielstron wants to merge 19 commits intodevfrom
contract-class-entrypoints

Conversation

@nielstron
Copy link
Copy Markdown
Contributor

Tackles #557

@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 9, 2026

⚠️ Binary Size Changes Detected

Binary Size Comparison Report
Loading baseline measurements...
Measuring current binary sizes and execution costs...
Measuring assert_sum...
  O0: 57566 bytes
    Evaluating test case: valid_sum
      CPU: 46,906,550 | MEM: 254,536
  O1: 3670 bytes
    Evaluating test case: valid_sum
      CPU: 22,010,550 | MEM: 98,936
  O2: 3670 bytes
    Evaluating test case: valid_sum
      CPU: 21,806,670 | MEM: 97,808
  O3: 1482 bytes
    Evaluating test case: valid_sum
      CPU: 19,630,670 | MEM: 84,208
Measuring liquidity_pool...
  O0: 155092 bytes
  O1: 47822 bytes
  O2: 47504 bytes
  O3: 18974 bytes
Measuring marketplace...
  O0: 126756 bytes
  O1: 26240 bytes
  O2: 26150 bytes
  O3: 4936 bytes
Measuring gift...
  O0: 60134 bytes
    Evaluating test case: valid_withdrawal
      CPU: 55,200,682 | MEM: 282,325
  O1: 5560 bytes
    Evaluating test case: valid_withdrawal
      CPU: 31,872,682 | MEM: 136,525
  O2: 5560 bytes
    Evaluating test case: valid_withdrawal
      CPU: 31,629,559 | MEM: 135,165
  O3: 1834 bytes
    Evaluating test case: valid_withdrawal
      CPU: 28,813,559 | MEM: 117,565
Measuring wrapped_token...
  O0: 68658 bytes
  O1: 12578 bytes
  O2: 12406 bytes
  O3: 5278 bytes
Measuring micropayments...
  O0: 90736 bytes
  O1: 20486 bytes
  O2: 20416 bytes
  O3: 7480 bytes

============================================================
BINARY SIZE AND EXECUTION COST COMPARISON REPORT
============================================================

Contract: assert_sum
Description: Simple spending validator with assertion
----------------------------------------
  O0: 54,954 → 57,566 bytes (+2,612 bytes, +4.8%)
    Test 'valid_sum': CPU 44,505,759 → 46,906,550 (+2,400,791, +5.4%) | MEM 241,674 → 254,536 (+12,862, +5.3%) ⚠️ (ignored)
  O1: 3,536 → 3,670 bytes (+134 bytes, +3.8%)
    Test 'valid_sum': CPU 19,817,759 → 22,010,550 (+2,192,791, +11.1%) | MEM 87,374 → 98,936 (+11,562, +13.2%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 3,534 → 3,670 bytes (+136 bytes, +3.8%)
    Test 'valid_sum': CPU 19,778,516 → 21,806,670 (+2,028,154, +10.3%) | MEM 87,142 → 97,808 (+10,666, +12.2%) ⚠️  SIGNIFICANT CHANGE
  O3: 1,348 → 1,482 bytes (+134 bytes, +9.9%) ⚠️
    Test 'valid_sum': CPU 17,970,516 → 19,630,670 (+1,660,154, +9.2%) | MEM 75,842 → 84,208 (+8,366, +11.0%) ⚠️  SIGNIFICANT CHANGE

Contract: liquidity_pool
Description: Simple DEX pool
----------------------------------------
  O0: 152,112 → 155,092 bytes (+2,980 bytes, +2.0%)
  O1: 47,652 → 47,822 bytes (+170 bytes, +0.4%)
  O2: 47,334 → 47,504 bytes (+170 bytes, +0.4%)
  O3: 18,690 → 18,974 bytes (+284 bytes, +1.5%)

Contract: marketplace
Description: Marketplace contract with complex data structures
----------------------------------------
  O0: 124,108 → 126,756 bytes (+2,648 bytes, +2.1%)
  O1: 26,262 → 26,240 bytes (-22 bytes, -0.1%) ↘️ (size reduced)
  O2: 26,170 → 26,150 bytes (-20 bytes, -0.1%) ↘️ (size reduced)
  O3: 4,854 → 4,936 bytes (+82 bytes, +1.7%)

Contract: gift
Description: Gift contract with simple logic
----------------------------------------
  O0: 57,426 → 60,134 bytes (+2,708 bytes, +4.7%)
    Test 'valid_withdrawal': CPU 52,052,498 → 55,200,682 (+3,148,184, +6.0%) | MEM 266,735 → 282,325 (+15,590, +5.8%) ⚠️ (ignored)
  O1: 5,356 → 5,560 bytes (+204 bytes, +3.8%)
    Test 'valid_withdrawal': CPU 28,788,498 → 31,872,682 (+3,084,184, +10.7%) | MEM 121,335 → 136,525 (+15,190, +12.5%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 5,352 → 5,560 bytes (+208 bytes, +3.9%)
    Test 'valid_withdrawal': CPU 28,710,012 → 31,629,559 (+2,919,547, +10.2%) | MEM 120,871 → 135,165 (+14,294, +11.8%) ⚠️  SIGNIFICANT CHANGE
  O3: 1,676 → 1,834 bytes (+158 bytes, +9.4%) ⚠️
    Test 'valid_withdrawal': CPU 26,262,012 → 28,813,559 (+2,551,547, +9.7%) | MEM 105,571 → 117,565 (+11,994, +11.4%) ⚠️  SIGNIFICANT CHANGE

Contract: wrapped_token
Description: Dual-use contract to generate a wrapped token
----------------------------------------
  O0: 64,838 → 68,658 bytes (+3,820 bytes, +5.9%) ⚠️ (ignored)
  O1: 9,352 → 12,578 bytes (+3,226 bytes, +34.5%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 9,080 → 12,406 bytes (+3,326 bytes, +36.6%) ⚠️  SIGNIFICANT CHANGE
  O3: 3,876 → 5,278 bytes (+1,402 bytes, +36.2%) ⚠️  SIGNIFICANT CHANGE

Contract: micropayments
Description: Channel for fee-less micropayments
----------------------------------------
  O0: 88,026 → 90,736 bytes (+2,710 bytes, +3.1%)
  O1: 19,894 → 20,486 bytes (+592 bytes, +3.0%)
  O2: 19,820 → 20,416 bytes (+596 bytes, +3.0%)
  O3: 7,212 → 7,480 bytes (+268 bytes, +3.7%)

Total size change compared to previous release: +28,526 bytes

⚠️  SIGNIFICANT CHANGES DETECTED
Please review the changes and consider optimization if sizes or costs increased significantly.
============================================================

Please review the binary size changes. Significant increases may impact contract deployment costs and execution limits.


This report compares the binary sizes of compiled contracts against the baseline from the latest release.

1 similar comment
@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 9, 2026

⚠️ Binary Size Changes Detected

Binary Size Comparison Report
Loading baseline measurements...
Measuring current binary sizes and execution costs...
Measuring assert_sum...
  O0: 57566 bytes
    Evaluating test case: valid_sum
      CPU: 46,906,550 | MEM: 254,536
  O1: 3670 bytes
    Evaluating test case: valid_sum
      CPU: 22,010,550 | MEM: 98,936
  O2: 3670 bytes
    Evaluating test case: valid_sum
      CPU: 21,806,670 | MEM: 97,808
  O3: 1482 bytes
    Evaluating test case: valid_sum
      CPU: 19,630,670 | MEM: 84,208
Measuring liquidity_pool...
  O0: 155092 bytes
  O1: 47822 bytes
  O2: 47504 bytes
  O3: 18974 bytes
Measuring marketplace...
  O0: 126756 bytes
  O1: 26240 bytes
  O2: 26150 bytes
  O3: 4936 bytes
Measuring gift...
  O0: 60134 bytes
    Evaluating test case: valid_withdrawal
      CPU: 55,200,682 | MEM: 282,325
  O1: 5560 bytes
    Evaluating test case: valid_withdrawal
      CPU: 31,872,682 | MEM: 136,525
  O2: 5560 bytes
    Evaluating test case: valid_withdrawal
      CPU: 31,629,559 | MEM: 135,165
  O3: 1834 bytes
    Evaluating test case: valid_withdrawal
      CPU: 28,813,559 | MEM: 117,565
Measuring wrapped_token...
  O0: 68658 bytes
  O1: 12578 bytes
  O2: 12406 bytes
  O3: 5278 bytes
Measuring micropayments...
  O0: 90736 bytes
  O1: 20486 bytes
  O2: 20416 bytes
  O3: 7480 bytes

============================================================
BINARY SIZE AND EXECUTION COST COMPARISON REPORT
============================================================

Contract: assert_sum
Description: Simple spending validator with assertion
----------------------------------------
  O0: 54,954 → 57,566 bytes (+2,612 bytes, +4.8%)
    Test 'valid_sum': CPU 44,505,759 → 46,906,550 (+2,400,791, +5.4%) | MEM 241,674 → 254,536 (+12,862, +5.3%) ⚠️ (ignored)
  O1: 3,536 → 3,670 bytes (+134 bytes, +3.8%)
    Test 'valid_sum': CPU 19,817,759 → 22,010,550 (+2,192,791, +11.1%) | MEM 87,374 → 98,936 (+11,562, +13.2%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 3,534 → 3,670 bytes (+136 bytes, +3.8%)
    Test 'valid_sum': CPU 19,778,516 → 21,806,670 (+2,028,154, +10.3%) | MEM 87,142 → 97,808 (+10,666, +12.2%) ⚠️  SIGNIFICANT CHANGE
  O3: 1,348 → 1,482 bytes (+134 bytes, +9.9%) ⚠️
    Test 'valid_sum': CPU 17,970,516 → 19,630,670 (+1,660,154, +9.2%) | MEM 75,842 → 84,208 (+8,366, +11.0%) ⚠️  SIGNIFICANT CHANGE

Contract: liquidity_pool
Description: Simple DEX pool
----------------------------------------
  O0: 152,112 → 155,092 bytes (+2,980 bytes, +2.0%)
  O1: 47,652 → 47,822 bytes (+170 bytes, +0.4%)
  O2: 47,334 → 47,504 bytes (+170 bytes, +0.4%)
  O3: 18,690 → 18,974 bytes (+284 bytes, +1.5%)

Contract: marketplace
Description: Marketplace contract with complex data structures
----------------------------------------
  O0: 124,108 → 126,756 bytes (+2,648 bytes, +2.1%)
  O1: 26,262 → 26,240 bytes (-22 bytes, -0.1%) ↘️ (size reduced)
  O2: 26,170 → 26,150 bytes (-20 bytes, -0.1%) ↘️ (size reduced)
  O3: 4,854 → 4,936 bytes (+82 bytes, +1.7%)

Contract: gift
Description: Gift contract with simple logic
----------------------------------------
  O0: 57,426 → 60,134 bytes (+2,708 bytes, +4.7%)
    Test 'valid_withdrawal': CPU 52,052,498 → 55,200,682 (+3,148,184, +6.0%) | MEM 266,735 → 282,325 (+15,590, +5.8%) ⚠️ (ignored)
  O1: 5,356 → 5,560 bytes (+204 bytes, +3.8%)
    Test 'valid_withdrawal': CPU 28,788,498 → 31,872,682 (+3,084,184, +10.7%) | MEM 121,335 → 136,525 (+15,190, +12.5%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 5,352 → 5,560 bytes (+208 bytes, +3.9%)
    Test 'valid_withdrawal': CPU 28,710,012 → 31,629,559 (+2,919,547, +10.2%) | MEM 120,871 → 135,165 (+14,294, +11.8%) ⚠️  SIGNIFICANT CHANGE
  O3: 1,676 → 1,834 bytes (+158 bytes, +9.4%) ⚠️
    Test 'valid_withdrawal': CPU 26,262,012 → 28,813,559 (+2,551,547, +9.7%) | MEM 105,571 → 117,565 (+11,994, +11.4%) ⚠️  SIGNIFICANT CHANGE

Contract: wrapped_token
Description: Dual-use contract to generate a wrapped token
----------------------------------------
  O0: 64,838 → 68,658 bytes (+3,820 bytes, +5.9%) ⚠️ (ignored)
  O1: 9,352 → 12,578 bytes (+3,226 bytes, +34.5%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 9,080 → 12,406 bytes (+3,326 bytes, +36.6%) ⚠️  SIGNIFICANT CHANGE
  O3: 3,876 → 5,278 bytes (+1,402 bytes, +36.2%) ⚠️  SIGNIFICANT CHANGE

Contract: micropayments
Description: Channel for fee-less micropayments
----------------------------------------
  O0: 88,026 → 90,736 bytes (+2,710 bytes, +3.1%)
  O1: 19,894 → 20,486 bytes (+592 bytes, +3.0%)
  O2: 19,820 → 20,416 bytes (+596 bytes, +3.0%)
  O3: 7,212 → 7,480 bytes (+268 bytes, +3.7%)

Total size change compared to previous release: +28,526 bytes

⚠️  SIGNIFICANT CHANGES DETECTED
Please review the changes and consider optimization if sizes or costs increased significantly.
============================================================

Please review the binary size changes. Significant increases may impact contract deployment costs and execution limits.


This report compares the binary sizes of compiled contracts against the baseline from the latest release.

@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 9, 2026

⚠️ Binary Size Changes Detected

Binary Size Comparison Report
Loading baseline measurements...
Measuring current binary sizes and execution costs...
Measuring assert_sum...
  O0: 56420 bytes
    Evaluating test case: valid_sum
      CPU: 44,813,156 | MEM: 241,572
  O1: 3308 bytes
    Evaluating test case: valid_sum
      CPU: 19,821,156 | MEM: 85,372
  O2: 3304 bytes
    Evaluating test case: valid_sum
      CPU: 19,742,670 | MEM: 84,908
  O3: 1258 bytes
    Evaluating test case: valid_sum
      CPU: 17,614,670 | MEM: 71,608
Measuring liquidity_pool...
  O0: 152744 bytes
  O1: 46892 bytes
  O2: 46572 bytes
  O3: 18180 bytes
Measuring marketplace...
  O0: 125486 bytes
  O1: 25750 bytes
  O2: 25658 bytes
  O3: 4624 bytes
Measuring gift...
  O0: 59016 bytes
    Evaluating test case: valid_withdrawal
      CPU: 53,203,288 | MEM: 269,961
  O1: 5218 bytes
    Evaluating test case: valid_withdrawal
      CPU: 29,779,288 | MEM: 123,561
  O2: 5214 bytes
    Evaluating test case: valid_withdrawal
      CPU: 29,661,559 | MEM: 122,865
  O3: 1620 bytes
    Evaluating test case: valid_withdrawal
      CPU: 26,845,559 | MEM: 105,265
Measuring wrapped_token...
  O0: 67704 bytes
  O1: 12438 bytes
  O2: 12264 bytes
  O3: 4838 bytes
Measuring micropayments...
  O0: 89192 bytes
  O1: 19820 bytes
  O2: 19746 bytes
  O3: 6912 bytes

============================================================
BINARY SIZE AND EXECUTION COST COMPARISON REPORT
============================================================

Contract: assert_sum
Description: Simple spending validator with assertion
----------------------------------------
  O0: 54,954 → 56,420 bytes (+1,466 bytes, +2.7%)
    Test 'valid_sum': CPU 44,505,759 → 44,813,156 (+307,397, +0.7%) | MEM 241,674 → 241,572 (-102, -0.0%)
  O1: 3,536 → 3,308 bytes (-228 bytes, -6.4%) ↘️ (size reduced)
    Test 'valid_sum': CPU 19,817,759 → 19,821,156 (+3,397, +0.0%) | MEM 87,374 → 85,372 (-2,002, -2.3%)
  O2: 3,534 → 3,304 bytes (-230 bytes, -6.5%) ↘️ (size reduced)
    Test 'valid_sum': CPU 19,778,516 → 19,742,670 (-35,846, -0.2%) | MEM 87,142 → 84,908 (-2,234, -2.6%) ↘️ (costs reduced)
  O3: 1,348 → 1,258 bytes (-90 bytes, -6.7%) ↘️ (size reduced)
    Test 'valid_sum': CPU 17,970,516 → 17,614,670 (-355,846, -2.0%) | MEM 75,842 → 71,608 (-4,234, -5.6%) ↘️ (costs reduced)

Contract: liquidity_pool
Description: Simple DEX pool
----------------------------------------
  O0: 152,112 → 152,744 bytes (+632 bytes, +0.4%)
  O1: 47,652 → 46,892 bytes (-760 bytes, -1.6%) ↘️ (size reduced)
  O2: 47,334 → 46,572 bytes (-762 bytes, -1.6%) ↘️ (size reduced)
  O3: 18,690 → 18,180 bytes (-510 bytes, -2.7%) ↘️ (size reduced)

Contract: marketplace
Description: Marketplace contract with complex data structures
----------------------------------------
  O0: 124,108 → 125,486 bytes (+1,378 bytes, +1.1%)
  O1: 26,262 → 25,750 bytes (-512 bytes, -1.9%) ↘️ (size reduced)
  O2: 26,170 → 25,658 bytes (-512 bytes, -2.0%) ↘️ (size reduced)
  O3: 4,854 → 4,624 bytes (-230 bytes, -4.7%) ↘️ (size reduced)

Contract: gift
Description: Gift contract with simple logic
----------------------------------------
  O0: 57,426 → 59,016 bytes (+1,590 bytes, +2.8%)
    Test 'valid_withdrawal': CPU 52,052,498 → 53,203,288 (+1,150,790, +2.2%) | MEM 266,735 → 269,961 (+3,226, +1.2%)
  O1: 5,356 → 5,218 bytes (-138 bytes, -2.6%) ↘️ (size reduced)
    Test 'valid_withdrawal': CPU 28,788,498 → 29,779,288 (+990,790, +3.4%) | MEM 121,335 → 123,561 (+2,226, +1.8%)
  O2: 5,352 → 5,214 bytes (-138 bytes, -2.6%) ↘️ (size reduced)
    Test 'valid_withdrawal': CPU 28,710,012 → 29,661,559 (+951,547, +3.3%) | MEM 120,871 → 122,865 (+1,994, +1.6%)
  O3: 1,676 → 1,620 bytes (-56 bytes, -3.3%) ↘️ (size reduced)
    Test 'valid_withdrawal': CPU 26,262,012 → 26,845,559 (+583,547, +2.2%) | MEM 105,571 → 105,265 (-306, -0.3%)

Contract: wrapped_token
Description: Dual-use contract to generate a wrapped token
----------------------------------------
  O0: 64,838 → 67,704 bytes (+2,866 bytes, +4.4%)
  O1: 9,352 → 12,438 bytes (+3,086 bytes, +33.0%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 9,080 → 12,264 bytes (+3,184 bytes, +35.1%) ⚠️  SIGNIFICANT CHANGE
  O3: 3,876 → 4,838 bytes (+962 bytes, +24.8%) ⚠️  SIGNIFICANT CHANGE

Contract: micropayments
Description: Channel for fee-less micropayments
----------------------------------------
  O0: 88,026 → 89,192 bytes (+1,166 bytes, +1.3%)
  O1: 19,894 → 19,820 bytes (-74 bytes, -0.4%) ↘️ (size reduced)
  O2: 19,820 → 19,746 bytes (-74 bytes, -0.4%) ↘️ (size reduced)
  O3: 7,212 → 6,912 bytes (-300 bytes, -4.2%) ↘️ (size reduced)

Total size change compared to previous release: +11,716 bytes

⚠️  SIGNIFICANT CHANGES DETECTED
Please review the changes and consider optimization if sizes or costs increased significantly.
============================================================

Please review the binary size changes. Significant increases may impact contract deployment costs and execution limits.


This report compares the binary sizes of compiled contracts against the baseline from the latest release.

@nielstron nielstron marked this pull request as draft March 9, 2026 10:10
@nielstron
Copy link
Copy Markdown
Contributor Author

This is still a terrible mess but drafts nicely what I have in mind for the future contract format.
Some additional things

  • need to properly test kwarg stlye parameter passing. ideally configure statically somewhere else
  • opshin init create a stub contract and modify pyproject toml to store some compiler configs, pin opshin version
  • the resolution of the datum and purpose should either use native uplc, independent of the name of attributes in the plutusv3 api def -- or it should reuse the logic from the prelude.

@nielstron nielstron force-pushed the contract-class-entrypoints branch from 92bdc8d to d783aa2 Compare March 14, 2026 09:40
@github-actions
Copy link
Copy Markdown

⚠️ Binary Size Changes Detected

Binary Size Comparison Report
Loading baseline measurements...
Measuring current binary sizes and execution costs...
Measuring assert_sum...
  O0: 55074 bytes
    Evaluating test case: valid_sum
      CPU: 44,217,759 | MEM: 239,874
  O1: 3816 bytes
    Evaluating test case: valid_sum
      CPU: 19,721,759 | MEM: 86,774
  O2: 3810 bytes
    Evaluating test case: valid_sum
      CPU: 19,682,516 | MEM: 86,542
  O3: 1354 bytes
    Evaluating test case: valid_sum
      CPU: 17,874,516 | MEM: 75,242
Measuring liquidity_pool...
  O0: 151810 bytes
  O1: 47734 bytes
  O2: 47468 bytes
  O3: 18594 bytes
Measuring marketplace...
  O0: 124076 bytes
  O1: 26428 bytes
  O2: 26332 bytes
  O3: 4778 bytes
Measuring gift...
  O0: 57642 bytes
    Evaluating test case: valid_withdrawal
      CPU: 52,463,891 | MEM: 267,363
  O1: 5580 bytes
    Evaluating test case: valid_withdrawal
      CPU: 29,439,891 | MEM: 123,463
  O2: 5574 bytes
    Evaluating test case: valid_withdrawal
      CPU: 29,361,405 | MEM: 122,999
  O3: 1684 bytes
    Evaluating test case: valid_withdrawal
      CPU: 26,913,405 | MEM: 107,699
Measuring wrapped_token...
  O0: 64774 bytes
  O1: 9516 bytes
  O2: 9226 bytes
  O3: 3826 bytes
Measuring micropayments...
  O0: 88712 bytes
  O1: 21738 bytes
  O2: 21664 bytes
  O3: 7432 bytes
Measuring pool_validator...
  O0: 63204 bytes
    Evaluating test case: swap_a_for_b
      CPU: 144,496,682 | MEM: 550,657
    Evaluating test case: swap_b_for_a
      CPU: 144,496,682 | MEM: 550,657
    Evaluating test case: deposit
      CPU: 145,521,818 | MEM: 540,207
    Evaluating test case: withdraw
      CPU: 146,018,200 | MEM: 542,509
  O1: 11202 bytes
    Evaluating test case: swap_a_for_b
      CPU: 128,848,682 | MEM: 452,857
    Evaluating test case: swap_b_for_a
      CPU: 128,848,682 | MEM: 452,857
    Evaluating test case: deposit
      CPU: 130,257,818 | MEM: 444,807
    Evaluating test case: withdraw
      CPU: 130,754,200 | MEM: 447,109
  O2: 10756 bytes
    Evaluating test case: swap_a_for_b
      CPU: 127,479,243 | MEM: 444,891
    Evaluating test case: swap_b_for_a
      CPU: 127,479,243 | MEM: 444,891
    Evaluating test case: deposit
      CPU: 129,379,332 | MEM: 439,343
    Evaluating test case: withdraw
      CPU: 129,843,714 | MEM: 441,445
  O3: 4676 bytes
    Evaluating test case: swap_a_for_b
      CPU: 120,219,315 | MEM: 409,107
    Evaluating test case: swap_b_for_a
      CPU: 120,219,315 | MEM: 409,107
    Evaluating test case: deposit
      CPU: 122,119,404 | MEM: 403,559
    Evaluating test case: withdraw
      CPU: 122,583,786 | MEM: 405,661
Measuring lp_minting_policy...
  O0: 56424 bytes
    Evaluating test case: mint_one_nft
      CPU: 54,068,929 | MEM: 267,073
    Evaluating test case: mint_two_nfts
      CPU: 71,341,257 | MEM: 317,848
  O1: 2768 bytes
    Evaluating test case: mint_one_nft
      CPU: 28,932,929 | MEM: 109,973
    Evaluating test case: mint_two_nfts
      CPU: 47,197,257 | MEM: 166,948
  O2: 2764 bytes
    Evaluating test case: mint_one_nft
      CPU: 28,893,686 | MEM: 109,741
    Evaluating test case: mint_two_nfts
      CPU: 47,118,771 | MEM: 166,484
  O3: 1328 bytes
    Evaluating test case: mint_one_nft
      CPU: 27,501,686 | MEM: 101,041
    Evaluating test case: mint_two_nfts
      CPU: 45,726,771 | MEM: 157,784
Measuring nft_marketplace_validator...
  O0: 57338 bytes
    Evaluating test case: buy_one
      CPU: 64,707,409 | MEM: 308,335
    Evaluating test case: cancel_one
      CPU: 55,914,847 | MEM: 288,419
  O1: 6078 bytes
    Evaluating test case: buy_one
      CPU: 42,803,409 | MEM: 171,435
    Evaluating test case: cancel_one
      CPU: 33,610,847 | MEM: 149,019
  O2: 5840 bytes
    Evaluating test case: buy_one
      CPU: 42,308,923 | MEM: 168,371
    Evaluating test case: cancel_one
      CPU: 33,123,604 | MEM: 145,987
  O3: 2524 bytes
    Evaluating test case: buy_one
      CPU: 39,413,941 | MEM: 152,675
    Evaluating test case: cancel_one
      CPU: 29,940,622 | MEM: 128,491
Measuring nft_minting_policy...
  O0: 56470 bytes
    Evaluating test case: valid_mint
      CPU: 54,443,157 | MEM: 276,246
  O1: 3198 bytes
    Evaluating test case: valid_mint
      CPU: 31,067,157 | MEM: 130,146
  O2: 3196 bytes
    Evaluating test case: valid_mint
      CPU: 31,027,914 | MEM: 129,914
  O3: 1510 bytes
    Evaluating test case: valid_mint
      CPU: 28,259,914 | MEM: 112,614

============================================================
BINARY SIZE AND EXECUTION COST COMPARISON REPORT
============================================================

Contract: assert_sum
Description: Simple spending validator with assertion
----------------------------------------
  O0: 54,450 → 55,074 bytes (+624 bytes, +1.1%)
    Test 'valid_sum': CPU 44,089,759 → 44,217,759 (+128,000, +0.3%) | MEM 239,074 → 239,874 (+800, +0.3%)
  O1: 3,440 → 3,816 bytes (+376 bytes, +10.9%) ⚠️  SIGNIFICANT CHANGE (ignored)
    Test 'valid_sum': CPU 19,353,759 → 19,721,759 (+368,000, +1.9%) | MEM 84,474 → 86,774 (+2,300, +2.7%)
  O2: 3,438 → 3,810 bytes (+372 bytes, +10.8%) ⚠️  SIGNIFICANT CHANGE
    Test 'valid_sum': CPU 19,314,516 → 19,682,516 (+368,000, +1.9%) | MEM 84,242 → 86,542 (+2,300, +2.7%)
  O3: 1,296 → 1,354 bytes (+58 bytes, +4.5%)
    Test 'valid_sum': CPU 17,506,516 → 17,874,516 (+368,000, +2.1%) | MEM 72,942 → 75,242 (+2,300, +3.2%)

Contract: liquidity_pool
Description: Simple DEX pool
----------------------------------------
  O0: 151,088 → 151,810 bytes (+722 bytes, +0.5%)
  O1: 47,478 → 47,734 bytes (+256 bytes, +0.5%)
  O2: 47,144 → 47,468 bytes (+324 bytes, +0.7%)
  O3: 18,544 → 18,594 bytes (+50 bytes, +0.3%)

Contract: marketplace
Description: Marketplace contract with complex data structures
----------------------------------------
  O0: 123,448 → 124,076 bytes (+628 bytes, +0.5%)
  O1: 26,036 → 26,428 bytes (+392 bytes, +1.5%)
  O2: 25,940 → 26,332 bytes (+392 bytes, +1.5%)
  O3: 4,708 → 4,778 bytes (+70 bytes, +1.5%)

Contract: gift
Description: Gift contract with simple logic
----------------------------------------
  O0: 56,918 → 57,642 bytes (+724 bytes, +1.3%)
    Test 'valid_withdrawal': CPU 51,588,498 → 52,463,891 (+875,393, +1.7%) | MEM 263,835 → 267,363 (+3,528, +1.3%)
  O1: 5,256 → 5,580 bytes (+324 bytes, +6.2%) ⚠️ (ignored)
    Test 'valid_withdrawal': CPU 28,276,498 → 29,439,891 (+1,163,393, +4.1%) | MEM 118,135 → 123,463 (+5,328, +4.5%)
  O2: 5,252 → 5,574 bytes (+322 bytes, +6.1%) ⚠️
    Test 'valid_withdrawal': CPU 28,198,012 → 29,361,405 (+1,163,393, +4.1%) | MEM 117,671 → 122,999 (+5,328, +4.5%)
  O3: 1,614 → 1,684 bytes (+70 bytes, +4.3%)
    Test 'valid_withdrawal': CPU 25,702,012 → 26,913,405 (+1,211,393, +4.7%) | MEM 102,071 → 107,699 (+5,628, +5.5%) ⚠️

Contract: wrapped_token
Description: Dual-use contract to generate a wrapped token
----------------------------------------
  O0: 64,204 → 64,774 bytes (+570 bytes, +0.9%)
  O1: 9,186 → 9,516 bytes (+330 bytes, +3.6%)
  O2: 8,906 → 9,226 bytes (+320 bytes, +3.6%)
  O3: 3,770 → 3,826 bytes (+56 bytes, +1.5%)

Contract: micropayments
Description: Channel for fee-less micropayments
----------------------------------------
  O0: 87,178 → 88,712 bytes (+1,534 bytes, +1.8%)
  O1: 19,562 → 21,738 bytes (+2,176 bytes, +11.1%) ⚠️  SIGNIFICANT CHANGE (ignored)
  O2: 19,488 → 21,664 bytes (+2,176 bytes, +11.2%) ⚠️  SIGNIFICANT CHANGE
  O3: 6,918 → 7,432 bytes (+514 bytes, +7.4%) ⚠️

Contract: pool_validator
Description: UPLC benchmark DEX pool validator
----------------------------------------
  O0: 62,488 → 63,204 bytes (+716 bytes, +1.1%)
    Test 'swap_a_for_b': CPU 155,211,202 → 144,496,682 (-10,714,520, -6.9%) | MEM 592,349 → 550,657 (-41,692, -7.0%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 155,211,202 → 144,496,682 (-10,714,520, -6.9%) | MEM 592,349 → 550,657 (-41,692, -7.0%) ↘️ (costs reduced)
    Test 'deposit': CPU 156,236,338 → 145,521,818 (-10,714,520, -6.9%) | MEM 581,899 → 540,207 (-41,692, -7.2%) ↘️ (costs reduced)
    Test 'withdraw': CPU 156,732,720 → 146,018,200 (-10,714,520, -6.8%) | MEM 584,201 → 542,509 (-41,692, -7.1%) ↘️ (costs reduced)
  O1: 10,670 → 11,202 bytes (+532 bytes, +5.0%)
    Test 'swap_a_for_b': CPU 142,651,202 → 128,848,682 (-13,802,520, -9.7%) | MEM 513,849 → 452,857 (-60,992, -11.9%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 142,651,202 → 128,848,682 (-13,802,520, -9.7%) | MEM 513,849 → 452,857 (-60,992, -11.9%) ↘️ (costs reduced)
    Test 'deposit': CPU 144,060,338 → 130,257,818 (-13,802,520, -9.6%) | MEM 505,799 → 444,807 (-60,992, -12.1%) ↘️ (costs reduced)
    Test 'withdraw': CPU 144,556,720 → 130,754,200 (-13,802,520, -9.5%) | MEM 508,101 → 447,109 (-60,992, -12.0%) ↘️ (costs reduced)
  O2: 10,234 → 10,756 bytes (+522 bytes, +5.1%) ⚠️
    Test 'swap_a_for_b': CPU 141,203,277 → 127,479,243 (-13,724,034, -9.7%) | MEM 505,419 → 444,891 (-60,528, -12.0%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 141,203,277 → 127,479,243 (-13,724,034, -9.7%) | MEM 505,419 → 444,891 (-60,528, -12.0%) ↘️ (costs reduced)
    Test 'deposit': CPU 143,103,366 → 129,379,332 (-13,724,034, -9.6%) | MEM 499,871 → 439,343 (-60,528, -12.1%) ↘️ (costs reduced)
    Test 'withdraw': CPU 143,567,748 → 129,843,714 (-13,724,034, -9.6%) | MEM 501,973 → 441,445 (-60,528, -12.1%) ↘️ (costs reduced)
  O3: 4,724 → 4,676 bytes (-48 bytes, -1.0%) ↘️ (size reduced)
    Test 'swap_a_for_b': CPU 136,643,277 → 120,219,315 (-16,423,962, -12.0%) | MEM 476,919 → 409,107 (-67,812, -14.2%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 136,643,277 → 120,219,315 (-16,423,962, -12.0%) | MEM 476,919 → 409,107 (-67,812, -14.2%) ↘️ (costs reduced)
    Test 'deposit': CPU 138,543,366 → 122,119,404 (-16,423,962, -11.9%) | MEM 471,371 → 403,559 (-67,812, -14.4%) ↘️ (costs reduced)
    Test 'withdraw': CPU 139,007,748 → 122,583,786 (-16,423,962, -11.8%) | MEM 473,473 → 405,661 (-67,812, -14.3%) ↘️ (costs reduced)

Contract: lp_minting_policy
Description: UPLC benchmark LP minting policy
----------------------------------------
  O0: 56,086 → 56,424 bytes (+338 bytes, +0.6%)
    Test 'mint_one_nft': CPU 54,116,929 → 54,068,929 (-48,000, -0.1%) | MEM 267,373 → 267,073 (-300, -0.1%) ↘️ (costs reduced)
    Test 'mint_two_nfts': CPU 71,389,257 → 71,341,257 (-48,000, -0.1%) | MEM 318,148 → 317,848 (-300, -0.1%) ↘️ (costs reduced)
  O1: 2,682 → 2,768 bytes (+86 bytes, +3.2%)
    Test 'mint_one_nft': CPU 28,740,929 → 28,932,929 (+192,000, +0.7%) | MEM 108,773 → 109,973 (+1,200, +1.1%)
    Test 'mint_two_nfts': CPU 47,005,257 → 47,197,257 (+192,000, +0.4%) | MEM 165,748 → 166,948 (+1,200, +0.7%)
  O2: 2,680 → 2,764 bytes (+84 bytes, +3.1%)
    Test 'mint_one_nft': CPU 28,701,686 → 28,893,686 (+192,000, +0.7%) | MEM 108,541 → 109,741 (+1,200, +1.1%)
    Test 'mint_two_nfts': CPU 46,926,771 → 47,118,771 (+192,000, +0.4%) | MEM 165,284 → 166,484 (+1,200, +0.7%)
  O3: 1,292 → 1,328 bytes (+36 bytes, +2.8%)
    Test 'mint_one_nft': CPU 27,309,686 → 27,501,686 (+192,000, +0.7%) | MEM 99,841 → 101,041 (+1,200, +1.2%)
    Test 'mint_two_nfts': CPU 45,534,771 → 45,726,771 (+192,000, +0.4%) | MEM 156,584 → 157,784 (+1,200, +0.8%)

Contract: nft_marketplace_validator
Description: UPLC benchmark NFT marketplace validator
----------------------------------------
  O0: 57,066 → 57,338 bytes (+272 bytes, +0.5%)
    Test 'buy_one': CPU 71,012,598 → 64,707,409 (-6,305,189, -8.9%) | MEM 334,783 → 308,335 (-26,448, -7.9%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 62,220,036 → 55,914,847 (-6,305,189, -10.1%) | MEM 314,867 → 288,419 (-26,448, -8.4%) ↘️ (costs reduced)
  O1: 6,036 → 6,078 bytes (+42 bytes, +0.7%)
    Test 'buy_one': CPU 49,812,598 → 42,803,409 (-7,009,189, -14.1%) | MEM 202,283 → 171,435 (-30,848, -15.2%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 40,620,036 → 33,610,847 (-7,009,189, -17.3%) | MEM 179,867 → 149,019 (-30,848, -17.2%) ↘️ (costs reduced)
  O2: 5,798 → 5,840 bytes (+42 bytes, +0.7%)
    Test 'buy_one': CPU 49,278,869 → 42,308,923 (-6,969,946, -14.1%) | MEM 198,987 → 168,371 (-30,616, -15.4%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 40,093,550 → 33,123,604 (-6,969,946, -17.4%) | MEM 176,603 → 145,987 (-30,616, -17.3%) ↘️ (costs reduced)
  O3: 2,642 → 2,524 bytes (-118 bytes, -4.5%) ↘️ (size reduced)
    Test 'buy_one': CPU 46,878,869 → 39,413,941 (-7,464,928, -15.9%) | MEM 183,987 → 152,675 (-31,312, -17.0%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 37,405,550 → 29,940,622 (-7,464,928, -20.0%) | MEM 159,803 → 128,491 (-31,312, -19.6%) ↘️ (costs reduced)

Contract: nft_minting_policy
Description: UPLC benchmark NFT minting policy
----------------------------------------
  O0: 56,194 → 56,470 bytes (+276 bytes, +0.5%)
    Test 'valid_mint': CPU 54,603,157 → 54,443,157 (-160,000, -0.3%) | MEM 277,246 → 276,246 (-1,000, -0.4%) ↘️ (costs reduced)
  O1: 3,180 → 3,198 bytes (+18 bytes, +0.6%)
    Test 'valid_mint': CPU 31,035,157 → 31,067,157 (+32,000, +0.1%) | MEM 129,946 → 130,146 (+200, +0.2%)
  O2: 3,178 → 3,196 bytes (+18 bytes, +0.6%)
    Test 'valid_mint': CPU 30,995,914 → 31,027,914 (+32,000, +0.1%) | MEM 129,714 → 129,914 (+200, +0.2%)
  O3: 1,488 → 1,510 bytes (+22 bytes, +1.5%)
    Test 'valid_mint': CPU 28,179,914 → 28,259,914 (+80,000, +0.3%) | MEM 112,114 → 112,614 (+500, +0.4%)

Total size change compared to previous release: +16,218 bytes

⚠️  SIGNIFICANT CHANGES DETECTED
Please review the changes and consider optimization if sizes or costs increased significantly.
============================================================

Please review the binary size changes. Significant increases may impact contract deployment costs and execution limits.


This report compares the binary sizes of compiled contracts against the baseline from the latest release.

@github-actions
Copy link
Copy Markdown

⚠️ Binary Size Changes Detected

Binary Size Comparison Report
Loading baseline measurements...
Measuring current binary sizes and execution costs...
Measuring assert_sum...
  O0: 55074 bytes
    Evaluating test case: valid_sum
      CPU: 44,217,759 | MEM: 239,874
  O1: 3816 bytes
    Evaluating test case: valid_sum
      CPU: 19,721,759 | MEM: 86,774
  O2: 3810 bytes
    Evaluating test case: valid_sum
      CPU: 19,682,516 | MEM: 86,542
  O3: 1354 bytes
    Evaluating test case: valid_sum
      CPU: 17,874,516 | MEM: 75,242
Measuring liquidity_pool...
  O0: 151810 bytes
  O1: 47734 bytes
  O2: 47468 bytes
  O3: 18594 bytes
Measuring marketplace...
  O0: 124076 bytes
  O1: 26428 bytes
  O2: 26332 bytes
  O3: 4778 bytes
Measuring gift...
  O0: 57642 bytes
    Evaluating test case: valid_withdrawal
      CPU: 52,463,891 | MEM: 267,363
  O1: 5580 bytes
    Evaluating test case: valid_withdrawal
      CPU: 29,439,891 | MEM: 123,463
  O2: 5574 bytes
    Evaluating test case: valid_withdrawal
      CPU: 29,361,405 | MEM: 122,999
  O3: 1684 bytes
    Evaluating test case: valid_withdrawal
      CPU: 26,913,405 | MEM: 107,699
Measuring wrapped_token...
  O0: 64774 bytes
  O1: 9516 bytes
  O2: 9226 bytes
  O3: 3826 bytes
Measuring micropayments...
  O0: 88246 bytes
  O1: 21198 bytes
  O2: 21124 bytes
  O3: 7250 bytes
Measuring pool_validator...
  O0: 63204 bytes
    Evaluating test case: swap_a_for_b
      CPU: 144,496,682 | MEM: 550,657
    Evaluating test case: swap_b_for_a
      CPU: 144,496,682 | MEM: 550,657
    Evaluating test case: deposit
      CPU: 145,521,818 | MEM: 540,207
    Evaluating test case: withdraw
      CPU: 146,018,200 | MEM: 542,509
  O1: 11202 bytes
    Evaluating test case: swap_a_for_b
      CPU: 128,848,682 | MEM: 452,857
    Evaluating test case: swap_b_for_a
      CPU: 128,848,682 | MEM: 452,857
    Evaluating test case: deposit
      CPU: 130,257,818 | MEM: 444,807
    Evaluating test case: withdraw
      CPU: 130,754,200 | MEM: 447,109
  O2: 10756 bytes
    Evaluating test case: swap_a_for_b
      CPU: 127,479,243 | MEM: 444,891
    Evaluating test case: swap_b_for_a
      CPU: 127,479,243 | MEM: 444,891
    Evaluating test case: deposit
      CPU: 129,379,332 | MEM: 439,343
    Evaluating test case: withdraw
      CPU: 129,843,714 | MEM: 441,445
  O3: 4676 bytes
    Evaluating test case: swap_a_for_b
      CPU: 120,219,315 | MEM: 409,107
    Evaluating test case: swap_b_for_a
      CPU: 120,219,315 | MEM: 409,107
    Evaluating test case: deposit
      CPU: 122,119,404 | MEM: 403,559
    Evaluating test case: withdraw
      CPU: 122,583,786 | MEM: 405,661
Measuring lp_minting_policy...
  O0: 56424 bytes
    Evaluating test case: mint_one_nft
      CPU: 54,068,929 | MEM: 267,073
    Evaluating test case: mint_two_nfts
      CPU: 71,341,257 | MEM: 317,848
  O1: 2768 bytes
    Evaluating test case: mint_one_nft
      CPU: 28,932,929 | MEM: 109,973
    Evaluating test case: mint_two_nfts
      CPU: 47,197,257 | MEM: 166,948
  O2: 2764 bytes
    Evaluating test case: mint_one_nft
      CPU: 28,893,686 | MEM: 109,741
    Evaluating test case: mint_two_nfts
      CPU: 47,118,771 | MEM: 166,484
  O3: 1328 bytes
    Evaluating test case: mint_one_nft
      CPU: 27,501,686 | MEM: 101,041
    Evaluating test case: mint_two_nfts
      CPU: 45,726,771 | MEM: 157,784
Measuring nft_marketplace_validator...
  O0: 57338 bytes
    Evaluating test case: buy_one
      CPU: 64,707,409 | MEM: 308,335
    Evaluating test case: cancel_one
      CPU: 55,914,847 | MEM: 288,419
  O1: 6078 bytes
    Evaluating test case: buy_one
      CPU: 42,803,409 | MEM: 171,435
    Evaluating test case: cancel_one
      CPU: 33,610,847 | MEM: 149,019
  O2: 5840 bytes
    Evaluating test case: buy_one
      CPU: 42,308,923 | MEM: 168,371
    Evaluating test case: cancel_one
      CPU: 33,123,604 | MEM: 145,987
  O3: 2524 bytes
    Evaluating test case: buy_one
      CPU: 39,413,941 | MEM: 152,675
    Evaluating test case: cancel_one
      CPU: 29,940,622 | MEM: 128,491
Measuring nft_minting_policy...
  O0: 56470 bytes
    Evaluating test case: valid_mint
      CPU: 54,443,157 | MEM: 276,246
  O1: 3198 bytes
    Evaluating test case: valid_mint
      CPU: 31,067,157 | MEM: 130,146
  O2: 3196 bytes
    Evaluating test case: valid_mint
      CPU: 31,027,914 | MEM: 129,914
  O3: 1510 bytes
    Evaluating test case: valid_mint
      CPU: 28,259,914 | MEM: 112,614

============================================================
BINARY SIZE AND EXECUTION COST COMPARISON REPORT
============================================================

Contract: assert_sum
Description: Simple spending validator with assertion
----------------------------------------
  O0: 54,450 → 55,074 bytes (+624 bytes, +1.1%)
    Test 'valid_sum': CPU 44,089,759 → 44,217,759 (+128,000, +0.3%) | MEM 239,074 → 239,874 (+800, +0.3%)
  O1: 3,440 → 3,816 bytes (+376 bytes, +10.9%) ⚠️  SIGNIFICANT CHANGE (ignored)
    Test 'valid_sum': CPU 19,353,759 → 19,721,759 (+368,000, +1.9%) | MEM 84,474 → 86,774 (+2,300, +2.7%)
  O2: 3,438 → 3,810 bytes (+372 bytes, +10.8%) ⚠️  SIGNIFICANT CHANGE
    Test 'valid_sum': CPU 19,314,516 → 19,682,516 (+368,000, +1.9%) | MEM 84,242 → 86,542 (+2,300, +2.7%)
  O3: 1,296 → 1,354 bytes (+58 bytes, +4.5%)
    Test 'valid_sum': CPU 17,506,516 → 17,874,516 (+368,000, +2.1%) | MEM 72,942 → 75,242 (+2,300, +3.2%)

Contract: liquidity_pool
Description: Simple DEX pool
----------------------------------------
  O0: 151,088 → 151,810 bytes (+722 bytes, +0.5%)
  O1: 47,478 → 47,734 bytes (+256 bytes, +0.5%)
  O2: 47,144 → 47,468 bytes (+324 bytes, +0.7%)
  O3: 18,544 → 18,594 bytes (+50 bytes, +0.3%)

Contract: marketplace
Description: Marketplace contract with complex data structures
----------------------------------------
  O0: 123,448 → 124,076 bytes (+628 bytes, +0.5%)
  O1: 26,036 → 26,428 bytes (+392 bytes, +1.5%)
  O2: 25,940 → 26,332 bytes (+392 bytes, +1.5%)
  O3: 4,708 → 4,778 bytes (+70 bytes, +1.5%)

Contract: gift
Description: Gift contract with simple logic
----------------------------------------
  O0: 56,918 → 57,642 bytes (+724 bytes, +1.3%)
    Test 'valid_withdrawal': CPU 51,588,498 → 52,463,891 (+875,393, +1.7%) | MEM 263,835 → 267,363 (+3,528, +1.3%)
  O1: 5,256 → 5,580 bytes (+324 bytes, +6.2%) ⚠️ (ignored)
    Test 'valid_withdrawal': CPU 28,276,498 → 29,439,891 (+1,163,393, +4.1%) | MEM 118,135 → 123,463 (+5,328, +4.5%)
  O2: 5,252 → 5,574 bytes (+322 bytes, +6.1%) ⚠️
    Test 'valid_withdrawal': CPU 28,198,012 → 29,361,405 (+1,163,393, +4.1%) | MEM 117,671 → 122,999 (+5,328, +4.5%)
  O3: 1,614 → 1,684 bytes (+70 bytes, +4.3%)
    Test 'valid_withdrawal': CPU 25,702,012 → 26,913,405 (+1,211,393, +4.7%) | MEM 102,071 → 107,699 (+5,628, +5.5%) ⚠️

Contract: wrapped_token
Description: Dual-use contract to generate a wrapped token
----------------------------------------
  O0: 64,204 → 64,774 bytes (+570 bytes, +0.9%)
  O1: 9,186 → 9,516 bytes (+330 bytes, +3.6%)
  O2: 8,906 → 9,226 bytes (+320 bytes, +3.6%)
  O3: 3,770 → 3,826 bytes (+56 bytes, +1.5%)

Contract: micropayments
Description: Channel for fee-less micropayments
----------------------------------------
  O0: 87,178 → 88,246 bytes (+1,068 bytes, +1.2%)
  O1: 19,562 → 21,198 bytes (+1,636 bytes, +8.4%) ⚠️ (ignored)
  O2: 19,488 → 21,124 bytes (+1,636 bytes, +8.4%) ⚠️
  O3: 6,918 → 7,250 bytes (+332 bytes, +4.8%)

Contract: pool_validator
Description: UPLC benchmark DEX pool validator
----------------------------------------
  O0: 62,488 → 63,204 bytes (+716 bytes, +1.1%)
    Test 'swap_a_for_b': CPU 155,211,202 → 144,496,682 (-10,714,520, -6.9%) | MEM 592,349 → 550,657 (-41,692, -7.0%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 155,211,202 → 144,496,682 (-10,714,520, -6.9%) | MEM 592,349 → 550,657 (-41,692, -7.0%) ↘️ (costs reduced)
    Test 'deposit': CPU 156,236,338 → 145,521,818 (-10,714,520, -6.9%) | MEM 581,899 → 540,207 (-41,692, -7.2%) ↘️ (costs reduced)
    Test 'withdraw': CPU 156,732,720 → 146,018,200 (-10,714,520, -6.8%) | MEM 584,201 → 542,509 (-41,692, -7.1%) ↘️ (costs reduced)
  O1: 10,670 → 11,202 bytes (+532 bytes, +5.0%)
    Test 'swap_a_for_b': CPU 142,651,202 → 128,848,682 (-13,802,520, -9.7%) | MEM 513,849 → 452,857 (-60,992, -11.9%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 142,651,202 → 128,848,682 (-13,802,520, -9.7%) | MEM 513,849 → 452,857 (-60,992, -11.9%) ↘️ (costs reduced)
    Test 'deposit': CPU 144,060,338 → 130,257,818 (-13,802,520, -9.6%) | MEM 505,799 → 444,807 (-60,992, -12.1%) ↘️ (costs reduced)
    Test 'withdraw': CPU 144,556,720 → 130,754,200 (-13,802,520, -9.5%) | MEM 508,101 → 447,109 (-60,992, -12.0%) ↘️ (costs reduced)
  O2: 10,234 → 10,756 bytes (+522 bytes, +5.1%) ⚠️
    Test 'swap_a_for_b': CPU 141,203,277 → 127,479,243 (-13,724,034, -9.7%) | MEM 505,419 → 444,891 (-60,528, -12.0%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 141,203,277 → 127,479,243 (-13,724,034, -9.7%) | MEM 505,419 → 444,891 (-60,528, -12.0%) ↘️ (costs reduced)
    Test 'deposit': CPU 143,103,366 → 129,379,332 (-13,724,034, -9.6%) | MEM 499,871 → 439,343 (-60,528, -12.1%) ↘️ (costs reduced)
    Test 'withdraw': CPU 143,567,748 → 129,843,714 (-13,724,034, -9.6%) | MEM 501,973 → 441,445 (-60,528, -12.1%) ↘️ (costs reduced)
  O3: 4,724 → 4,676 bytes (-48 bytes, -1.0%) ↘️ (size reduced)
    Test 'swap_a_for_b': CPU 136,643,277 → 120,219,315 (-16,423,962, -12.0%) | MEM 476,919 → 409,107 (-67,812, -14.2%) ↘️ (costs reduced)
    Test 'swap_b_for_a': CPU 136,643,277 → 120,219,315 (-16,423,962, -12.0%) | MEM 476,919 → 409,107 (-67,812, -14.2%) ↘️ (costs reduced)
    Test 'deposit': CPU 138,543,366 → 122,119,404 (-16,423,962, -11.9%) | MEM 471,371 → 403,559 (-67,812, -14.4%) ↘️ (costs reduced)
    Test 'withdraw': CPU 139,007,748 → 122,583,786 (-16,423,962, -11.8%) | MEM 473,473 → 405,661 (-67,812, -14.3%) ↘️ (costs reduced)

Contract: lp_minting_policy
Description: UPLC benchmark LP minting policy
----------------------------------------
  O0: 56,086 → 56,424 bytes (+338 bytes, +0.6%)
    Test 'mint_one_nft': CPU 54,116,929 → 54,068,929 (-48,000, -0.1%) | MEM 267,373 → 267,073 (-300, -0.1%) ↘️ (costs reduced)
    Test 'mint_two_nfts': CPU 71,389,257 → 71,341,257 (-48,000, -0.1%) | MEM 318,148 → 317,848 (-300, -0.1%) ↘️ (costs reduced)
  O1: 2,682 → 2,768 bytes (+86 bytes, +3.2%)
    Test 'mint_one_nft': CPU 28,740,929 → 28,932,929 (+192,000, +0.7%) | MEM 108,773 → 109,973 (+1,200, +1.1%)
    Test 'mint_two_nfts': CPU 47,005,257 → 47,197,257 (+192,000, +0.4%) | MEM 165,748 → 166,948 (+1,200, +0.7%)
  O2: 2,680 → 2,764 bytes (+84 bytes, +3.1%)
    Test 'mint_one_nft': CPU 28,701,686 → 28,893,686 (+192,000, +0.7%) | MEM 108,541 → 109,741 (+1,200, +1.1%)
    Test 'mint_two_nfts': CPU 46,926,771 → 47,118,771 (+192,000, +0.4%) | MEM 165,284 → 166,484 (+1,200, +0.7%)
  O3: 1,292 → 1,328 bytes (+36 bytes, +2.8%)
    Test 'mint_one_nft': CPU 27,309,686 → 27,501,686 (+192,000, +0.7%) | MEM 99,841 → 101,041 (+1,200, +1.2%)
    Test 'mint_two_nfts': CPU 45,534,771 → 45,726,771 (+192,000, +0.4%) | MEM 156,584 → 157,784 (+1,200, +0.8%)

Contract: nft_marketplace_validator
Description: UPLC benchmark NFT marketplace validator
----------------------------------------
  O0: 57,066 → 57,338 bytes (+272 bytes, +0.5%)
    Test 'buy_one': CPU 71,012,598 → 64,707,409 (-6,305,189, -8.9%) | MEM 334,783 → 308,335 (-26,448, -7.9%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 62,220,036 → 55,914,847 (-6,305,189, -10.1%) | MEM 314,867 → 288,419 (-26,448, -8.4%) ↘️ (costs reduced)
  O1: 6,036 → 6,078 bytes (+42 bytes, +0.7%)
    Test 'buy_one': CPU 49,812,598 → 42,803,409 (-7,009,189, -14.1%) | MEM 202,283 → 171,435 (-30,848, -15.2%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 40,620,036 → 33,610,847 (-7,009,189, -17.3%) | MEM 179,867 → 149,019 (-30,848, -17.2%) ↘️ (costs reduced)
  O2: 5,798 → 5,840 bytes (+42 bytes, +0.7%)
    Test 'buy_one': CPU 49,278,869 → 42,308,923 (-6,969,946, -14.1%) | MEM 198,987 → 168,371 (-30,616, -15.4%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 40,093,550 → 33,123,604 (-6,969,946, -17.4%) | MEM 176,603 → 145,987 (-30,616, -17.3%) ↘️ (costs reduced)
  O3: 2,642 → 2,524 bytes (-118 bytes, -4.5%) ↘️ (size reduced)
    Test 'buy_one': CPU 46,878,869 → 39,413,941 (-7,464,928, -15.9%) | MEM 183,987 → 152,675 (-31,312, -17.0%) ↘️ (costs reduced)
    Test 'cancel_one': CPU 37,405,550 → 29,940,622 (-7,464,928, -20.0%) | MEM 159,803 → 128,491 (-31,312, -19.6%) ↘️ (costs reduced)

Contract: nft_minting_policy
Description: UPLC benchmark NFT minting policy
----------------------------------------
  O0: 56,194 → 56,470 bytes (+276 bytes, +0.5%)
    Test 'valid_mint': CPU 54,603,157 → 54,443,157 (-160,000, -0.3%) | MEM 277,246 → 276,246 (-1,000, -0.4%) ↘️ (costs reduced)
  O1: 3,180 → 3,198 bytes (+18 bytes, +0.6%)
    Test 'valid_mint': CPU 31,035,157 → 31,067,157 (+32,000, +0.1%) | MEM 129,946 → 130,146 (+200, +0.2%)
  O2: 3,178 → 3,196 bytes (+18 bytes, +0.6%)
    Test 'valid_mint': CPU 30,995,914 → 31,027,914 (+32,000, +0.1%) | MEM 129,714 → 129,914 (+200, +0.2%)
  O3: 1,488 → 1,510 bytes (+22 bytes, +1.5%)
    Test 'valid_mint': CPU 28,179,914 → 28,259,914 (+80,000, +0.3%) | MEM 112,114 → 112,614 (+500, +0.4%)

Total size change compared to previous release: +14,490 bytes

⚠️  SIGNIFICANT CHANGES DETECTED
Please review the changes and consider optimization if sizes or costs increased significantly.
============================================================

Please review the binary size changes. Significant increases may impact contract deployment costs and execution limits.


This report compares the binary sizes of compiled contracts against the baseline from the latest release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant