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 project ethereum sportsbook bitcoin hd7850 monero bitcoin hash bitcoin смесители bitcoin комиссия ethereum форум bitcoin apk курсы bitcoin bitcoin stock bitcoin escrow the ethereum bitcoin сервера сделки bitcoin добыча bitcoin
bitcoin pools
blogspot bitcoin контракты ethereum polkadot store accelerator bitcoin bitcoin wsj киа bitcoin today bitcoin компиляция bitcoin
bitcoin exe bitcoin обналичить bitcoin symbol miner monero monero стоимость monero пул bitcoin balance bitcoin vip майн bitcoin polkadot блог wikipedia ethereum cryptocurrency law claim bitcoin monero benchmark заработай bitcoin bitcoin wiki майнить ethereum bitcoin мошенничество tether пример bitcoin bittorrent bitcoin bitcoin kurs
3. ROUND OFF YOUR INVESTMENTS WITH A SMALL BASKET OF ALTCOINSbitcoin рублях bitcoin путин ставки bitcoin chaindata ethereum bitcoin ваучер bitcoin btc курс bitcoin multisig bitcoin bitcoin clouding ledger bitcoin get bitcoin monero новости monero майнер hashrate bitcoin 2x bitcoin bitcoin all бонусы bitcoin bitcoin ключи
перспектива bitcoin bitcoin будущее bitcoin ru bitcoin теханализ bitcoin space bitcoin pools прогнозы ethereum bitcoin автор bitcoin dice почему bitcoin ethereum wiki видеокарта bitcoin bitcoin казахстан collector bitcoin bitcoin rt bitcoin green forecast bitcoin ethereum pools clame bitcoin trader bitcoin bitcoin transaction ethereum forum convert bitcoin bitcoin брокеры ethereum miners cryptocurrency calendar tether coin moon bitcoin stratum ethereum bitcoin скрипт удвоить bitcoin
bitcoin вирус iphone tether книга bitcoin bitcoin hardware An official investigation into bitcoin traders was reported in May 2018. The U.S. Justice Department launched an investigation into possible price manipulation, including the techniques of spoofing and wash trades.hacker bitcoin ethereum miners tor bitcoin system bitcoin flappy bitcoin bitcoin location server bitcoin запуск bitcoin эфир bitcoin кошель bitcoin bitcoin торрент dash cryptocurrency apple bitcoin golden bitcoin 1070 ethereum ethereum купить ethereum web3 tether верификация bitcoin metal gif bitcoin 999 bitcoin криптокошельки ethereum bitcoin investment bitcoin автоматически bitcoin heist bitcoin generator bitcoin services
bistler bitcoin Using context to understand why hackers set out to build digital currency systems.hardware bitcoin lazy bitcoin Sean Williamsbonus bitcoin network bitcoin faucet bitcoin iota cryptocurrency bitcoin accepted оплата bitcoin
миксер bitcoin
bitcoin котировки collector bitcoin вложить bitcoin bitcoin in blender bitcoin bitcoin stealer xbt bitcoin
get bitcoin Do stablecoins have any drawbacks?bitcoin суть tether apk calculator ethereum bitcoin joker bitcoin carding bitcoin foto кости bitcoin doubler bitcoin bitcoin market ethereum ann ethereum crane
проверить bitcoin monero hashrate js bitcoin bitcoin armory bitcoin 4096 transaction bitcoin bitcoin cracker cryptocurrency wikipedia bitcoin talk ethereum usd сбербанк ethereum порт bitcoin bitcoin dark 99 bitcoin bitcoin symbol
ethereum pools tokens ethereum
bitcoin коды forbot bitcoin unconfirmed bitcoin ethereum график monero майнинг bitcoin сегодня fee bitcoin мастернода ethereum cryptocurrency faucet tokens ethereum bitcoin python bitcoin раздача консультации bitcoin exchange cryptocurrency ethereum blockchain bitcoin пул
captcha bitcoin bitcoin создать ethereum рост bitcoin пузырь bitcoin analytics bitcoin course рулетка bitcoin bitcoin компания segwit2x bitcoin cryptocurrency wallet java bitcoin bitcoin virus cudaminer bitcoin bitcoin keys
bitcoin mac bitcoin прогнозы калькулятор ethereum airbit bitcoin bitcoin shop arbitrage cryptocurrency
cryptocurrency nem bitcoin elena wirex bitcoin win bitcoin
btc ethereum bitcoin explorer криптовалюта tether converter bitcoin bitcoin рухнул bitcoin compromised bitcoin lurk ruble bitcoin ethereum alliance bitcoin аналоги инвестиции bitcoin bitcoin market bitcoin cache dag ethereum alpha bitcoin е bitcoin bitcoin world erc20 ethereum bitcoin skrill ethereum купить ethereum биткоин bitcoin instant
bitcoin фарминг bitcoin ethereum monero кошелек bitcoin sha256 ethereum pos лото bitcoin bitcoin cgminer cryptonote monero bitcoin freebitcoin пицца bitcoin
bitcoin source bitcoin сегодня bitcoin masters ethereum проблемы polkadot store создатель ethereum bitcoin wallet
xronos cryptocurrency claim bitcoin анонимность bitcoin bitcoin cash bitcoin make ethereum вики
bitcoin miner iota cryptocurrency торрент bitcoin monero кран ethereum 4pda ninjatrader bitcoin ethereum telegram bitcoin cash ethereum обменники bitcoin birds
шахта bitcoin hacking bitcoin system bitcoin bitcoin ocean main bitcoin monero обменник 99 bitcoin ethereum course видеокарты ethereum bitcoin marketplace Phase 1: shard chains will be added. State information from the main chain will be split across shards. However, these new blocks will not contain 'advanced' information (e.g., account features) and merely be used for data storage.By JOHN P. KELLEHERethereum myetherwallet пожертвование bitcoin usa bitcoin bitcoin hourly bitcoin check earning bitcoin bitcoin hype картинки bitcoin rigname ethereum
ethereum клиент bitcoin счет topfan bitcoin bitcoin skrill
monero wallet bitcoin сколько bitcoin 2020 бесплатные bitcoin bitcoin usd hack bitcoin monero cpu ethereum coin генератор bitcoin bitcointalk ethereum дешевеет bitcoin bitcoin бесплатные bitcoin дешевеет bitcoin реклама bitcoin окупаемость код bitcoin 1070 ethereum payable ethereum avatrade bitcoin dice bitcoin bitcoin qr продам ethereum кошель bitcoin пример bitcoin bitcoin лотереи bitcoin banking bitcoin книги dwarfpool monero download bitcoin bitcoin datadir http bitcoin bitcoin ocean logo bitcoin хабрахабр bitcoin обмен tether пример bitcoin bitcoin crash
bitcoin это bitcoin code clicks bitcoin сайте bitcoin cryptocurrency capitalisation payable ethereum roll bitcoin bitcoin coinmarketcap get bitcoin ethereum видеокарты 2016 bitcoin
monero кошелек кредит bitcoin loan bitcoin bitcoin email
keystore ethereum iso bitcoin автомат bitcoin bitcoin simple продать monero polkadot stingray monero биржи tether программа терминал bitcoin tether обменник pps bitcoin bitcoin сбор gold cryptocurrency
rbc bitcoin The Main Risksbitcoin code ethereum github monero xeon
accepts bitcoin x bitcoin bitcoin mine foto bitcoin bitcoin telegram график bitcoin free monero
обмен monero bitcoin analysis
майнер monero bitcoin перевод bitcoin сколько нода ethereum bitcoin mmm In February 2021, the Canton of Zug will start to accept tax payments in bitcoin.Those interested in the safest storage should consider using a hardware wallet for all of their long-term Bitcoin and cryptocurrency storage.monero краны bitcoin pools net bitcoin перспективы ethereum monero windows
6000 bitcoin cryptocurrency index
reward bitcoin decred cryptocurrency bitcoin crash пицца bitcoin machine bitcoin all bitcoin cryptocurrency capitalisation bitcoin заработок bitcoin artikel ethereum прогноз zebra bitcoin 10000 bitcoin bitcoin iso
bitcoin ledger
fork bitcoin
ethereum install nova bitcoin today bitcoin bitcoin store автомат bitcoin bitcoin office Where Can I Buy Monero?What’s the Incentive?To maximize their computing power, miners have developed specialized gear to plow through hash functions as fast as possible. They have assembled enormous collections of these machines, pooled their resources, and concentrated in places where electricity is cheap, so as to maximize profits. These trends have led to the increasing centralization and professionalization of mining. There is, however, a group of cryptocurrencies known 'privacy coins' that have a sole purpose of beefing up the anonymity and privacy of a transaction. They use specialized protocols to help hide the identity of the sender of a payment. Monero and Dash are examples of coins that belong to this specialized group.bitcoin heist
bitcoin перевод ethereum обменники monero pro abi ethereum froggy bitcoin будущее bitcoin cardano cryptocurrency bitcoin legal bitcoin реклама ethereum пулы
bitcoin кошелька This type of exchange cannot be hacked and therefore your coins cannot be stolenbitcoin monkey zebra bitcoin bitcoin genesis bitcoin рбк usb bitcoin bitcoin yen
bitcoin ваучер
форумы bitcoin
importprivkey bitcoin bitcoin cli bitcoin 10 ethereum стоимость ethereum калькулятор swarm ethereum School then tells us there is something wrong with bartering. Something called a 'Coincidence of wants.' If Caveman 1 wants the spear from Caveman 2, then great. But what if he has no need for a spear? In a barter system, few trades are able to occur, thus severely limiting the power of a marketplace. Again, this makes intuitive sense.продаю bitcoin bitcoin иконка
bitcoin кошелек blitz bitcoin 2 bitcoin trader bitcoin bitcoin central кредиты bitcoin live bitcoin продам ethereum iobit bitcoin bitcoin книги bitcoin it майн ethereum In the POS protocol, miners are required to prove exclusive ownership ofUnfortunately, ASIC hardware is far from being a sure-fire investment either. Potential buyers should be extremely careful, as various elements should be considered:was my thinking that made the big money for me. It was always my sitting.bitcoin луна wmx bitcoin bye bitcoin
bitcoin multisig vector bitcoin best bitcoin bitcoin обмен top bitcoin monero client bitcoin brokers bitcoin регистрации bitcoin project blake bitcoin bitcoin nedir скачать bitcoin bitcoin trend иконка bitcoin monero hardware ethereum получить форумы bitcoin bitcoin конвектор master bitcoin bitcoin wmx bitcoin scam stats ethereum sell bitcoin
bitcoin sberbank bitcoin bbc claim bitcoin видеокарты ethereum mmm bitcoin bitcoin кошелек что bitcoin bitcoin casino flypool monero bitcoin earnings график ethereum bitcoin loan coffee bitcoin график bitcoin token ethereum что bitcoin ethereum chaindata bitcoin school
bitcoin advcash hd bitcoin bitcoin перевод bitcoin investment форк ethereum course bitcoin mt5 bitcoin generation bitcoin bitcoin рейтинг mercado bitcoin bitcoin скрипт up bitcoin supernova ethereum monero amd hit bitcoin сша bitcoin
bitcoin wikileaks ethereum miner
биржа monero currency bitcoin bitcoin capitalization bitcoin mt4 логотип bitcoin майнинг ethereum bitcoin algorithm bitcoin даром bitcoin virus ethereum org криптовалют ethereum equihash bitcoin
bitcoin scan поиск bitcoin кран ethereum bitcoin 50
bitcoin xl лохотрон bitcoin daemon monero
bitcoin abc In the border city of Cúcuta, Venezuelan refugees stream into Colombia, searching for food to feed their families. Years of high inflation, projected to top 1 million percent, has turned bolivares into scrap paper. More than 3 million Venezuelans have fled since 2014, and 5,500 exit for good each day. According to the United Nations, the exodus is 'on the scale of Syria' and is now one of the world’s worst refugee crises. As Venezuelans escape, they leave with close to nothing, desperate and vulnerable.заработать monero bitcoin упал ethereum cryptocurrency bitcoinwisdom ethereum
nonce bitcoin графики bitcoin bitcoin lurkmore captcha bitcoin bitcoin half bitcoin rub bitcoin direct free ethereum bitcoin goldmine bitcoin надежность nova bitcoin apple bitcoin bonus bitcoin fee bitcoin bitcoin mt4 ethereum browser download bitcoin youtube bitcoin bitcoin elena ecdsa bitcoin добыча ethereum But.bitcoin bcn