Replies: 1 comment
-
Done! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
EVM upgrade plan
Authors: Dan Liu, XDC Protocol Team
Note: this post is an updated and more detailed version of a previous EVM upgrade post.
1. Context
The XDC network currently only supports solidity v0.8.6 in ful and v0.8.19 partially. Here is the current support status:
To meet on-chain development needs and embrace latest ZK and rollup techniques, the XDC network should fully support Solidity V0.8.23. To achieve this, we need to upgrade XDC's EVM, which mainly involves adding new opcodes. This post specifies the EVM upgrade plan.
V0.8.24 is a huge yet very recent upgrade. For the timebeing and for system reliability, we will not consider it for now.
2. Methodology
2.1 opcodes
To support solidity v0.8.23, the following opcodes must be added to EVM:
2.2 Special note about EIP-1559
The opcode BASEFEE was implement in EIP-3198, which is part of the gigantic EIP-1559 upgrade. However, EIP-1559 is mainly about adaptive fees, which is not of high priority for XDC. Therefore, we will only impellent EIP-3198 without implementing the entire EIP-1559. But we can implement the JSONRPC API for EIP-1559 based on fixed gas price.
3. Detailed Operations
3.1 Preparation
Upgrade package vm by pick some new commits from Ethereum codebase after 2018. Our vm package is updated by the PR new EVM Upgrade on 2019-01-04. Our code is a bit outdated now. We reviewed all new commits about vm package, and plan to apply the following PR from Ethereum into XDC chain. This will not only improve the performance of our network, but will also make further EIP upgrade on XDC much easier.
OpCode.String()
3.2 EIP-3198
We can pick codes from Ethereum in the implementation of EIP-1559:
3.3 EIP-4399
We can pick codes from Ethereum in the implementation of EIP-4399:
3.4 EIP-3855
We can pick codes from Ethereum in the implementation of EIP-3855:
4. Develop schedule
We will work from the latest commit of the dev-upgrade branch. Each PR will also be merged into the dev-upgrade branch.
In terms of role, Dan Liu and Gerui Wang will develop the code. Galaxy Deng will provide test smart contracts. The protocol team will also provide infra support.
The expected total development time will be 6-8 weeks.
5. Test Strategy
5.1 Local test
5.2 Online test
After the development:
6. Future Work
Beta Was this translation helpful? Give feedback.
All reactions