EIPs Explained

EIP-1240 · Withdrawn · Core · 2018-07-21

EIP-1240: Remove Difficulty Bomb

A withdrawn 2018 proposal to delete Ethereum's proof-of-work difficulty bomb outright, so moving to proof of stake would be a choice rather than something forced by ever-slower blocks.

What problem does it solve?

Ethereum's proof-of-work difficulty formula included an exponentially growing "bomb" term (the ice age). As it grew, blocks took longer and longer to mine, pressuring the community to keep upgrading and, eventually, to switch to proof of stake. By mid-2018 block times were visibly rising.

Micah Zoltu argued the bomb rests on a wrong assumption: that miners decide which chain economic users run. In his view miners follow users, because a chain nobody uses has no value. If the developers wanted Casper (proof of stake), users should choose it freely rather than be pushed by an artificial deadline. So instead of delaying the bomb again, EIP-1240 proposed removing it.

How it works

From a fork block onward, the bomb term (called epsilon) in calc_difficulty is set to 0 instead of being a function of the block number. The regular difficulty adjustment, which reacts to block timestamps and keeps block times near target, continues unchanged. The result would have been a difficulty that no longer drifts upward over time.

Because it changes the difficulty calculation, it is not backwards compatible and would have needed a scheduled hard fork.

Sample code

Simplified pseudocode of the PoW difficulty calculation and where the change applies:

def calc_difficulty(parent, block):
    # Regular adjustment: keeps block time near target (details vary per fork)
    adjustment = parent.difficulty // 2048 * time_adjustment_factor(parent, block)
    difficulty = parent.difficulty + adjustment

    # The "bomb" (epsilon)
    if block.number >= FORK_BLOCK_NUMBER:   # EIP-1240
        epsilon = 0
    else:
        period = (block.number - BOMB_DELAY) // 100_000
        epsilon = 2 ** (period - 2) if period >= 2 else 0

    return max(difficulty + epsilon, MIN_DIFFICULTY)

Things to know

  • Status is Withdrawn. It was never activated.
  • Instead, Ethereum repeatedly delayed the bomb in hard forks, for example EIP-649 (Byzantium), EIP-1234 (Constantinople) and EIP-2384 (Muir Glacier), with further delays after that.
  • The question became moot with the Merge (EIP-3675): under proof of stake there is no PoW difficulty, so the bomb no longer has any effect on mainnet.
  • The proposal is mainly of historical interest: it records the argument that a protocol should not contain a forcing function to push users toward upgrades.

#difficulty-bomb #pow #core #withdrawn #governance

Details

Authors
Micah Zoltu (@MicahZoltu)
Status
Withdrawn
Type
Standards Track / Core
Created
2018-07-21

Machine-readable: Markdown · JSON