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

feat: add EL sim utility fn to send big raw blob txs #5661

Merged
merged 1 commit into from
Jun 20, 2023

Conversation

g11tech
Copy link
Contributor

@g11tech g11tech commented Jun 17, 2023

Continuing extraction from

enhance sim utility to send big raw blob txs which can be curled via file post

@g11tech g11tech requested a review from a team as a code owner June 17, 2023 06:18
@github-actions
Copy link
Contributor

Performance Report

✔️ no performance regression detected

Full benchmark results
Benchmark suite Current: 147d4f0 Previous: aecb3d1 Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 566.14 us/op 1.1107 ms/op 0.51
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 45.751 us/op 94.290 us/op 0.49
BLS verify - blst-native 1.2262 ms/op 1.9111 ms/op 0.64
BLS verifyMultipleSignatures 3 - blst-native 2.4981 ms/op 4.0104 ms/op 0.62
BLS verifyMultipleSignatures 8 - blst-native 5.3245 ms/op 8.6398 ms/op 0.62
BLS verifyMultipleSignatures 32 - blst-native 19.060 ms/op 32.074 ms/op 0.59
BLS aggregatePubkeys 32 - blst-native 25.880 us/op 43.817 us/op 0.59
BLS aggregatePubkeys 128 - blst-native 101.22 us/op 145.84 us/op 0.69
getAttestationsForBlock 54.764 ms/op 113.45 ms/op 0.48
isKnown best case - 1 super set check 265.00 ns/op 372.00 ns/op 0.71
isKnown normal case - 2 super set checks 250.00 ns/op 411.00 ns/op 0.61
isKnown worse case - 16 super set checks 252.00 ns/op 374.00 ns/op 0.67
CheckpointStateCache - add get delete 5.3440 us/op 8.5650 us/op 0.62
validate gossip signedAggregateAndProof - struct 2.8151 ms/op 3.7127 ms/op 0.76
validate gossip attestation - struct 1.3358 ms/op 1.6599 ms/op 0.80
pickEth1Vote - no votes 1.2634 ms/op 1.9464 ms/op 0.65
pickEth1Vote - max votes 8.7302 ms/op 17.988 ms/op 0.49
pickEth1Vote - Eth1Data hashTreeRoot value x2048 8.1980 ms/op 17.183 ms/op 0.48
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 14.428 ms/op 26.072 ms/op 0.55
pickEth1Vote - Eth1Data fastSerialize value x2048 628.52 us/op 969.88 us/op 0.65
pickEth1Vote - Eth1Data fastSerialize tree x2048 8.1333 ms/op 8.4618 ms/op 0.96
bytes32 toHexString 505.00 ns/op 1.3080 us/op 0.39
bytes32 Buffer.toString(hex) 355.00 ns/op 702.00 ns/op 0.51
bytes32 Buffer.toString(hex) from Uint8Array 554.00 ns/op 1.3390 us/op 0.41
bytes32 Buffer.toString(hex) + 0x 352.00 ns/op 741.00 ns/op 0.48
Object access 1 prop 0.17100 ns/op 0.34100 ns/op 0.50
Map access 1 prop 0.15800 ns/op 0.28800 ns/op 0.55
Object get x1000 6.9630 ns/op 10.934 ns/op 0.64
Map get x1000 0.55400 ns/op 1.6490 ns/op 0.34
Object set x1000 53.843 ns/op 117.13 ns/op 0.46
Map set x1000 44.893 ns/op 88.993 ns/op 0.50
Return object 10000 times 0.24060 ns/op 0.68000 ns/op 0.35
Throw Error 10000 times 4.3064 us/op 8.8030 us/op 0.49
fastMsgIdFn sha256 / 200 bytes 3.6140 us/op 5.8820 us/op 0.61
fastMsgIdFn h32 xxhash / 200 bytes 281.00 ns/op 730.00 ns/op 0.38
fastMsgIdFn h64 xxhash / 200 bytes 388.00 ns/op 1.0620 us/op 0.37
fastMsgIdFn sha256 / 1000 bytes 11.816 us/op 20.140 us/op 0.59
fastMsgIdFn h32 xxhash / 1000 bytes 417.00 ns/op 934.00 ns/op 0.45
fastMsgIdFn h64 xxhash / 1000 bytes 502.00 ns/op 1.1640 us/op 0.43
fastMsgIdFn sha256 / 10000 bytes 105.88 us/op 170.51 us/op 0.62
fastMsgIdFn h32 xxhash / 10000 bytes 1.9980 us/op 3.2370 us/op 0.62
fastMsgIdFn h64 xxhash / 10000 bytes 1.4320 us/op 1.9650 us/op 0.73
enrSubnets - fastDeserialize 64 bits 1.3350 us/op 3.1290 us/op 0.43
enrSubnets - ssz BitVector 64 bits 515.00 ns/op 1.1700 us/op 0.44
enrSubnets - fastDeserialize 4 bits 171.00 ns/op 385.00 ns/op 0.44
enrSubnets - ssz BitVector 4 bits 495.00 ns/op 958.00 ns/op 0.52
prioritizePeers score -10:0 att 32-0.1 sync 2-0 110.74 us/op 236.49 us/op 0.47
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 138.45 us/op 283.91 us/op 0.49
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 168.02 us/op 359.58 us/op 0.47
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 303.89 us/op 717.41 us/op 0.42
prioritizePeers score 0:0 att 64-1 sync 4-1 367.83 us/op 670.47 us/op 0.55
array of 16000 items push then shift 1.6652 us/op 3.1345 us/op 0.53
LinkedList of 16000 items push then shift 8.9950 ns/op 17.203 ns/op 0.52
array of 16000 items push then pop 85.564 ns/op 213.91 ns/op 0.40
LinkedList of 16000 items push then pop 8.6990 ns/op 12.403 ns/op 0.70
array of 24000 items push then shift 2.3748 us/op 3.1074 us/op 0.76
LinkedList of 24000 items push then shift 9.0150 ns/op 12.890 ns/op 0.70
array of 24000 items push then pop 75.717 ns/op 128.19 ns/op 0.59
LinkedList of 24000 items push then pop 8.7030 ns/op 10.568 ns/op 0.82
intersect bitArray bitLen 8 13.424 ns/op 16.055 ns/op 0.84
intersect array and set length 8 78.467 ns/op 112.47 ns/op 0.70
intersect bitArray bitLen 128 44.745 ns/op 50.962 ns/op 0.88
intersect array and set length 128 1.0640 us/op 1.4102 us/op 0.75
Buffer.concat 32 items 2.8220 us/op 3.2940 us/op 0.86
Uint8Array.set 32 items 3.0780 us/op 3.5860 us/op 0.86
transfer serialized Status (84 B) 2.2100 us/op 2.6240 us/op 0.84
copy serialized Status (84 B) 1.8960 us/op 2.1770 us/op 0.87
transfer serialized SignedVoluntaryExit (112 B) 2.3440 us/op 2.6230 us/op 0.89
copy serialized SignedVoluntaryExit (112 B) 1.8810 us/op 2.1910 us/op 0.86
transfer serialized ProposerSlashing (416 B) 2.6980 us/op 2.9760 us/op 0.91
copy serialized ProposerSlashing (416 B) 2.8820 us/op 2.6860 us/op 1.07
transfer serialized Attestation (485 B) 2.2860 us/op 2.9650 us/op 0.77
copy serialized Attestation (485 B) 2.0030 us/op 2.7060 us/op 0.74
transfer serialized AttesterSlashing (33232 B) 2.2780 us/op 2.9020 us/op 0.78
copy serialized AttesterSlashing (33232 B) 5.1910 us/op 8.2380 us/op 0.63
transfer serialized Small SignedBeaconBlock (128000 B) 2.5870 us/op 3.4290 us/op 0.75
copy serialized Small SignedBeaconBlock (128000 B) 12.451 us/op 25.107 us/op 0.50
transfer serialized Avg SignedBeaconBlock (200000 B) 2.9320 us/op 4.6730 us/op 0.63
copy serialized Avg SignedBeaconBlock (200000 B) 19.174 us/op 47.937 us/op 0.40
transfer serialized BlobsSidecar (524380 B) 3.0270 us/op 4.5100 us/op 0.67
copy serialized BlobsSidecar (524380 B) 144.97 us/op 226.36 us/op 0.64
transfer serialized Big SignedBeaconBlock (1000000 B) 3.4520 us/op 5.1570 us/op 0.67
copy serialized Big SignedBeaconBlock (1000000 B) 324.38 us/op 373.10 us/op 0.87
pass gossip attestations to forkchoice per slot 2.7287 ms/op 3.1848 ms/op 0.86
forkChoice updateHead vc 100000 bc 64 eq 0 2.1083 ms/op 2.3750 ms/op 0.89
forkChoice updateHead vc 600000 bc 64 eq 0 14.761 ms/op 16.528 ms/op 0.89
forkChoice updateHead vc 1000000 bc 64 eq 0 18.852 ms/op 23.275 ms/op 0.81
forkChoice updateHead vc 600000 bc 320 eq 0 16.431 ms/op 18.875 ms/op 0.87
forkChoice updateHead vc 600000 bc 1200 eq 0 78.207 ms/op 96.613 ms/op 0.81
forkChoice updateHead vc 600000 bc 64 eq 1000 23.188 ms/op 23.280 ms/op 1.00
forkChoice updateHead vc 600000 bc 64 eq 10000 24.931 ms/op 26.525 ms/op 0.94
forkChoice updateHead vc 600000 bc 64 eq 300000 35.607 ms/op 36.717 ms/op 0.97
computeDeltas 3.0081 ms/op 3.0466 ms/op 0.99
computeProposerBoostScoreFromBalances 1.7590 ms/op 1.8057 ms/op 0.97
altair processAttestation - 250000 vs - 7PWei normalcase 2.1435 ms/op 2.2818 ms/op 0.94
altair processAttestation - 250000 vs - 7PWei worstcase 3.2933 ms/op 3.3839 ms/op 0.97
altair processAttestation - setStatus - 1/6 committees join 131.32 us/op 142.61 us/op 0.92
altair processAttestation - setStatus - 1/3 committees join 270.55 us/op 283.37 us/op 0.95
altair processAttestation - setStatus - 1/2 committees join 370.12 us/op 384.07 us/op 0.96
altair processAttestation - setStatus - 2/3 committees join 456.29 us/op 486.51 us/op 0.94
altair processAttestation - setStatus - 4/5 committees join 649.01 us/op 685.46 us/op 0.95
altair processAttestation - setStatus - 100% committees join 756.32 us/op 786.18 us/op 0.96
altair processBlock - 250000 vs - 7PWei normalcase 18.165 ms/op 17.365 ms/op 1.05
altair processBlock - 250000 vs - 7PWei normalcase hashState 23.374 ms/op 25.231 ms/op 0.93
altair processBlock - 250000 vs - 7PWei worstcase 48.618 ms/op 50.947 ms/op 0.95
altair processBlock - 250000 vs - 7PWei worstcase hashState 70.752 ms/op 72.727 ms/op 0.97
phase0 processBlock - 250000 vs - 7PWei normalcase 1.9640 ms/op 2.2513 ms/op 0.87
phase0 processBlock - 250000 vs - 7PWei worstcase 27.633 ms/op 29.927 ms/op 0.92
altair processEth1Data - 250000 vs - 7PWei normalcase 455.15 us/op 510.07 us/op 0.89
getExpectedWithdrawals 250000 eb:1,eth1:1,we:0,wn:0,smpl:15 6.5850 us/op 7.2010 us/op 0.91
getExpectedWithdrawals 250000 eb:0.95,eth1:0.1,we:0.05,wn:0,smpl:219 19.400 us/op 23.811 us/op 0.81
getExpectedWithdrawals 250000 eb:0.95,eth1:0.3,we:0.05,wn:0,smpl:42 7.9950 us/op 11.583 us/op 0.69
getExpectedWithdrawals 250000 eb:0.95,eth1:0.7,we:0.05,wn:0,smpl:18 6.2260 us/op 6.3810 us/op 0.98
getExpectedWithdrawals 250000 eb:0.1,eth1:0.1,we:0,wn:0,smpl:1020 76.512 us/op 74.947 us/op 1.02
getExpectedWithdrawals 250000 eb:0.03,eth1:0.03,we:0,wn:0,smpl:11777 639.55 us/op 622.74 us/op 1.03
getExpectedWithdrawals 250000 eb:0.01,eth1:0.01,we:0,wn:0,smpl:16384 897.23 us/op 892.80 us/op 1.00
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,smpl:16384 856.51 us/op 858.98 us/op 1.00
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,nocache,smpl:16384 2.1298 ms/op 2.3171 ms/op 0.92
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,smpl:16384 1.5197 ms/op 1.8592 ms/op 0.82
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,nocache,smpl:16384 3.8877 ms/op 3.9515 ms/op 0.98
Tree 40 250000 create 321.94 ms/op 307.48 ms/op 1.05
Tree 40 250000 get(125000) 190.34 ns/op 189.74 ns/op 1.00
Tree 40 250000 set(125000) 989.28 ns/op 985.22 ns/op 1.00
Tree 40 250000 toArray() 17.668 ms/op 18.777 ms/op 0.94
Tree 40 250000 iterate all - toArray() + loop 17.883 ms/op 18.272 ms/op 0.98
Tree 40 250000 iterate all - get(i) 71.664 ms/op 71.187 ms/op 1.01
MutableVector 250000 create 10.173 ms/op 11.182 ms/op 0.91
MutableVector 250000 get(125000) 6.4010 ns/op 6.5900 ns/op 0.97
MutableVector 250000 set(125000) 268.15 ns/op 263.52 ns/op 1.02
MutableVector 250000 toArray() 2.6788 ms/op 2.8040 ms/op 0.96
MutableVector 250000 iterate all - toArray() + loop 2.8075 ms/op 2.9554 ms/op 0.95
MutableVector 250000 iterate all - get(i) 1.5340 ms/op 1.5450 ms/op 0.99
Array 250000 create 2.4667 ms/op 2.6826 ms/op 0.92
Array 250000 clone - spread 1.1194 ms/op 1.2616 ms/op 0.89
Array 250000 get(125000) 0.58000 ns/op 0.62100 ns/op 0.93
Array 250000 set(125000) 0.64500 ns/op 0.67400 ns/op 0.96
Array 250000 iterate all - loop 82.742 us/op 107.85 us/op 0.77
effectiveBalanceIncrements clone Uint8Array 300000 31.374 us/op 40.870 us/op 0.77
effectiveBalanceIncrements clone MutableVector 300000 357.00 ns/op 409.00 ns/op 0.87
effectiveBalanceIncrements rw all Uint8Array 300000 170.49 us/op 177.05 us/op 0.96
effectiveBalanceIncrements rw all MutableVector 300000 83.225 ms/op 96.906 ms/op 0.86
phase0 afterProcessEpoch - 250000 vs - 7PWei 113.38 ms/op 118.71 ms/op 0.96
phase0 beforeProcessEpoch - 250000 vs - 7PWei 36.130 ms/op 35.096 ms/op 1.03
altair processEpoch - mainnet_e81889 321.45 ms/op 338.91 ms/op 0.95
mainnet_e81889 - altair beforeProcessEpoch 65.183 ms/op 67.961 ms/op 0.96
mainnet_e81889 - altair processJustificationAndFinalization 16.058 us/op 22.392 us/op 0.72
mainnet_e81889 - altair processInactivityUpdates 5.3786 ms/op 6.2795 ms/op 0.86
mainnet_e81889 - altair processRewardsAndPenalties 51.777 ms/op 68.766 ms/op 0.75
mainnet_e81889 - altair processRegistryUpdates 2.4220 us/op 3.1030 us/op 0.78
mainnet_e81889 - altair processSlashings 481.00 ns/op 834.00 ns/op 0.58
mainnet_e81889 - altair processEth1DataReset 498.00 ns/op 647.00 ns/op 0.77
mainnet_e81889 - altair processEffectiveBalanceUpdates 1.2147 ms/op 1.6293 ms/op 0.75
mainnet_e81889 - altair processSlashingsReset 4.9380 us/op 6.8420 us/op 0.72
mainnet_e81889 - altair processRandaoMixesReset 4.6280 us/op 6.5410 us/op 0.71
mainnet_e81889 - altair processHistoricalRootsUpdate 783.00 ns/op 2.0260 us/op 0.39
mainnet_e81889 - altair processParticipationFlagUpdates 2.4530 us/op 4.3650 us/op 0.56
mainnet_e81889 - altair processSyncCommitteeUpdates 511.00 ns/op 1000.0 ns/op 0.51
mainnet_e81889 - altair afterProcessEpoch 118.19 ms/op 158.08 ms/op 0.75
phase0 processEpoch - mainnet_e58758 318.38 ms/op 476.06 ms/op 0.67
mainnet_e58758 - phase0 beforeProcessEpoch 121.61 ms/op 163.08 ms/op 0.75
mainnet_e58758 - phase0 processJustificationAndFinalization 17.299 us/op 24.374 us/op 0.71
mainnet_e58758 - phase0 processRewardsAndPenalties 56.496 ms/op 69.003 ms/op 0.82
mainnet_e58758 - phase0 processRegistryUpdates 7.4200 us/op 10.032 us/op 0.74
mainnet_e58758 - phase0 processSlashings 523.00 ns/op 721.00 ns/op 0.73
mainnet_e58758 - phase0 processEth1DataReset 513.00 ns/op 821.00 ns/op 0.62
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 978.06 us/op 1.1161 ms/op 0.88
mainnet_e58758 - phase0 processSlashingsReset 3.0020 us/op 6.6080 us/op 0.45
mainnet_e58758 - phase0 processRandaoMixesReset 4.9520 us/op 5.7340 us/op 0.86
mainnet_e58758 - phase0 processHistoricalRootsUpdate 815.00 ns/op 842.00 ns/op 0.97
mainnet_e58758 - phase0 processParticipationRecordUpdates 5.4740 us/op 4.5460 us/op 1.20
mainnet_e58758 - phase0 afterProcessEpoch 94.332 ms/op 101.00 ms/op 0.93
phase0 processEffectiveBalanceUpdates - 250000 normalcase 1.2400 ms/op 1.2529 ms/op 0.99
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 1.4852 ms/op 1.5697 ms/op 0.95
altair processInactivityUpdates - 250000 normalcase 26.655 ms/op 27.083 ms/op 0.98
altair processInactivityUpdates - 250000 worstcase 27.088 ms/op 28.749 ms/op 0.94
phase0 processRegistryUpdates - 250000 normalcase 7.0380 us/op 6.4220 us/op 1.10
phase0 processRegistryUpdates - 250000 badcase_full_deposits 238.86 us/op 282.10 us/op 0.85
phase0 processRegistryUpdates - 250000 worstcase 0.5 124.30 ms/op 143.54 ms/op 0.87
altair processRewardsAndPenalties - 250000 normalcase 66.631 ms/op 73.209 ms/op 0.91
altair processRewardsAndPenalties - 250000 worstcase 67.861 ms/op 74.361 ms/op 0.91
phase0 getAttestationDeltas - 250000 normalcase 7.1018 ms/op 7.4106 ms/op 0.96
phase0 getAttestationDeltas - 250000 worstcase 6.9015 ms/op 7.0751 ms/op 0.98
phase0 processSlashings - 250000 worstcase 3.4887 ms/op 3.8769 ms/op 0.90
altair processSyncCommitteeUpdates - 250000 176.42 ms/op 192.82 ms/op 0.91
BeaconState.hashTreeRoot - No change 365.00 ns/op 284.00 ns/op 1.29
BeaconState.hashTreeRoot - 1 full validator 52.042 us/op 55.584 us/op 0.94
BeaconState.hashTreeRoot - 32 full validator 492.06 us/op 570.25 us/op 0.86
BeaconState.hashTreeRoot - 512 full validator 5.8655 ms/op 5.8811 ms/op 1.00
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 65.204 us/op 69.887 us/op 0.93
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 945.70 us/op 917.60 us/op 1.03
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 11.296 ms/op 13.408 ms/op 0.84
BeaconState.hashTreeRoot - 1 balances 51.359 us/op 51.538 us/op 1.00
BeaconState.hashTreeRoot - 32 balances 442.43 us/op 465.20 us/op 0.95
BeaconState.hashTreeRoot - 512 balances 4.4415 ms/op 5.0646 ms/op 0.88
BeaconState.hashTreeRoot - 250000 balances 70.987 ms/op 83.833 ms/op 0.85
aggregationBits - 2048 els - zipIndexesInBitList 16.225 us/op 18.676 us/op 0.87
regular array get 100000 times 42.685 us/op 36.086 us/op 1.18
wrappedArray get 100000 times 33.954 us/op 35.938 us/op 0.94
arrayWithProxy get 100000 times 17.016 ms/op 18.339 ms/op 0.93
ssz.Root.equals 562.00 ns/op 593.00 ns/op 0.95
byteArrayEquals 565.00 ns/op 594.00 ns/op 0.95
shuffle list - 16384 els 7.2936 ms/op 7.4932 ms/op 0.97
shuffle list - 250000 els 102.65 ms/op 111.57 ms/op 0.92
processSlot - 1 slots 9.0100 us/op 10.793 us/op 0.83
processSlot - 32 slots 1.3671 ms/op 1.6457 ms/op 0.83
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 34.929 ms/op 39.901 ms/op 0.88
getCommitteeAssignments - req 1 vs - 250000 vc 2.9398 ms/op 3.0675 ms/op 0.96
getCommitteeAssignments - req 100 vs - 250000 vc 4.0635 ms/op 4.5081 ms/op 0.90
getCommitteeAssignments - req 1000 vs - 250000 vc 4.5566 ms/op 4.8134 ms/op 0.95
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 4.7400 ns/op 5.4600 ns/op 0.87
state getBlockRootAtSlot - 250000 vs - 7PWei 595.94 ns/op 712.70 ns/op 0.84
computeProposers - vc 250000 10.638 ms/op 11.597 ms/op 0.92
computeEpochShuffling - vc 250000 102.02 ms/op 114.34 ms/op 0.89
getNextSyncCommittee - vc 250000 172.54 ms/op 208.39 ms/op 0.83
computeSigningRoot for AttestationData 12.618 us/op 16.539 us/op 0.76
hash AttestationData serialized data then Buffer.toString(base64) 2.4330 us/op 2.8692 us/op 0.85
toHexString serialized data 1.0610 us/op 1.3575 us/op 0.78
Buffer.toString(base64) 323.14 ns/op 435.87 ns/op 0.74

by benchmarkbot/action

@g11tech g11tech enabled auto-merge (squash) June 17, 2023 06:42
@g11tech g11tech merged commit 5d9d86d into unstable Jun 20, 2023
@g11tech g11tech deleted the g11tech/runel-sendrawtxbig branch June 20, 2023 14:06
@wemeetagain
Copy link
Member

🎉 This PR is included in v1.10.0 🎉

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.

2 participants