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

Track queue concurrency metric #5177

Merged
merged 1 commit into from
Feb 23, 2023
Merged

Conversation

dapplion
Copy link
Contributor

Motivation

Description

  • Track queue concurrency metric

Blocked

@github-actions
Copy link
Contributor

github-actions bot commented Feb 20, 2023

Performance Report

✔️ no performance regression detected

Full benchmark results
Benchmark suite Current: 537d5b5 Previous: 3916c4c Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 815.73 us/op 770.53 us/op 1.06
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 46.354 us/op 45.239 us/op 1.02
BLS verify - blst-native 1.2172 ms/op 1.2212 ms/op 1.00
BLS verifyMultipleSignatures 3 - blst-native 2.4829 ms/op 2.4575 ms/op 1.01
BLS verifyMultipleSignatures 8 - blst-native 5.3510 ms/op 5.3084 ms/op 1.01
BLS verifyMultipleSignatures 32 - blst-native 19.142 ms/op 19.073 ms/op 1.00
BLS aggregatePubkeys 32 - blst-native 25.532 us/op 25.728 us/op 0.99
BLS aggregatePubkeys 128 - blst-native 100.03 us/op 100.20 us/op 1.00
getAttestationsForBlock 60.409 ms/op 53.656 ms/op 1.13
isKnown best case - 1 super set check 286.00 ns/op 262.00 ns/op 1.09
isKnown normal case - 2 super set checks 276.00 ns/op 261.00 ns/op 1.06
isKnown worse case - 16 super set checks 275.00 ns/op 258.00 ns/op 1.07
CheckpointStateCache - add get delete 5.7810 us/op 5.2660 us/op 1.10
validate gossip signedAggregateAndProof - struct 2.8277 ms/op 2.7829 ms/op 1.02
validate gossip attestation - struct 1.3284 ms/op 1.3145 ms/op 1.01
pickEth1Vote - no votes 1.3437 ms/op 1.2676 ms/op 1.06
pickEth1Vote - max votes 9.1640 ms/op 9.3202 ms/op 0.98
pickEth1Vote - Eth1Data hashTreeRoot value x2048 8.7700 ms/op 8.2541 ms/op 1.06
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 14.126 ms/op 13.460 ms/op 1.05
pickEth1Vote - Eth1Data fastSerialize value x2048 659.59 us/op 628.51 us/op 1.05
pickEth1Vote - Eth1Data fastSerialize tree x2048 4.6828 ms/op 6.6709 ms/op 0.70
bytes32 toHexString 501.00 ns/op 491.00 ns/op 1.02
bytes32 Buffer.toString(hex) 367.00 ns/op 338.00 ns/op 1.09
bytes32 Buffer.toString(hex) from Uint8Array 578.00 ns/op 539.00 ns/op 1.07
bytes32 Buffer.toString(hex) + 0x 365.00 ns/op 338.00 ns/op 1.08
Object access 1 prop 0.16900 ns/op 0.16900 ns/op 1.00
Map access 1 prop 0.16400 ns/op 0.16100 ns/op 1.02
Object get x1000 6.6300 ns/op 6.5420 ns/op 1.01
Map get x1000 0.63400 ns/op 0.57100 ns/op 1.11
Object set x1000 54.305 ns/op 52.655 ns/op 1.03
Map set x1000 45.559 ns/op 43.873 ns/op 1.04
Return object 10000 times 0.23860 ns/op 0.23740 ns/op 1.01
Throw Error 10000 times 4.2093 us/op 4.1573 us/op 1.01
fastMsgIdFn sha256 / 200 bytes 3.5400 us/op 3.6010 us/op 0.98
fastMsgIdFn h32 xxhash / 200 bytes 292.00 ns/op 314.00 ns/op 0.93
fastMsgIdFn h64 xxhash / 200 bytes 391.00 ns/op 451.00 ns/op 0.87
fastMsgIdFn sha256 / 1000 bytes 11.689 us/op 11.966 us/op 0.98
fastMsgIdFn h32 xxhash / 1000 bytes 423.00 ns/op 434.00 ns/op 0.97
fastMsgIdFn h64 xxhash / 1000 bytes 477.00 ns/op 504.00 ns/op 0.95
fastMsgIdFn sha256 / 10000 bytes 104.47 us/op 104.72 us/op 1.00
fastMsgIdFn h32 xxhash / 10000 bytes 1.9620 us/op 1.9760 us/op 0.99
fastMsgIdFn h64 xxhash / 10000 bytes 1.3970 us/op 1.4310 us/op 0.98
enrSubnets - fastDeserialize 64 bits 1.2930 us/op 1.4510 us/op 0.89
enrSubnets - ssz BitVector 64 bits 479.00 ns/op 543.00 ns/op 0.88
enrSubnets - fastDeserialize 4 bits 170.00 ns/op 182.00 ns/op 0.93
enrSubnets - ssz BitVector 4 bits 483.00 ns/op 502.00 ns/op 0.96
prioritizePeers score -10:0 att 32-0.1 sync 2-0 98.692 us/op 93.033 us/op 1.06
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 132.83 us/op 126.34 us/op 1.05
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 173.14 us/op 178.22 us/op 0.97
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 307.51 us/op 343.28 us/op 0.90
prioritizePeers score 0:0 att 64-1 sync 4-1 396.32 us/op 382.95 us/op 1.03
array of 16000 items push then shift 1.6392 us/op 1.6672 us/op 0.98
LinkedList of 16000 items push then shift 8.8730 ns/op 8.9650 ns/op 0.99
array of 16000 items push then pop 95.369 ns/op 104.83 ns/op 0.91
LinkedList of 16000 items push then pop 9.1700 ns/op 8.6100 ns/op 1.07
array of 24000 items push then shift 2.3886 us/op 2.3499 us/op 1.02
LinkedList of 24000 items push then shift 9.0030 ns/op 8.7570 ns/op 1.03
array of 24000 items push then pop 87.380 ns/op 78.965 ns/op 1.11
LinkedList of 24000 items push then pop 8.7590 ns/op 8.4680 ns/op 1.03
intersect bitArray bitLen 8 13.347 ns/op 13.333 ns/op 1.00
intersect array and set length 8 76.923 ns/op 81.643 ns/op 0.94
intersect bitArray bitLen 128 44.311 ns/op 44.428 ns/op 1.00
intersect array and set length 128 1.0530 us/op 1.0906 us/op 0.97
Buffer.concat 32 items 2.7290 us/op 2.6730 us/op 1.02
Uint8Array.set 32 items 2.7940 us/op 2.1220 us/op 1.32
pass gossip attestations to forkchoice per slot 2.4137 ms/op 2.3155 ms/op 1.04
computeDeltas 3.0110 ms/op 3.3408 ms/op 0.90
computeProposerBoostScoreFromBalances 1.8095 ms/op 1.7823 ms/op 1.02
altair processAttestation - 250000 vs - 7PWei normalcase 2.4972 ms/op 2.2015 ms/op 1.13
altair processAttestation - 250000 vs - 7PWei worstcase 3.3682 ms/op 3.3344 ms/op 1.01
altair processAttestation - setStatus - 1/6 committees join 143.16 us/op 137.91 us/op 1.04
altair processAttestation - setStatus - 1/3 committees join 289.14 us/op 274.02 us/op 1.06
altair processAttestation - setStatus - 1/2 committees join 372.08 us/op 366.19 us/op 1.02
altair processAttestation - setStatus - 2/3 committees join 479.43 us/op 462.54 us/op 1.04
altair processAttestation - setStatus - 4/5 committees join 650.99 us/op 642.97 us/op 1.01
altair processAttestation - setStatus - 100% committees join 763.10 us/op 763.98 us/op 1.00
altair processBlock - 250000 vs - 7PWei normalcase 19.348 ms/op 16.333 ms/op 1.18
altair processBlock - 250000 vs - 7PWei normalcase hashState 24.755 ms/op 26.559 ms/op 0.93
altair processBlock - 250000 vs - 7PWei worstcase 50.462 ms/op 54.886 ms/op 0.92
altair processBlock - 250000 vs - 7PWei worstcase hashState 68.633 ms/op 67.117 ms/op 1.02
phase0 processBlock - 250000 vs - 7PWei normalcase 2.2709 ms/op 1.9903 ms/op 1.14
phase0 processBlock - 250000 vs - 7PWei worstcase 30.026 ms/op 29.525 ms/op 1.02
altair processEth1Data - 250000 vs - 7PWei normalcase 494.87 us/op 494.48 us/op 1.00
vc - 250000 eb 1 eth1 1 we 0 wn 0 - smpl 15 8.2530 us/op 8.1500 us/op 1.01
vc - 250000 eb 0.95 eth1 0.1 we 0.05 wn 0 - smpl 219 24.748 us/op 25.112 us/op 0.99
vc - 250000 eb 0.95 eth1 0.3 we 0.05 wn 0 - smpl 42 11.283 us/op 9.1770 us/op 1.23
vc - 250000 eb 0.95 eth1 0.7 we 0.05 wn 0 - smpl 18 8.3210 us/op 8.3980 us/op 0.99
vc - 250000 eb 0.1 eth1 0.1 we 0 wn 0 - smpl 1020 102.12 us/op 92.949 us/op 1.10
vc - 250000 eb 0.03 eth1 0.03 we 0 wn 0 - smpl 11777 651.99 us/op 649.45 us/op 1.00
vc - 250000 eb 0.01 eth1 0.01 we 0 wn 0 - smpl 16384 909.97 us/op 894.21 us/op 1.02
vc - 250000 eb 0 eth1 0 we 0 wn 0 - smpl 16384 907.35 us/op 899.75 us/op 1.01
vc - 250000 eb 0 eth1 0 we 0 wn 0 nocache - smpl 16384 2.4298 ms/op 2.3274 ms/op 1.04
vc - 250000 eb 0 eth1 1 we 0 wn 0 - smpl 16384 1.4610 ms/op 1.4705 ms/op 0.99
vc - 250000 eb 0 eth1 1 we 0 wn 0 nocache - smpl 16384 3.8673 ms/op 3.8650 ms/op 1.00
Tree 40 250000 create 310.29 ms/op 302.33 ms/op 1.03
Tree 40 250000 get(125000) 191.95 ns/op 181.21 ns/op 1.06
Tree 40 250000 set(125000) 917.61 ns/op 990.08 ns/op 0.93
Tree 40 250000 toArray() 16.859 ms/op 18.531 ms/op 0.91
Tree 40 250000 iterate all - toArray() + loop 16.467 ms/op 17.754 ms/op 0.93
Tree 40 250000 iterate all - get(i) 66.155 ms/op 69.452 ms/op 0.95
MutableVector 250000 create 10.551 ms/op 9.6368 ms/op 1.09
MutableVector 250000 get(125000) 6.3290 ns/op 6.3130 ns/op 1.00
MutableVector 250000 set(125000) 260.32 ns/op 253.77 ns/op 1.03
MutableVector 250000 toArray() 3.3713 ms/op 2.7657 ms/op 1.22
MutableVector 250000 iterate all - toArray() + loop 3.1356 ms/op 3.0012 ms/op 1.04
MutableVector 250000 iterate all - get(i) 1.5096 ms/op 1.5386 ms/op 0.98
Array 250000 create 2.6427 ms/op 2.7320 ms/op 0.97
Array 250000 clone - spread 1.1202 ms/op 1.1517 ms/op 0.97
Array 250000 get(125000) 0.52900 ns/op 0.57400 ns/op 0.92
Array 250000 set(125000) 0.61000 ns/op 0.63700 ns/op 0.96
Array 250000 iterate all - loop 107.89 us/op 83.565 us/op 1.29
effectiveBalanceIncrements clone Uint8Array 300000 24.510 us/op 29.610 us/op 0.83
effectiveBalanceIncrements clone MutableVector 300000 325.00 ns/op 356.00 ns/op 0.91
effectiveBalanceIncrements rw all Uint8Array 300000 165.68 us/op 166.91 us/op 0.99
effectiveBalanceIncrements rw all MutableVector 300000 77.928 ms/op 82.489 ms/op 0.94
phase0 afterProcessEpoch - 250000 vs - 7PWei 112.38 ms/op 115.63 ms/op 0.97
phase0 beforeProcessEpoch - 250000 vs - 7PWei 41.001 ms/op 38.193 ms/op 1.07
altair processEpoch - mainnet_e81889 298.01 ms/op 325.08 ms/op 0.92
mainnet_e81889 - altair beforeProcessEpoch 63.901 ms/op 49.243 ms/op 1.30
mainnet_e81889 - altair processJustificationAndFinalization 16.241 us/op 15.860 us/op 1.02
mainnet_e81889 - altair processInactivityUpdates 5.0762 ms/op 5.5709 ms/op 0.91
mainnet_e81889 - altair processRewardsAndPenalties 51.630 ms/op 64.985 ms/op 0.79
mainnet_e81889 - altair processRegistryUpdates 2.6200 us/op 2.8470 us/op 0.92
mainnet_e81889 - altair processSlashings 554.00 ns/op 420.00 ns/op 1.32
mainnet_e81889 - altair processEth1DataReset 553.00 ns/op 471.00 ns/op 1.17
mainnet_e81889 - altair processEffectiveBalanceUpdates 1.2470 ms/op 1.2526 ms/op 1.00
mainnet_e81889 - altair processSlashingsReset 4.3860 us/op 4.7790 us/op 0.92
mainnet_e81889 - altair processRandaoMixesReset 8.9100 us/op 5.4730 us/op 1.63
mainnet_e81889 - altair processHistoricalRootsUpdate 714.00 ns/op 1.1180 us/op 0.64
mainnet_e81889 - altair processParticipationFlagUpdates 2.9070 us/op 3.0420 us/op 0.96
mainnet_e81889 - altair processSyncCommitteeUpdates 600.00 ns/op 601.00 ns/op 1.00
mainnet_e81889 - altair afterProcessEpoch 123.72 ms/op 129.56 ms/op 0.95
phase0 processEpoch - mainnet_e58758 345.81 ms/op 358.57 ms/op 0.96
mainnet_e58758 - phase0 beforeProcessEpoch 139.84 ms/op 134.55 ms/op 1.04
mainnet_e58758 - phase0 processJustificationAndFinalization 17.875 us/op 16.782 us/op 1.07
mainnet_e58758 - phase0 processRewardsAndPenalties 64.191 ms/op 64.998 ms/op 0.99
mainnet_e58758 - phase0 processRegistryUpdates 7.7380 us/op 7.4740 us/op 1.04
mainnet_e58758 - phase0 processSlashings 491.00 ns/op 457.00 ns/op 1.07
mainnet_e58758 - phase0 processEth1DataReset 537.00 ns/op 479.00 ns/op 1.12
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 988.60 us/op 956.67 us/op 1.03
mainnet_e58758 - phase0 processSlashingsReset 4.0370 us/op 4.2610 us/op 0.95
mainnet_e58758 - phase0 processRandaoMixesReset 4.5040 us/op 4.5010 us/op 1.00
mainnet_e58758 - phase0 processHistoricalRootsUpdate 551.00 ns/op 553.00 ns/op 1.00
mainnet_e58758 - phase0 processParticipationRecordUpdates 3.8700 us/op 4.0820 us/op 0.95
mainnet_e58758 - phase0 afterProcessEpoch 97.227 ms/op 95.528 ms/op 1.02
phase0 processEffectiveBalanceUpdates - 250000 normalcase 1.2292 ms/op 1.1827 ms/op 1.04
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 1.5193 ms/op 1.4598 ms/op 1.04
altair processInactivityUpdates - 250000 normalcase 26.436 ms/op 25.220 ms/op 1.05
altair processInactivityUpdates - 250000 worstcase 26.911 ms/op 26.369 ms/op 1.02
phase0 processRegistryUpdates - 250000 normalcase 6.3910 us/op 6.7710 us/op 0.94
phase0 processRegistryUpdates - 250000 badcase_full_deposits 268.59 us/op 313.05 us/op 0.86
phase0 processRegistryUpdates - 250000 worstcase 0.5 129.10 ms/op 129.72 ms/op 1.00
altair processRewardsAndPenalties - 250000 normalcase 68.146 ms/op 68.088 ms/op 1.00
altair processRewardsAndPenalties - 250000 worstcase 70.360 ms/op 69.882 ms/op 1.01
phase0 getAttestationDeltas - 250000 normalcase 6.4786 ms/op 6.6077 ms/op 0.98
phase0 getAttestationDeltas - 250000 worstcase 6.4094 ms/op 6.6127 ms/op 0.97
phase0 processSlashings - 250000 worstcase 3.4588 ms/op 3.5916 ms/op 0.96
altair processSyncCommitteeUpdates - 250000 171.14 ms/op 170.19 ms/op 1.01
BeaconState.hashTreeRoot - No change 324.00 ns/op 260.00 ns/op 1.25
BeaconState.hashTreeRoot - 1 full validator 48.689 us/op 53.471 us/op 0.91
BeaconState.hashTreeRoot - 32 full validator 511.39 us/op 535.25 us/op 0.96
BeaconState.hashTreeRoot - 512 full validator 5.6059 ms/op 5.3382 ms/op 1.05
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 60.247 us/op 61.061 us/op 0.99
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 861.88 us/op 874.04 us/op 0.99
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 11.052 ms/op 11.850 ms/op 0.93
BeaconState.hashTreeRoot - 1 balances 46.428 us/op 47.730 us/op 0.97
BeaconState.hashTreeRoot - 32 balances 439.73 us/op 462.64 us/op 0.95
BeaconState.hashTreeRoot - 512 balances 4.0878 ms/op 4.3385 ms/op 0.94
BeaconState.hashTreeRoot - 250000 balances 72.046 ms/op 75.271 ms/op 0.96
aggregationBits - 2048 els - zipIndexesInBitList 15.232 us/op 15.349 us/op 0.99
regular array get 100000 times 32.629 us/op 32.828 us/op 0.99
wrappedArray get 100000 times 32.611 us/op 32.809 us/op 0.99
arrayWithProxy get 100000 times 14.890 ms/op 15.539 ms/op 0.96
ssz.Root.equals 538.00 ns/op 541.00 ns/op 0.99
byteArrayEquals 530.00 ns/op 529.00 ns/op 1.00
shuffle list - 16384 els 6.7933 ms/op 6.7444 ms/op 1.01
shuffle list - 250000 els 99.348 ms/op 98.084 ms/op 1.01
processSlot - 1 slots 9.2290 us/op 8.2690 us/op 1.12
processSlot - 32 slots 1.3251 ms/op 1.2980 ms/op 1.02
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 186.56 us/op 187.16 us/op 1.00
getCommitteeAssignments - req 1 vs - 250000 vc 2.9005 ms/op 2.8440 ms/op 1.02
getCommitteeAssignments - req 100 vs - 250000 vc 4.0723 ms/op 4.1850 ms/op 0.97
getCommitteeAssignments - req 1000 vs - 250000 vc 4.3912 ms/op 4.5158 ms/op 0.97
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 4.6300 ns/op 4.7200 ns/op 0.98
state getBlockRootAtSlot - 250000 vs - 7PWei 877.36 ns/op 819.66 ns/op 1.07
computeProposers - vc 250000 10.301 ms/op 10.819 ms/op 0.95
computeEpochShuffling - vc 250000 99.360 ms/op 103.43 ms/op 0.96
getNextSyncCommittee - vc 250000 170.71 ms/op 184.99 ms/op 0.92

by benchmarkbot/action

@dapplion dapplion force-pushed the dapplion/concurrency-metric branch from e8c9fd5 to 080c8f9 Compare February 23, 2023 07:55
@dapplion dapplion marked this pull request as ready for review February 23, 2023 07:55
@dapplion dapplion requested a review from a team as a code owner February 23, 2023 07:55
@wemeetagain wemeetagain merged commit bfe9a32 into unstable Feb 23, 2023
@wemeetagain wemeetagain deleted the dapplion/concurrency-metric branch February 23, 2023 19:18
@wemeetagain
Copy link
Member

🎉 This PR is included in v1.6.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