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

fix: correctly persist states based on archive epoch frequency #5979

Merged
merged 1 commit into from
Sep 22, 2023

Conversation

nflaig
Copy link
Member

@nflaig nflaig commented Sep 21, 2023

Motivation

Closes #5976

Description

Setting --chain.archiveStateEpochFrequency 1 should persist a state every epoch and not prune any previously stored states. This allows to download finalized states (#5846) by providing the start slot of the epoch (epoch * SLOTS_PER_EPOCH).

Sep-21 16:32:00.667[chain]         verbose: Archived state completed finalizedEpoch=205203, minEpoch=205202, storedStateSlots=6566464, statesSlotsToDelete=
Sep-21 16:38:24.702[chain]         verbose: Archived state completed finalizedEpoch=205204, minEpoch=205203, storedStateSlots=6566496, statesSlotsToDelete=
Sep-21 16:44:48.615[chain]         verbose: Archived state completed finalizedEpoch=205205, minEpoch=205204, storedStateSlots=6566528, statesSlotsToDelete=
Sep-21 16:51:12.671[chain]         verbose: Archived state completed finalizedEpoch=205206, minEpoch=205205, storedStateSlots=6566560, statesSlotsToDelete=
Sep-21 16:57:36.735[chain]         verbose: Archived state completed finalizedEpoch=205207, minEpoch=205206, storedStateSlots=6566592, statesSlotsToDelete=
Sep-21 17:04:00.898[chain]         verbose: Archived state completed finalizedEpoch=205208, minEpoch=205207, storedStateSlots=6566624, statesSlotsToDelete=
Sep-21 17:10:24.685[chain]         verbose: Archived state completed finalizedEpoch=205209, minEpoch=205208, storedStateSlots=6566656, statesSlotsToDelete=
Sep-21 17:16:48.791[chain]         verbose: Archived state completed finalizedEpoch=205210, minEpoch=205209, storedStateSlots=6566688, statesSlotsToDelete=
Sep-21 17:23:12.714[chain]         verbose: Archived state completed finalizedEpoch=205211, minEpoch=205210, storedStateSlots=6566720, statesSlotsToDelete=

@nflaig nflaig requested a review from a team as a code owner September 21, 2023 15:30
@github-actions
Copy link
Contributor

github-actions bot commented Sep 21, 2023

Performance Report

✔️ no performance regression detected

Full benchmark results
Benchmark suite Current: 870c9e3 Previous: 4fd3d4d Ratio
getPubkeys - index2pubkey - req 1000 vs - 250000 vc 549.71 us/op 371.23 us/op 1.48
getPubkeys - validatorsArr - req 1000 vs - 250000 vc 86.361 us/op 46.649 us/op 1.85
BLS verify - blst-native 1.3312 ms/op 1.0971 ms/op 1.21
BLS verifyMultipleSignatures 3 - blst-native 2.8057 ms/op 2.3688 ms/op 1.18
BLS verifyMultipleSignatures 8 - blst-native 6.5782 ms/op 5.0347 ms/op 1.31
BLS verifyMultipleSignatures 32 - blst-native 22.649 ms/op 18.746 ms/op 1.21
BLS verifyMultipleSignatures 64 - blst-native 44.946 ms/op 39.066 ms/op 1.15
BLS verifyMultipleSignatures 128 - blst-native 88.445 ms/op 73.104 ms/op 1.21
BLS deserializing 10000 signatures 909.30 ms/op 777.11 ms/op 1.17
BLS deserializing 100000 signatures 9.2717 s/op 7.9852 s/op 1.16
BLS verifyMultipleSignatures - same message - 3 - blst-native 1.3733 ms/op 1.1714 ms/op 1.17
BLS verifyMultipleSignatures - same message - 8 - blst-native 1.5352 ms/op 1.2914 ms/op 1.19
BLS verifyMultipleSignatures - same message - 32 - blst-native 2.3750 ms/op 2.1296 ms/op 1.12
BLS verifyMultipleSignatures - same message - 64 - blst-native 3.4891 ms/op 3.0462 ms/op 1.15
BLS verifyMultipleSignatures - same message - 128 - blst-native 6.3315 ms/op 5.3830 ms/op 1.18
BLS aggregatePubkeys 32 - blst-native 26.047 us/op 23.532 us/op 1.11
BLS aggregatePubkeys 128 - blst-native 101.73 us/op 87.781 us/op 1.16
getAttestationsForBlock 52.068 ms/op 35.675 ms/op 1.46
isKnown best case - 1 super set check 365.00 ns/op 480.00 ns/op 0.76
isKnown normal case - 2 super set checks 409.00 ns/op 366.00 ns/op 1.12
isKnown worse case - 16 super set checks 415.00 ns/op 328.00 ns/op 1.27
CheckpointStateCache - add get delete 6.0660 us/op 4.1750 us/op 1.45
validate api signedAggregateAndProof - struct 2.9171 ms/op 2.3785 ms/op 1.23
validate gossip signedAggregateAndProof - struct 2.9011 ms/op 2.3849 ms/op 1.22
validate gossip attestation - vc 640000 1.4242 ms/op 1.1619 ms/op 1.23
batch validate gossip attestation - vc 640000 - chunk 32 173.97 us/op 145.22 us/op 1.20
batch validate gossip attestation - vc 640000 - chunk 64 153.95 us/op 127.26 us/op 1.21
batch validate gossip attestation - vc 640000 - chunk 128 143.79 us/op 109.77 us/op 1.31
batch validate gossip attestation - vc 640000 - chunk 256 134.45 us/op 108.90 us/op 1.23
pickEth1Vote - no votes 1.2237 ms/op 836.17 us/op 1.46
pickEth1Vote - max votes 8.8499 ms/op 8.6167 ms/op 1.03
pickEth1Vote - Eth1Data hashTreeRoot value x2048 16.295 ms/op 15.251 ms/op 1.07
pickEth1Vote - Eth1Data hashTreeRoot tree x2048 22.604 ms/op 16.148 ms/op 1.40
pickEth1Vote - Eth1Data fastSerialize value x2048 615.59 us/op 407.20 us/op 1.51
pickEth1Vote - Eth1Data fastSerialize tree x2048 4.9037 ms/op 3.5510 ms/op 1.38
bytes32 toHexString 534.00 ns/op 448.00 ns/op 1.19
bytes32 Buffer.toString(hex) 290.00 ns/op 342.00 ns/op 0.85
bytes32 Buffer.toString(hex) from Uint8Array 428.00 ns/op 512.00 ns/op 0.84
bytes32 Buffer.toString(hex) + 0x 295.00 ns/op 333.00 ns/op 0.89
Object access 1 prop 0.16600 ns/op 0.21800 ns/op 0.76
Map access 1 prop 0.15700 ns/op 0.19300 ns/op 0.81
Object get x1000 7.3970 ns/op 5.4820 ns/op 1.35
Map get x1000 0.64100 ns/op 0.58500 ns/op 1.10
Object set x1000 50.891 ns/op 24.437 ns/op 2.08
Map set x1000 45.145 ns/op 17.411 ns/op 2.59
Return object 10000 times 0.25540 ns/op 0.24140 ns/op 1.06
Throw Error 10000 times 3.9200 us/op 2.8445 us/op 1.38
fastMsgIdFn sha256 / 200 bytes 3.3980 us/op 2.1330 us/op 1.59
fastMsgIdFn h32 xxhash / 200 bytes 312.00 ns/op 324.00 ns/op 0.96
fastMsgIdFn h64 xxhash / 200 bytes 365.00 ns/op 389.00 ns/op 0.94
fastMsgIdFn sha256 / 1000 bytes 11.860 us/op 6.4500 us/op 1.84
fastMsgIdFn h32 xxhash / 1000 bytes 452.00 ns/op 441.00 ns/op 1.02
fastMsgIdFn h64 xxhash / 1000 bytes 464.00 ns/op 465.00 ns/op 1.00
fastMsgIdFn sha256 / 10000 bytes 108.24 us/op 55.020 us/op 1.97
fastMsgIdFn h32 xxhash / 10000 bytes 2.0530 us/op 1.9030 us/op 1.08
fastMsgIdFn h64 xxhash / 10000 bytes 1.4130 us/op 1.3230 us/op 1.07
send data - 1000 256B messages 20.122 ms/op 14.890 ms/op 1.35
send data - 1000 512B messages 27.663 ms/op 18.735 ms/op 1.48
send data - 1000 1024B messages 43.087 ms/op 26.541 ms/op 1.62
send data - 1000 1200B messages 29.684 ms/op 23.893 ms/op 1.24
send data - 1000 2048B messages 36.088 ms/op 25.708 ms/op 1.40
send data - 1000 4096B messages 37.467 ms/op 25.367 ms/op 1.48
send data - 1000 16384B messages 73.281 ms/op 56.487 ms/op 1.30
send data - 1000 65536B messages 296.99 ms/op 229.14 ms/op 1.30
enrSubnets - fastDeserialize 64 bits 1.3240 us/op 912.00 ns/op 1.45
enrSubnets - ssz BitVector 64 bits 494.00 ns/op 429.00 ns/op 1.15
enrSubnets - fastDeserialize 4 bits 192.00 ns/op 196.00 ns/op 0.98
enrSubnets - ssz BitVector 4 bits 445.00 ns/op 420.00 ns/op 1.06
prioritizePeers score -10:0 att 32-0.1 sync 2-0 109.06 us/op 65.881 us/op 1.66
prioritizePeers score 0:0 att 32-0.25 sync 2-0.25 133.41 us/op 75.621 us/op 1.76
prioritizePeers score 0:0 att 32-0.5 sync 2-0.5 170.67 us/op 101.63 us/op 1.68
prioritizePeers score 0:0 att 64-0.75 sync 4-0.75 296.47 us/op 179.06 us/op 1.66
prioritizePeers score 0:0 att 64-1 sync 4-1 356.17 us/op 204.55 us/op 1.74
array of 16000 items push then shift 1.7013 us/op 1.3092 us/op 1.30
LinkedList of 16000 items push then shift 9.1170 ns/op 5.9650 ns/op 1.53
array of 16000 items push then pop 80.000 ns/op 52.410 ns/op 1.53
LinkedList of 16000 items push then pop 9.0310 ns/op 5.6840 ns/op 1.59
array of 24000 items push then shift 2.5925 us/op 1.9046 us/op 1.36
LinkedList of 24000 items push then shift 9.6410 ns/op 6.0980 ns/op 1.58
array of 24000 items push then pop 125.17 ns/op 107.07 ns/op 1.17
LinkedList of 24000 items push then pop 8.7990 ns/op 5.7700 ns/op 1.52
intersect bitArray bitLen 8 7.0010 ns/op 5.8060 ns/op 1.21
intersect array and set length 8 60.456 ns/op 41.610 ns/op 1.45
intersect bitArray bitLen 128 33.065 ns/op 26.042 ns/op 1.27
intersect array and set length 128 848.62 ns/op 580.14 ns/op 1.46
bitArray.getTrueBitIndexes() bitLen 128 1.5870 us/op 1.2520 us/op 1.27
bitArray.getTrueBitIndexes() bitLen 248 2.6480 us/op 2.0040 us/op 1.32
bitArray.getTrueBitIndexes() bitLen 512 5.5470 us/op 3.9490 us/op 1.40
Buffer.concat 32 items 992.00 ns/op 817.00 ns/op 1.21
Uint8Array.set 32 items 2.1890 us/op 1.9330 us/op 1.13
Set add up to 64 items then delete first 4.3554 us/op 1.7798 us/op 2.45
OrderedSet add up to 64 items then delete first 5.5034 us/op 2.5549 us/op 2.15
Set add up to 64 items then delete last 4.6992 us/op 1.9264 us/op 2.44
OrderedSet add up to 64 items then delete last 6.4251 us/op 3.0765 us/op 2.09
Set add up to 64 items then delete middle 4.9213 us/op 1.9451 us/op 2.53
OrderedSet add up to 64 items then delete middle 7.2168 us/op 4.3103 us/op 1.67
Set add up to 128 items then delete first 9.9564 us/op 3.7512 us/op 2.65
OrderedSet add up to 128 items then delete first 12.701 us/op 5.6037 us/op 2.27
Set add up to 128 items then delete last 10.126 us/op 3.7592 us/op 2.69
OrderedSet add up to 128 items then delete last 12.510 us/op 6.0823 us/op 2.06
Set add up to 128 items then delete middle 9.5514 us/op 3.7995 us/op 2.51
OrderedSet add up to 128 items then delete middle 18.044 us/op 10.689 us/op 1.69
Set add up to 256 items then delete first 19.547 us/op 7.4795 us/op 2.61
OrderedSet add up to 256 items then delete first 26.092 us/op 11.173 us/op 2.34
Set add up to 256 items then delete last 19.242 us/op 7.8491 us/op 2.45
OrderedSet add up to 256 items then delete last 24.332 us/op 12.354 us/op 1.97
Set add up to 256 items then delete middle 19.583 us/op 8.0013 us/op 2.45
OrderedSet add up to 256 items then delete middle 49.190 us/op 31.978 us/op 1.54
transfer serialized Status (84 B) 1.8380 us/op 1.6070 us/op 1.14
copy serialized Status (84 B) 1.5920 us/op 1.4460 us/op 1.10
transfer serialized SignedVoluntaryExit (112 B) 1.9580 us/op 1.9330 us/op 1.01
copy serialized SignedVoluntaryExit (112 B) 1.6050 us/op 1.6390 us/op 0.98
transfer serialized ProposerSlashing (416 B) 2.6890 us/op 2.4340 us/op 1.10
copy serialized ProposerSlashing (416 B) 2.4340 us/op 2.2130 us/op 1.10
transfer serialized Attestation (485 B) 2.7220 us/op 2.0740 us/op 1.31
copy serialized Attestation (485 B) 2.3630 us/op 2.0310 us/op 1.16
transfer serialized AttesterSlashing (33232 B) 2.6940 us/op 1.8090 us/op 1.49
copy serialized AttesterSlashing (33232 B) 7.1630 us/op 5.5290 us/op 1.30
transfer serialized Small SignedBeaconBlock (128000 B) 2.8110 us/op 2.3810 us/op 1.18
copy serialized Small SignedBeaconBlock (128000 B) 20.423 us/op 17.429 us/op 1.17
transfer serialized Avg SignedBeaconBlock (200000 B) 3.2740 us/op 2.2830 us/op 1.43
copy serialized Avg SignedBeaconBlock (200000 B) 29.745 us/op 21.680 us/op 1.37
transfer serialized BlobsSidecar (524380 B) 3.4650 us/op 2.7960 us/op 1.24
copy serialized BlobsSidecar (524380 B) 108.78 us/op 94.017 us/op 1.16
transfer serialized Big SignedBeaconBlock (1000000 B) 3.9840 us/op 3.5010 us/op 1.14
copy serialized Big SignedBeaconBlock (1000000 B) 161.02 us/op 215.54 us/op 0.75
pass gossip attestations to forkchoice per slot 3.8897 ms/op 2.7215 ms/op 1.43
forkChoice updateHead vc 100000 bc 64 eq 0 698.53 us/op 498.56 us/op 1.40
forkChoice updateHead vc 600000 bc 64 eq 0 5.0780 ms/op 2.6641 ms/op 1.91
forkChoice updateHead vc 1000000 bc 64 eq 0 8.0108 ms/op 4.4182 ms/op 1.81
forkChoice updateHead vc 600000 bc 320 eq 0 4.5030 ms/op 2.6986 ms/op 1.67
forkChoice updateHead vc 600000 bc 1200 eq 0 5.0210 ms/op 2.7587 ms/op 1.82
forkChoice updateHead vc 600000 bc 7200 eq 0 5.8311 ms/op 3.4259 ms/op 1.70
forkChoice updateHead vc 600000 bc 64 eq 1000 12.111 ms/op 10.129 ms/op 1.20
forkChoice updateHead vc 600000 bc 64 eq 10000 12.519 ms/op 9.8776 ms/op 1.27
forkChoice updateHead vc 600000 bc 64 eq 300000 19.553 ms/op 12.285 ms/op 1.59
computeDeltas 500000 validators 300 proto nodes 6.6373 ms/op 3.1907 ms/op 2.08
computeDeltas 500000 validators 1200 proto nodes 6.5937 ms/op 3.0704 ms/op 2.15
computeDeltas 500000 validators 7200 proto nodes 6.3531 ms/op 3.0831 ms/op 2.06
computeDeltas 750000 validators 300 proto nodes 9.4815 ms/op 5.2361 ms/op 1.81
computeDeltas 750000 validators 1200 proto nodes 9.6150 ms/op 4.4139 ms/op 2.18
computeDeltas 750000 validators 7200 proto nodes 10.389 ms/op 4.5308 ms/op 2.29
computeDeltas 1400000 validators 300 proto nodes 19.896 ms/op 8.4076 ms/op 2.37
computeDeltas 1400000 validators 1200 proto nodes 22.721 ms/op 8.3718 ms/op 2.71
computeDeltas 1400000 validators 7200 proto nodes 23.985 ms/op 8.5058 ms/op 2.82
computeDeltas 2100000 validators 300 proto nodes 32.306 ms/op 12.492 ms/op 2.59
computeDeltas 2100000 validators 1200 proto nodes 30.277 ms/op 12.669 ms/op 2.39
computeDeltas 2100000 validators 7200 proto nodes 27.359 ms/op 12.849 ms/op 2.13
computeProposerBoostScoreFromBalances 500000 validators 3.2990 ms/op 2.7331 ms/op 1.21
computeProposerBoostScoreFromBalances 750000 validators 3.3210 ms/op 2.7240 ms/op 1.22
computeProposerBoostScoreFromBalances 1400000 validators 3.3943 ms/op 2.7249 ms/op 1.25
computeProposerBoostScoreFromBalances 2100000 validators 3.4503 ms/op 2.7780 ms/op 1.24
altair processAttestation - 250000 vs - 7PWei normalcase 3.2294 ms/op 2.0245 ms/op 1.60
altair processAttestation - 250000 vs - 7PWei worstcase 3.5853 ms/op 4.6021 ms/op 0.78
altair processAttestation - setStatus - 1/6 committees join 212.80 us/op 146.42 us/op 1.45
altair processAttestation - setStatus - 1/3 committees join 440.61 us/op 254.24 us/op 1.73
altair processAttestation - setStatus - 1/2 committees join 553.39 us/op 285.11 us/op 1.94
altair processAttestation - setStatus - 2/3 committees join 632.22 us/op 353.10 us/op 1.79
altair processAttestation - setStatus - 4/5 committees join 1.0248 ms/op 498.47 us/op 2.06
altair processAttestation - setStatus - 100% committees join 1.1450 ms/op 587.87 us/op 1.95
altair processBlock - 250000 vs - 7PWei normalcase 8.5962 ms/op 7.4797 ms/op 1.15
altair processBlock - 250000 vs - 7PWei normalcase hashState 34.844 ms/op 30.936 ms/op 1.13
altair processBlock - 250000 vs - 7PWei worstcase 42.820 ms/op 38.346 ms/op 1.12
altair processBlock - 250000 vs - 7PWei worstcase hashState 105.70 ms/op 106.22 ms/op 1.00
phase0 processBlock - 250000 vs - 7PWei normalcase 3.3708 ms/op 2.8492 ms/op 1.18
phase0 processBlock - 250000 vs - 7PWei worstcase 35.049 ms/op 30.404 ms/op 1.15
altair processEth1Data - 250000 vs - 7PWei normalcase 579.34 us/op 528.23 us/op 1.10
getExpectedWithdrawals 250000 eb:1,eth1:1,we:0,wn:0,smpl:15 15.148 us/op 17.663 us/op 0.86
getExpectedWithdrawals 250000 eb:0.95,eth1:0.1,we:0.05,wn:0,smpl:219 96.248 us/op 63.197 us/op 1.52
getExpectedWithdrawals 250000 eb:0.95,eth1:0.3,we:0.05,wn:0,smpl:42 33.290 us/op 28.843 us/op 1.15
getExpectedWithdrawals 250000 eb:0.95,eth1:0.7,we:0.05,wn:0,smpl:18 25.147 us/op 16.938 us/op 1.48
getExpectedWithdrawals 250000 eb:0.1,eth1:0.1,we:0,wn:0,smpl:1020 229.44 us/op 136.80 us/op 1.68
getExpectedWithdrawals 250000 eb:0.03,eth1:0.03,we:0,wn:0,smpl:11777 1.7311 ms/op 1.2261 ms/op 1.41
getExpectedWithdrawals 250000 eb:0.01,eth1:0.01,we:0,wn:0,smpl:16384 2.4137 ms/op 1.6229 ms/op 1.49
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,smpl:16384 2.1959 ms/op 1.7146 ms/op 1.28
getExpectedWithdrawals 250000 eb:0,eth1:0,we:0,wn:0,nocache,smpl:16384 5.0860 ms/op 4.5458 ms/op 1.12
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,smpl:16384 3.0882 ms/op 2.5553 ms/op 1.21
getExpectedWithdrawals 250000 eb:0,eth1:1,we:0,wn:0,nocache,smpl:16384 8.4410 ms/op 7.8059 ms/op 1.08
Tree 40 250000 create 440.87 ms/op 396.89 ms/op 1.11
Tree 40 250000 get(125000) 215.49 ns/op 136.52 ns/op 1.58
Tree 40 250000 set(125000) 1.0439 us/op 1.7306 us/op 0.60
Tree 40 250000 toArray() 27.948 ms/op 21.623 ms/op 1.29
Tree 40 250000 iterate all - toArray() + loop 25.480 ms/op 21.315 ms/op 1.20
Tree 40 250000 iterate all - get(i) 77.206 ms/op 63.025 ms/op 1.23
MutableVector 250000 create 15.325 ms/op 7.0154 ms/op 2.18
MutableVector 250000 get(125000) 7.0000 ns/op 6.0600 ns/op 1.16
MutableVector 250000 set(125000) 299.53 ns/op 197.51 ns/op 1.52
MutableVector 250000 toArray() 4.1672 ms/op 2.4733 ms/op 1.68
MutableVector 250000 iterate all - toArray() + loop 4.1911 ms/op 2.8153 ms/op 1.49
MutableVector 250000 iterate all - get(i) 1.5823 ms/op 1.3921 ms/op 1.14
Array 250000 create 3.7095 ms/op 2.6213 ms/op 1.42
Array 250000 clone - spread 1.2892 ms/op 1.1307 ms/op 1.14
Array 250000 get(125000) 0.60700 ns/op 0.61100 ns/op 0.99
Array 250000 set(125000) 0.64500 ns/op 0.69200 ns/op 0.93
Array 250000 iterate all - loop 85.798 us/op 83.537 us/op 1.03
effectiveBalanceIncrements clone Uint8Array 300000 46.983 us/op 13.024 us/op 3.61
effectiveBalanceIncrements clone MutableVector 300000 332.00 ns/op 371.00 ns/op 0.89
effectiveBalanceIncrements rw all Uint8Array 300000 191.42 us/op 174.49 us/op 1.10
effectiveBalanceIncrements rw all MutableVector 300000 109.36 ms/op 68.933 ms/op 1.59
phase0 afterProcessEpoch - 250000 vs - 7PWei 121.71 ms/op 84.636 ms/op 1.44
phase0 beforeProcessEpoch - 250000 vs - 7PWei 47.016 ms/op 33.180 ms/op 1.42
altair processEpoch - mainnet_e81889 535.45 ms/op 441.64 ms/op 1.21
mainnet_e81889 - altair beforeProcessEpoch 62.123 ms/op 63.976 ms/op 0.97
mainnet_e81889 - altair processJustificationAndFinalization 20.080 us/op 21.485 us/op 0.93
mainnet_e81889 - altair processInactivityUpdates 10.588 ms/op 5.7925 ms/op 1.83
mainnet_e81889 - altair processRewardsAndPenalties 58.078 ms/op 44.878 ms/op 1.29
mainnet_e81889 - altair processRegistryUpdates 3.1340 us/op 4.4970 us/op 0.70
mainnet_e81889 - altair processSlashings 842.00 ns/op 1.0130 us/op 0.83
mainnet_e81889 - altair processEth1DataReset 1.4320 us/op 1.0410 us/op 1.38
mainnet_e81889 - altair processEffectiveBalanceUpdates 1.3813 ms/op 1.4204 ms/op 0.97
mainnet_e81889 - altair processSlashingsReset 5.5250 us/op 5.9660 us/op 0.93
mainnet_e81889 - altair processRandaoMixesReset 7.9060 us/op 9.0780 us/op 0.87
mainnet_e81889 - altair processHistoricalRootsUpdate 1.9500 us/op 1.8780 us/op 1.04
mainnet_e81889 - altair processParticipationFlagUpdates 3.1020 us/op 4.2480 us/op 0.73
mainnet_e81889 - altair processSyncCommitteeUpdates 1.0610 us/op 1.3870 us/op 0.76
mainnet_e81889 - altair afterProcessEpoch 134.22 ms/op 89.061 ms/op 1.51
capella processEpoch - mainnet_e217614 1.6359 s/op 1.6140 s/op 1.01
mainnet_e217614 - capella beforeProcessEpoch 302.55 ms/op 260.02 ms/op 1.16
mainnet_e217614 - capella processJustificationAndFinalization 25.961 us/op 21.300 us/op 1.22
mainnet_e217614 - capella processInactivityUpdates 23.984 ms/op 18.957 ms/op 1.27
mainnet_e217614 - capella processRewardsAndPenalties 301.54 ms/op 280.89 ms/op 1.07
mainnet_e217614 - capella processRegistryUpdates 25.333 us/op 29.201 us/op 0.87
mainnet_e217614 - capella processSlashings 775.00 ns/op 1.2210 us/op 0.63
mainnet_e217614 - capella processEth1DataReset 653.00 ns/op 1.5260 us/op 0.43
mainnet_e217614 - capella processEffectiveBalanceUpdates 4.2474 ms/op 3.2881 ms/op 1.29
mainnet_e217614 - capella processSlashingsReset 3.4110 us/op 5.4330 us/op 0.63
mainnet_e217614 - capella processRandaoMixesReset 4.4170 us/op 8.8300 us/op 0.50
mainnet_e217614 - capella processHistoricalRootsUpdate 648.00 ns/op 1.5450 us/op 0.42
mainnet_e217614 - capella processParticipationFlagUpdates 2.4640 us/op 3.3980 us/op 0.73
mainnet_e217614 - capella afterProcessEpoch 315.03 ms/op 226.82 ms/op 1.39
phase0 processEpoch - mainnet_e58758 460.70 ms/op 430.35 ms/op 1.07
mainnet_e58758 - phase0 beforeProcessEpoch 122.53 ms/op 127.51 ms/op 0.96
mainnet_e58758 - phase0 processJustificationAndFinalization 19.158 us/op 23.475 us/op 0.82
mainnet_e58758 - phase0 processRewardsAndPenalties 50.776 ms/op 48.035 ms/op 1.06
mainnet_e58758 - phase0 processRegistryUpdates 14.843 us/op 14.467 us/op 1.03
mainnet_e58758 - phase0 processSlashings 1.0620 us/op 1.4010 us/op 0.76
mainnet_e58758 - phase0 processEth1DataReset 942.00 ns/op 1.2910 us/op 0.73
mainnet_e58758 - phase0 processEffectiveBalanceUpdates 1.3158 ms/op 963.95 us/op 1.36
mainnet_e58758 - phase0 processSlashingsReset 3.5290 us/op 5.0630 us/op 0.70
mainnet_e58758 - phase0 processRandaoMixesReset 6.8900 us/op 8.9350 us/op 0.77
mainnet_e58758 - phase0 processHistoricalRootsUpdate 953.00 ns/op 1.3450 us/op 0.71
mainnet_e58758 - phase0 processParticipationRecordUpdates 6.1480 us/op 8.9100 us/op 0.69
mainnet_e58758 - phase0 afterProcessEpoch 112.69 ms/op 77.285 ms/op 1.46
phase0 processEffectiveBalanceUpdates - 250000 normalcase 1.6225 ms/op 1.4524 ms/op 1.12
phase0 processEffectiveBalanceUpdates - 250000 worstcase 0.5 1.5186 ms/op 1.8203 ms/op 0.83
altair processInactivityUpdates - 250000 normalcase 22.599 ms/op 14.859 ms/op 1.52
altair processInactivityUpdates - 250000 worstcase 24.633 ms/op 20.653 ms/op 1.19
phase0 processRegistryUpdates - 250000 normalcase 13.998 us/op 12.514 us/op 1.12
phase0 processRegistryUpdates - 250000 badcase_full_deposits 444.93 us/op 388.22 us/op 1.15
phase0 processRegistryUpdates - 250000 worstcase 0.5 149.66 ms/op 117.95 ms/op 1.27
altair processRewardsAndPenalties - 250000 normalcase 58.678 ms/op 51.045 ms/op 1.15
altair processRewardsAndPenalties - 250000 worstcase 53.654 ms/op 47.491 ms/op 1.13
phase0 getAttestationDeltas - 250000 normalcase 9.4746 ms/op 6.2889 ms/op 1.51
phase0 getAttestationDeltas - 250000 worstcase 8.9372 ms/op 6.2639 ms/op 1.43
phase0 processSlashings - 250000 worstcase 2.4657 ms/op 2.2702 ms/op 1.09
altair processSyncCommitteeUpdates - 250000 162.99 ms/op 125.85 ms/op 1.30
BeaconState.hashTreeRoot - No change 334.00 ns/op 410.00 ns/op 0.81
BeaconState.hashTreeRoot - 1 full validator 156.76 us/op 139.38 us/op 1.12
BeaconState.hashTreeRoot - 32 full validator 1.9062 ms/op 1.3351 ms/op 1.43
BeaconState.hashTreeRoot - 512 full validator 19.662 ms/op 10.993 ms/op 1.79
BeaconState.hashTreeRoot - 1 validator.effectiveBalance 231.44 us/op 117.08 us/op 1.98
BeaconState.hashTreeRoot - 32 validator.effectiveBalance 2.7302 ms/op 1.5529 ms/op 1.76
BeaconState.hashTreeRoot - 512 validator.effectiveBalance 36.238 ms/op 20.773 ms/op 1.74
BeaconState.hashTreeRoot - 1 balances 168.15 us/op 101.19 us/op 1.66
BeaconState.hashTreeRoot - 32 balances 1.5714 ms/op 864.13 us/op 1.82
BeaconState.hashTreeRoot - 512 balances 14.211 ms/op 9.2113 ms/op 1.54
BeaconState.hashTreeRoot - 250000 balances 223.52 ms/op 228.66 ms/op 0.98
aggregationBits - 2048 els - zipIndexesInBitList 22.691 us/op 29.284 us/op 0.77
regular array get 100000 times 45.718 us/op 31.538 us/op 1.45
wrappedArray get 100000 times 35.578 us/op 31.528 us/op 1.13
arrayWithProxy get 100000 times 15.566 ms/op 10.551 ms/op 1.48
ssz.Root.equals 284.00 ns/op 322.00 ns/op 0.88
byteArrayEquals 283.00 ns/op 312.00 ns/op 0.91
shuffle list - 16384 els 7.3507 ms/op 4.8865 ms/op 1.50
shuffle list - 250000 els 108.71 ms/op 71.251 ms/op 1.53
processSlot - 1 slots 21.109 us/op 19.931 us/op 1.06
processSlot - 32 slots 3.9593 ms/op 3.2278 ms/op 1.23
getEffectiveBalanceIncrementsZeroInactive - 250000 vs - 7PWei 54.686 ms/op 41.925 ms/op 1.30
getCommitteeAssignments - req 1 vs - 250000 vc 2.5964 ms/op 2.3110 ms/op 1.12
getCommitteeAssignments - req 100 vs - 250000 vc 3.8355 ms/op 3.5003 ms/op 1.10
getCommitteeAssignments - req 1000 vs - 250000 vc 4.3029 ms/op 3.7662 ms/op 1.14
RootCache.getBlockRootAtSlot - 250000 vs - 7PWei 6.3300 ns/op 5.3600 ns/op 1.18
state getBlockRootAtSlot - 250000 vs - 7PWei 906.38 ns/op 526.25 ns/op 1.72
computeProposers - vc 250000 11.201 ms/op 6.4316 ms/op 1.74
computeEpochShuffling - vc 250000 117.42 ms/op 73.971 ms/op 1.59
getNextSyncCommittee - vc 250000 176.54 ms/op 113.11 ms/op 1.56
computeSigningRoot for AttestationData 29.483 us/op 28.513 us/op 1.03
hash AttestationData serialized data then Buffer.toString(base64) 2.5255 us/op 1.3386 us/op 1.89
toHexString serialized data 1.8820 us/op 826.48 ns/op 2.28
Buffer.toString(base64) 279.57 ns/op 160.77 ns/op 1.74

by benchmarkbot/action

@nflaig nflaig force-pushed the nflaig/fix-archive-state-epoch-frequency branch from d988974 to b9eae24 Compare September 21, 2023 21:03
@nflaig nflaig changed the title fix: correctly persist states based on configured epoch frequency fix: correctly persist states based on archive epoch frequency Sep 21, 2023
@wemeetagain wemeetagain reopened this Sep 22, 2023
@wemeetagain wemeetagain merged commit 24a74d0 into unstable Sep 22, 2023
22 of 24 checks passed
@wemeetagain wemeetagain deleted the nflaig/fix-archive-state-epoch-frequency branch September 22, 2023 18:58
@wemeetagain
Copy link
Member

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

Archive state epoch frequency is incorrect
2 participants