input-output-hk / hydra

Implementation of the Hydra Head protocol
https://hydra.family/head-protocol/
Apache License 2.0
264 stars 86 forks source link

Add magic-nix #1472

Open locallycompact opened 2 weeks ago

locallycompact commented 2 weeks ago

github-actions[bot] commented 2 weeks ago

Transactions 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-06-17 19:02:09.339577768 UTC
Max. memory units 14000000
Max. CPU units 10000000000
Max. tx size (kB) 16384

Script summary

Name Hash Size (Bytes)
νInitial baafeb5dc37bbe6e068784746bda0a3b1bb1d034fa0c55270f6079c1 4082
νCommit fe7af84822bcba542fae377ae7311fc5fd20152f925ccd980f73ecdc 2061
νHead 93c08c55e804d7f82ca545a01883b5fda6a6d3623cb78885625800ae 9366
μHead 5e65c73722b4bb3f0cbfcc8433e1dcdfea099eaf0a43060f1731a65b* 4237
Parties Tx size % max Mem % max CPU Min fee ₳
1 4823 5.78 2.27 0.43
2 5019 7.29 2.86 0.45
3 5220 8.80 3.46 0.48
5 5623 11.54 4.54 0.52
10 6629 18.74 7.39 0.65
58 16276 85.75 33.80 1.80

Cost of Commit Transaction

This is using ada-only outputs for better comparability.

UTxO Tx size % max Mem % max CPU Min fee ₳
1 556 9.69 3.82 0.28
2 749 12.48 5.10 0.32
3 934 15.33 6.40 0.36
5 1306 21.26 9.09 0.45
10 2238 37.35 16.27 0.67
25 5053 96.42 41.75 1.45

Cost of CollectCom Transaction

Parties UTxO (bytes) Tx size % max Mem % max CPU Min fee ₳
1 56 543 14.78 5.90 0.34
2 114 654 23.48 9.48 0.44
3 170 768 32.40 13.25 0.54
4 225 874 45.48 18.67 0.69
5 282 984 58.38 24.13 0.84
6 339 1095 70.63 29.44 0.98
7 393 1205 92.40 38.40 1.23

Cost of Close Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 625 8.22 4.59 0.28
2 798 9.37 5.99 0.30
3 890 9.71 6.74 0.32
5 1178 11.31 9.10 0.36
10 2027 16.14 15.48 0.48
50 8069 51.28 63.52 1.38

Cost of Contest Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 618 8.60 4.71 0.28
2 771 9.33 5.79 0.30
3 889 10.10 6.87 0.32
5 1110 11.05 8.64 0.35
10 1929 15.91 15.01 0.47
50 8263 51.58 64.00 1.39

Cost of Abort Transaction

Some variation because of random mixture of still initial and already committed outputs.

Parties Tx size % max Mem % max CPU Min fee ₳
1 4689 17.04 7.37 0.55
2 4799 24.54 10.57 0.64
3 4987 41.86 18.41 0.84
4 5044 56.70 24.85 1.01
5 5296 77.43 34.13 1.25
6 5270 91.12 39.97 1.41

Cost of FanOut Transaction

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 ₳
5 0 0 4651 7.61 3.18 0.44
5 1 57 4685 8.97 3.98 0.46
5 5 284 4821 13.58 6.83 0.52
5 10 569 4990 19.55 10.48 0.60
5 20 1141 5333 30.87 17.52 0.76
5 30 1704 5667 42.61 24.75 0.92
5 40 2275 6008 54.35 31.97 1.08
5 50 2846 6349 65.68 39.03 1.24
5 79 4498 7335 99.05 59.71 1.70

End-To-End Benchmark Results

This page is intended to collect the latest end-to-end benchmarks results produced by Hydra's Continuous Integration system from the latest master code.

Please take those results with a grain of salt as they are currently produced from very limited cloud VMs and not controlled hardware. Instead of focusing on the absolute results, the emphasis should be on relative results, eg. how the timings for a scenario evolve as the code changes.

Generated at 2024-06-17 19:06:50.116382074 UTC

Baseline Scenario

Number of nodes 1
Number of txs 3000
Avg. Confirmation Time (ms) 4.087913834
P99 10.04815334999999ms
P95 5.0221497ms
P50 3.835885ms
Number of Invalid txs 0

Three local nodes

Number of nodes 3
Number of txs 9000
Avg. Confirmation Time (ms) 21.456971645
P99 69.42431469000155ms
P95 30.195933999999987ms
P50 19.0298225ms
Number of Invalid txs 0
github-actions[bot] commented 2 weeks ago

Test Results

437 tests  ±0   425 :white_check_mark: ±0   15m 48s :stopwatch: +50s 143 suites ±0    12 :zzz: ±0    5 files   ±0     0 :x: ±0 

Results for commit b4d042cd. ± Comparison against base commit 4af74cfa.

:recycle: This comment has been updated with latest results.