Cancun upgrade: Another milestone after Shanghai

Cancun upgrade: Another milestone after Shanghai.

Introduction to Cancun Upgrade

Cancun-Deneb (Dencun, hereafter referred to as Cancun Upgrade) is the next important upgrade on the Ethereum blockchain, which will improve the scalability, security, and usability of the Ethereum network.

Cancun is an additional upgrade to the Ethereum execution layer based on the Shanghai upgrade, and the first step was completed in the Shanghai upgrade on April 12th this year. Deneb represents the upgrade of the Ethereum consensus layer. The upgrade includes the highly anticipated EIP-4844, also known as Proto-DankSharding. This feature will lay an important foundation for the full implementation of DankSharding.

DankSharding

The launch of the beacon chain and the implementation of the merge are the first two parts of the Ethereum framework upgrade, and DankSharding is the third part and the main event. This newly designed structure will completely replace the original idea proposed by the core team to introduce 64 shard chains.

DankSharding does not allow the main chain to handle more transactions, but focuses on increasing the data availability of rollups. Rollup is a layer 2 technology that bundles blockchain transactions together and processes them. Any rollup operator can process a batch of transactions and submit the results and proof to the main chain. With specific rollup technologies such as optimistic or ZK, other validators or smart contracts in the network can review the results.

Currently, the mainstream Ethereum layer 2 expansion protocols include Optimism, Arbitrum, Metis, zkSync Era, and Scroll. In order to help the Ethereum network transition to full DankSharding in the long term, EIP-4844 will introduce many key components of the execution layer this year.

Proto-DankSharding

EIP-4844, also known as Proto-DankSharding, is a temporary upgrade to the Ethereum network proposed by Ethereum developers Protolambda and Dankrad Feist. On the EIP-4844 Q&A page, Ethereum co-founder Vitalik Buterin described Proto-Danksharding as a “stopgap” solution that will significantly reduce the gas fees for rollups before full shard implementation.

EIP-4844 is a scalability solution that revolves around Rollup and is the first step in Ethereum’s scaling roadmap. Before the upgrade, rollup data was permanently stored on Ethereum, which was expensive, and 90% of the transaction costs paid by users for rollup were due to this storage cost.

To this end, EIP-4844 introduces a new transaction type – Blob Transaction, where the data will be migrated to the “Blob” for temporary storage, which lasts about one month, and the data will be deleted afterwards. If long-term data storage is needed, other service providers will be responsible for storage according to actual needs.As just mentioned, EIP-4844 introduces a transaction type called “blob-carrying transaction”. Blob (binary large object) represents a 125 KB payload. To create a blob-carrying transaction, the rollup needs to submit its data to the blob and attach it to the block.A blob-carrying transaction can contain up to two blobs. Additionally, to encourage such transactions, the upgrade will implement a multi-dimensional EIP-1559 fee market. This feature will introduce variable gas fees for blob-carrying transactions based on supply and demand.The main advantage of blob-carrying transactions is cost-effectiveness. Currently, rollups permanently store transaction data on the Ethereum blockchain through CallData. However, blob data is much cheaper than CallData because it is not permanently stored on the execution layer (Ethereum Virtual Machine). Instead, the beacon node stores it in the consensus layer, and after a month or a year, the blob will be deleted. This process is similar to clearing cache data on a laptop or device.Although Blob was introduced by EIP-4844, it will be fully compatible with the format used in the final shards. In EIP-4844, each rollup transaction can contain up to 2 blobs, and each block contains 8-16 blobs, about 1MB to 2MB. In a complete sharding scenario, blobs can be further expanded to 16MB to 32MB.That is to say, when Blob becomes part of the Ethereum protocol through Proto-DankSharding, more Blobs will be added to the Ethereum block, and Ethereum’s throughput will once again be greatly expanded while transaction costs will also decrease.During the transaction process, a polynomial scheme called KZG (named after its creators Kate, Zaverucha, and Goldberg) will verify the transaction data published in the blob. Like other zero-knowledge verification systems, KZG can verify without disclosing all the contents of the blob.The core of the Cancun upgrade: EIP-4844According to the Ethereum execution layer core developer meeting in June, the Cancun upgrade includes 5 EIPs, aimed at increasing more data storage and reducing fees. The core content of the upgrade is EIP-4844, which aims to implement off-chain data temporary storage and retrieval through Ethereum nodes to meet the data and storage needs of blockchain applications.

Devnet testing continues to improve

Since October 2022, Ethereum developers have launched a multi-client test network for EIP-4844, also known as devnet. Since the successful activation of the “Shanghai upgrade” on April 12th this year, Ethereum developers have immediately shifted their focus to preparing for the “Cancun upgrade”.

Specifically, Cancun is the name of the next upgrade for the Ethereum Execution Layer (EL), while Deneb is the name of the corresponding upgrade for the Ethereum Consensus Layer (CL). During the ACDE conference call, developers discussed the final scope of the Cancun/Deneb upgrade, which will be centered on the implementation of the blob transaction type, EIP-4844, with preparations for Deneb starting from the launch of Devnet 5.

Significant changes have been made to Devnet 5, such as EL prohibiting zero blob transactions, switching the blob transaction type to 0x03, and decoupling blobs from blocks. In terms of updates to the Engine API, there are plans to add corresponding proofs to the not-yet-merged getBlobsBundleV1 and merge the “getBlockingyloadV3” and “getBlobsBundleV1” calls into one. As for the Beacon Chain API, a blob signature endpoint will be added as optional.

At the end of May this year, Ethereum community developer terence.eth shared the contents of the 22nd EIP-4844 implementer conference call, which mainly covered three main themes:

1. Deneb engine API version control;

2. Adding “data_gas_used” to execution headers;

3. Devnet 6 scope and test updates.

Among them, the meeting has decided to add “data_gas_used” to the execution header in the EIP-4844 update, because in the previously used EIP1559, the regular base fee was calculated using the current header. In EIP-4844, data gas calculation uses the parent header instead of the current header, excess_data_gas is the pricing of the next block, and base_fee is the pricing of the current block.

In addition, the meeting decided to use another test network belonging to EIP4844 for testing before transferring “data_gas_used” to Devnet 6 in order to include the “data_gas_used” update in Devnet 6.

At the end of June, developers from the Ethereum Foundation’s DevOps team said all EL and CL client teams have passed the relevant Hive tests for Devnet 7 and plan to launch Devnet 7 as early as June 30th or July 3rd. Devnet 7 is a dedicated short-term test network for EIP-4844 and will not test other code changes.

Devnet 7 aims to increase the blob limit from 2 to 3 and the maximum blob limit from 4 to 6. The goal of increasing the blob capacity was proposed by Dankrad Feist, a researcher at the Ethereum Foundation, after experimenting with data on the test network to process large blocks. As for the progress of the Cancun upgrade, the developers have agreed to update the precompiled address of EIP-4844, the test case of EVM instruction to copy memory area (EIP-5656) has been added to the testing framework, and the engine API responsible for communication between the consensus layer and the execution layer will face some changes. Devnet 6 has been stabilized after fixing some issues and will be replaced with Devnet 7, which will focus on testing related to EIP-4844.**Expected Launch Time of the Cancun Upgrade**On May 26 of this year, Ethereum Foundation researcher Alex Stokes stated that the reasonable target date for the activation of Cancun is October 2023. Geth (EL) developer Lightclient confirmed this statement, stating that the upgrade based on its current scope will take at least 5-6 more months.On June 9, Ethereum core developer Tim Beiko summarized the content of the latest Ethereum Execution Layer Core Developer Meeting (ACDE) on his social media platform. The meeting ultimately confirmed that the Cancun upgrade includes 5 EIPs, aimed at adding more data storage and reducing costs.The core content is EIP-4844, which aims to implement off-chain data temporary storage and retrieval through Ethereum nodes to meet the data and storage needs of blockchain applications.Other selected EIPs include EIP-1153 (reducing the cost of on-chain storage data to improve block space), EIP-4788 (improving the design of cross-chain bridges and equity pools), EIP-5656 (adding minor code changes related to the Ethereum virtual machine), and EIP-6780 (removing code that may terminate smart contracts). The meeting did not make an accurate prediction on the timing of the Cancun upgrade, but it is expected to occur before the end of 2023.**Goals and Impact of the Cancun Upgrade**The overall goal of the Cancun upgrade is to continue to prepare for a complete data sharding network, while expanding the rollup during the transition period. Introducing blob-carrying transactions will increase the data availability of rollups and greatly reduce the cost of rollups. EIP-4844 will also include the basic work of most execution layer logic and complete sharding. This step will greatly reduce the implementation work required for subsequent upgrades.

After the Cancun upgrade is activated, users will experience faster and cheaper payments when using native cryptocurrencies, applications, and ERC-based tokens in the Ethereum ecosystem. The Cancun upgrade is an important upgrade for Ethereum, opening a new chapter for Ethereum L1 sharding, reducing transmission costs between L1 and L2, achieving lower gas fees and higher TPS, and benefiting related ecosystems such as L2, thereby further enhancing the competitiveness of the “Ethereum + L2” architecture.

Ebunker, a long-term Ethereum supporter, pays close attention to Ethereum technology development, proposal upgrades, and community changes for the first time, sharing research and opinions on Ethereum key race tracks such as Staking, L2, and DeFi.

Currently, Ebunker includes Ebunker Pool (a non-custodial Ethereum staking pool for funds) and Ebunker Venture (Ethereum’s largest venture capital) and other businesses.

Ebunker official website: https://www.ebunker.io