You may have heard of something called the EVM, or Ethereum Virtual Machine. Although it's called the *Ethereum* Virtual Machine, many blockchains other than Ethereum utilize the tech including Polygon, Optimism, Arbitrum, Binance Smart Chain, Avalanche, Fantom, and many more.
So what does EVM do? How does it work? And what’s the point?
What is the EVM?
The Ethereum Virtual Machine (EVM) is like a global, giant computer that everybody can use. This isn't a physical computer that sits in one place. Instead, it's made up of many, many computers from all over the world, operated by individuals and organizations, that are all connected through the internet. In order to contribute, each computer that participates in the Ethereum network runs a piece of software that verifies transactions. That means regular people like you and me are the ones making Ethereum truly decentralized!
How does the EVM work?
Imagine you've written a set of instructions or a program that you want to run on this giant computer we call the EVM. These instructions might be something like "if this happens, then do this other thing". In the crypto world, these instructions are called “smart contracts”.
You submit your instructions, and they get sent to the giant computer. Every individual computer that makes up the giant computer receives your instructions and performs them. This ensures that no single computer can make a mistake or cheat because everyone else would see it.
In order to prevent people from overloading this giant computer with unnecessary tasks, there's a system in place. Each operation your instructions require costs a little bit, kind of like putting coins in a vending machine. If your instructions have a lot of steps, you'll need to pay more.
The EVM can't interact with the outside world by itself. It's like a calculator: you input data, it does the calculations, and you get the result. You can, however, contribute to the EVM by writing your own smart contracts (like one for minting your own tokens), which add to the calculator’s programming.
That's essentially what the EVM does. It's handling and executing sets of instructions in smart contracts that are sent to it by people using the Ethereum network. It makes sure that everything runs as expected, and that everyone agrees on the result.
State of the EVM
The EVM processes transactions sequentially, one by one. If the process fails for whatever reason (for example trying to send someone 1 ETH when you only own 0.5 ETH), then the transaction gets skipped. Each time the EVM runs a transaction, we say that ‘the state of the EVM is updated.’
This is because each transaction that the EVM processes changes the data that is on the EVM. We call this collection of data at any given point a ‘state.’ If just one thing changes in the EVM, even a single number, the state of the EVM has changed.
Each time the EVM changes or processes a new transaction, there's always a complete record of what the EVM consisted of before and after the transaction took place. Every new block is cryptographically tied to the state of the EVM in the previous block, which is why the blockchain record is permanent and unalterable.
Why do blockchains other than Ethereum use EVM?
For developers, the EVM is like a universal translator, capable of understanding different programming languages. Teams can create applications using a language they're comfortable with, and the EVM will still be able to run it.
This interoperability paves the way for the creation of applications that can easily communicate and interact with each other, as they're all operating within the confines of the EVM. It also makes it easy to move projects and dApps from one chain to another, assuming both chains use the EVM. If you have a dApp on Polygon, you can also deploy it on another EVM chain like Optimism or Arbitrum, depending on where your customer base is most likely to be.
What is an EVM-compatible network?
We call these chains that are compatible/built with the EVM an “EVM network” or “EVM-compatible network”. This simply means that the network executes smart contracts and has the potential to be interoperable with other EVM networks. As an exclusively Ethereum wallet in the past, MEW is evolving with the industry into an EVM and multichain wallet, supporting as many ecosystems as possible!
The main takeaway here is that the EVM sits at the heart of the Ethereum ecosystem, allowing it to grow faster than many other blockchains. Thanks to the EVM, Ethereum is a vibrant and dynamic ecosystem that supports a wealth of complex decentralized applications (dApps), from decentralized finance (DeFi) platforms, to games, decentralized exchanges (DEXs), and beyond. Its true potential is only just being explored.