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 electra support for remote signer #7100

Merged
merged 2 commits into from
Sep 26, 2024

Conversation

nflaig
Copy link
Member

@nflaig nflaig commented Sep 21, 2024

Motivation

Adds electra support for remote signer as per ethereum/remote-signing-api#15 and ethereum/remote-signing-api#17

Description

  • adds new AGGREGATE_AND_PROOF_V2 message type which will be used post-electra
  • test signAggregateAndProof for different forks

TODO

  • enable electra fork in e2e once web3signer release is out can be done later

Copy link

codecov bot commented Sep 21, 2024

Codecov Report

Attention: Patch coverage is 22.22222% with 14 lines in your changes missing coverage. Please review.

Project coverage is 50.82%. Comparing base (ad4ec77) to head (4e9ddf4).
Report is 3 commits behind head on unstable.

Additional details and impacted files
@@             Coverage Diff              @@
##           unstable    #7100      +/-   ##
============================================
- Coverage     50.82%   50.82%   -0.01%     
============================================
  Files           597      597              
  Lines         39789    39800      +11     
  Branches       2059     2063       +4     
============================================
+ Hits          20224    20227       +3     
- Misses        19565    19573       +8     

Copy link
Contributor

github-actions bot commented Sep 21, 2024

Performance Report

✔️ no performance regression detected

Full benchmark results
Benchmark suite Current: 7291d70 Previous: ad4ec77 Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 2.2178 ms/op 1.9501 ms/op 1.14
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 44.562 us/op 50.224 us/op 0.89
BLS verify - blst 908.12 us/op 827.53 us/op 1.10
BLS verifyMultipleSignatures 3 - blst 1.3507 ms/op 2.5308 ms/op 0.53
BLS verifyMultipleSignatures 8 - blst 2.2007 ms/op 2.2683 ms/op 0.97
BLS verifyMultipleSignatures 32 - blst 4.6818 ms/op 6.9331 ms/op 0.68
BLS verifyMultipleSignatures 64 - blst 8.7307 ms/op 11.030 ms/op 0.79
BLS verifyMultipleSignatures 128 - blst 17.338 ms/op 18.012 ms/op 0.96
BLS deserializing 10000 signatures 649.26 ms/op 701.15 ms/op 0.93
BLS deserializing 100000 signatures 6.6508 s/op 6.9664 s/op 0.95
BLS verifyMultipleSignatures - same message - 3 - blst 916.76 us/op 1.1606 ms/op 0.79
BLS verifyMultipleSignatures - same message - 8 - blst 1.0697 ms/op 1.1206 ms/op 0.95
BLS verifyMultipleSignatures - same message - 32 - blst 1.7414 ms/op 1.7464 ms/op 1.00
BLS verifyMultipleSignatures - same message - 64 - blst 2.5546 ms/op 2.8032 ms/op 0.91
BLS verifyMultipleSignatures - same message - 128 - blst 4.2238 ms/op 4.5110 ms/op 0.94
BLS aggregatePubkeys 32 - blst 18.854 us/op 20.539 us/op 0.92
BLS aggregatePubkeys 128 - blst 64.655 us/op 71.549 us/op 0.90
notSeenSlots=1 numMissedVotes=1 numBadVotes=10 71.478 ms/op 79.517 ms/op 0.90
notSeenSlots=1 numMissedVotes=0 numBadVotes=4 66.440 ms/op 76.245 ms/op 0.87
notSeenSlots=2 numMissedVotes=1 numBadVotes=10 33.274 ms/op 46.836 ms/op 0.71
getSlashingsAndExits - default max 92.552 us/op 87.538 us/op 1.06
getSlashingsAndExits - 2k 272.75 us/op 259.79 us/op 1.05
proposeBlockBody type=full, size=empty 5.2179 ms/op 5.8706 ms/op 0.89
isKnown best case - 1 super set check 502.00 ns/op 283.00 ns/op 1.77
isKnown normal case - 2 super set checks 487.00 ns/op 264.00 ns/op 1.84
isKnown worse case - 16 super set checks 488.00 ns/op 269.00 ns/op 1.81
InMemoryCheckpointStateCache - add get delete 3.2350 us/op 2.6630 us/op 1.21
updateUnfinalizedPubkeys - updating 10 pubkeys 583.13 us/op 945.88 us/op 0.62
updateUnfinalizedPubkeys - updating 100 pubkeys 3.1526 ms/op 3.6376 ms/op 0.87
updateUnfinalizedPubkeys - updating 1000 pubkeys 43.062 ms/op 50.886 ms/op 0.85
validate api signedAggregateAndProof - struct 1.6903 ms/op 2.5933 ms/op 0.65
validate gossip signedAggregateAndProof - struct 1.9877 ms/op 2.5950 ms/op 0.77
validate gossip attestation - vc 640000 976.26 us/op 1.2759 ms/op 0.77
batch validate gossip attestation - vc 640000 - chunk 32 132.26 us/op 136.42 us/op 0.97
batch validate gossip attestation - vc 640000 - chunk 64 118.47 us/op 121.25 us/op 0.98
batch validate gossip attestation - vc 640000 - chunk 128 106.54 us/op 112.64 us/op 0.95
batch validate gossip attestation - vc 640000 - chunk 256 110.20 us/op 106.54 us/op 1.03
pickEth1Vote - no votes 997.52 us/op 1.0675 ms/op 0.93
pickEth1Vote - max votes 6.0331 ms/op 7.9230 ms/op 0.76
pickEth1Vote - Eth1Data hashTreeRoot value x2048 11.418 ms/op 17.009 ms/op 0.67
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 23.586 ms/op 25.354 ms/op 0.93
pickEth1Vote - Eth1Data fastSerialize value x2048 405.77 us/op 492.63 us/op 0.82
pickEth1Vote - Eth1Data fastSerialize tree x2048 5.0352 ms/op 3.5457 ms/op 1.42
bytes32 toHexString 711.00 ns/op 442.00 ns/op 1.61
bytes32 Buffer.toString(hex) 485.00 ns/op 254.00 ns/op 1.91
bytes32 Buffer.toString(hex) from Uint8Array 639.00 ns/op 381.00 ns/op 1.68
bytes32 Buffer.toString(hex) + 0x 468.00 ns/op 257.00 ns/op 1.82
Object access 1 prop 0.37600 ns/op 0.14600 ns/op 2.58
Map access 1 prop 0.34600 ns/op 0.13800 ns/op 2.51
Object get x1000 5.3190 ns/op 5.9480 ns/op 0.89
Map get x1000 6.0990 ns/op 6.6250 ns/op 0.92
Object set x1000 23.868 ns/op 32.532 ns/op 0.73
Map set x1000 20.182 ns/op 22.713 ns/op 0.89
Return object 10000 times 0.31800 ns/op 0.28870 ns/op 1.10
Throw Error 10000 times 2.8089 us/op 3.3407 us/op 0.84
toHex 115.05 ns/op 145.69 ns/op 0.79
Buffer.from 111.34 ns/op 133.04 ns/op 0.84
shared Buffer 73.699 ns/op 88.086 ns/op 0.84
fastMsgIdFn sha256 / 200 bytes 2.2280 us/op 2.2570 us/op 0.99
fastMsgIdFn h32 xxhash / 200 bytes 529.00 ns/op 231.00 ns/op 2.29
fastMsgIdFn h64 xxhash / 200 bytes 520.00 ns/op 280.00 ns/op 1.86
fastMsgIdFn sha256 / 1000 bytes 6.1970 us/op 7.3690 us/op 0.84
fastMsgIdFn h32 xxhash / 1000 bytes 670.00 ns/op 360.00 ns/op 1.86
fastMsgIdFn h64 xxhash / 1000 bytes 603.00 ns/op 352.00 ns/op 1.71
fastMsgIdFn sha256 / 10000 bytes 52.849 us/op 65.054 us/op 0.81
fastMsgIdFn h32 xxhash / 10000 bytes 2.0500 us/op 1.8790 us/op 1.09
fastMsgIdFn h64 xxhash / 10000 bytes 1.3980 us/op 1.2430 us/op 1.12
send data - 1000 256B messages 11.088 ms/op 12.382 ms/op 0.90
send data - 1000 512B messages 16.085 ms/op 17.594 ms/op 0.91
send data - 1000 1024B messages 28.709 ms/op 26.565 ms/op 1.08
send data - 1000 1200B messages 27.818 ms/op 26.676 ms/op 1.04
send data - 1000 2048B messages 34.236 ms/op 31.738 ms/op 1.08
send data - 1000 4096B messages 30.935 ms/op 29.363 ms/op 1.05
send data - 1000 16384B messages 73.541 ms/op 73.864 ms/op 1.00
send data - 1000 65536B messages 267.30 ms/op 200.68 ms/op 1.33
enrSubnets - fastDeserialize 64 bits 1.2090 us/op 1.1040 us/op 1.10
enrSubnets - ssz BitVector 64 bits 629.00 ns/op 351.00 ns/op 1.79
enrSubnets - fastDeserialize 4 bits 419.00 ns/op 156.00 ns/op 2.69
enrSubnets - ssz BitVector 4 bits 655.00 ns/op 351.00 ns/op 1.87
prioritizePeers score -10:0 att 32-0.1 sync 2-0 143.13 us/op 146.32 us/op 0.98
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 150.51 us/op 195.30 us/op 0.77
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 331.70 us/op 281.40 us/op 1.18
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 494.49 us/op 684.86 us/op 0.72
prioritizePeers score 0:0 att 64-1 sync 4-1 779.99 us/op 921.94 us/op 0.85
array of 16000 items push then shift 1.2930 us/op 1.6637 us/op 0.78
LinkedList of 16000 items push then shift 8.3200 ns/op 7.1550 ns/op 1.16
array of 16000 items push then pop 112.82 ns/op 97.842 ns/op 1.15
LinkedList of 16000 items push then pop 6.4580 ns/op 7.0660 ns/op 0.91
array of 24000 items push then shift 2.0012 us/op 2.4581 us/op 0.81
LinkedList of 24000 items push then shift 7.1330 ns/op 7.1250 ns/op 1.00
array of 24000 items push then pop 138.55 ns/op 133.24 ns/op 1.04
LinkedList of 24000 items push then pop 6.2930 ns/op 7.0110 ns/op 0.90
intersect bitArray bitLen 8 5.5890 ns/op 6.4530 ns/op 0.87
intersect array and set length 8 38.013 ns/op 46.877 ns/op 0.81
intersect bitArray bitLen 128 26.750 ns/op 30.156 ns/op 0.89
intersect array and set length 128 581.10 ns/op 681.55 ns/op 0.85
bitArray.getTrueBitIndexes() bitLen 128 2.0960 us/op 2.7190 us/op 0.77
bitArray.getTrueBitIndexes() bitLen 248 3.6050 us/op 3.6530 us/op 0.99
bitArray.getTrueBitIndexes() bitLen 512 7.1230 us/op 9.5700 us/op 0.74
Buffer.concat 32 items 1.1510 us/op 1.0330 us/op 1.11
Uint8Array.set 32 items 1.6200 us/op 1.7630 us/op 0.92
Buffer.copy 1.8150 us/op 2.0490 us/op 0.89
Uint8Array.set - with subarray 2.1420 us/op 2.9930 us/op 0.72
Uint8Array.set - without subarray 1.6390 us/op 1.6560 us/op 0.99
getUint32 - dataview 492.00 ns/op 263.00 ns/op 1.87
getUint32 - manual 463.00 ns/op 160.00 ns/op 2.89
Set add up to 64 items then delete first 1.9011 us/op 2.2280 us/op 0.85
OrderedSet add up to 64 items then delete first 2.9543 us/op 3.2979 us/op 0.90
Set add up to 64 items then delete last 2.1423 us/op 2.5788 us/op 0.83
OrderedSet add up to 64 items then delete last 3.3935 us/op 3.9188 us/op 0.87
Set add up to 64 items then delete middle 2.1851 us/op 2.5525 us/op 0.86
OrderedSet add up to 64 items then delete middle 4.8620 us/op 5.4074 us/op 0.90
Set add up to 128 items then delete first 4.2070 us/op 5.0349 us/op 0.84
OrderedSet add up to 128 items then delete first 6.3956 us/op 7.4439 us/op 0.86
Set add up to 128 items then delete last 4.1970 us/op 5.0911 us/op 0.82
OrderedSet add up to 128 items then delete last 6.4585 us/op 7.7845 us/op 0.83
Set add up to 128 items then delete middle 4.1851 us/op 4.9347 us/op 0.85
OrderedSet add up to 128 items then delete middle 12.649 us/op 14.115 us/op 0.90
Set add up to 256 items then delete first 8.2230 us/op 9.9835 us/op 0.82
OrderedSet add up to 256 items then delete first 12.653 us/op 14.862 us/op 0.85
Set add up to 256 items then delete last 8.1345 us/op 10.048 us/op 0.81
OrderedSet add up to 256 items then delete last 12.901 us/op 15.746 us/op 0.82
Set add up to 256 items then delete middle 8.1030 us/op 10.078 us/op 0.80
OrderedSet add up to 256 items then delete middle 36.645 us/op 40.896 us/op 0.90
transfer serialized Status (84 B) 1.4210 us/op 1.5540 us/op 0.91
copy serialized Status (84 B) 1.2980 us/op 1.2770 us/op 1.02
transfer serialized SignedVoluntaryExit (112 B) 1.4990 us/op 1.7650 us/op 0.85
copy serialized SignedVoluntaryExit (112 B) 1.4140 us/op 1.3860 us/op 1.02
transfer serialized ProposerSlashing (416 B) 2.5460 us/op 2.1060 us/op 1.21
copy serialized ProposerSlashing (416 B) 1.9610 us/op 2.0780 us/op 0.94
transfer serialized Attestation (485 B) 1.7650 us/op 2.2760 us/op 0.78
copy serialized Attestation (485 B) 1.8930 us/op 2.0250 us/op 0.93
transfer serialized AttesterSlashing (33232 B) 2.5410 us/op 2.4490 us/op 1.04
copy serialized AttesterSlashing (33232 B) 5.3720 us/op 5.8070 us/op 0.93
transfer serialized Small SignedBeaconBlock (128000 B) 2.6780 us/op 3.7490 us/op 0.71
copy serialized Small SignedBeaconBlock (128000 B) 11.607 us/op 16.298 us/op 0.71
transfer serialized Avg SignedBeaconBlock (200000 B) 3.0530 us/op 4.1930 us/op 0.73
copy serialized Avg SignedBeaconBlock (200000 B) 16.134 us/op 23.067 us/op 0.70
transfer serialized BlobsSidecar (524380 B) 3.6030 us/op 3.4430 us/op 1.05
copy serialized BlobsSidecar (524380 B) 82.996 us/op 154.22 us/op 0.54
transfer serialized Big SignedBeaconBlock (1000000 B) 4.0480 us/op 3.1410 us/op 1.29
copy serialized Big SignedBeaconBlock (1000000 B) 236.85 us/op 161.32 us/op 1.47
pass gossip attestations to forkchoice per slot 2.5503 ms/op 2.8771 ms/op 0.89
forkChoice updateHead vc 100000 bc 64 eq 0 451.30 us/op 541.27 us/op 0.83
forkChoice updateHead vc 600000 bc 64 eq 0 2.5867 ms/op 3.1069 ms/op 0.83
forkChoice updateHead vc 1000000 bc 64 eq 0 4.3648 ms/op 5.4551 ms/op 0.80
forkChoice updateHead vc 600000 bc 320 eq 0 2.5617 ms/op 3.0965 ms/op 0.83
forkChoice updateHead vc 600000 bc 1200 eq 0 2.6248 ms/op 3.1378 ms/op 0.84
forkChoice updateHead vc 600000 bc 7200 eq 0 3.0914 ms/op 3.6403 ms/op 0.85
forkChoice updateHead vc 600000 bc 64 eq 1000 9.9043 ms/op 11.313 ms/op 0.88
forkChoice updateHead vc 600000 bc 64 eq 10000 9.5662 ms/op 10.895 ms/op 0.88
forkChoice updateHead vc 600000 bc 64 eq 300000 14.146 ms/op 14.660 ms/op 0.96
computeDeltas 500000 validators 300 proto nodes 3.1678 ms/op 3.5772 ms/op 0.89
computeDeltas 500000 validators 1200 proto nodes 3.4151 ms/op 3.6434 ms/op 0.94
computeDeltas 500000 validators 7200 proto nodes 3.3985 ms/op 3.6837 ms/op 0.92
computeDeltas 750000 validators 300 proto nodes 5.0341 ms/op 5.5141 ms/op 0.91
computeDeltas 750000 validators 1200 proto nodes 4.7731 ms/op 5.5944 ms/op 0.85
computeDeltas 750000 validators 7200 proto nodes 4.8337 ms/op 5.5464 ms/op 0.87
computeDeltas 1400000 validators 300 proto nodes 8.7196 ms/op 10.226 ms/op 0.85
computeDeltas 1400000 validators 1200 proto nodes 8.6531 ms/op 11.228 ms/op 0.77
computeDeltas 1400000 validators 7200 proto nodes 8.9342 ms/op 12.255 ms/op 0.73
computeDeltas 2100000 validators 300 proto nodes 13.583 ms/op 18.686 ms/op 0.73
computeDeltas 2100000 validators 1200 proto nodes 13.312 ms/op 21.374 ms/op 0.62
computeDeltas 2100000 validators 7200 proto nodes 13.646 ms/op 21.740 ms/op 0.63
altair processAttestation - 250000 vs - 7PWei normalcase 1.5113 ms/op 3.0531 ms/op 0.49
altair processAttestation - 250000 vs - 7PWei worstcase 3.3245 ms/op 4.6790 ms/op 0.71
altair processAttestation - setStatus - 1/6 committees join 73.350 us/op 175.49 us/op 0.42
altair processAttestation - setStatus - 1/3 committees join 159.76 us/op 333.91 us/op 0.48
altair processAttestation - setStatus - 1/2 committees join 210.34 us/op 413.75 us/op 0.51
altair processAttestation - setStatus - 2/3 committees join 293.50 us/op 551.04 us/op 0.53
altair processAttestation - setStatus - 4/5 committees join 438.08 us/op 951.70 us/op 0.46
altair processAttestation - setStatus - 100% committees join 514.62 us/op 1.1084 ms/op 0.46
altair processBlock - 250000 vs - 7PWei normalcase 4.5653 ms/op 8.1806 ms/op 0.56
altair processBlock - 250000 vs - 7PWei normalcase hashState 27.383 ms/op 49.672 ms/op 0.55
altair processBlock - 250000 vs - 7PWei worstcase 37.195 ms/op 62.955 ms/op 0.59
altair processBlock - 250000 vs - 7PWei worstcase hashState 77.053 ms/op 130.08 ms/op 0.59
phase0 processBlock - 250000 vs - 7PWei normalcase 3.0549 ms/op 4.2790 ms/op 0.71
phase0 processBlock - 250000 vs - 7PWei worstcase 27.071 ms/op 43.392 ms/op 0.62
altair processEth1Data - 250000 vs - 7PWei normalcase 456.76 us/op 586.51 us/op 0.78
getExpectedWithdrawals 250000 eb:1,eth1:1,we:0,wn:0,smpl:15 7.4710 us/op 8.4450 us/op 0.88
getExpectedWithdrawals 250000 eb:0.95,eth1:0.1,we:0.05,wn:0,smpl:219 32.302 us/op 50.562 us/op 0.64
getExpectedWithdrawals 250000 eb:0.95,eth1:0.3,we:0.05,wn:0,smpl:42 9.6890 us/op 15.088 us/op 0.64
getExpectedWithdrawals 250000 eb:0.95,eth1:0.7,we:0.05,wn:0,smpl:18 6.8340 us/op 9.1610 us/op 0.75
getExpectedWithdrawals 250000 eb:0.1,eth1:0.1,we:0,wn:0,smpl:1020 118.20 us/op 207.78 us/op 0.57
getExpectedWithdrawals 250000 eb:0.03,eth1:0.03,we:0,wn:0,smpl:11777 1.0052 ms/op 1.6493 ms/op 0.61
getExpectedWithdrawals 250000 eb:0.01,eth1:0.01,we:0,wn:0,smpl:16384 1.4791 ms/op 2.6131 ms/op 0.57
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,smpl:16384 1.2150 ms/op 2.3558 ms/op 0.52
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,nocache,smpl:16384 3.5021 ms/op 6.7542 ms/op 0.52
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,smpl:16384 1.6139 ms/op 2.5803 ms/op 0.63
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,nocache,smpl:16384 3.5861 ms/op 7.7101 ms/op 0.47
Tree 40 250000 create 197.16 ms/op 444.25 ms/op 0.44
Tree 40 250000 get(125000) 136.68 ns/op 323.11 ns/op 0.42
Tree 40 250000 set(125000) 566.52 ns/op 1.2928 us/op 0.44
Tree 40 250000 toArray() 22.891 ms/op 31.511 ms/op 0.73
Tree 40 250000 iterate all - toArray() + loop 28.087 ms/op 29.790 ms/op 0.94
Tree 40 250000 iterate all - get(i) 57.688 ms/op 102.45 ms/op 0.56
Array 250000 create 4.4420 ms/op 6.0243 ms/op 0.74
Array 250000 clone - spread 4.9431 ms/op 2.5110 ms/op 1.97
Array 250000 get(125000) 0.70700 ns/op 0.73900 ns/op 0.96
Array 250000 set(125000) 0.71100 ns/op 0.78200 ns/op 0.91
Array 250000 iterate all - loop 89.907 us/op 129.54 us/op 0.69
phase0 afterProcessEpoch - 250000 vs - 7PWei 78.155 ms/op 169.93 ms/op 0.46
Array.fill - length 1000000 3.5885 ms/op 6.8550 ms/op 0.52
Array push - length 1000000 22.699 ms/op 29.742 ms/op 0.76
Array.get 0.30064 ns/op 0.50197 ns/op 0.60
Uint8Array.get 0.41140 ns/op 0.78375 ns/op 0.52
phase0 beforeProcessEpoch - 250000 vs - 7PWei 29.702 ms/op 24.823 ms/op 1.20
altair processEpoch - mainnet_e81889 434.33 ms/op 620.13 ms/op 0.70
mainnet_e81889 - altair beforeProcessEpoch 29.138 ms/op 30.922 ms/op 0.94
mainnet_e81889 - altair processJustificationAndFinalization 22.910 us/op 20.389 us/op 1.12
mainnet_e81889 - altair processInactivityUpdates 7.2377 ms/op 9.9956 ms/op 0.72
mainnet_e81889 - altair processRewardsAndPenalties 65.482 ms/op 59.859 ms/op 1.09
mainnet_e81889 - altair processRegistryUpdates 4.3430 us/op 3.5520 us/op 1.22
mainnet_e81889 - altair processSlashings 1.1240 us/op 656.00 ns/op 1.71
mainnet_e81889 - altair processEth1DataReset 1.0450 us/op 787.00 ns/op 1.33
mainnet_e81889 - altair processEffectiveBalanceUpdates 1.2184 ms/op 5.0686 ms/op 0.24
mainnet_e81889 - altair processSlashingsReset 4.1940 us/op 11.092 us/op 0.38
mainnet_e81889 - altair processRandaoMixesReset 11.450 us/op 9.8090 us/op 1.17
mainnet_e81889 - altair processHistoricalRootsUpdate 1.2710 us/op 1.1190 us/op 1.14
mainnet_e81889 - altair processParticipationFlagUpdates 4.3960 us/op 11.772 us/op 0.37
mainnet_e81889 - altair processSyncCommitteeUpdates 957.00 ns/op 1.4600 us/op 0.66
mainnet_e81889 - altair afterProcessEpoch 83.577 ms/op 171.31 ms/op 0.49
capella processEpoch - mainnet_e217614 1.5954 s/op 2.7132 s/op 0.59
mainnet_e217614 - capella beforeProcessEpoch 104.57 ms/op 159.46 ms/op 0.66
mainnet_e217614 - capella processJustificationAndFinalization 32.248 us/op 29.822 us/op 1.08
mainnet_e217614 - capella processInactivityUpdates 25.626 ms/op 34.514 ms/op 0.74
mainnet_e217614 - capella processRewardsAndPenalties 298.26 ms/op 486.93 ms/op 0.61
mainnet_e217614 - capella processRegistryUpdates 19.577 us/op 50.394 us/op 0.39
mainnet_e217614 - capella processSlashings 1.2850 us/op 1.8730 us/op 0.69
mainnet_e217614 - capella processEth1DataReset 1.0800 us/op 700.00 ns/op 1.54
mainnet_e217614 - capella processEffectiveBalanceUpdates 21.825 ms/op 14.266 ms/op 1.53
mainnet_e217614 - capella processSlashingsReset 6.0850 us/op 15.480 us/op 0.39
mainnet_e217614 - capella processRandaoMixesReset 6.4440 us/op 18.586 us/op 0.35
mainnet_e217614 - capella processHistoricalRootsUpdate 1.2210 us/op 1.3960 us/op 0.87
mainnet_e217614 - capella processParticipationFlagUpdates 4.4320 us/op 8.3350 us/op 0.53
mainnet_e217614 - capella afterProcessEpoch 218.68 ms/op 790.57 ms/op 0.28
phase0 processEpoch - mainnet_e58758 477.01 ms/op 1.1300 s/op 0.42
mainnet_e58758 - phase0 beforeProcessEpoch 122.03 ms/op 185.32 ms/op 0.66
mainnet_e58758 - phase0 processJustificationAndFinalization 19.685 us/op 79.095 us/op 0.25
mainnet_e58758 - phase0 processRewardsAndPenalties 37.192 ms/op 67.429 ms/op 0.55
mainnet_e58758 - phase0 processRegistryUpdates 10.388 us/op 17.184 us/op 0.60
mainnet_e58758 - phase0 processSlashings 1.0720 us/op 966.00 ns/op 1.11
mainnet_e58758 - phase0 processEth1DataReset 988.00 ns/op 3.1630 us/op 0.31
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 1.2733 ms/op 3.1494 ms/op 0.40
mainnet_e58758 - phase0 processSlashingsReset 4.4680 us/op 6.4920 us/op 0.69
mainnet_e58758 - phase0 processRandaoMixesReset 10.457 us/op 11.552 us/op 0.91
mainnet_e58758 - phase0 processHistoricalRootsUpdate 1.2500 us/op 761.00 ns/op 1.64
mainnet_e58758 - phase0 processParticipationRecordUpdates 5.0720 us/op 7.8960 us/op 0.64
mainnet_e58758 - phase0 afterProcessEpoch 75.194 ms/op 131.99 ms/op 0.57
phase0 processEffectiveBalanceUpdates - 250000 normalcase 1.1925 ms/op 3.4186 ms/op 0.35
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 3.9229 ms/op 5.0776 ms/op 0.77
altair processInactivityUpdates - 250000 normalcase 21.783 ms/op 36.131 ms/op 0.60
altair processInactivityUpdates - 250000 worstcase 29.441 ms/op 36.927 ms/op 0.80
phase0 processRegistryUpdates - 250000 normalcase 15.222 us/op 10.274 us/op 1.48
phase0 processRegistryUpdates - 250000 badcase_full_deposits 505.59 us/op 496.67 us/op 1.02
phase0 processRegistryUpdates - 250000 worstcase 0.5 233.32 ms/op 310.30 ms/op 0.75
altair processRewardsAndPenalties - 250000 normalcase 53.693 ms/op 122.81 ms/op 0.44
altair processRewardsAndPenalties - 250000 worstcase 52.294 ms/op 113.15 ms/op 0.46
phase0 getAttestationDeltas - 250000 normalcase 8.1643 ms/op 18.886 ms/op 0.43
phase0 getAttestationDeltas - 250000 worstcase 8.5326 ms/op 15.163 ms/op 0.56
phase0 processSlashings - 250000 worstcase 100.93 us/op 135.64 us/op 0.74
altair processSyncCommitteeUpdates - 250000 133.79 ms/op 273.86 ms/op 0.49
BeaconState.hashTreeRoot - No change 602.00 ns/op 528.00 ns/op 1.14
BeaconState.hashTreeRoot - 1 full validator 124.25 us/op 212.48 us/op 0.58
BeaconState.hashTreeRoot - 32 full validator 1.2107 ms/op 2.2519 ms/op 0.54
BeaconState.hashTreeRoot - 512 full validator 13.189 ms/op 23.356 ms/op 0.56
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 180.66 us/op 244.07 us/op 0.74
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 2.8418 ms/op 3.4675 ms/op 0.82
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 27.028 ms/op 46.628 ms/op 0.58
BeaconState.hashTreeRoot - 1 balances 127.99 us/op 215.25 us/op 0.59
BeaconState.hashTreeRoot - 32 balances 1.1815 ms/op 1.9426 ms/op 0.61
BeaconState.hashTreeRoot - 512 balances 8.9842 ms/op 18.070 ms/op 0.50
BeaconState.hashTreeRoot - 250000 balances 201.70 ms/op 288.14 ms/op 0.70
aggregationBits - 2048 els - zipIndexesInBitList 41.667 us/op 45.931 us/op 0.91
byteArrayEquals 32 49.819 ns/op 97.563 ns/op 0.51
Buffer.compare 32 16.222 ns/op 30.400 ns/op 0.53
byteArrayEquals 1024 1.3137 us/op 2.7967 us/op 0.47
Buffer.compare 1024 24.026 ns/op 45.033 ns/op 0.53
byteArrayEquals 16384 20.706 us/op 44.303 us/op 0.47
Buffer.compare 16384 208.31 ns/op 361.19 ns/op 0.58
byteArrayEquals 123687377 157.30 ms/op 288.96 ms/op 0.54
Buffer.compare 123687377 6.9649 ms/op 6.2905 ms/op 1.11
byteArrayEquals 32 - diff last byte 53.257 ns/op 67.512 ns/op 0.79
Buffer.compare 32 - diff last byte 15.832 ns/op 21.242 ns/op 0.75
byteArrayEquals 1024 - diff last byte 1.2471 us/op 1.8260 us/op 0.68
Buffer.compare 1024 - diff last byte 31.103 ns/op 30.765 ns/op 1.01
byteArrayEquals 16384 - diff last byte 19.800 us/op 30.405 us/op 0.65
Buffer.compare 16384 - diff last byte 180.83 ns/op 240.75 ns/op 0.75
byteArrayEquals 123687377 - diff last byte 157.30 ms/op 219.41 ms/op 0.72
Buffer.compare 123687377 - diff last byte 5.4593 ms/op 6.7517 ms/op 0.81
byteArrayEquals 32 - random bytes 5.1210 ns/op 6.1980 ns/op 0.83
Buffer.compare 32 - random bytes 16.253 ns/op 20.215 ns/op 0.80
byteArrayEquals 1024 - random bytes 5.1780 ns/op 6.1590 ns/op 0.84
Buffer.compare 1024 - random bytes 16.001 ns/op 20.034 ns/op 0.80
byteArrayEquals 16384 - random bytes 5.1060 ns/op 5.8190 ns/op 0.88
Buffer.compare 16384 - random bytes 16.018 ns/op 19.867 ns/op 0.81
byteArrayEquals 123687377 - random bytes 8.1700 ns/op 6.8900 ns/op 1.19
Buffer.compare 123687377 - random bytes 19.110 ns/op 20.040 ns/op 0.95
regular array get 100000 times 31.653 us/op 34.322 us/op 0.92
wrappedArray get 100000 times 31.566 us/op 34.264 us/op 0.92
arrayWithProxy get 100000 times 10.444 ms/op 14.340 ms/op 0.73
ssz.Root.equals 45.649 ns/op 49.132 ns/op 0.93
byteArrayEquals 43.898 ns/op 48.231 ns/op 0.91
Buffer.compare 9.3370 ns/op 11.269 ns/op 0.83
shuffle list - 16384 els 5.6068 ms/op 6.7992 ms/op 0.82
shuffle list - 250000 els 83.983 ms/op 100.31 ms/op 0.84
processSlot - 1 slots 9.9560 us/op 15.658 us/op 0.64
processSlot - 32 slots 1.8191 ms/op 3.7654 ms/op 0.48
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 39.211 ms/op 43.308 ms/op 0.91
getCommitteeAssignments - req 1 vs - 250000 vc 1.8516 ms/op 2.5013 ms/op 0.74
getCommitteeAssignments - req 100 vs - 250000 vc 3.6162 ms/op 4.6619 ms/op 0.78
getCommitteeAssignments - req 1000 vs - 250000 vc 3.9159 ms/op 5.7165 ms/op 0.69
findModifiedValidators - 10000 modified validators 225.48 ms/op 269.04 ms/op 0.84
findModifiedValidators - 1000 modified validators 165.28 ms/op 214.74 ms/op 0.77
findModifiedValidators - 100 modified validators 144.09 ms/op 205.88 ms/op 0.70
findModifiedValidators - 10 modified validators 132.82 ms/op 166.01 ms/op 0.80
findModifiedValidators - 1 modified validators 122.24 ms/op 178.27 ms/op 0.69
findModifiedValidators - no difference 138.93 ms/op 185.52 ms/op 0.75
compare ViewDUs 3.0715 s/op 3.3685 s/op 0.91
compare each validator Uint8Array 1.2309 s/op 1.4752 s/op 0.83
compare ViewDU to Uint8Array 970.75 ms/op 1.2608 s/op 0.77
migrate state 1000000 validators, 24 modified, 0 new 860.25 ms/op 1.0006 s/op 0.86
migrate state 1000000 validators, 1700 modified, 1000 new 1.0742 s/op 1.5480 s/op 0.69
migrate state 1000000 validators, 3400 modified, 2000 new 1.1829 s/op 1.9752 s/op 0.60
migrate state 1500000 validators, 24 modified, 0 new 791.74 ms/op 1.4120 s/op 0.56
migrate state 1500000 validators, 1700 modified, 1000 new 1.0206 s/op 1.7550 s/op 0.58
migrate state 1500000 validators, 3400 modified, 2000 new 1.2920 s/op 2.0674 s/op 0.62
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 6.7200 ns/op 6.4700 ns/op 1.04
state getBlockRootAtSlot - 250000 vs - 7PWei 844.37 ns/op 856.23 ns/op 0.99
computeProposers - vc 250000 6.3071 ms/op 11.267 ms/op 0.56
computeEpochShuffling - vc 250000 83.848 ms/op 115.33 ms/op 0.73
getNextSyncCommittee - vc 250000 107.84 ms/op 165.33 ms/op 0.65
computeSigningRoot for AttestationData 28.521 us/op 33.037 us/op 0.86
hash AttestationData serialized data then Buffer.toString(base64) 1.1722 us/op 2.2376 us/op 0.52
toHexString serialized data 788.06 ns/op 1.2925 us/op 0.61
Buffer.toString(base64) 157.39 ns/op 314.94 ns/op 0.50
nodejs block root to RootHex using toHex 125.36 ns/op 258.32 ns/op 0.49
nodejs block root to RootHex using toRootHex 80.507 ns/op 149.82 ns/op 0.54
browser block root to RootHex using the deprecated toHexString 214.29 ns/op 355.88 ns/op 0.60
browser block root to RootHex using toHex 168.43 ns/op 350.13 ns/op 0.48
browser block root to RootHex using toRootHex 159.31 ns/op 280.05 ns/op 0.57

by benchmarkbot/action

@nflaig nflaig marked this pull request as ready for review September 23, 2024 16:45
@nflaig nflaig requested a review from a team as a code owner September 23, 2024 16:45
@nflaig
Copy link
Member Author

nflaig commented Sep 23, 2024

spec PRs have been merged, I think we can merge this before web3signer has a release that supports electra

Copy link
Contributor

@ensi321 ensi321 left a comment

Choose a reason for hiding this comment

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

lgtm. Minor comment.

Not familiar with the deprecation schedule of remote signing api. When can we safely remove AGGREGATE_AND_PROOF?

@nflaig
Copy link
Member Author

nflaig commented Sep 25, 2024

Not familiar with the deprecation schedule of remote signing api. When can we safely remove AGGREGATE_AND_PROOF?

Since we only implement the client-side here, we can just stop using the v1 after electra fork on mainnet, all remote signers need to implement the v2 type until then, otherwise they won't be able to support post-electra aggregate signing.

we can include that in our post-electra api cleanup

@wemeetagain wemeetagain merged commit bb82046 into unstable Sep 26, 2024
20 checks passed
@wemeetagain wemeetagain deleted the nflaig/remote-signer-electra branch September 26, 2024 20:01
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