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

Align @lodestar/reqresp package version #4791

Merged
merged 1 commit into from
Nov 21, 2022

Conversation

wemeetagain
Copy link
Member

No description provided.

@wemeetagain wemeetagain requested a review from a team as a code owner November 21, 2022 21:11
@dapplion dapplion enabled auto-merge (squash) November 21, 2022 21:11
@github-actions
Copy link
Contributor

Performance Report

✔️ no performance regression detected

Full benchmark results
Benchmark suite Current: 91086e9 Previous: 8a211da Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 2.8996 ms/op 1.9221 ms/op 1.51
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 91.044 us/op 64.615 us/op 1.41
BLS verify - blst-native 2.2173 ms/op 2.1695 ms/op 1.02
BLS verifyMultipleSignatures 3 - blst-native 4.4982 ms/op 4.4888 ms/op 1.00
BLS verifyMultipleSignatures 8 - blst-native 9.8811 ms/op 9.6916 ms/op 1.02
BLS verifyMultipleSignatures 32 - blst-native 35.822 ms/op 35.194 ms/op 1.02
BLS aggregatePubkeys 32 - blst-native 48.247 us/op 46.917 us/op 1.03
BLS aggregatePubkeys 128 - blst-native 187.56 us/op 182.95 us/op 1.03
getAttestationsForBlock 124.35 ms/op 84.168 ms/op 1.48
isKnown best case - 1 super set check 527.00 ns/op 486.00 ns/op 1.08
isKnown normal case - 2 super set checks 524.00 ns/op 479.00 ns/op 1.09
isKnown worse case - 16 super set checks 501.00 ns/op 474.00 ns/op 1.06
CheckpointStateCache - add get delete 10.845 us/op 9.1010 us/op 1.19
validate gossip signedAggregateAndProof - struct 5.1539 ms/op 5.0220 ms/op 1.03
validate gossip attestation - struct 2.4158 ms/op 2.3764 ms/op 1.02
pickEth1Vote - no votes 2.5985 ms/op 2.4465 ms/op 1.06
pickEth1Vote - max votes 25.049 ms/op 20.559 ms/op 1.22
pickEth1Vote - Eth1Data hashTreeRoot value x2048 13.467 ms/op 12.943 ms/op 1.04
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 22.466 ms/op 21.144 ms/op 1.06
pickEth1Vote - Eth1Data fastSerialize value x2048 1.8673 ms/op 1.5059 ms/op 1.24
pickEth1Vote - Eth1Data fastSerialize tree x2048 17.399 ms/op 14.312 ms/op 1.22
bytes32 toHexString 1.3820 us/op 1.0870 us/op 1.27
bytes32 Buffer.toString(hex) 881.00 ns/op 751.00 ns/op 1.17
bytes32 Buffer.toString(hex) from Uint8Array 1.3670 us/op 1.0070 us/op 1.36
bytes32 Buffer.toString(hex) + 0x 878.00 ns/op 736.00 ns/op 1.19
Object access 1 prop 0.48400 ns/op 0.36900 ns/op 1.31
Map access 1 prop 0.34300 ns/op 0.31300 ns/op 1.10
Object get x1000 16.252 ns/op 10.996 ns/op 1.48
Map get x1000 1.1770 ns/op 0.96700 ns/op 1.22
Object set x1000 121.27 ns/op 72.923 ns/op 1.66
Map set x1000 83.843 ns/op 48.519 ns/op 1.73
Return object 10000 times 0.42880 ns/op 0.43840 ns/op 0.98
Throw Error 10000 times 6.9567 us/op 6.0328 us/op 1.15
fastMsgIdFn sha256 / 200 bytes 5.4540 us/op 4.8350 us/op 1.13
fastMsgIdFn h32 xxhash / 200 bytes 663.00 ns/op 558.00 ns/op 1.19
fastMsgIdFn h64 xxhash / 200 bytes 953.00 ns/op 813.00 ns/op 1.17
fastMsgIdFn sha256 / 1000 bytes 16.276 us/op 15.408 us/op 1.06
fastMsgIdFn h32 xxhash / 1000 bytes 802.00 ns/op 735.00 ns/op 1.09
fastMsgIdFn h64 xxhash / 1000 bytes 1.0150 us/op 890.00 ns/op 1.14
fastMsgIdFn sha256 / 10000 bytes 141.94 us/op 134.28 us/op 1.06
fastMsgIdFn h32 xxhash / 10000 bytes 2.7420 us/op 2.5910 us/op 1.06
fastMsgIdFn h64 xxhash / 10000 bytes 2.0980 us/op 1.9010 us/op 1.10
enrSubnets - fastDeserialize 64 bits 3.2730 us/op 2.8780 us/op 1.14
enrSubnets - ssz BitVector 64 bits 888.00 ns/op 861.00 ns/op 1.03
enrSubnets - fastDeserialize 4 bits 466.00 ns/op 391.00 ns/op 1.19
enrSubnets - ssz BitVector 4 bits 875.00 ns/op 845.00 ns/op 1.04
prioritizePeers score -10:0 att 32-0.1 sync 2-0 120.31 us/op 86.150 us/op 1.40
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 160.47 us/op 132.88 us/op 1.21
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 304.51 us/op 215.53 us/op 1.41
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 665.47 us/op 348.81 us/op 1.91
prioritizePeers score 0:0 att 64-1 sync 4-1 598.32 us/op 449.47 us/op 1.33
RateTracker 1000000 limit, 1 obj count per request 216.90 ns/op 190.09 ns/op 1.14
RateTracker 1000000 limit, 2 obj count per request 161.96 ns/op 137.73 ns/op 1.18
RateTracker 1000000 limit, 4 obj count per request 134.34 ns/op 113.17 ns/op 1.19
RateTracker 1000000 limit, 8 obj count per request 117.48 ns/op 100.58 ns/op 1.17
RateTracker with prune 5.4450 us/op 3.9570 us/op 1.38
array of 16000 items push then shift 5.7554 us/op 51.580 us/op 0.11
LinkedList of 16000 items push then shift 21.772 ns/op 12.827 ns/op 1.70
array of 16000 items push then pop 278.48 ns/op 208.55 ns/op 1.34
LinkedList of 16000 items push then pop 19.085 ns/op 12.302 ns/op 1.55
array of 24000 items push then shift 8.3647 us/op 77.347 us/op 0.11
LinkedList of 24000 items push then shift 21.573 ns/op 13.081 ns/op 1.65
array of 24000 items push then pop 263.72 ns/op 181.32 ns/op 1.45
LinkedList of 24000 items push then pop 19.304 ns/op 12.388 ns/op 1.56
intersect bitArray bitLen 8 14.194 ns/op 10.477 ns/op 1.35
intersect array and set length 8 205.16 ns/op 147.36 ns/op 1.39
intersect bitArray bitLen 128 72.139 ns/op 59.403 ns/op 1.21
intersect array and set length 128 2.4530 us/op 1.8583 us/op 1.32
Buffer.concat 32 items 2.9000 ns/op 1.8880 ns/op 1.54
pass gossip attestations to forkchoice per slot 4.5242 ms/op 5.4911 ms/op 0.82
computeDeltas 6.2693 ms/op 4.8688 ms/op 1.29
computeProposerBoostScoreFromBalances 892.21 us/op 805.17 us/op 1.11
altair processAttestation - 250000 vs - 7PWei normalcase 5.1614 ms/op 3.8923 ms/op 1.33
altair processAttestation - 250000 vs - 7PWei worstcase 7.9055 ms/op 5.2978 ms/op 1.49
altair processAttestation - setStatus - 1/6 committees join 249.12 us/op 181.48 us/op 1.37
altair processAttestation - setStatus - 1/3 committees join 494.39 us/op 357.98 us/op 1.38
altair processAttestation - setStatus - 1/2 committees join 743.60 us/op 512.72 us/op 1.45
altair processAttestation - setStatus - 2/3 committees join 936.02 us/op 669.37 us/op 1.40
altair processAttestation - setStatus - 4/5 committees join 1.3018 ms/op 930.05 us/op 1.40
altair processAttestation - setStatus - 100% committees join 1.5079 ms/op 1.1241 ms/op 1.34
altair processBlock - 250000 vs - 7PWei normalcase 34.358 ms/op 24.325 ms/op 1.41
altair processBlock - 250000 vs - 7PWei normalcase hashState 43.183 ms/op 38.146 ms/op 1.13
altair processBlock - 250000 vs - 7PWei worstcase 108.92 ms/op 81.832 ms/op 1.33
altair processBlock - 250000 vs - 7PWei worstcase hashState 119.96 ms/op 102.41 ms/op 1.17
phase0 processBlock - 250000 vs - 7PWei normalcase 4.8293 ms/op 3.2218 ms/op 1.50
phase0 processBlock - 250000 vs - 7PWei worstcase 56.588 ms/op 51.354 ms/op 1.10
altair processEth1Data - 250000 vs - 7PWei normalcase 1.1788 ms/op 802.98 us/op 1.47
Tree 40 250000 create 1.0200 s/op 709.70 ms/op 1.44
Tree 40 250000 get(125000) 343.87 ns/op 265.98 ns/op 1.29
Tree 40 250000 set(125000) 3.4340 us/op 2.2310 us/op 1.54
Tree 40 250000 toArray() 39.891 ms/op 27.322 ms/op 1.46
Tree 40 250000 iterate all - toArray() + loop 39.303 ms/op 27.646 ms/op 1.42
Tree 40 250000 iterate all - get(i) 139.80 ms/op 119.71 ms/op 1.17
MutableVector 250000 create 22.486 ms/op 13.104 ms/op 1.72
MutableVector 250000 get(125000) 14.644 ns/op 10.778 ns/op 1.36
MutableVector 250000 set(125000) 1.0119 us/op 569.08 ns/op 1.78
MutableVector 250000 toArray() 8.5534 ms/op 5.7779 ms/op 1.48
MutableVector 250000 iterate all - toArray() + loop 8.9419 ms/op 5.9244 ms/op 1.51
MutableVector 250000 iterate all - get(i) 6.2860 ms/op 2.6175 ms/op 2.40
Array 250000 create 7.1493 ms/op 5.5547 ms/op 1.29
Array 250000 clone - spread 4.6446 ms/op 3.1844 ms/op 1.46
Array 250000 get(125000) 1.8420 ns/op 1.5040 ns/op 1.22
Array 250000 set(125000) 1.7870 ns/op 1.4790 ns/op 1.21
Array 250000 iterate all - loop 149.00 us/op 150.97 us/op 0.99
effectiveBalanceIncrements clone Uint8Array 300000 126.42 us/op 593.34 us/op 0.21
effectiveBalanceIncrements clone MutableVector 300000 1.3480 us/op 684.00 ns/op 1.97
effectiveBalanceIncrements rw all Uint8Array 300000 294.37 us/op 247.30 us/op 1.19
effectiveBalanceIncrements rw all MutableVector 300000 310.81 ms/op 144.77 ms/op 2.15
phase0 afterProcessEpoch - 250000 vs - 7PWei 199.61 ms/op 192.04 ms/op 1.04
phase0 beforeProcessEpoch - 250000 vs - 7PWei 112.37 ms/op 56.716 ms/op 1.98
altair processEpoch - mainnet_e81889 554.76 ms/op 562.66 ms/op 0.99
mainnet_e81889 - altair beforeProcessEpoch 187.01 ms/op 112.30 ms/op 1.67
mainnet_e81889 - altair processJustificationAndFinalization 76.176 us/op 17.111 us/op 4.45
mainnet_e81889 - altair processInactivityUpdates 13.186 ms/op 9.1618 ms/op 1.44
mainnet_e81889 - altair processRewardsAndPenalties 112.29 ms/op 78.267 ms/op 1.43
mainnet_e81889 - altair processRegistryUpdates 14.873 us/op 2.7110 us/op 5.49
mainnet_e81889 - altair processSlashings 2.9970 us/op 631.00 ns/op 4.75
mainnet_e81889 - altair processEth1DataReset 3.5520 us/op 646.00 ns/op 5.50
mainnet_e81889 - altair processEffectiveBalanceUpdates 2.9300 ms/op 1.9164 ms/op 1.53
mainnet_e81889 - altair processSlashingsReset 26.621 us/op 4.5130 us/op 5.90
mainnet_e81889 - altair processRandaoMixesReset 25.294 us/op 4.9240 us/op 5.14
mainnet_e81889 - altair processHistoricalRootsUpdate 3.7450 us/op 773.00 ns/op 4.84
mainnet_e81889 - altair processParticipationFlagUpdates 14.932 us/op 5.5500 us/op 2.69
mainnet_e81889 - altair processSyncCommitteeUpdates 3.0850 us/op 1.9290 us/op 1.60
mainnet_e81889 - altair afterProcessEpoch 205.11 ms/op 222.36 ms/op 0.92
phase0 processEpoch - mainnet_e58758 623.71 ms/op 486.93 ms/op 1.28
mainnet_e58758 - phase0 beforeProcessEpoch 289.78 ms/op 176.51 ms/op 1.64
mainnet_e58758 - phase0 processJustificationAndFinalization 69.308 us/op 16.915 us/op 4.10
mainnet_e58758 - phase0 processRewardsAndPenalties 172.44 ms/op 96.362 ms/op 1.79
mainnet_e58758 - phase0 processRegistryUpdates 37.959 us/op 9.2670 us/op 4.10
mainnet_e58758 - phase0 processSlashings 2.8750 us/op 553.00 ns/op 5.20
mainnet_e58758 - phase0 processEth1DataReset 3.3730 us/op 668.00 ns/op 5.05
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 2.5378 ms/op 1.7848 ms/op 1.42
mainnet_e58758 - phase0 processSlashingsReset 17.868 us/op 4.5970 us/op 3.89
mainnet_e58758 - phase0 processRandaoMixesReset 26.778 us/op 4.3280 us/op 6.19
mainnet_e58758 - phase0 processHistoricalRootsUpdate 3.8420 us/op 699.00 ns/op 5.50
mainnet_e58758 - phase0 processParticipationRecordUpdates 23.696 us/op 3.5800 us/op 6.62
mainnet_e58758 - phase0 afterProcessEpoch 165.54 ms/op 164.98 ms/op 1.00
phase0 processEffectiveBalanceUpdates - 250000 normalcase 2.5685 ms/op 2.0189 ms/op 1.27
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 3.2000 ms/op 2.3746 ms/op 1.35
altair processInactivityUpdates - 250000 normalcase 60.037 ms/op 40.608 ms/op 1.48
altair processInactivityUpdates - 250000 worstcase 74.303 ms/op 33.542 ms/op 2.22
phase0 processRegistryUpdates - 250000 normalcase 29.238 us/op 7.6220 us/op 3.84
phase0 processRegistryUpdates - 250000 badcase_full_deposits 530.52 us/op 385.25 us/op 1.38
phase0 processRegistryUpdates - 250000 worstcase 0.5 256.14 ms/op 196.42 ms/op 1.30
altair processRewardsAndPenalties - 250000 normalcase 145.61 ms/op 102.05 ms/op 1.43
altair processRewardsAndPenalties - 250000 worstcase 99.190 ms/op 76.868 ms/op 1.29
phase0 getAttestationDeltas - 250000 normalcase 16.214 ms/op 12.448 ms/op 1.30
phase0 getAttestationDeltas - 250000 worstcase 16.023 ms/op 12.605 ms/op 1.27
phase0 processSlashings - 250000 worstcase 6.9842 ms/op 5.1795 ms/op 1.35
altair processSyncCommitteeUpdates - 250000 342.47 ms/op 298.28 ms/op 1.15
BeaconState.hashTreeRoot - No change 683.00 ns/op 560.00 ns/op 1.22
BeaconState.hashTreeRoot - 1 full validator 85.775 us/op 74.585 us/op 1.15
BeaconState.hashTreeRoot - 32 full validator 798.84 us/op 775.60 us/op 1.03
BeaconState.hashTreeRoot - 512 full validator 9.6576 ms/op 6.9185 ms/op 1.40
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 103.56 us/op 97.082 us/op 1.07
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 1.4781 ms/op 1.2761 ms/op 1.16
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 19.431 ms/op 16.911 ms/op 1.15
BeaconState.hashTreeRoot - 1 balances 76.083 us/op 69.762 us/op 1.09
BeaconState.hashTreeRoot - 32 balances 701.91 us/op 646.60 us/op 1.09
BeaconState.hashTreeRoot - 512 balances 7.0089 ms/op 6.4525 ms/op 1.09
BeaconState.hashTreeRoot - 250000 balances 106.45 ms/op 105.34 ms/op 1.01
aggregationBits - 2048 els - zipIndexesInBitList 44.076 us/op 30.436 us/op 1.45
regular array get 100000 times 57.607 us/op 60.555 us/op 0.95
wrappedArray get 100000 times 59.780 us/op 61.101 us/op 0.98
arrayWithProxy get 100000 times 35.161 ms/op 28.955 ms/op 1.21
ssz.Root.equals 761.00 ns/op 506.00 ns/op 1.50
byteArrayEquals 607.00 ns/op 510.00 ns/op 1.19
shuffle list - 16384 els 11.938 ms/op 12.768 ms/op 0.94
shuffle list - 250000 els 173.70 ms/op 169.36 ms/op 1.03
processSlot - 1 slots 17.381 us/op 12.932 us/op 1.34
processSlot - 32 slots 2.4844 ms/op 1.9667 ms/op 1.26
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 461.46 us/op 397.39 us/op 1.16
getCommitteeAssignments - req 1 vs - 250000 vc 5.2236 ms/op 5.4788 ms/op 0.95
getCommitteeAssignments - req 100 vs - 250000 vc 7.6727 ms/op 8.0613 ms/op 0.95
getCommitteeAssignments - req 1000 vs - 250000 vc 8.1893 ms/op 8.5744 ms/op 0.96
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 10.380 ns/op 9.1900 ns/op 1.13
state getBlockRootAtSlot - 250000 vs - 7PWei 1.4291 us/op 1.0412 us/op 1.37
computeProposers - vc 250000 21.023 ms/op 17.956 ms/op 1.17
computeEpochShuffling - vc 250000 172.45 ms/op 172.82 ms/op 1.00
getNextSyncCommittee - vc 250000 332.52 ms/op 294.34 ms/op 1.13

by benchmarkbot/action

@dapplion dapplion merged commit 13190d2 into unstable Nov 21, 2022
@dapplion dapplion deleted the cayman/update-reqresp-version branch November 21, 2022 21:51
Copy link

@01netmovement 01netmovement left a comment

Choose a reason for hiding this comment

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

Feeds changed

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.

3 participants