这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@nflaig
Copy link
Member

@nflaig nflaig commented Sep 26, 2025

No description provided.

@nflaig nflaig requested a review from a team as a code owner September 26, 2025 10:26
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @nflaig, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request enhances the fork configuration mechanism by integrating specific timing parameters for the upcoming Gloas fork. It ensures that critical slot-related operations, such as attestation and aggregation due times, dynamically adjust based on the network's current fork status, thereby maintaining optimal performance and adherence to protocol rules across different network upgrades.

Highlights

  • Gloas Fork Timing Integration: Introduced conditional logic to various slot time functions to apply Gloas-specific timing parameters after the Gloas fork.
  • New Import: Added the isForkPostGloas utility function from @lodestar/params to detect if the network is operating post-Gloas fork.
  • Dynamic Due Times: Updated getAttestationDueMs, getAggregateDueMs, getSyncMessageDueMs, and getSyncContributionDueMs to use _GLOAS suffixed configuration values when the Gloas fork is active, allowing for adaptive timing.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces Gloas-specific timing parameters for various slot-related functions. The changes correctly apply the new Gloas timings based on the fork. However, the implementation introduces repetitive logic across multiple functions. I've provided a suggestion to refactor this duplicated code, which will improve the maintainability and readability of the code.

@codecov
Copy link

codecov bot commented Sep 26, 2025

Codecov Report

❌ Patch coverage is 25.00000% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 52.24%. Comparing base (39be8f0) to head (57ba769).
⚠️ Report is 3 commits behind head on unstable.

Additional details and impacted files
@@             Coverage Diff              @@
##           unstable    #8474      +/-   ##
============================================
- Coverage     52.25%   52.24%   -0.01%     
============================================
  Files           852      852              
  Lines         64976    64988      +12     
  Branches       4768     4769       +1     
============================================
  Hits          33954    33954              
- Misses        30953    30965      +12     
  Partials         69       69              
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions
Copy link
Contributor

Performance Report

✔️ no performance regression detected

Full benchmark results
Benchmark suite Current: 05c63e9 Previous: 39be8f0 Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 918.33 us/op 742.48 us/op 1.24
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 35.064 us/op 30.211 us/op 1.16
BLS verify - blst 811.97 us/op 874.34 us/op 0.93
BLS verifyMultipleSignatures 3 - blst 1.1497 ms/op 1.2771 ms/op 0.90
BLS verifyMultipleSignatures 8 - blst 1.6239 ms/op 2.0660 ms/op 0.79
BLS verifyMultipleSignatures 32 - blst 4.8266 ms/op 4.4281 ms/op 1.09
BLS verifyMultipleSignatures 64 - blst 8.9423 ms/op 8.1187 ms/op 1.10
BLS verifyMultipleSignatures 128 - blst 17.022 ms/op 15.954 ms/op 1.07
BLS deserializing 10000 signatures 685.91 ms/op 617.41 ms/op 1.11
BLS deserializing 100000 signatures 6.9386 s/op 6.0087 s/op 1.15
BLS verifyMultipleSignatures - same message - 3 - blst 933.27 us/op 941.98 us/op 0.99
BLS verifyMultipleSignatures - same message - 8 - blst 1.0022 ms/op 1.0724 ms/op 0.93
BLS verifyMultipleSignatures - same message - 32 - blst 1.7075 ms/op 1.6997 ms/op 1.00
BLS verifyMultipleSignatures - same message - 64 - blst 2.6323 ms/op 2.4543 ms/op 1.07
BLS verifyMultipleSignatures - same message - 128 - blst 4.6636 ms/op 4.0034 ms/op 1.16
BLS aggregatePubkeys 32 - blst 20.163 us/op 17.063 us/op 1.18
BLS aggregatePubkeys 128 - blst 71.717 us/op 59.210 us/op 1.21
notSeenSlots=1 numMissedVotes=1 numBadVotes=10 49.580 ms/op 40.965 ms/op 1.21
notSeenSlots=1 numMissedVotes=0 numBadVotes=4 47.560 ms/op 34.109 ms/op 1.39
notSeenSlots=2 numMissedVotes=1 numBadVotes=10 36.881 ms/op 39.831 ms/op 0.93
getSlashingsAndExits - default max 78.728 us/op 49.014 us/op 1.61
getSlashingsAndExits - 2k 292.64 us/op 264.40 us/op 1.11
isKnown best case - 1 super set check 206.00 ns/op 386.00 ns/op 0.53
isKnown normal case - 2 super set checks 205.00 ns/op 383.00 ns/op 0.54
isKnown worse case - 16 super set checks 207.00 ns/op 382.00 ns/op 0.54
InMemoryCheckpointStateCache - add get delete 2.3190 us/op 2.4250 us/op 0.96
validate api signedAggregateAndProof - struct 1.3783 ms/op 1.9365 ms/op 0.71
validate gossip signedAggregateAndProof - struct 1.3769 ms/op 1.9379 ms/op 0.71
batch validate gossip attestation - vc 640000 - chunk 32 119.99 us/op 104.08 us/op 1.15
batch validate gossip attestation - vc 640000 - chunk 64 104.79 us/op 92.011 us/op 1.14
batch validate gossip attestation - vc 640000 - chunk 128 98.380 us/op 83.963 us/op 1.17
batch validate gossip attestation - vc 640000 - chunk 256 99.539 us/op 82.147 us/op 1.21
pickEth1Vote - no votes 972.50 us/op 816.68 us/op 1.19
pickEth1Vote - max votes 5.2776 ms/op 4.3938 ms/op 1.20
pickEth1Vote - Eth1Data hashTreeRoot value x2048 10.693 ms/op 8.3652 ms/op 1.28
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 14.635 ms/op 10.767 ms/op 1.36
pickEth1Vote - Eth1Data fastSerialize value x2048 446.61 us/op 379.00 us/op 1.18
pickEth1Vote - Eth1Data fastSerialize tree x2048 2.2697 ms/op 1.9435 ms/op 1.17
bytes32 toHexString 364.00 ns/op 555.00 ns/op 0.66
bytes32 Buffer.toString(hex) 243.00 ns/op 410.00 ns/op 0.59
bytes32 Buffer.toString(hex) from Uint8Array 324.00 ns/op 490.00 ns/op 0.66
bytes32 Buffer.toString(hex) + 0x 245.00 ns/op 407.00 ns/op 0.60
Object access 1 prop 0.11400 ns/op 0.30300 ns/op 0.38
Map access 1 prop 0.11800 ns/op 0.30800 ns/op 0.38
Object get x1000 6.0010 ns/op 5.2670 ns/op 1.14
Map get x1000 6.1560 ns/op 5.9670 ns/op 1.03
Object set x1000 28.665 ns/op 18.583 ns/op 1.54
Map set x1000 19.211 ns/op 16.091 ns/op 1.19
Return object 10000 times 0.28600 ns/op 0.27680 ns/op 1.03
Throw Error 10000 times 4.2390 us/op 3.4330 us/op 1.23
toHex 137.80 ns/op 103.54 ns/op 1.33
Buffer.from 126.03 ns/op 97.357 ns/op 1.29
shared Buffer 88.341 ns/op 68.460 ns/op 1.29
fastMsgIdFn sha256 / 200 bytes 2.1590 us/op 1.9730 us/op 1.09
fastMsgIdFn h32 xxhash / 200 bytes 200.00 ns/op 379.00 ns/op 0.53
fastMsgIdFn h64 xxhash / 200 bytes 262.00 ns/op 426.00 ns/op 0.62
fastMsgIdFn sha256 / 1000 bytes 7.4920 us/op 5.7630 us/op 1.30
fastMsgIdFn h32 xxhash / 1000 bytes 324.00 ns/op 503.00 ns/op 0.64
fastMsgIdFn h64 xxhash / 1000 bytes 337.00 ns/op 504.00 ns/op 0.67
fastMsgIdFn sha256 / 10000 bytes 66.491 us/op 49.506 us/op 1.34
fastMsgIdFn h32 xxhash / 10000 bytes 1.7880 us/op 1.8840 us/op 0.95
fastMsgIdFn h64 xxhash / 10000 bytes 1.1830 us/op 1.3160 us/op 0.90
send data - 1000 256B messages 15.745 ms/op 11.781 ms/op 1.34
send data - 1000 512B messages 20.898 ms/op 17.402 ms/op 1.20
send data - 1000 1024B messages 27.278 ms/op 23.145 ms/op 1.18
send data - 1000 1200B messages 24.441 ms/op 14.564 ms/op 1.68
send data - 1000 2048B messages 25.439 ms/op 14.318 ms/op 1.78
send data - 1000 4096B messages 26.829 ms/op 15.547 ms/op 1.73
send data - 1000 16384B messages 44.190 ms/op 22.687 ms/op 1.95
send data - 1000 65536B messages 110.81 ms/op 61.611 ms/op 1.80
enrSubnets - fastDeserialize 64 bits 872.00 ns/op 961.00 ns/op 0.91
enrSubnets - ssz BitVector 64 bits 326.00 ns/op 489.00 ns/op 0.67
enrSubnets - fastDeserialize 4 bits 126.00 ns/op 308.00 ns/op 0.41
enrSubnets - ssz BitVector 4 bits 330.00 ns/op 490.00 ns/op 0.67
prioritizePeers score -10:0 att 32-0.1 sync 2-0 239.88 us/op 194.09 us/op 1.24
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 267.74 us/op 224.58 us/op 1.19
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 377.66 us/op 360.71 us/op 1.05
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 712.17 us/op 630.50 us/op 1.13
prioritizePeers score 0:0 att 64-1 sync 4-1 869.22 us/op 724.42 us/op 1.20
array of 16000 items push then shift 1.6173 us/op 1.2669 us/op 1.28
LinkedList of 16000 items push then shift 7.2240 ns/op 6.5000 ns/op 1.11
array of 16000 items push then pop 77.714 ns/op 62.111 ns/op 1.25
LinkedList of 16000 items push then pop 7.1140 ns/op 6.1880 ns/op 1.15
array of 24000 items push then shift 2.3802 us/op 1.8603 us/op 1.28
LinkedList of 24000 items push then shift 7.2450 ns/op 6.4270 ns/op 1.13
array of 24000 items push then pop 104.37 ns/op 85.494 ns/op 1.22
LinkedList of 24000 items push then pop 7.2450 ns/op 6.1850 ns/op 1.17
intersect bitArray bitLen 8 6.4510 ns/op 5.6690 ns/op 1.14
intersect array and set length 8 38.727 ns/op 32.364 ns/op 1.20
intersect bitArray bitLen 128 30.334 ns/op 26.417 ns/op 1.15
intersect array and set length 128 637.79 ns/op 542.38 ns/op 1.18
bitArray.getTrueBitIndexes() bitLen 128 1.0220 us/op 1.1070 us/op 0.92
bitArray.getTrueBitIndexes() bitLen 248 1.8260 us/op 1.7540 us/op 1.04
bitArray.getTrueBitIndexes() bitLen 512 3.7300 us/op 3.2310 us/op 1.15
Buffer.concat 32 items 655.00 ns/op 783.00 ns/op 0.84
Uint8Array.set 32 items 960.00 ns/op 976.00 ns/op 0.98
Buffer.copy 2.0720 us/op 2.0410 us/op 1.02
Uint8Array.set - with subarray 1.6290 us/op 1.5920 us/op 1.02
Uint8Array.set - without subarray 877.00 ns/op 994.00 ns/op 0.88
getUint32 - dataview 198.00 ns/op 376.00 ns/op 0.53
getUint32 - manual 125.00 ns/op 311.00 ns/op 0.40
Set add up to 64 items then delete first 2.2915 us/op 1.8263 us/op 1.25
OrderedSet add up to 64 items then delete first 3.4309 us/op 2.8668 us/op 1.20
Set add up to 64 items then delete last 2.5053 us/op 2.0742 us/op 1.21
OrderedSet add up to 64 items then delete last 4.2725 us/op 3.1904 us/op 1.34
Set add up to 64 items then delete middle 2.6570 us/op 2.0798 us/op 1.28
OrderedSet add up to 64 items then delete middle 5.5537 us/op 4.6013 us/op 1.21
Set add up to 128 items then delete first 5.3502 us/op 4.1200 us/op 1.30
OrderedSet add up to 128 items then delete first 8.7316 us/op 6.4965 us/op 1.34
Set add up to 128 items then delete last 5.6463 us/op 3.9821 us/op 1.42
OrderedSet add up to 128 items then delete last 7.7315 us/op 6.1599 us/op 1.26
Set add up to 128 items then delete middle 5.1286 us/op 3.9792 us/op 1.29
OrderedSet add up to 128 items then delete middle 20.871 us/op 11.829 us/op 1.76
Set add up to 256 items then delete first 11.259 us/op 8.0610 us/op 1.40
OrderedSet add up to 256 items then delete first 16.689 us/op 12.636 us/op 1.32
Set add up to 256 items then delete last 10.306 us/op 7.8158 us/op 1.32
OrderedSet add up to 256 items then delete last 15.360 us/op 12.061 us/op 1.27
Set add up to 256 items then delete middle 10.020 us/op 7.8221 us/op 1.28
OrderedSet add up to 256 items then delete middle 43.829 us/op 34.329 us/op 1.28
transfer serialized Status (84 B) 2.2420 us/op 1.9310 us/op 1.16
copy serialized Status (84 B) 1.1200 us/op 1.1840 us/op 0.95
transfer serialized SignedVoluntaryExit (112 B) 2.2350 us/op 1.9450 us/op 1.15
copy serialized SignedVoluntaryExit (112 B) 1.1450 us/op 1.1790 us/op 0.97
transfer serialized ProposerSlashing (416 B) 2.2610 us/op 2.1080 us/op 1.07
copy serialized ProposerSlashing (416 B) 1.2100 us/op 1.3380 us/op 0.90
transfer serialized Attestation (485 B) 2.2600 us/op 2.0810 us/op 1.09
copy serialized Attestation (485 B) 1.2510 us/op 1.3480 us/op 0.93
transfer serialized AttesterSlashing (33232 B) 2.3210 us/op 2.1470 us/op 1.08
copy serialized AttesterSlashing (33232 B) 3.1680 us/op 2.5340 us/op 1.25
transfer serialized Small SignedBeaconBlock (128000 B) 3.2220 us/op 2.1860 us/op 1.47
copy serialized Small SignedBeaconBlock (128000 B) 8.5060 us/op 5.5960 us/op 1.52
transfer serialized Avg SignedBeaconBlock (200000 B) 3.5470 us/op 2.3560 us/op 1.51
copy serialized Avg SignedBeaconBlock (200000 B) 12.959 us/op 8.0400 us/op 1.61
transfer serialized BlobsSidecar (524380 B) 3.3310 us/op 3.0870 us/op 1.08
copy serialized BlobsSidecar (524380 B) 58.706 us/op 95.290 us/op 0.62
transfer serialized Big SignedBeaconBlock (1000000 B) 3.4630 us/op 3.4430 us/op 1.01
copy serialized Big SignedBeaconBlock (1000000 B) 212.64 us/op 114.60 us/op 1.86
pass gossip attestations to forkchoice per slot 2.8650 ms/op 2.3385 ms/op 1.23
forkChoice updateHead vc 100000 bc 64 eq 0 461.90 us/op 395.20 us/op 1.17
forkChoice updateHead vc 600000 bc 64 eq 0 2.8323 ms/op 2.3380 ms/op 1.21
forkChoice updateHead vc 1000000 bc 64 eq 0 4.9657 ms/op 3.8828 ms/op 1.28
forkChoice updateHead vc 600000 bc 320 eq 0 2.7998 ms/op 2.4376 ms/op 1.15
forkChoice updateHead vc 600000 bc 1200 eq 0 2.8878 ms/op 2.3889 ms/op 1.21
forkChoice updateHead vc 600000 bc 7200 eq 0 3.0954 ms/op 2.5309 ms/op 1.22
forkChoice updateHead vc 600000 bc 64 eq 1000 10.451 ms/op 9.4372 ms/op 1.11
forkChoice updateHead vc 600000 bc 64 eq 10000 10.433 ms/op 9.3493 ms/op 1.12
forkChoice updateHead vc 600000 bc 64 eq 300000 14.118 ms/op 11.210 ms/op 1.26
computeDeltas 500000 validators 300 proto nodes 3.9659 ms/op 3.0753 ms/op 1.29
computeDeltas 500000 validators 1200 proto nodes 3.9543 ms/op 3.0793 ms/op 1.28
computeDeltas 500000 validators 7200 proto nodes 4.1264 ms/op 3.0079 ms/op 1.37
computeDeltas 750000 validators 300 proto nodes 6.0552 ms/op 4.6891 ms/op 1.29
computeDeltas 750000 validators 1200 proto nodes 6.3082 ms/op 4.5363 ms/op 1.39
computeDeltas 750000 validators 7200 proto nodes 6.1756 ms/op 4.5426 ms/op 1.36
computeDeltas 1400000 validators 300 proto nodes 11.865 ms/op 8.5766 ms/op 1.38
computeDeltas 1400000 validators 1200 proto nodes 12.258 ms/op 8.4038 ms/op 1.46
computeDeltas 1400000 validators 7200 proto nodes 12.161 ms/op 8.3982 ms/op 1.45
computeDeltas 2100000 validators 300 proto nodes 17.989 ms/op 12.922 ms/op 1.39
computeDeltas 2100000 validators 1200 proto nodes 18.487 ms/op 13.006 ms/op 1.42
computeDeltas 2100000 validators 7200 proto nodes 17.468 ms/op 12.814 ms/op 1.36
altair processAttestation - 250000 vs - 7PWei normalcase 2.9598 ms/op 1.6087 ms/op 1.84
altair processAttestation - 250000 vs - 7PWei worstcase 3.3047 ms/op 2.4484 ms/op 1.35
altair processAttestation - setStatus - 1/6 committees join 133.35 us/op 102.49 us/op 1.30
altair processAttestation - setStatus - 1/3 committees join 250.81 us/op 182.59 us/op 1.37
altair processAttestation - setStatus - 1/2 committees join 346.48 us/op 254.78 us/op 1.36
altair processAttestation - setStatus - 2/3 committees join 435.51 us/op 393.42 us/op 1.11
altair processAttestation - setStatus - 4/5 committees join 607.39 us/op 473.85 us/op 1.28
altair processAttestation - setStatus - 100% committees join 744.46 us/op 546.98 us/op 1.36
altair processBlock - 250000 vs - 7PWei normalcase 4.2115 ms/op 3.8498 ms/op 1.09
altair processBlock - 250000 vs - 7PWei normalcase hashState 28.843 ms/op 30.047 ms/op 0.96
altair processBlock - 250000 vs - 7PWei worstcase 34.249 ms/op 37.640 ms/op 0.91
altair processBlock - 250000 vs - 7PWei worstcase hashState 71.565 ms/op 78.909 ms/op 0.91
phase0 processBlock - 250000 vs - 7PWei normalcase 1.6833 ms/op 1.8807 ms/op 0.90
phase0 processBlock - 250000 vs - 7PWei worstcase 19.987 ms/op 23.965 ms/op 0.83
altair processEth1Data - 250000 vs - 7PWei normalcase 338.71 us/op 258.90 us/op 1.31
getExpectedWithdrawals 250000 eb:1,eth1:1,we:0,wn:0,smpl:15 5.7290 us/op 5.6680 us/op 1.01
getExpectedWithdrawals 250000 eb:0.95,eth1:0.1,we:0.05,wn:0,smpl:219 35.510 us/op 34.514 us/op 1.03
getExpectedWithdrawals 250000 eb:0.95,eth1:0.3,we:0.05,wn:0,smpl:42 9.6930 us/op 9.5800 us/op 1.01
getExpectedWithdrawals 250000 eb:0.95,eth1:0.7,we:0.05,wn:0,smpl:18 7.2720 us/op 3.7110 us/op 1.96
getExpectedWithdrawals 250000 eb:0.1,eth1:0.1,we:0,wn:0,smpl:1020 160.91 us/op 160.61 us/op 1.00
getExpectedWithdrawals 250000 eb:0.03,eth1:0.03,we:0,wn:0,smpl:11777 1.8950 ms/op 1.2739 ms/op 1.49
getExpectedWithdrawals 250000 eb:0.01,eth1:0.01,we:0,wn:0,smpl:16384 2.4351 ms/op 1.6093 ms/op 1.51
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,smpl:16384 2.4173 ms/op 1.7055 ms/op 1.42
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,nocache,smpl:16384 4.4880 ms/op 3.6349 ms/op 1.23
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,smpl:16384 2.4297 ms/op 1.7765 ms/op 1.37
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,nocache,smpl:16384 4.6543 ms/op 3.7079 ms/op 1.26
Tree 40 250000 create 424.62 ms/op 339.97 ms/op 1.25
Tree 40 250000 get(125000) 141.11 ns/op 109.48 ns/op 1.29
Tree 40 250000 set(125000) 1.4834 us/op 1.1701 us/op 1.27
Tree 40 250000 toArray() 17.080 ms/op 12.620 ms/op 1.35
Tree 40 250000 iterate all - toArray() + loop 15.038 ms/op 13.897 ms/op 1.08
Tree 40 250000 iterate all - get(i) 50.400 ms/op 41.235 ms/op 1.22
Array 250000 create 2.4438 ms/op 2.1255 ms/op 1.15
Array 250000 clone - spread 810.91 us/op 625.28 us/op 1.30
Array 250000 get(125000) 0.41700 ns/op 0.52500 ns/op 0.79
Array 250000 set(125000) 0.43500 ns/op 0.53400 ns/op 0.81
Array 250000 iterate all - loop 82.230 us/op 92.614 us/op 0.89
phase0 afterProcessEpoch - 250000 vs - 7PWei 41.669 ms/op 37.573 ms/op 1.11
Array.fill - length 1000000 3.4181 ms/op 2.6525 ms/op 1.29
Array push - length 1000000 13.897 ms/op 11.214 ms/op 1.24
Array.get 0.26594 ns/op 0.24580 ns/op 1.08
Uint8Array.get 0.43743 ns/op 0.39178 ns/op 1.12
phase0 beforeProcessEpoch - 250000 vs - 7PWei 17.474 ms/op 17.118 ms/op 1.02
altair processEpoch - mainnet_e81889 239.56 ms/op 276.69 ms/op 0.87
mainnet_e81889 - altair beforeProcessEpoch 18.819 ms/op 15.085 ms/op 1.25
mainnet_e81889 - altair processJustificationAndFinalization 5.7180 us/op 4.6310 us/op 1.23
mainnet_e81889 - altair processInactivityUpdates 4.6050 ms/op 3.5313 ms/op 1.30
mainnet_e81889 - altair processRewardsAndPenalties 37.700 ms/op 35.774 ms/op 1.05
mainnet_e81889 - altair processRegistryUpdates 712.00 ns/op 850.00 ns/op 0.84
mainnet_e81889 - altair processSlashings 187.00 ns/op 393.00 ns/op 0.48
mainnet_e81889 - altair processEth1DataReset 181.00 ns/op 389.00 ns/op 0.47
mainnet_e81889 - altair processEffectiveBalanceUpdates 1.1967 ms/op 1.1342 ms/op 1.06
mainnet_e81889 - altair processSlashingsReset 863.00 ns/op 984.00 ns/op 0.88
mainnet_e81889 - altair processRandaoMixesReset 1.1330 us/op 1.2010 us/op 0.94
mainnet_e81889 - altair processHistoricalRootsUpdate 186.00 ns/op 391.00 ns/op 0.48
mainnet_e81889 - altair processParticipationFlagUpdates 547.00 ns/op 688.00 ns/op 0.80
mainnet_e81889 - altair processSyncCommitteeUpdates 147.00 ns/op 352.00 ns/op 0.42
mainnet_e81889 - altair afterProcessEpoch 45.527 ms/op 39.453 ms/op 1.15
capella processEpoch - mainnet_e217614 908.42 ms/op 899.04 ms/op 1.01
mainnet_e217614 - capella beforeProcessEpoch 62.337 ms/op 56.389 ms/op 1.11
mainnet_e217614 - capella processJustificationAndFinalization 5.3610 us/op 4.4060 us/op 1.22
mainnet_e217614 - capella processInactivityUpdates 14.275 ms/op 12.031 ms/op 1.19
mainnet_e217614 - capella processRewardsAndPenalties 178.84 ms/op 189.89 ms/op 0.94
mainnet_e217614 - capella processRegistryUpdates 6.3590 us/op 5.0450 us/op 1.26
mainnet_e217614 - capella processSlashings 181.00 ns/op 386.00 ns/op 0.47
mainnet_e217614 - capella processEth1DataReset 178.00 ns/op 383.00 ns/op 0.46
mainnet_e217614 - capella processEffectiveBalanceUpdates 4.1578 ms/op 3.3378 ms/op 1.25
mainnet_e217614 - capella processSlashingsReset 863.00 ns/op 980.00 ns/op 0.88
mainnet_e217614 - capella processRandaoMixesReset 1.1300 us/op 1.4950 us/op 0.76
mainnet_e217614 - capella processHistoricalRootsUpdate 180.00 ns/op 400.00 ns/op 0.45
mainnet_e217614 - capella processParticipationFlagUpdates 523.00 ns/op 694.00 ns/op 0.75
mainnet_e217614 - capella afterProcessEpoch 113.85 ms/op 100.54 ms/op 1.13
phase0 processEpoch - mainnet_e58758 287.52 ms/op 264.50 ms/op 1.09
mainnet_e58758 - phase0 beforeProcessEpoch 63.535 ms/op 72.754 ms/op 0.87
mainnet_e58758 - phase0 processJustificationAndFinalization 5.3840 us/op 5.4790 us/op 0.98
mainnet_e58758 - phase0 processRewardsAndPenalties 33.911 ms/op 36.218 ms/op 0.94
mainnet_e58758 - phase0 processRegistryUpdates 3.2090 us/op 3.7090 us/op 0.87
mainnet_e58758 - phase0 processSlashings 184.00 ns/op 394.00 ns/op 0.47
mainnet_e58758 - phase0 processEth1DataReset 179.00 ns/op 388.00 ns/op 0.46
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 1.1579 ms/op 880.60 us/op 1.31
mainnet_e58758 - phase0 processSlashingsReset 899.00 ns/op 1.0880 us/op 0.83
mainnet_e58758 - phase0 processRandaoMixesReset 1.1600 us/op 1.2050 us/op 0.96
mainnet_e58758 - phase0 processHistoricalRootsUpdate 182.00 ns/op 397.00 ns/op 0.46
mainnet_e58758 - phase0 processParticipationRecordUpdates 874.00 ns/op 1.1600 us/op 0.75
mainnet_e58758 - phase0 afterProcessEpoch 35.091 ms/op 31.793 ms/op 1.10
phase0 processEffectiveBalanceUpdates - 250000 normalcase 1.4591 ms/op 936.11 us/op 1.56
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 1.9479 ms/op 1.4748 ms/op 1.32
altair processInactivityUpdates - 250000 normalcase 16.192 ms/op 18.120 ms/op 0.89
altair processInactivityUpdates - 250000 worstcase 16.535 ms/op 15.643 ms/op 1.06
phase0 processRegistryUpdates - 250000 normalcase 6.4150 us/op 5.0700 us/op 1.27
phase0 processRegistryUpdates - 250000 badcase_full_deposits 220.46 us/op 277.05 us/op 0.80
phase0 processRegistryUpdates - 250000 worstcase 0.5 96.405 ms/op 109.41 ms/op 0.88
altair processRewardsAndPenalties - 250000 normalcase 27.544 ms/op 25.186 ms/op 1.09
altair processRewardsAndPenalties - 250000 worstcase 26.772 ms/op 30.421 ms/op 0.88
phase0 getAttestationDeltas - 250000 normalcase 6.1443 ms/op 4.3357 ms/op 1.42
phase0 getAttestationDeltas - 250000 worstcase 6.5641 ms/op 5.1979 ms/op 1.26
phase0 processSlashings - 250000 worstcase 82.089 us/op 83.411 us/op 0.98
altair processSyncCommitteeUpdates - 250000 10.536 ms/op 9.6011 ms/op 1.10
BeaconState.hashTreeRoot - No change 214.00 ns/op 425.00 ns/op 0.50
BeaconState.hashTreeRoot - 1 full validator 88.361 us/op 71.742 us/op 1.23
BeaconState.hashTreeRoot - 32 full validator 1.2267 ms/op 989.55 us/op 1.24
BeaconState.hashTreeRoot - 512 full validator 11.884 ms/op 7.0966 ms/op 1.67
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 90.512 us/op 87.519 us/op 1.03
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 1.2871 ms/op 1.5017 ms/op 0.86
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 22.735 ms/op 23.910 ms/op 0.95
BeaconState.hashTreeRoot - 1 balances 76.014 us/op 73.456 us/op 1.03
BeaconState.hashTreeRoot - 32 balances 900.57 us/op 613.42 us/op 1.47
BeaconState.hashTreeRoot - 512 balances 8.4947 ms/op 5.5968 ms/op 1.52
BeaconState.hashTreeRoot - 250000 balances 174.89 ms/op 162.33 ms/op 1.08
aggregationBits - 2048 els - zipIndexesInBitList 21.166 us/op 17.686 us/op 1.20
byteArrayEquals 32 53.334 ns/op 42.385 ns/op 1.26
Buffer.compare 32 23.757 ns/op 15.758 ns/op 1.51
byteArrayEquals 1024 1.5801 us/op 1.2469 us/op 1.27
Buffer.compare 1024 25.280 ns/op 24.249 ns/op 1.04
byteArrayEquals 16384 25.170 us/op 19.953 us/op 1.26
Buffer.compare 16384 202.20 ns/op 172.63 ns/op 1.17
byteArrayEquals 123687377 188.65 ms/op 151.00 ms/op 1.25
Buffer.compare 123687377 6.7579 ms/op 4.4533 ms/op 1.52
byteArrayEquals 32 - diff last byte 52.926 ns/op 41.895 ns/op 1.26
Buffer.compare 32 - diff last byte 17.220 ns/op 15.767 ns/op 1.09
byteArrayEquals 1024 - diff last byte 1.9208 us/op 1.2557 us/op 1.53
Buffer.compare 1024 - diff last byte 37.220 ns/op 23.943 ns/op 1.55
byteArrayEquals 16384 - diff last byte 26.077 us/op 20.002 us/op 1.30
Buffer.compare 16384 - diff last byte 196.54 ns/op 194.68 ns/op 1.01
byteArrayEquals 123687377 - diff last byte 194.09 ms/op 148.29 ms/op 1.31
Buffer.compare 123687377 - diff last byte 8.1194 ms/op 4.3284 ms/op 1.88
byteArrayEquals 32 - random bytes 5.2000 ns/op 4.8720 ns/op 1.07
Buffer.compare 32 - random bytes 18.549 ns/op 15.851 ns/op 1.17
byteArrayEquals 1024 - random bytes 5.2860 ns/op 4.8340 ns/op 1.09
Buffer.compare 1024 - random bytes 18.620 ns/op 15.085 ns/op 1.23
byteArrayEquals 16384 - random bytes 5.2590 ns/op 4.7260 ns/op 1.11
Buffer.compare 16384 - random bytes 18.468 ns/op 14.892 ns/op 1.24
byteArrayEquals 123687377 - random bytes 6.5000 ns/op 7.6800 ns/op 0.85
Buffer.compare 123687377 - random bytes 19.390 ns/op 18.900 ns/op 1.03
regular array get 100000 times 45.215 us/op 40.289 us/op 1.12
wrappedArray get 100000 times 33.975 us/op 40.491 us/op 0.84
arrayWithProxy get 100000 times 13.485 ms/op 9.3924 ms/op 1.44
ssz.Root.equals 46.950 ns/op 39.212 ns/op 1.20
byteArrayEquals 46.837 ns/op 38.657 ns/op 1.21
Buffer.compare 10.827 ns/op 9.4240 ns/op 1.15
processSlot - 1 slots 10.674 us/op 8.6860 us/op 1.23
processSlot - 32 slots 2.0094 ms/op 1.9913 ms/op 1.01
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 3.3876 ms/op 2.0751 ms/op 1.63
getCommitteeAssignments - req 1 vs - 250000 vc 2.4495 ms/op 1.7377 ms/op 1.41
getCommitteeAssignments - req 100 vs - 250000 vc 4.2468 ms/op 3.4374 ms/op 1.24
getCommitteeAssignments - req 1000 vs - 250000 vc 4.5160 ms/op 3.6601 ms/op 1.23
findModifiedValidators - 10000 modified validators 779.44 ms/op 777.78 ms/op 1.00
findModifiedValidators - 1000 modified validators 760.18 ms/op 683.51 ms/op 1.11
findModifiedValidators - 100 modified validators 268.13 ms/op 222.82 ms/op 1.20
findModifiedValidators - 10 modified validators 208.84 ms/op 130.84 ms/op 1.60
findModifiedValidators - 1 modified validators 224.80 ms/op 156.42 ms/op 1.44
findModifiedValidators - no difference 268.26 ms/op 130.85 ms/op 2.05
compare ViewDUs 6.8582 s/op 5.9606 s/op 1.15
compare each validator Uint8Array 1.6659 s/op 1.9524 s/op 0.85
compare ViewDU to Uint8Array 1.5624 s/op 863.72 ms/op 1.81
migrate state 1000000 validators, 24 modified, 0 new 1.0875 s/op 839.98 ms/op 1.29
migrate state 1000000 validators, 1700 modified, 1000 new 1.3309 s/op 1.0642 s/op 1.25
migrate state 1000000 validators, 3400 modified, 2000 new 1.2935 s/op 1.2209 s/op 1.06
migrate state 1500000 validators, 24 modified, 0 new 882.50 ms/op 921.08 ms/op 0.96
migrate state 1500000 validators, 1700 modified, 1000 new 1.0116 s/op 1.0322 s/op 0.98
migrate state 1500000 validators, 3400 modified, 2000 new 1.3202 s/op 1.2325 s/op 1.07
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 4.2600 ns/op 5.8200 ns/op 0.73
state getBlockRootAtSlot - 250000 vs - 7PWei 566.93 ns/op 352.35 ns/op 1.61
naive computeProposerIndex 100000 validators 54.179 ms/op 43.275 ms/op 1.25
computeProposerIndex 100000 validators 1.5150 ms/op 1.3235 ms/op 1.14
naiveGetNextSyncCommitteeIndices 1000 validators 7.4066 s/op 6.5120 s/op 1.14
getNextSyncCommitteeIndices 1000 validators 113.89 ms/op 91.352 ms/op 1.25
naiveGetNextSyncCommitteeIndices 10000 validators 8.3064 s/op 6.8792 s/op 1.21
getNextSyncCommitteeIndices 10000 validators 118.51 ms/op 91.111 ms/op 1.30
naiveGetNextSyncCommitteeIndices 100000 validators 8.3363 s/op 6.1532 s/op 1.35
getNextSyncCommitteeIndices 100000 validators 117.06 ms/op 90.574 ms/op 1.29
naive computeShuffledIndex 100000 validators 25.065 s/op 21.429 s/op 1.17
cached computeShuffledIndex 100000 validators 566.66 ms/op 455.85 ms/op 1.24
naive computeShuffledIndex 2000000 validators 522.61 s/op 409.42 s/op 1.28
cached computeShuffledIndex 2000000 validators 42.173 s/op 14.331 s/op 2.94
computeProposers - vc 250000 596.33 us/op 531.39 us/op 1.12
computeEpochShuffling - vc 250000 43.501 ms/op 36.751 ms/op 1.18
getNextSyncCommittee - vc 250000 10.542 ms/op 8.9499 ms/op 1.18
computeSigningRoot for AttestationData 22.151 us/op 16.606 us/op 1.33
hash AttestationData serialized data then Buffer.toString(base64) 1.6438 us/op 1.0721 us/op 1.53
toHexString serialized data 1.1831 us/op 809.63 ns/op 1.46
Buffer.toString(base64) 172.13 ns/op 100.64 ns/op 1.71
nodejs block root to RootHex using toHex 144.39 ns/op 110.59 ns/op 1.31
nodejs block root to RootHex using toRootHex 90.330 ns/op 74.657 ns/op 1.21
nodejs fromhex(blob) 113.28 ms/op 93.255 ms/op 1.21
nodejs fromHexInto(blob) 95.174 ms/op 80.088 ms/op 1.19
browser block root to RootHex using the deprecated toHexString 214.51 ns/op 188.90 ns/op 1.14
browser block root to RootHex using toHex 178.39 ns/op 152.29 ns/op 1.17
browser block root to RootHex using toRootHex 160.36 ns/op 137.36 ns/op 1.17
browser fromHexInto(blob) 829.95 us/op 616.88 us/op 1.35
browser fromHex(blob) 809.72 ms/op 563.11 ms/op 1.44

by benchmarkbot/action

@wemeetagain wemeetagain merged commit c1880f6 into unstable Sep 26, 2025
31 of 33 checks passed
@wemeetagain wemeetagain deleted the nflaig/gloas-timings branch September 26, 2025 13:06
@wemeetagain
Copy link
Member

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

3 participants