Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove unused functions #1762

Open
wants to merge 57 commits into
base: master
Choose a base branch
from
Open

Conversation

locallycompact
Copy link
Contributor

@locallycompact locallycompact commented Dec 8, 2024

Every function that is not used in this codebase has been removed, with the few exceptions listed in the weeder roots.

A weeder check has been added to ensure no unused functions sneak back in.

Anything that is actually really needed can either be readded from history, or upstreamed to a library or form a new library so that it can be discovered in hoogle.


  • CHANGELOG updated or not needed
  • Documentation updated or not needed
  • Haddocks updated or not needed
  • No new TODOs introduced or explained herafter

Copy link

github-actions bot commented Dec 8, 2024

Transaction cost differences

No cost or size differences found

Copy link

github-actions bot commented Dec 8, 2024

Transaction costs

Sizes and execution budgets for Hydra protocol transactions. Note that unlisted parameters are currently using arbitrary values and results are not fully deterministic and comparable to previous runs.

Metadata
Generated at 2024-12-10 10:27:39.970614343 UTC
Max. memory units 14000000
Max. CPU units 10000000000
Max. tx size (kB) 16384

Script summary

Name Hash Size (Bytes)
νInitial 00a6ddbc130ab92f5b7cb8d1ccd8d79eca5bfe25f6843c07b62841f0 2667
νCommit 3e5a776bcee213e3dfd15806952a10ac5590e3e97d09d62eb99266b2 690
νHead 8fc2a74df32d01d1db56b3acb561831ef9c9970123079423abfcb86e 12622
μHead c40e78e78083a4c137734abe9ac4070cc978842e9755fe88e0c7b922* 11133
νDeposit 2feb47889a4f658dc593cefcb0e37d584b9431944f08a687f3dab4af 4865
  • The minting policy hash is only usable for comparison. As the script is parameterized, the actual script is unique per head.

Init transaction costs

Parties Tx size % max Mem % max CPU Min fee ₳
1 11717 9.01 2.95 0.76
2 11919 10.63 3.46 0.79
3 12123 12.22 3.97 0.81
5 12524 16.50 5.41 0.87
10 13527 24.69 8.03 1.00
24 16344 49.68 16.17 1.39

Commit transaction costs

This uses ada-only outputs for better comparability.

UTxO Tx size % max Mem % max CPU Min fee ₳
1 561 2.45 1.17 0.20
2 740 3.40 1.74 0.22
3 917 4.39 2.34 0.24
5 1282 6.46 3.61 0.29
10 2179 12.24 7.28 0.40
54 10062 99.20 68.72 1.89

CollectCom transaction costs

Parties UTxO (bytes) Tx size % max Mem % max CPU Min fee ₳
1 57 560 24.83 7.22 0.43
2 113 671 32.85 9.54 0.51
3 169 782 41.83 12.10 0.61
4 227 897 50.21 14.48 0.70
5 282 1004 55.38 16.11 0.76
6 337 1116 70.79 20.20 0.92
7 395 1227 73.47 21.28 0.95
8 451 1342 82.32 23.85 1.05

Cost of Decrement Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 635 22.63 7.30 0.41
2 841 25.34 8.73 0.45
3 935 24.80 9.23 0.46
5 1184 28.59 11.64 0.52
10 1940 38.13 17.64 0.67
42 6629 92.19 54.16 1.58

Close transaction costs

Parties Tx size % max Mem % max CPU Min fee ₳
1 676 24.43 8.04 0.44
2 789 25.94 9.18 0.46
3 985 28.07 10.62 0.50
5 1241 31.19 12.94 0.55
10 2136 41.58 20.08 0.72
43 6829 97.40 60.50 1.67

Contest transaction costs

Parties Tx size % max Mem % max CPU Min fee ₳
1 679 30.47 9.64 0.50
2 830 32.36 10.90 0.53
3 904 33.61 11.84 0.55
5 1295 39.12 15.18 0.63
10 1917 47.52 21.02 0.77
34 5651 98.79 53.99 1.59

Abort transaction costs

There is some variation due to the random mixture of initial and already committed outputs.

Parties Tx size % max Mem % max CPU Min fee ₳
1 11609 25.76 8.75 0.93
2 11683 31.01 10.50 0.99
3 11913 43.33 14.82 1.13
4 12079 53.18 18.16 1.24
5 12172 61.79 21.06 1.34
6 12231 69.58 23.62 1.42
7 12389 77.72 26.46 1.51
8 12547 88.36 30.19 1.63
9 12660 94.32 32.13 1.70

FanOut transaction costs

Involves spending head output and burning head tokens. Uses ada-only UTXO for better comparability.

Parties UTxO UTxO (bytes) Tx size % max Mem % max CPU Min fee ₳
10 0 0 11715 18.07 6.20 0.86
10 1 57 11749 18.83 6.56 0.87
10 5 283 11883 26.23 9.61 0.95
10 10 569 12053 35.86 13.55 1.07
10 20 1141 12395 54.74 21.30 1.29
10 30 1703 12729 73.27 28.92 1.51
10 40 2272 13069 91.60 36.46 1.73
10 44 2503 13207 98.12 39.18 1.81

End-to-end benchmark results

This page is intended to collect the latest end-to-end benchmark results produced by Hydra's continuous integration (CI) system from the latest master code.

Please note that these results are approximate as they are currently produced from limited cloud VMs and not controlled hardware. Rather than focusing on the absolute results, the emphasis should be on relative results, such as how the timings for a scenario evolve as the code changes.

Generated at 2024-12-10 10:30:23.439548252 UTC

Baseline Scenario

Number of nodes 1
Number of txs 300
Avg. Confirmation Time (ms) 5.225228980
P99 12.6347754ms
P95 6.913726950000001ms
P50 4.825255ms
Number of Invalid txs 0

Three local nodes

Number of nodes 3
Number of txs 900
Avg. Confirmation Time (ms) 24.495600886
P99 104.07618915999988ms
P95 33.752405399999994ms
P50 22.338351ms
Number of Invalid txs 0

Copy link

github-actions bot commented Dec 8, 2024

Test Results

  5 files  ±0  162 suites  ±0   33m 43s ⏱️ +35s
555 tests ±0  548 ✅ ±0  7 💤 ±0  0 ❌ ±0 
557 runs  ±0  550 ✅ ±0  7 💤 ±0  0 ❌ ±0 

Results for commit 9ee86e6. ± Comparison against base commit dd67f3d.

♻️ This comment has been updated with latest results.

@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch 3 times, most recently from 753f3d8 to a7591dc Compare December 8, 2024 15:12
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch from a7591dc to cf7893f Compare December 8, 2024 15:16
@locallycompact locallycompact requested a review from a team December 8, 2024 16:13
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch 2 times, most recently from 9e552fd to b82cf10 Compare December 8, 2024 17:13
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch from b82cf10 to 9b8c189 Compare December 8, 2024 17:14
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch from 7906771 to d871761 Compare December 8, 2024 17:17
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch from 9878b60 to 902dd42 Compare December 8, 2024 17:28
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch from 902dd42 to 8c3b112 Compare December 8, 2024 17:37
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch 4 times, most recently from ec2e064 to 4f4b2e5 Compare December 9, 2024 05:50
@locallycompact locallycompact force-pushed the lc/remove-unused-functions branch from db28f63 to a9b4b63 Compare December 9, 2024 05:52
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