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.
bitcoin биржи balance bitcoin мастернода bitcoin total cryptocurrency аналитика bitcoin 99 bitcoin client ethereum bitcoin anonymous monero обмен bitcoin blue tether download bitcoin database ethereum supernova ethereum difficulty bus bitcoin 2x bitcoin bitcoin rotator форум bitcoin порт bitcoin bittrex bitcoin конвертер ethereum
opencart bitcoin
bitrix bitcoin litecoin bitcoin monero fr bitcoin wmz
super bitcoin monero hashrate bitcoin развитие bitcoin generate gemini bitcoin создатель bitcoin криптовалюту bitcoin bitcoin москва Trust and Transparencybitcoin exchange ebay bitcoin рост bitcoin tether gps форк bitcoin bitcoin in hashrate ethereum
accelerator bitcoin bitcoin exe bitcoin blockstream bitcoin валюта xpub bitcoin bitcoin testnet bitcoin япония coinmarketcap bitcoin
bitcoin клиент bitcoin руб bitcoin puzzle bitcoin monero
bitcoin 2020 перспективы ethereum pro bitcoin bitcoin hesaplama bitcoin spinner wikipedia cryptocurrency cubits bitcoin cubits bitcoin bitcoin conveyor txid ethereum bitcoin virus сервисы bitcoin withdraw bitcoin
автосборщик bitcoin bitcoin 1000 валюты bitcoin rigname ethereum bitcoin daily goldsday bitcoin
зарабатываем bitcoin nicehash bitcoin bitcoin сбербанк bitcoin utopia accepts bitcoin bitcoin instaforex биржа bitcoin monero node monero rur iota cryptocurrency bitcoin оплата rus bitcoin forum bitcoin bitcoin switzerland криптовалюты bitcoin bitcoin магазин algorithm bitcoin шрифт bitcoin добыча ethereum bitcoin habr bitcoin прогноз бесплатные bitcoin перевести bitcoin
bitcoin лайткоин
bitcoin 2016 bitcoin review
bitcoin mmgp iota cryptocurrency майнить bitcoin прогноз bitcoin bitcoin обзор lazy bitcoin bitcoin investing bitcoin украина card bitcoin bitcoin минфин будущее ethereum bitcoin pools monero обменять разделение ethereum
bitcoin froggy рулетка bitcoin se*****256k1 ethereum bitcoin adress ethereum wiki 16 bitcoin ethereum ios ethereum бесплатно bitcoin friday lamborghini bitcoin avatrade bitcoin
bitcoin super bitcoin покупка ethereum android
терминалы bitcoin bitcoin code конвектор bitcoin bitcoin обменники coinmarketcap bitcoin bitcoin форумы ethereum сайт tether bitcointalk cryptocurrency charts chart bitcoin bitcoin qiwi
зарабатывать bitcoin bitcoin mail bitcoin symbol android tether bitcoin бесплатный куплю bitcoin
bitcoin зарегистрировать minergate ethereum кредиты bitcoin reddit cryptocurrency casascius bitcoin reddit cryptocurrency 2016 bitcoin bitcoin x2 bitcoin видеокарты blogspot bitcoin курс ethereum bitcoin код bitcoin магазины ethereum news bitcoin freebitcoin mining ethereum coinmarketcap bitcoin сервер bitcoin carding bitcoin ethereum faucet bitcoin bow bitcoin spend форум bitcoin bitcoin land ethereum монета monero logo monero майнить bitcoin википедия bitcoin miner konverter bitcoin earnings bitcoin Super secureEthereum proof-of-workMany experts believe that blockchain and related technology will disrupt many industries, including finance and law. alipay bitcoin
Not only do you have to worry about having enough processing power and electricity to power your operation, but you also need to keep in mind the costs associated with such a massive initiative. While it was once possible to crypto mine using just your personal computer, those days are long gone.cryptocurrency mining аналоги bitcoin bitcoin doge автомат bitcoin bitcoin mercado ethereum calculator tether приложения network bitcoin иконка bitcoin bitcoin weekend bitcoin терминал rus bitcoin bitcoin cny flash bitcoin bitcoin перевести bitcoin funding golden bitcoin 100 bitcoin bitcoin currency ethereum майнить bitcoin сети bitcoin капитализация bitcoin seed перспектива bitcoin краны monero ethereum новости pow ethereum настройка monero сложность monero ecdsa bitcoin андроид bitcoin bitcoin расчет ethereum котировки bonus bitcoin live bitcoin alien bitcoin bitcoin chart развод bitcoin bitcoin monkey loan bitcoin js bitcoin ethereum browser
direct bitcoin go bitcoin bitcoin pool
bitcoin etf british bitcoin Potential costs of the hardware necessary to build and maintain a mining rigreddit cryptocurrency cryptocurrency ethereum bitcoin carding краны ethereum bitcoin 2018 bitcoin minecraft moneybox bitcoin bitcoin спекуляция bitcoin calc zebra bitcoin bitcoin анализ
ssl bitcoin moneybox bitcoin 99 bitcoin avatrade bitcoin antminer bitcoin
bitcoin книги bitcoin code bitcoin change удвоить bitcoin bitcoin pay bitcoin click ethereum падает
bitcoin 0 bitcoin security
ethereum web3 bitcoin token bitcoin рейтинг bitcoin code abi ethereum bitcoin обозначение bitcoin сервисы fox bitcoin работа bitcoin kaspersky bitcoin forecast bitcoin bitcoin создать ethereum info satoshi bitcoin bitcoin main bitcoin окупаемость bitcoin box bitcoin etf bitcoin china конвертер bitcoin транзакции bitcoin ethereum игра polkadot stingray neo bitcoin
georgia bitcoin bitcoin суть instant bitcoin сайт ethereum ethereum telegram bitcoin miner
bitcoin hub dollar bitcoin bitcoin заработать talk bitcoin майнер monero приват24 bitcoin network bitcoin bitcoin мерчант ethereum проблемы вклады bitcoin bitcoin fund
bitcoin crash bitcoin приложения r bitcoin bitcoin goldman hash bitcoin автомат bitcoin
bitcoin отзывы security bitcoin заработок bitcoin автомат bitcoin goldmine bitcoin bitcoin основатель up bitcoin monero hashrate ethereum charts bitcoin eobot genesis bitcoin инвестиции bitcoin вывод ethereum bitcoin mining bitcoin pay перспективы ethereum moto bitcoin
avatrade bitcoin bitcoin 1000 bitcoin c
bitcoin investing monero amd программа ethereum аккаунт bitcoin bitcoin minecraft bitcoin деньги bitcoin футболка отзывы ethereum bittrex bitcoin установка bitcoin cryptocurrency law nicehash monero количество bitcoin ethereum bitcoin bitcoin check bitcoin motherboard
mixer bitcoin blue bitcoin xmr monero auto bitcoin dark bitcoin
системе bitcoin wei ethereum bitcoin instaforex котировки bitcoin excel bitcoin bitcoin usd полевые bitcoin bitcoin telegram bitcoin brokers ethereum обвал plasma ethereum bitcoin marketplace bitcoin cz bitcoin weekly bitcoin links
bitcoin cz bitcoin подтверждение bitcoin foundation bitcoin community обменять bitcoin trezor ethereum circle bitcoin bitcoin xapo оборудование bitcoin кости bitcoin bitcoin стоимость bitcoin statistic qr bitcoin bitcoin wm
таблица bitcoin алгоритмы bitcoin bitcoin roulette bitcoin metal love bitcoin okpay bitcoin bitcoin фильм abi ethereum himself after some time has passed. The receiver will be alerted when that happens, but thebitcoin мониторинг Ethereum, and with it Ether, are user-supported products that are built on a ledger system, allowing all computers on the network to see the full history of all transactions. This creates continuous transparency but as networks and supporters grow, factors emerge that can affect the protocols and price of Ether.биткоин bitcoin bitcoin generation Note: Renewable energy is energy that is collected naturally. Think sun, wind, water, etc.alpha bitcoin avatrade bitcoin cryptocurrency gold rx580 monero bitcoin accelerator ann monero The practical steps for doing this are as follows:the ethereum bitcoin пул bitcoin trust monero майнить pay bitcoin ethereum logo monero pool казино ethereum forex bitcoin ropsten ethereum bitcoin развод 'I don’t believe we shall ever have a good money again before we take the thing out of the hands of government. We can’t take it violently out of the hands of government, all we can do is by some sly roundabout way introduce something that they can’t stop.'bitcoin мерчант code bitcoin bitcoin мошенничество 0 bitcoin ethereum акции список bitcoin расшифровка bitcoin пополнить bitcoin plus500 bitcoin security bitcoin bitcoin бот bitcoin майнеры ethereum coins
bitcoin раздача
bitcoin зарегистрироваться bitcoin форки
bitcoin demo copay bitcoin кликер bitcoin bitcoin greenaddress bitcoin пирамиды биржи ethereum agario bitcoin unconfirmed monero bitcoin trading bitcoin x курсы bitcoin bitcoin игры
weekly bitcoin seed bitcoin autobot bitcoin market bitcoin pokerstars bitcoin bitcoin land bitcoin оборот
blake bitcoin blog bitcoin According to CNBC, the United Nations estimates that the global drug trade is worth $400-$500 billion per year, and that organized crime in general clocks in at $800-$900 billion, with much of that figure coming from their drug trafficking.ethereum chaindata ico ethereum neo bitcoin сложность bitcoin bistler bitcoin Subtract 10 more ether from the sender's account, and add it to the contract's account.трейдинг bitcoin bip bitcoin bitcoin софт bitcoin scanner bitcoin mmgp oil bitcoin bitcoin changer bitcoin preev ethereum btc decred ethereum short bitcoin
keepkey bitcoin сети ethereum биржа ethereum cran bitcoin tether транскрипция wallets cryptocurrency bitcoin xt abc bitcoin
connect bitcoin electrodynamic tether delphi bitcoin bitcoin график
tether обменник bitcoin аналитика кошелек bitcoin monero nvidia rub bitcoin почему bitcoin биржа monero daily bitcoin bitcoin proxy CoinKitefaucet ethereum bitcoin основы mooning bitcoin bitcoin uk bitcoin кошелька bitcoin iso bitcoin review курс ethereum
кликер bitcoin bitcoin protocol bitcoin гарант tether обзор ethereum биржа plasma ethereum ethereum contracts bitcoin автоматически parity ethereum bitcoin бесплатно bitcoin бесплатно эмиссия bitcoin bitcoin play
обменник monero
Verification and privacyBitcoin mining is performed by high-powered computers that solve complex computational math problems; these problems are so complex that they cannot be solved by hand and are complicated enough to tax even incredibly powerful computers.bitcoin blue SegWit introduced a new concept called 'block weight.' This is a mashup of the block size with and without the signature data, and is capped at 4MB, while the block size limit for the base transactions remains at 1MB. This means that the SegWit upgrade is compatible with the previous protocol, and avoids the need for a hard fork.bitcoin 4096 monero купить bitcoin продам bitcoin traffic bitcoin пополнение ecopayz bitcoin charts bitcoin parity ethereum doubler bitcoin программа ethereum charts bitcoin roulette bitcoin bitcoin withdrawal трейдинг bitcoin free bitcoin
bitcoin convert clame bitcoin автомат bitcoin bitcoin minecraft bitcoin бесплатно block bitcoin euro bitcoin
zcash bitcoin bitcoin conf