Gnosis Dencun: Seeking for proper EIP-7514 value
September 13th, 2024

The Ethereum Improvement Proposal EIP-7514 introduces a significant specification parameter: MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT. This parameter plays a crucial role in shaping the activation cue, directly impacting the activation churn. It's important to note that this parameter specifically affects the activation cue and does not fall under the considerations of weak subjectivity.

You can try every function used for calculations and plots building yourself:

Understanding Activation Churn

The activation churn equation is a fundamental aspect of EIP-7514. The churn limit for validator activation in the current epoch is determined by the following function:

def get_validator_activation_churn_limit(state: BeaconState) -> uint64:
    """
    Return the validator activation churn limit for the current epoch.
    """
    return min(MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT, get_validator_churn_limit(state))

The Validator Set and Growth Projection

EIP-7514 is expected to become active during the Dancun upgrade, tentatively scheduled for the EOY 2023. To determine an optimal value for MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT, we analyse the expected size of the validator set around the time of the hardfork.

Based on growth rate projections since the Shapella hard fork on Gnosis chain, it is estimated that the validator set will reach approximately 163000 validators by mid-December 2023. The current mean growth rate stands at approximately 165 validators per day:

PRE_SHAPELLA_SET = 140611
PRE_SHAPELLA_DATE = datetime(2023, 7, 31)

CURRENT_SET = 149349
CURRENT_SET_DATE = datetime(2023, 9, 22)

DANCUN_DATE = datetime(2023, 12, 15)

set_growth = CURRENT_SET - PRE_SHAPELLA_SET
days_between = (CURRENT_SET_DATE - PRE_SHAPELLA_DATE).days

growth_rate_per_day = set_growth / days_between

future_set = CURRENT_SET + growth_rate_per_day * (DANCUN_DATE - CURRENT_SET_DATE).days # ~163198

Analysing Activation Speed

Possible queue grow (Ethereum demand)

To comprehend how EIP-7514 might affect the entry queue on the Gnosis chain, we take Ethereum entry demand model and consider two scenarios: the worst Ethereum queue on June 10, 2023, and the current Ethereum status as of end of September, 2023. These scenarios allow us to calculate wait periods for different MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT values, assuming that the demand on the Gnosis chain aligns with that of Ethereum AT MOST.

# June 10, 2023
WORST_CASE_VALIDATOR_SET: 608224
WORST_CASE_QUEUE: 96508

# September, 2023
CURRENT_CASE_VALIDATOR_SET: 822593
CURRENT_CASE_QUEUE: 20292

Gnosis entry demand

This following plot provides insights into the historical demand to enter the network, represented by the average activations per epoch, for each month since December 2022 ("The Merge" on Gnosis). Plot shows (monthly_activations / monthly_epochs) for every month respectively.

The highest value so far is 0.35 activations per epoch (~1 activation per 3 epochs) in July 2023.

We can also calculate the time it would take to process daily entries for each listed MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT. For the current (September 2023) daily entries (165/day), the table below showcases the results:

Columns:

  • Necessary Epochs column shows how many epochs it will take to process current daily entries

  • Percentage of 24h column shows how many % of day time it will take to process daily entries

  • Total Time is self describing

We see that even with the tightest MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT: 2 it takes only 7.7% of day time to process all daily entries (with current demand).

The maximum daily capacities(MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT * epochs_number_24h) looks as follows (assuming 1 GNO == 100$):

As chain capacity with MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT: 2 is way more higher than current and maximal historical demand it would be a safe ground to pick the lowest value as it provides highest security benefits and better serves the purpose described in EIP.

How fast chain will churn at max

The churn percantage also might be helpful to analyze how different limits suppress chain churn while validator set grows:

The plot indicates that tightening the entry rate, denoted by MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT: 2, could have a significant impact if the validator set grows substantially. However, this effect is deemed acceptable.

Optimizing Churn Speed for Increased Security

A lower value for MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT can significantly contribute to a slower chain churning speed. This deliberate slowing of the churn process inherently increases the security of the chain. Moreover, we can calculate the time it would take to churn the validator set to reach target fractions (>1/3 and >2/3 of the chain) for different MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT values.

  • >1/3 fraction considered important threshold because it devaluates the Gasper consensus security assumption, i.e. chain become >1/3 slashable and dishonest party could prevent chain finalization

  • >2/3 threshold reflects a situation akin to a "51% attack," where a dishonest party gains control over a majority


Recap

MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT: 2

Important Consideration:

  • Resilience to Demand Surges: The conservative value of 2 equips the chain to handle unexpected spikes in demand, more than 10 times higher from current.

  • Optimal Balance with UX: While 2 is the lowest viable value, it's essential to note that choosing such a low churn limit strikes a delicate balance. It optimizes chain security and churn reduction without dramatically impacting UX.

  • Aggressive yet Cautious Choice: This choice reflects an aggressive approach in freezing chain economy grow to provide time for better solutions, with an acknowledgment that possible growth tightening is viewed as acceptable.

Subscribe to 4rgon4ut
Receive the latest updates directly to your inbox.
Mint this entry as an NFT to add it to your collection.
Verification
This entry has been permanently stored onchain and signed by its creator.
More from 4rgon4ut

Skeleton

Skeleton

Skeleton