EIPs Explained

EIP-2070 · Withdrawn · Meta · 2019-05-20

EIP-2070: Hardfork Meta: Berlin

The withdrawn meta-EIP that reserved the name Berlin for an Ethereum hard fork; the actual list of Berlin changes was tracked outside the EIP process.

What problem does it solve?

Every Ethereum network upgrade needs a single place that says what it contains and when it activates. Historically this was a "Hardfork Meta" EIP, such as EIP-1679 for Istanbul. EIP-2070 was created in 2019 as the meta EIP for the next upgrade, codenamed Berlin.

How it works

The specification is almost empty: it gives the codename "Berlin" and says that, at the current stage of coordination, the included changes are tracked and discussed in the Ethereum specs repository (then called eth1.0-specs) rather than in this EIP.

The process changed during Berlin: core developers moved upgrade tracking out of meta EIPs into that repository, and this EIP was withdrawn.

Berlin itself did ship on mainnet (April 2021), with these changes:

EIP Change
EIP-2565 Cheaper MODEXP precompile
EIP-2929 Higher gas for the first ("cold") access to an account or storage slot
EIP-2718 Typed transaction envelope
EIP-2930 Optional access lists (transaction type 0x01)

Sample code

The best-known user-facing feature of Berlin is the type-1 access-list transaction (ethers v6):

import { JsonRpcProvider, Wallet } from "ethers";

const provider = new JsonRpcProvider(process.env.RPC_URL);
const wallet = new Wallet(process.env.PRIVATE_KEY!, provider);

const tx = await wallet.sendTransaction({
  type: 1,                       // EIP-2930 access-list transaction
  to: contractAddress,
  data: calldata,
  accessList: [
    { address: contractAddress, storageKeys: ["0x" + "0".repeat(64)] },
  ],
});
await tx.wait();

Pre-declaring addresses and slots makes them "warm", reducing the extra cost EIP-2929 charges for cold access.

Things to know

  • Status is Withdrawn. Do not use this document to find what Berlin contains; consult the Ethereum execution specs repository, which replaced meta EIPs for upgrade tracking.
  • Withdrawal of the meta EIP does not mean the upgrade was cancelled. Berlin activated on mainnet with the four EIPs above.
  • EIP-2929 changed gas costs for existing contracts, which is why access lists (EIP-2930) shipped with it to soften the impact.

#hardfork #meta #berlin #upgrade

Details

Authors
Alex Beregszaszi (@axic)
Status
Withdrawn
Type
Meta
Created
2019-05-20
Requires
Required by

Machine-readable: Markdown · JSON