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: pass execution requests as bytes to engine API #7145

Merged
merged 2 commits into from
Oct 11, 2024

Conversation

ensi321
Copy link
Contributor

@ensi321 ensi321 commented Oct 10, 2024

According to the latest change to the spec, execution requests are passed as bytes to engine_newPayloadV4, and EL will also return execution requests in bytes from engine_getPayloadV4.

  • execution requests rpc type is defined as DATA[3], with deposit, withdrawal and consolidation requests rpc being the first, second and third element respectively
  • Deposit requests RPC is the ssz serialized bytes of DepositRequests. Withdrawal and consolidation requests are in a similar fashion

Relevant spec can be found in the following:

@ensi321 ensi321 changed the base branch from unstable to nc/devnet-4 October 10, 2024 05:27
Copy link

codecov bot commented Oct 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (nc/devnet-4@f2b96ff). Learn more about missing BASE report.

Additional details and impacted files
@@              Coverage Diff               @@
##             nc/devnet-4    #7145   +/-   ##
==============================================
  Coverage               ?   49.04%           
==============================================
  Files                  ?      596           
  Lines                  ?    39744           
  Branches               ?     2069           
==============================================
  Hits                   ?    19494           
  Misses                 ?    20209           
  Partials               ?       41           

Copy link
Contributor

Performance Report

✔️ no performance regression detected

🚀🚀 Significant benchmark improvement detected

Benchmark suite Current: f2a2279 Previous: 068fbae Ratio
isKnown worse case - 16 super set checks 261.00 ns/op 815.00 ns/op 0.32
Array push - length 1000000 18.654 ms/op 63.623 ms/op 0.29
Full benchmark results
Benchmark suite Current: f2a2279 Previous: 068fbae Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 1.8313 ms/op 2.1370 ms/op 0.86
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 50.748 us/op 49.291 us/op 1.03
BLS verify - blst 993.01 us/op 1.4424 ms/op 0.69
BLS verifyMultipleSignatures 3 - blst 1.2714 ms/op 1.2566 ms/op 1.01
BLS verifyMultipleSignatures 8 - blst 1.9166 ms/op 2.5203 ms/op 0.76
BLS verifyMultipleSignatures 32 - blst 5.6202 ms/op 6.9366 ms/op 0.81
BLS verifyMultipleSignatures 64 - blst 10.576 ms/op 11.122 ms/op 0.95
BLS verifyMultipleSignatures 128 - blst 17.571 ms/op 17.933 ms/op 0.98
BLS deserializing 10000 signatures 684.21 ms/op 697.34 ms/op 0.98
BLS deserializing 100000 signatures 6.7904 s/op 7.2298 s/op 0.94
BLS verifyMultipleSignatures - same message - 3 - blst 884.65 us/op 1.1015 ms/op 0.80
BLS verifyMultipleSignatures - same message - 8 - blst 1.1939 ms/op 1.1840 ms/op 1.01
BLS verifyMultipleSignatures - same message - 32 - blst 1.6520 ms/op 1.8230 ms/op 0.91
BLS verifyMultipleSignatures - same message - 64 - blst 2.5422 ms/op 2.8011 ms/op 0.91
BLS verifyMultipleSignatures - same message - 128 - blst 4.4523 ms/op 4.8989 ms/op 0.91
BLS aggregatePubkeys 32 - blst 19.239 us/op 22.005 us/op 0.87
BLS aggregatePubkeys 128 - blst 69.798 us/op 76.488 us/op 0.91
notSeenSlots=1 numMissedVotes=1 numBadVotes=10 79.313 ms/op 77.844 ms/op 1.02
notSeenSlots=1 numMissedVotes=0 numBadVotes=4 75.550 ms/op 58.941 ms/op 1.28
notSeenSlots=2 numMissedVotes=1 numBadVotes=10 42.333 ms/op 40.060 ms/op 1.06
getSlashingsAndExits - default max 99.958 us/op 143.51 us/op 0.70
getSlashingsAndExits - 2k 291.40 us/op 386.24 us/op 0.75
proposeBlockBody type=full, size=empty 5.7986 ms/op 7.7443 ms/op 0.75
isKnown best case - 1 super set check 293.00 ns/op 629.00 ns/op 0.47
isKnown normal case - 2 super set checks 265.00 ns/op 763.00 ns/op 0.35
isKnown worse case - 16 super set checks 261.00 ns/op 815.00 ns/op 0.32
InMemoryCheckpointStateCache - add get delete 2.5940 us/op 4.1970 us/op 0.62
updateUnfinalizedPubkeys - updating 10 pubkeys 1.0258 ms/op 1.5945 ms/op 0.64
updateUnfinalizedPubkeys - updating 100 pubkeys 3.5647 ms/op 5.4536 ms/op 0.65
updateUnfinalizedPubkeys - updating 1000 pubkeys 53.255 ms/op 65.419 ms/op 0.81
validate api signedAggregateAndProof - struct 1.9181 ms/op 1.9236 ms/op 1.00
validate gossip signedAggregateAndProof - struct 1.5783 ms/op 1.7809 ms/op 0.89
batch validate gossip attestation - vc 640000 - chunk 32 132.30 us/op 172.99 us/op 0.76
batch validate gossip attestation - vc 640000 - chunk 64 116.32 us/op 143.38 us/op 0.81
batch validate gossip attestation - vc 640000 - chunk 128 101.95 us/op 130.23 us/op 0.78
batch validate gossip attestation - vc 640000 - chunk 256 100.07 us/op 124.52 us/op 0.80
pickEth1Vote - no votes 1.0051 ms/op 1.2952 ms/op 0.78
pickEth1Vote - max votes 6.5204 ms/op 9.0634 ms/op 0.72
pickEth1Vote - Eth1Data hashTreeRoot value x2048 14.895 ms/op 17.786 ms/op 0.84
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 24.717 ms/op 27.007 ms/op 0.92
pickEth1Vote - Eth1Data fastSerialize value x2048 477.86 us/op 610.27 us/op 0.78
pickEth1Vote - Eth1Data fastSerialize tree x2048 2.9048 ms/op 4.3980 ms/op 0.66
bytes32 toHexString 421.00 ns/op 685.00 ns/op 0.61
bytes32 Buffer.toString(hex) 243.00 ns/op 302.00 ns/op 0.80
bytes32 Buffer.toString(hex) from Uint8Array 361.00 ns/op 523.00 ns/op 0.69
bytes32 Buffer.toString(hex) + 0x 260.00 ns/op 310.00 ns/op 0.84
Object access 1 prop 0.20800 ns/op 0.20800 ns/op 1.00
Map access 1 prop 0.12600 ns/op 0.15700 ns/op 0.80
Object get x1000 5.6460 ns/op 7.1070 ns/op 0.79
Map get x1000 6.1630 ns/op 7.6480 ns/op 0.81
Object set x1000 32.289 ns/op 48.064 ns/op 0.67
Map set x1000 20.986 ns/op 28.569 ns/op 0.73
Return object 10000 times 0.27520 ns/op 0.32130 ns/op 0.86
Throw Error 10000 times 3.2139 us/op 3.9245 us/op 0.82
toHex 137.37 ns/op 191.07 ns/op 0.72
Buffer.from 134.51 ns/op 171.29 ns/op 0.79
shared Buffer 84.584 ns/op 111.91 ns/op 0.76
fastMsgIdFn sha256 / 200 bytes 2.2150 us/op 2.5890 us/op 0.86
fastMsgIdFn h32 xxhash / 200 bytes 226.00 ns/op 311.00 ns/op 0.73
fastMsgIdFn h64 xxhash / 200 bytes 266.00 ns/op 303.00 ns/op 0.88
fastMsgIdFn sha256 / 1000 bytes 7.4170 us/op 8.3090 us/op 0.89
fastMsgIdFn h32 xxhash / 1000 bytes 349.00 ns/op 446.00 ns/op 0.78
fastMsgIdFn h64 xxhash / 1000 bytes 333.00 ns/op 387.00 ns/op 0.86
fastMsgIdFn sha256 / 10000 bytes 63.703 us/op 73.349 us/op 0.87
fastMsgIdFn h32 xxhash / 10000 bytes 1.8600 us/op 2.0520 us/op 0.91
fastMsgIdFn h64 xxhash / 10000 bytes 1.2150 us/op 1.3330 us/op 0.91
send data - 1000 256B messages 12.593 ms/op 15.425 ms/op 0.82
send data - 1000 512B messages 15.733 ms/op 20.121 ms/op 0.78
send data - 1000 1024B messages 24.218 ms/op 29.612 ms/op 0.82
send data - 1000 1200B messages 25.383 ms/op 27.503 ms/op 0.92
send data - 1000 2048B messages 32.571 ms/op 34.642 ms/op 0.94
send data - 1000 4096B messages 30.124 ms/op 32.127 ms/op 0.94
send data - 1000 16384B messages 67.309 ms/op 79.678 ms/op 0.84
send data - 1000 65536B messages 212.17 ms/op 236.58 ms/op 0.90
enrSubnets - fastDeserialize 64 bits 1.0280 us/op 1.3160 us/op 0.78
enrSubnets - ssz BitVector 64 bits 336.00 ns/op 452.00 ns/op 0.74
enrSubnets - fastDeserialize 4 bits 138.00 ns/op 186.00 ns/op 0.74
enrSubnets - ssz BitVector 4 bits 341.00 ns/op 464.00 ns/op 0.73
prioritizePeers score -10:0 att 32-0.1 sync 2-0 144.22 us/op 177.71 us/op 0.81
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 299.57 us/op 232.98 us/op 1.29
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 393.36 us/op 351.90 us/op 1.12
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 597.97 us/op 524.77 us/op 1.14
prioritizePeers score 0:0 att 64-1 sync 4-1 706.10 us/op 934.84 us/op 0.76
array of 16000 items push then shift 1.6564 us/op 1.7718 us/op 0.93
LinkedList of 16000 items push then shift 7.3180 ns/op 8.4690 ns/op 0.86
array of 16000 items push then pop 106.15 ns/op 143.39 ns/op 0.74
LinkedList of 16000 items push then pop 6.9490 ns/op 8.0260 ns/op 0.87
array of 24000 items push then shift 2.4176 us/op 2.6293 us/op 0.92
LinkedList of 24000 items push then shift 7.2020 ns/op 8.0790 ns/op 0.89
array of 24000 items push then pop 132.49 ns/op 186.62 ns/op 0.71
LinkedList of 24000 items push then pop 6.7920 ns/op 7.8020 ns/op 0.87
intersect bitArray bitLen 8 6.2820 ns/op 6.7130 ns/op 0.94
intersect array and set length 8 45.454 ns/op 56.580 ns/op 0.80
intersect bitArray bitLen 128 29.141 ns/op 31.262 ns/op 0.93
intersect array and set length 128 663.31 ns/op 891.02 ns/op 0.74
bitArray.getTrueBitIndexes() bitLen 128 2.2780 us/op 2.2070 us/op 1.03
bitArray.getTrueBitIndexes() bitLen 248 3.6450 us/op 4.2670 us/op 0.85
bitArray.getTrueBitIndexes() bitLen 512 9.7290 us/op 10.341 us/op 0.94
Buffer.concat 32 items 1.0070 us/op 1.0630 us/op 0.95
Uint8Array.set 32 items 2.2560 us/op 1.7670 us/op 1.28
Buffer.copy 2.3880 us/op 2.1580 us/op 1.11
Uint8Array.set - with subarray 3.2960 us/op 3.6500 us/op 0.90
Uint8Array.set - without subarray 1.8300 us/op 1.8400 us/op 0.99
getUint32 - dataview 228.00 ns/op 322.00 ns/op 0.71
getUint32 - manual 147.00 ns/op 279.00 ns/op 0.53
Set add up to 64 items then delete first 2.1701 us/op 3.0391 us/op 0.71
OrderedSet add up to 64 items then delete first 3.1832 us/op 4.6066 us/op 0.69
Set add up to 64 items then delete last 2.4566 us/op 3.2731 us/op 0.75
OrderedSet add up to 64 items then delete last 3.5351 us/op 5.2249 us/op 0.68
Set add up to 64 items then delete middle 2.4742 us/op 3.3645 us/op 0.74
OrderedSet add up to 64 items then delete middle 5.1265 us/op 7.0069 us/op 0.73
Set add up to 128 items then delete first 4.9553 us/op 7.2213 us/op 0.69
OrderedSet add up to 128 items then delete first 8.8021 us/op 12.323 us/op 0.71
Set add up to 128 items then delete last 5.3249 us/op 7.2096 us/op 0.74
OrderedSet add up to 128 items then delete last 7.4346 us/op 10.607 us/op 0.70
Set add up to 128 items then delete middle 5.2555 us/op 6.5897 us/op 0.80
OrderedSet add up to 128 items then delete middle 14.114 us/op 17.277 us/op 0.82
Set add up to 256 items then delete first 10.629 us/op 12.972 us/op 0.82
OrderedSet add up to 256 items then delete first 16.092 us/op 19.595 us/op 0.82
Set add up to 256 items then delete last 9.6662 us/op 11.484 us/op 0.84
OrderedSet add up to 256 items then delete last 14.497 us/op 17.774 us/op 0.82
Set add up to 256 items then delete middle 9.6293 us/op 12.202 us/op 0.79
OrderedSet add up to 256 items then delete middle 41.939 us/op 50.190 us/op 0.84
transfer serialized Status (84 B) 1.3590 us/op 1.4280 us/op 0.95
copy serialized Status (84 B) 1.0880 us/op 1.2920 us/op 0.84
transfer serialized SignedVoluntaryExit (112 B) 1.4940 us/op 1.5410 us/op 0.97
copy serialized SignedVoluntaryExit (112 B) 1.1980 us/op 1.3460 us/op 0.89
transfer serialized ProposerSlashing (416 B) 2.5440 us/op 1.7710 us/op 1.44
copy serialized ProposerSlashing (416 B) 2.8260 us/op 1.8660 us/op 1.51
transfer serialized Attestation (485 B) 2.8590 us/op 1.8200 us/op 1.57
copy serialized Attestation (485 B) 2.3260 us/op 1.8430 us/op 1.26
transfer serialized AttesterSlashing (33232 B) 2.3010 us/op 1.8310 us/op 1.26
copy serialized AttesterSlashing (33232 B) 4.7130 us/op 6.3230 us/op 0.75
transfer serialized Small SignedBeaconBlock (128000 B) 3.4820 us/op 2.5660 us/op 1.36
copy serialized Small SignedBeaconBlock (128000 B) 14.227 us/op 20.631 us/op 0.69
transfer serialized Avg SignedBeaconBlock (200000 B) 3.7020 us/op 2.9840 us/op 1.24
copy serialized Avg SignedBeaconBlock (200000 B) 19.624 us/op 33.559 us/op 0.58
transfer serialized BlobsSidecar (524380 B) 3.2570 us/op 3.3430 us/op 0.97
copy serialized BlobsSidecar (524380 B) 85.519 us/op 90.240 us/op 0.95
transfer serialized Big SignedBeaconBlock (1000000 B) 2.8020 us/op 3.3380 us/op 0.84
copy serialized Big SignedBeaconBlock (1000000 B) 133.31 us/op 174.70 us/op 0.76
pass gossip attestations to forkchoice per slot 2.8046 ms/op 3.0905 ms/op 0.91
forkChoice updateHead vc 100000 bc 64 eq 0 530.01 us/op 618.07 us/op 0.86
forkChoice updateHead vc 600000 bc 64 eq 0 3.1814 ms/op 3.8137 ms/op 0.83
forkChoice updateHead vc 1000000 bc 64 eq 0 5.2646 ms/op 5.8579 ms/op 0.90
forkChoice updateHead vc 600000 bc 320 eq 0 3.0176 ms/op 3.6566 ms/op 0.83
forkChoice updateHead vc 600000 bc 1200 eq 0 3.1276 ms/op 3.6498 ms/op 0.86
forkChoice updateHead vc 600000 bc 7200 eq 0 3.6975 ms/op 5.3050 ms/op 0.70
forkChoice updateHead vc 600000 bc 64 eq 1000 10.656 ms/op 12.482 ms/op 0.85
forkChoice updateHead vc 600000 bc 64 eq 10000 10.653 ms/op 12.271 ms/op 0.87
forkChoice updateHead vc 600000 bc 64 eq 300000 14.276 ms/op 23.995 ms/op 0.59
computeDeltas 500000 validators 300 proto nodes 3.5224 ms/op 4.2318 ms/op 0.83
computeDeltas 500000 validators 1200 proto nodes 3.4940 ms/op 4.4475 ms/op 0.79
computeDeltas 500000 validators 7200 proto nodes 3.4899 ms/op 4.6504 ms/op 0.75
computeDeltas 750000 validators 300 proto nodes 5.3081 ms/op 7.7081 ms/op 0.69
computeDeltas 750000 validators 1200 proto nodes 5.2750 ms/op 7.3604 ms/op 0.72
computeDeltas 750000 validators 7200 proto nodes 5.2577 ms/op 7.4995 ms/op 0.70
computeDeltas 1400000 validators 300 proto nodes 9.7032 ms/op 12.589 ms/op 0.77
computeDeltas 1400000 validators 1200 proto nodes 9.8883 ms/op 12.562 ms/op 0.79
computeDeltas 1400000 validators 7200 proto nodes 9.7191 ms/op 12.818 ms/op 0.76
computeDeltas 2100000 validators 300 proto nodes 14.947 ms/op 19.283 ms/op 0.78
computeDeltas 2100000 validators 1200 proto nodes 16.224 ms/op 18.749 ms/op 0.87
computeDeltas 2100000 validators 7200 proto nodes 15.288 ms/op 17.583 ms/op 0.87
altair processAttestation - 250000 vs - 7PWei normalcase 1.7582 ms/op 1.8844 ms/op 0.93
altair processAttestation - 250000 vs - 7PWei worstcase 2.6430 ms/op 3.0727 ms/op 0.86
altair processAttestation - setStatus - 1/6 committees join 94.078 us/op 101.70 us/op 0.93
altair processAttestation - setStatus - 1/3 committees join 180.96 us/op 235.00 us/op 0.77
altair processAttestation - setStatus - 1/2 committees join 266.12 us/op 352.44 us/op 0.76
altair processAttestation - setStatus - 2/3 committees join 337.30 us/op 450.49 us/op 0.75
altair processAttestation - setStatus - 4/5 committees join 482.89 us/op 656.32 us/op 0.74
altair processAttestation - setStatus - 100% committees join 586.56 us/op 854.94 us/op 0.69
altair processBlock - 250000 vs - 7PWei normalcase 5.1262 ms/op 6.6742 ms/op 0.77
altair processBlock - 250000 vs - 7PWei normalcase hashState 30.510 ms/op 35.947 ms/op 0.85
altair processBlock - 250000 vs - 7PWei worstcase 39.312 ms/op 47.348 ms/op 0.83
altair processBlock - 250000 vs - 7PWei worstcase hashState 92.057 ms/op 108.19 ms/op 0.85
phase0 processBlock - 250000 vs - 7PWei normalcase 2.3600 ms/op 3.4151 ms/op 0.69
phase0 processBlock - 250000 vs - 7PWei worstcase 24.290 ms/op 36.032 ms/op 0.67
altair processEth1Data - 250000 vs - 7PWei normalcase 299.08 us/op 678.75 us/op 0.44
getExpectedWithdrawals 250000 eb:1,eth1:1,we:0,wn:0,smpl:15 7.7850 us/op 10.451 us/op 0.74
getExpectedWithdrawals 250000 eb:0.95,eth1:0.1,we:0.05,wn:0,smpl:219 43.868 us/op 50.228 us/op 0.87
getExpectedWithdrawals 250000 eb:0.95,eth1:0.3,we:0.05,wn:0,smpl:42 11.729 us/op 17.566 us/op 0.67
getExpectedWithdrawals 250000 eb:0.95,eth1:0.7,we:0.05,wn:0,smpl:18 7.8530 us/op 11.774 us/op 0.67
getExpectedWithdrawals 250000 eb:0.1,eth1:0.1,we:0,wn:0,smpl:1020 156.61 us/op 183.43 us/op 0.85
getExpectedWithdrawals 250000 eb:0.03,eth1:0.03,we:0,wn:0,smpl:11777 1.7467 ms/op 1.7031 ms/op 1.03
getExpectedWithdrawals 250000 eb:0.01,eth1:0.01,we:0,wn:0,smpl:16384 1.7905 ms/op 2.6780 ms/op 0.67
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,smpl:16384 2.0231 ms/op 2.6434 ms/op 0.77
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,nocache,smpl:16384 3.8354 ms/op 8.4853 ms/op 0.45
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,smpl:16384 2.0733 ms/op 2.3037 ms/op 0.90
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,nocache,smpl:16384 3.9199 ms/op 6.1309 ms/op 0.64
Tree 40 250000 create 227.88 ms/op 544.34 ms/op 0.42
Tree 40 250000 get(125000) 146.35 ns/op 249.06 ns/op 0.59
Tree 40 250000 set(125000) 679.16 ns/op 1.4101 us/op 0.48
Tree 40 250000 toArray() 18.160 ms/op 26.994 ms/op 0.67
Tree 40 250000 iterate all - toArray() + loop 19.120 ms/op 26.904 ms/op 0.71
Tree 40 250000 iterate all - get(i) 54.061 ms/op 79.074 ms/op 0.68
Array 250000 create 4.0273 ms/op 4.7643 ms/op 0.85
Array 250000 clone - spread 1.5385 ms/op 4.1554 ms/op 0.37
Array 250000 get(125000) 0.43700 ns/op 0.55000 ns/op 0.79
Array 250000 set(125000) 0.46100 ns/op 0.62900 ns/op 0.73
Array 250000 iterate all - loop 101.16 us/op 167.14 us/op 0.61
phase0 afterProcessEpoch - 250000 vs - 7PWei 94.700 ms/op 133.02 ms/op 0.71
Array.fill - length 1000000 3.9008 ms/op 8.9296 ms/op 0.44
Array push - length 1000000 18.654 ms/op 63.623 ms/op 0.29
Array.get 0.28205 ns/op 0.39023 ns/op 0.72
Uint8Array.get 0.44798 ns/op 0.63510 ns/op 0.71
phase0 beforeProcessEpoch - 250000 vs - 7PWei 29.668 ms/op 34.205 ms/op 0.87
altair processEpoch - mainnet_e81889 422.60 ms/op 536.93 ms/op 0.79
mainnet_e81889 - altair beforeProcessEpoch 28.377 ms/op 38.521 ms/op 0.74
mainnet_e81889 - altair processJustificationAndFinalization 32.179 us/op 33.230 us/op 0.97
mainnet_e81889 - altair processInactivityUpdates 7.9032 ms/op 11.125 ms/op 0.71
mainnet_e81889 - altair processRewardsAndPenalties 49.145 ms/op 62.127 ms/op 0.79
mainnet_e81889 - altair processRegistryUpdates 2.5310 us/op 5.0650 us/op 0.50
mainnet_e81889 - altair processSlashings 904.00 ns/op 1.1460 us/op 0.79
mainnet_e81889 - altair processEth1DataReset 968.00 ns/op 931.00 ns/op 1.04
mainnet_e81889 - altair processEffectiveBalanceUpdates 1.7863 ms/op 3.0305 ms/op 0.59
mainnet_e81889 - altair processSlashingsReset 4.5580 us/op 8.6610 us/op 0.53
mainnet_e81889 - altair processRandaoMixesReset 10.555 us/op 11.607 us/op 0.91
mainnet_e81889 - altair processHistoricalRootsUpdate 1.2110 us/op 1.7460 us/op 0.69
mainnet_e81889 - altair processParticipationFlagUpdates 3.6750 us/op 7.5050 us/op 0.49
mainnet_e81889 - altair processSyncCommitteeUpdates 641.00 ns/op 1.5010 us/op 0.43
mainnet_e81889 - altair afterProcessEpoch 91.178 ms/op 155.45 ms/op 0.59
capella processEpoch - mainnet_e217614 1.1988 s/op 2.2566 s/op 0.53
mainnet_e217614 - capella beforeProcessEpoch 67.356 ms/op 103.24 ms/op 0.65
mainnet_e217614 - capella processJustificationAndFinalization 21.398 us/op 39.977 us/op 0.54
mainnet_e217614 - capella processInactivityUpdates 17.338 ms/op 28.251 ms/op 0.61
mainnet_e217614 - capella processRewardsAndPenalties 254.45 ms/op 319.79 ms/op 0.80
mainnet_e217614 - capella processRegistryUpdates 17.215 us/op 20.583 us/op 0.84
mainnet_e217614 - capella processSlashings 558.00 ns/op 1.5940 us/op 0.35
mainnet_e217614 - capella processEth1DataReset 503.00 ns/op 1.0800 us/op 0.47
mainnet_e217614 - capella processEffectiveBalanceUpdates 12.638 ms/op 20.929 ms/op 0.60
mainnet_e217614 - capella processSlashingsReset 5.5630 us/op 7.6460 us/op 0.73
mainnet_e217614 - capella processRandaoMixesReset 5.9650 us/op 14.611 us/op 0.41
mainnet_e217614 - capella processHistoricalRootsUpdate 459.00 ns/op 2.7440 us/op 0.17
mainnet_e217614 - capella processParticipationFlagUpdates 5.1340 us/op 7.8320 us/op 0.66
mainnet_e217614 - capella afterProcessEpoch 232.99 ms/op 356.34 ms/op 0.65
phase0 processEpoch - mainnet_e58758 394.83 ms/op 535.50 ms/op 0.74
mainnet_e58758 - phase0 beforeProcessEpoch 86.378 ms/op 121.37 ms/op 0.71
mainnet_e58758 - phase0 processJustificationAndFinalization 17.707 us/op 36.523 us/op 0.48
mainnet_e58758 - phase0 processRewardsAndPenalties 39.026 ms/op 42.942 ms/op 0.91
mainnet_e58758 - phase0 processRegistryUpdates 11.582 us/op 15.604 us/op 0.74
mainnet_e58758 - phase0 processSlashings 580.00 ns/op 925.00 ns/op 0.63
mainnet_e58758 - phase0 processEth1DataReset 640.00 ns/op 1.0690 us/op 0.60
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 3.0900 ms/op 2.0448 ms/op 1.51
mainnet_e58758 - phase0 processSlashingsReset 6.4460 us/op 13.080 us/op 0.49
mainnet_e58758 - phase0 processRandaoMixesReset 5.8450 us/op 17.792 us/op 0.33
mainnet_e58758 - phase0 processHistoricalRootsUpdate 497.00 ns/op 1.5560 us/op 0.32
mainnet_e58758 - phase0 processParticipationRecordUpdates 4.7820 us/op 8.0000 us/op 0.60
mainnet_e58758 - phase0 afterProcessEpoch 80.986 ms/op 122.09 ms/op 0.66
phase0 processEffectiveBalanceUpdates - 250000 normalcase 1.5279 ms/op 2.3308 ms/op 0.66
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 2.9372 ms/op 3.5034 ms/op 0.84
altair processInactivityUpdates - 250000 normalcase 21.248 ms/op 28.109 ms/op 0.76
altair processInactivityUpdates - 250000 worstcase 21.257 ms/op 26.714 ms/op 0.80
phase0 processRegistryUpdates - 250000 normalcase 11.412 us/op 18.825 us/op 0.61
phase0 processRegistryUpdates - 250000 badcase_full_deposits 337.56 us/op 431.15 us/op 0.78
phase0 processRegistryUpdates - 250000 worstcase 0.5 125.53 ms/op 186.56 ms/op 0.67
altair processRewardsAndPenalties - 250000 normalcase 48.931 ms/op 56.661 ms/op 0.86
altair processRewardsAndPenalties - 250000 worstcase 52.901 ms/op 57.215 ms/op 0.92
phase0 getAttestationDeltas - 250000 normalcase 7.8362 ms/op 12.956 ms/op 0.60
phase0 getAttestationDeltas - 250000 worstcase 7.4606 ms/op 9.6158 ms/op 0.78
phase0 processSlashings - 250000 worstcase 119.25 us/op 127.36 us/op 0.94
altair processSyncCommitteeUpdates - 250000 123.53 ms/op 185.89 ms/op 0.66
BeaconState.hashTreeRoot - No change 240.00 ns/op 423.00 ns/op 0.57
BeaconState.hashTreeRoot - 1 full validator 86.394 us/op 140.12 us/op 0.62
BeaconState.hashTreeRoot - 32 full validator 1.4358 ms/op 1.5895 ms/op 0.90
BeaconState.hashTreeRoot - 512 full validator 15.427 ms/op 18.574 ms/op 0.83
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 182.16 us/op 287.75 us/op 0.63
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 2.3855 ms/op 3.1773 ms/op 0.75
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 27.780 ms/op 37.254 ms/op 0.75
BeaconState.hashTreeRoot - 1 balances 99.827 us/op 155.09 us/op 0.64
BeaconState.hashTreeRoot - 32 balances 1.0827 ms/op 1.5585 ms/op 0.69
BeaconState.hashTreeRoot - 512 balances 8.7108 ms/op 13.291 ms/op 0.66
BeaconState.hashTreeRoot - 250000 balances 176.53 ms/op 331.16 ms/op 0.53
aggregationBits - 2048 els - zipIndexesInBitList 31.064 us/op 47.475 us/op 0.65
byteArrayEquals 32 54.113 ns/op 75.946 ns/op 0.71
Buffer.compare 32 17.237 ns/op 24.263 ns/op 0.71
byteArrayEquals 1024 1.5961 us/op 2.4135 us/op 0.66
Buffer.compare 1024 24.695 ns/op 31.331 ns/op 0.79
byteArrayEquals 16384 25.363 us/op 35.043 us/op 0.72
Buffer.compare 16384 198.91 ns/op 262.56 ns/op 0.76
byteArrayEquals 123687377 202.65 ms/op 260.59 ms/op 0.78
Buffer.compare 123687377 14.856 ms/op 14.292 ms/op 1.04
byteArrayEquals 32 - diff last byte 64.063 ns/op 78.835 ns/op 0.81
Buffer.compare 32 - diff last byte 19.425 ns/op 29.238 ns/op 0.66
byteArrayEquals 1024 - diff last byte 1.8020 us/op 2.3001 us/op 0.78
Buffer.compare 1024 - diff last byte 30.274 ns/op 42.527 ns/op 0.71
byteArrayEquals 16384 - diff last byte 28.369 us/op 33.951 us/op 0.84
Buffer.compare 16384 - diff last byte 269.25 ns/op 332.30 ns/op 0.81
byteArrayEquals 123687377 - diff last byte 219.09 ms/op 261.19 ms/op 0.84
Buffer.compare 123687377 - diff last byte 10.733 ms/op 10.329 ms/op 1.04
byteArrayEquals 32 - random bytes 6.4480 ns/op 7.6630 ns/op 0.84
Buffer.compare 32 - random bytes 27.274 ns/op 22.203 ns/op 1.23
byteArrayEquals 1024 - random bytes 6.2750 ns/op 6.1140 ns/op 1.03
Buffer.compare 1024 - random bytes 19.656 ns/op 21.113 ns/op 0.93
byteArrayEquals 16384 - random bytes 6.0530 ns/op 7.0970 ns/op 0.85
Buffer.compare 16384 - random bytes 19.685 ns/op 21.497 ns/op 0.92
byteArrayEquals 123687377 - random bytes 7.8000 ns/op 8.4000 ns/op 0.93
Buffer.compare 123687377 - random bytes 22.120 ns/op 24.180 ns/op 0.91
regular array get 100000 times 38.349 us/op 59.113 us/op 0.65
wrappedArray get 100000 times 50.858 us/op 44.780 us/op 1.14
arrayWithProxy get 100000 times 16.604 ms/op 15.978 ms/op 1.04
ssz.Root.equals 51.653 ns/op 54.089 ns/op 0.95
byteArrayEquals 51.208 ns/op 54.947 ns/op 0.93
Buffer.compare 12.202 ns/op 12.978 ns/op 0.94
shuffle list - 16384 els 7.3697 ms/op 8.0369 ms/op 0.92
shuffle list - 250000 els 123.15 ms/op 121.33 ms/op 1.02
processSlot - 1 slots 16.310 us/op 17.062 us/op 0.96
processSlot - 32 slots 4.8460 ms/op 3.5118 ms/op 1.38
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 43.369 ms/op 43.407 ms/op 1.00
getCommitteeAssignments - req 1 vs - 250000 vc 2.2035 ms/op 2.6905 ms/op 0.82
getCommitteeAssignments - req 100 vs - 250000 vc 4.2803 ms/op 5.3951 ms/op 0.79
getCommitteeAssignments - req 1000 vs - 250000 vc 5.5541 ms/op 5.6410 ms/op 0.98
findModifiedValidators - 10000 modified validators 346.60 ms/op 417.68 ms/op 0.83
findModifiedValidators - 1000 modified validators 165.03 ms/op 277.09 ms/op 0.60
findModifiedValidators - 100 modified validators 151.82 ms/op 306.05 ms/op 0.50
findModifiedValidators - 10 modified validators 143.51 ms/op 243.98 ms/op 0.59
findModifiedValidators - 1 modified validators 142.54 ms/op 249.30 ms/op 0.57
findModifiedValidators - no difference 156.86 ms/op 232.73 ms/op 0.67
compare ViewDUs 3.2054 s/op 4.2862 s/op 0.75
compare each validator Uint8Array 1.5842 s/op 1.6307 s/op 0.97
compare ViewDU to Uint8Array 992.10 ms/op 1.6861 s/op 0.59
migrate state 1000000 validators, 24 modified, 0 new 904.58 ms/op 1.2479 s/op 0.72
migrate state 1000000 validators, 1700 modified, 1000 new 1.1757 s/op 1.7961 s/op 0.65
migrate state 1000000 validators, 3400 modified, 2000 new 1.3450 s/op 1.7993 s/op 0.75
migrate state 1500000 validators, 24 modified, 0 new 940.66 ms/op 1.1705 s/op 0.80
migrate state 1500000 validators, 1700 modified, 1000 new 1.1526 s/op 1.4496 s/op 0.80
migrate state 1500000 validators, 3400 modified, 2000 new 1.3613 s/op 1.6513 s/op 0.82
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 4.1400 ns/op 5.9200 ns/op 0.70
state getBlockRootAtSlot - 250000 vs - 7PWei 898.52 ns/op 676.79 ns/op 1.33
computeProposers - vc 250000 7.2027 ms/op 9.1278 ms/op 0.79
computeEpochShuffling - vc 250000 88.534 ms/op 117.77 ms/op 0.75
getNextSyncCommittee - vc 250000 124.43 ms/op 153.29 ms/op 0.81
computeSigningRoot for AttestationData 28.326 us/op 25.422 us/op 1.11
hash AttestationData serialized data then Buffer.toString(base64) 1.5847 us/op 1.9145 us/op 0.83
toHexString serialized data 841.53 ns/op 1.1226 us/op 0.75
Buffer.toString(base64) 162.31 ns/op 236.84 ns/op 0.69
nodejs block root to RootHex using toHex 146.23 ns/op 206.29 ns/op 0.71
nodejs block root to RootHex using toRootHex 93.715 ns/op 115.95 ns/op 0.81
browser block root to RootHex using the deprecated toHexString 216.49 ns/op 306.16 ns/op 0.71
browser block root to RootHex using toHex 171.81 ns/op 238.16 ns/op 0.72
browser block root to RootHex using toRootHex 153.68 ns/op 189.35 ns/op 0.81

by benchmarkbot/action

@ensi321 ensi321 marked this pull request as ready for review October 10, 2024 22:57
@ensi321 ensi321 requested a review from a team as a code owner October 10, 2024 22:58
@ensi321 ensi321 merged commit 1331994 into nc/devnet-4 Oct 11, 2024
16 of 17 checks passed
@ensi321 ensi321 deleted the nc/payload-engine-api branch October 11, 2024 03:16
@ensi321 ensi321 mentioned this pull request Oct 17, 2024
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