ETHEREUM VIRTUAL MACHINE (EVM)
Ryan Cordell
Last edit: @ryancreatescopy, November 30, 2020
See contributors
The EVM’s physical instantiation can’t be described in the same way that one might point to a cloud or an ocean wave, but it does exist as one single entity maintained by thousands of connected computers running an Ethereum client.
The Ethereum protocol itself exists solely for the purpose of keeping the continuous, uninterrupted, and immutable operation of this special state machine; It's the environment in which all Ethereum accounts and smart contracts live. At any given block in the chain, Ethereum has one and only one 'canonical' state, and the EVM is what defines the rules for computing a new valid state from block to block.
PREREQUISITES
Some basic familiarity with common terminology in computer science such as bytes, memory, and a stack are necessary to understand the EVM. It would also be helpful to be comfortable with cryptography/blockchain concepts like hash functions, Proof-of-Work and the Merkle Tree.
FROM LEDGER TO STATE MACHINE
The analogy of a 'distributed ledger' is often used to describe blockchains like Bitcoin, which enable a decentralized currency using fundamental tools of cryptography. A cryptocurrency behaves like a 'normal' currency because of the rules which govern what one can and cannot do to modify the ledger. For example, a Bitcoin address cannot spend more Bitcoin than it has previously received. These rules underpin all transactions on Bitcoin and many other blockchains.
While Ethereum has its own native cryptocurrency (Ether) that follows almost exactly the same intuitive rules, it also enables a much more powerful function: smart contracts. For this more complex feature, a more sophisticated analogy is required. Instead of a distributed ledger, Ethereum is a distributed state machine. Ethereum's state is a large data structure which holds not only all accounts and balances, but a machine state, which can change from block to block according to a pre-defined set of rules, and which can execute arbitrary machine code. The specific rules of changing state from block to block are defined by the EVM.
A diagram showing the make up of the EVM
Diagram adapted from Ethereum EVM illustrated
THE ETHEREUM STATE TRANSITION FUNCTION
The EVM behaves as a mathematical function would: Given an input, it produces a deterministic output. It therefore is quite helpful to more formally describe Ethereum as having a state transition function:
Y(S, T)= S'
Given an old valid state (S) and a new set of valid transactions (T), the Ethereum state transition function Y(S, T) produces a new valid output state S'
State
In the context of Ethereum, the state is an enormous data structure called a modified Merkle Patricia Trie, which keeps all accounts linked by hashes and reducible to a single root hash stored on the blockchain.
Transactions
Transactions are cryptographically signed instructions from accounts. There are two types of transactions: those which result in message calls and those which result in contract creation.
Contract creation results in the creation of a new contract account containing compiled smart contract bytecode. Whenever another account makes a message call to that contract, it executes its bytecode.
EVM INSTRUCTIONS
The EVM executes as a stack machine with a depth of 1024 items. Each item is a 256-bit word, which was chosen for maximum compatibility with the SHA-3-256 hash scheme.
During execution, the EVM maintains a transient memory (as a word-addressed byte array), which does not persist between transactions.
Contracts, however, do contain a Merkle Patricia storage trie (as a word-addressable word array), associated with the account in question and part of the global state.
Compiled smart contract bytecode executes as a number of EVM opcodes, which perform standard stack operations like XOR, AND, ADD, SUB, etc. The EVM also implements a number of blockchain-specific stack operations, such as ADDRESS, BALANCE, SHA3, BLOCKHASH, etc.
A diagram showing where gas is needed for EVM operations
Diagrams adapted from Ethereum EVM illustrated
EVM IMPLEMENTATIONS
All implementations of the EVM must adhere to the specification described in the Ethereum Yellowpaper.
Over Ethereum's 5 year history, the EVM has undergone several revisions, and there are several implementations of the EVM in various programming languages.
Increasing the total number of issued bitcoins beyond 21 million. While the precision / subdivisibility may be increased, proportional ownership must be unchanged.ethereum coin
japan bitcoin
bitcoin bitcointalk график ethereum free ethereum cryptocurrency ico
600 bitcoin by bitcoin Hot Wallets and Cold Storageзарабатывать ethereum putin bitcoin ethereum игра reklama bitcoin криптовалюту monero mining monero шрифт bitcoin
майнить bitcoin япония bitcoin bitcoin golden сайте bitcoin bitcoin work bitcoin maps bitcoin transaction bitcoin windows bitcoin конец minergate ethereum bitcoin store bitcoin boom bitcoin nedir windows bitcoin bitcoin faucets mmm bitcoin net bitcoin asic ethereum tether usd bitcoin joker clockworkmod tether bitcoin office bitcoin kurs книга bitcoin tether coin бесплатный bitcoin bitcoin girls bitcoin создатель bitcoin free crypto bitcoin bitcoin tor
bitcoin count cold bitcoin bitcoin forum создатель bitcoin
ethereum stats bitcoin goldman dark bitcoin обзор bitcoin bitcoin dump bitcoin спекуляция accept bitcoin ethereum dao bitcoin demo fox bitcoin bitcoin mixer bittrex bitcoin mikrotik bitcoin bitcoin java paidbooks bitcoin bitcoin программа автомат bitcoin monero nicehash pool monero galaxy bitcoin
сбербанк bitcoin алгоритм monero кредиты bitcoin bitcoin прогноз bitcoin сегодня перевод ethereum Immutability, in the context of the blockchain, means that once something has been entered into the blockchain, it cannot be tampered with.bitcoin вход скачать bitcoin ethereum miner torrent bitcoin wmx bitcoin tradingview bitcoin New nodes joining the network download all blocks in sequence, including the block containing our transaction of interest. They initialize a local EVM copy (which starts as a blank-state EVM), and then go through the process of executing every transaction in every block on top of their local EVM copy, verifying state checksums at each block along the way.кран bitcoin bitcoin перевод cryptocurrency market cryptocurrency dash
ethereum падает bitcoin scrypt bitcoin wordpress bitcoin blue bitcoin приват24 ethereum цена ico ethereum 0 bitcoin direct bitcoin dogecoin bitcoin
bitcoin direct
bitfenix bitcoin bitcoin community
segwit2x bitcoin pps bitcoin avatrade bitcoin
ninjatrader bitcoin secp256k1 ethereum monero хардфорк monero новости конвертер bitcoin bitcoin сбербанк bitcoin биржа bitcoin xl price bitcoin bitcoin center bitcoin hosting bitcoin space wei ethereum bitcoin msigna bitcoin favicon bitcoin spinner mine ethereum bitcoin lucky кошельки bitcoin
bitcoin change зарабатывать bitcoin monero стоимость bitcoin анализ конференция bitcoin video bitcoin bitcoin blog bounty bitcoin bitcoin motherboard asics bitcoin график monero etoro bitcoin ethereum addresses пул monero bitcoin баланс форумы bitcoin casinos bitcoin разработчик bitcoin блог bitcoin currency bitcoin bitcoin multiplier arbitrage cryptocurrency bitcoin phoenix unconfirmed bitcoin bitcoin markets up bitcoin index bitcoin ethereum рост bitcoin passphrase stealer bitcoin mine bitcoin хардфорк bitcoin bitcoin friday сигналы bitcoin bitcoin direct bitcoin bonus bitcoin motherboard check bitcoin bitcoin conveyor bitcoin okpay monster bitcoin multibit bitcoin bitcoin добыть
testnet bitcoin
ethereum testnet платформе ethereum
кости bitcoin bitcoin airbitclub blog bitcoin bitcoin games mine ethereum динамика ethereum erc20 ethereum
bitcoin mastercard книга bitcoin bitcoin инструкция
mooning bitcoin сколько bitcoin конвертер bitcoin алгоритм bitcoin bitcoin автоматически bitcoin биржи bitcoin обвал in bitcoin difficulty monero ethereum обменять direct bitcoin ubuntu bitcoin
падение bitcoin алгоритм monero project ethereum ethereum получить bitcoin play free monero обменник ethereum
казино bitcoin platinum bitcoin bitcoin payoneer elena bitcoin теханализ bitcoin monero fr bitcoin миксеры avto bitcoin фонд ethereum tether ico bitcoin суть bitcoin заработать micro bitcoin tp tether bitcoin исходники rush bitcoin bitcoin форки bitcoin payeer moto bitcoin сложность monero майнеры bitcoin валюта monero bitcoin symbol bitcoin fasttech форк ethereum и bitcoin bitcoin wmx coinmarketcap bitcoin
bitcoin перевод майнеры ethereum продажа bitcoin брокеры bitcoin bitcoin реклама bitcoin пулы bitcoin spinner
фильм bitcoin Low-voter turnoutbitcoin asics
курс ethereum 'Therefore, privacy in an open society requires anonymous transaction systems. Until now, cash has been the primary such system. An anonymous transaction system is not a secret transaction system. An anonymous system empowers individuals to reveal their identity when desired and only when desired; this is the essence of privacy. Privacy in an open society also requires cryptography… We cannot expect governments, corporations, or other large, faceless organizations to grant us privacy out of their beneficence. It is to their advantage to speak of us, and we should expect that they will speak. To try to prevent their speech is to fight against the realities of information. Information does not just want to be free, it longs to be free. Information expands to fill the available storage space. Information is Rumor's younger, stronger cousin; Information is fleeter of foot, has more eyes, knows more, and understands less than Rumor. We must defend our own privacy if we expect to have any. We must come together and create systems which allow anonymous transactions to take place. People have been defending their own privacy for centuries with whispers, darkness, envelopes, closed doors, secret handshakes, and couriers. The technologies of the past did not allow for strong privacy, but electronic technologies do. We the Cypherpunks are dedicated to building anonymous systems. We are defending our privacy with cryptography, with anonymous mail forwarding systems, with digital signatures, and with electronic money.'bitcoin dynamics zona bitcoin github bitcoin bitcoin global bitcoin автоматически логотип ethereum ethereum cpu bitcoin pizza bitcoin loans monero free attack bitcoin bitcoin spend easy bitcoin ethereum russia monero hardfork ethereum mine kurs bitcoin баланс bitcoin bitcoin trojan 999 bitcoin
bitcoin it bitcoin landing bitcoin zona billionaire bitcoin генераторы bitcoin bitcoin capitalization форк bitcoin monero пулы форк bitcoin ethereum хешрейт bitcoin cny accelerator bitcoin bitcoin cloud battle bitcoin bitcoin переводчик dwarfpool monero bitcoin покупка monero майнинг dwarfpool monero bitcoin protocol the ethereum ethereum настройка ethereum metropolis ethereum ann locate bitcoin bitcoin ммвб bitcoin iphone
gif bitcoin bitcoin вывести bitcoin iso bitcoin лого сети ethereum
фарм bitcoin bitcoin адреса bitcoin matrix bitcoin ютуб
bitcoin usb bitcoin 2 rate bitcoin график monero bitcoin instaforex торговать bitcoin bitcoin 4 bitcoin sportsbook ledger bitcoin bitcoin lucky foto bitcoin bitcoin haqida bitcoin cranes pro100business bitcoin tether обменник bitcoin information bitcoin clicks location bitcoin bitcoin xl bitcoin spinner usb bitcoin
claim bitcoin bitcoin rig
пример bitcoin обмен monero заработок bitcoin bitcoin neteller bitcoin сша widget bitcoin ethereum chart bitcoin cny bitcoin linux bcc bitcoin bitcoin links ethereum plasma
ethereum exchange bitcoin генератор rinkeby ethereum рост bitcoin bitcoin base monero обменять dark bitcoin electrum bitcoin смесители bitcoin fpga ethereum monero blockchain cryptocurrency market калькулятор bitcoin trade cryptocurrency vector bitcoin bitcoin информация bitcoin халява падение ethereum система bitcoin alpha bitcoin ethereum купить transaction bitcoin bitcoin c bitcoin net перспектива bitcoin cryptocurrency law bitcoin data контракты ethereum