You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/zkEVM/architecture/zknode/index.md
-94Lines changed: 0 additions & 94 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -72,97 +72,3 @@ Required services and components:
72
72
73
73
It's recommended that the prover is run on a separate instance, as it has important hardware requirements. On the other hand, all the other components can run on a single instance.
74
74
75
-
76
-
******************* *****************************
77
-
78
-
79
-
80
-
81
-
### (new version) ... zkEVM vs EVM differences
82
-
83
-
This document provides a comprehensive list of differences between the Ethereum Virtual Machine (EVM) and the Polygon Zero-Knowledge Ethereum Virtual Machine (zkEVM). The list includes supported EIPs, opcodes, and additional changes made to build the zkEVM.
84
-
85
-
86
-
87
-
### EVM-equivalence
88
-
89
-
Polygon zkEVM aiming being a Type-2, is designed to be EVM-equivalent rather than being compatible.
90
-
91
-
The difference between EVM-compatibility and EVM-equivalence is that;
92
-
93
-
- Solutions that are compatible, enable most of the existing applications to work, but sometimes with code changes. Additionally, compatibility may lead to the breaking of developer toolings.
94
-
- Polygon zkEVM strives for EVM-equivalence which means most applications, tools, and infrastructure built on Ethereum can immediately port over to Polygon zkEVM, with limited to no changes needed. Things are designed to work 100% on day one.
95
-
96
-
EVM-equivalence is critical to Polygon zkEVM for several reasons, including the following:
97
-
98
-
1. Development teams don't have to make changes to their code, and thus nullifies any chance to introduce security vulnerabilities.
99
-
2. No code changes, means no need for additional audits. This saves time and money.
100
-
3. Polygon zkEVM benefits from the security and decentralization of Ethereum, since transactions are still finalizing on Ethereum.
101
-
4. EVM-equivalence allows Polygon zkEVM to benefit from the already vibrant and active Ethereum community.
102
-
5. It also allows for significant and quick dApp adoption, because applications built on Ethereum are automatically compatible.
103
-
104
-
Ultimately, Polygon zkEVM gives developers an almost identical UX to Ethereum, but with significantly improved scalability.
105
-
106
-
107
-
108
-
!!!info
109
-
No impact on developer experience
110
-
111
-
Note that the following differences have no impact on the developer experience with the zkEVM as compared to the EVM. Gas optimization techniques, interacting with libraries like Web3.js and Ethers.js, and deploying contracts work seamlessly on the zkEVM without any overhead.
112
-
113
-
114
-
115
-
Note that the following differences have no impact on the developer experience with the zkEVM as compared to the EVM.
116
-
117
-
- Gas optimization techniques,
118
-
- Interacting with libraries, like Web3.js and Ethers.js,
119
-
- Deploying contracts work seamlessly on the zkEVM without any overhead.
120
-
121
-
122
-
123
-
### Opcodes
124
-
125
-
Below is a list of the changes we have made with Opcodes in zKEVM in comparison to the EVM.
126
-
127
-
-**SELFDESTRUCT**→ removed and replaced by **SENDALL**.
128
-
129
-
-**EXTCODEHASH**→ returns the hash of the contract bytecode from the zkEVM state tree without checking if the account is empty.
130
-
131
-
-**DIFFICULTY**→ returns "0" instead of a random number as in the EVM.
132
-
133
-
-**BLOCKHASH**→ returns all previous block hashes instead of just the last 256 blocks.
134
-
135
-
> **BLOCKHASH** is the state root at the end of a processable transaction and is stored on the system smart contract.
136
-
137
-
-**NUMBER**→ returns the number of processable transactions.
138
-
-**BASEFEE**→ not supported. The zkEVM implements Berlin hardfork, but not the London hardfork.
139
-
140
-
141
-
142
-
### Precompiled contracts
143
-
144
-
Among Ethereum's precompiled contracts, the zkEVM currrently supports: **ecRecover** and **identity**.
145
-
146
-
Other precompiled contracts have no effect on the zkEVM state tree and are treated as a `revert`, returning all gas to the previous context and setting the `success` flag to "0".
147
-
148
-
149
-
150
-
## Additions
151
-
152
-
**zk-counters**→ batch resources are available, linked to state-machine components, as a supplementary addition to gas computation.
153
-
154
-
155
-
156
-
## Other minor differences
157
-
158
-
- zkEVM doesn't clean storage when a contract is deployed at an address due to the zkEVM state tree specification.
159
-
160
-
-**JUMPDEST** opcode is allowed in push bytes to avoid runtime bytecode analysis.
161
-
162
-
- The zkEVM implements [EIP-3541](https://eips.ethereum.org/EIPS/eip-3541) from the [London hardfork](https://ethereum.org/en/history/#london).
163
-
164
-
-[EIP-2718](https://eips.ethereum.org/EIPS/eip-2718) which defines **Typed Transaction Envelope**, is not supported
165
-
-[EIP-2930](https://eips.ethereum.org/EIPS/eip-2930), which defines the **Optional Access Lists** transaction type, is not supported.
0 commit comments