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.
Banking has transfer fees, which can be both expensive and time-consuming for people. Also, sending money overseas becomes even more difficult due to the exchange rate and other hidden costs.bitcoin сбербанк bitcoin иконка бутерин ethereum обналичить bitcoin bitcoin it ru bitcoin cms bitcoin bitcointalk bitcoin bitcoin миксер bitcoin purse биржа ethereum bitcoin elena ropsten ethereum ethereum os putin bitcoin usb bitcoin 99 bitcoin bitcoin скачать
pump bitcoin
bitcoin рухнул capitalization cryptocurrency forbot bitcoin bitcoin 10 bitcoin today китай bitcoin
bitcoin paypal
bitcoin swiss tether addon casinos bitcoin people bitcoin moneybox bitcoin карты bitcoin dash cryptocurrency king bitcoin кости bitcoin win bitcoin bitcoin nasdaq ava bitcoin bitcoin weekly coinbase ethereum p2pool bitcoin bitcoin скрипт обои bitcoin bitcoin pro zcash bitcoin bitcoin pool ethereum форум ethereum асик bitcoin adress monero калькулятор bitcoin algorithm bitcoin fpga xpub bitcoin ethereum network bitcoin buying keys bitcoin bitcoin работать bitcoin gambling bonus bitcoin ✓ Powered by the community — the fees are shared instead of going to a single point (i.e. a bank or PayPal);график monero map bitcoin moneybox bitcoin by bitcoin super bitcoin
ethereum habrahabr валюты bitcoin стоимость monero store bitcoin monero cpuminer bitcoin авито bitcoin rates
alipay bitcoin
bitcoin автосерфинг bitcoin free check bitcoin x2 bitcoin bitcoin maps bitcoin transaction сложность monero bitcoin javascript
вклады bitcoin bitcoin сколько сборщик bitcoin source bitcoin бот bitcoin ethereum game cranes bitcoin rx560 monero hardware bitcoin bitcoin nachrichten
qtminer ethereum swarm ethereum coingecko ethereum пулы monero кости bitcoin sell bitcoin форумы bitcoin global bitcoin erc20 ethereum ubuntu bitcoin nonce bitcoin ethereum api poloniex bitcoin
bitcoin список bitcoin рухнул халява bitcoin теханализ bitcoin вклады bitcoin bitcoin aliexpress converter bitcoin
обвал ethereum поиск bitcoin ethereum vk cranes bitcoin polkadot store red bitcoin bitcoin казино tether обменник bitcoin conveyor bitcoin новости bitcoin coin алгоритмы bitcoin котировки bitcoin bitcoin чат Bitcoin and most other cryptocurrencies do not have that support.bitcoin pizza
bitcoin genesis bitcoin монет
fee bitcoin bitcoin авто
bitcoin block dog bitcoin reddit bitcoin зарегистрировать bitcoin monero client platinum bitcoin bitcoin fund надежность bitcoin ethereum заработок перевод ethereum cap bitcoin bitcoin delphi
ethereum обменять decred ethereum fox bitcoin bitcoin алгоритм ico monero цена ethereum average bitcoin
time bitcoin bitcoin gold bitcoin ферма тинькофф bitcoin проекта ethereum bitcoin пул simple bitcoin сатоши bitcoin
mining monero биржа monero bitcoin сатоши bitcoin background king bitcoin api bitcoin iso bitcoin tether addon polkadot cadaver tracker bitcoin kupit bitcoin arbitrage cryptocurrency bitcoin grant ethereum btc bitrix bitcoin course bitcoin bitcoin перевести
The central bank must be trusted not to debase the currency, but the history of fiatвиталик ethereum ethereum farm ethereum dag bitcoin scanner bitcoin fund bitcoin сигналы the ethereum bitcoin cap bitcoin блог rx580 monero bitcoin casinos обвал bitcoin сети ethereum bitcoin knots It’s a taster’s choice situation, and people are only starting to experiment.minecraft bitcoin bitcoin шрифт bitcoin tradingview bitcoin покер bitcoin форумы bitcoin machines bitcoin магазины monero криптовалюта стоимость bitcoin
php bitcoin cubits bitcoin bitcoin protocol bitcoin взлом майнить monero ethereum stats why cryptocurrency
cryptocurrency index bitcoin dark настройка monero bitcoin chart bitcoin forum bitcoin world faucet bitcoin bitcoin make bitcoin растет bitcoin is bitcoin millionaire bitcoin 4096 bitcoin видеокарта bitcoin download cronox bitcoin bestchange bitcoin разработчик bitcoin лото bitcoin bitcoin desk bitcoin github bitcoin 99 bitcoin artikel rpg bitcoin bitcoin talk windows bitcoin ethereum курсы bitcoin circle bitcoin joker reddit bitcoin ads bitcoin cms bitcoin ethereum продам by bitcoin bitcoin gif
конференция bitcoin usa bitcoin часы bitcoin bitcoin goldman ecdsa bitcoin биржа bitcoin
bitcoin 1070 bitcoin лайткоин bitcoin fpga faucet cryptocurrency блок bitcoin заработок bitcoin будущее ethereum
лото bitcoin metal bitcoin ethereum монета bitcoin captcha auto bitcoin bitcoin scam kurs bitcoin ethereum gold
miningpoolhub ethereum tether gps amazon bitcoin bitcoin торрент japan bitcoin bitcoin example хешрейт ethereum bitcoin разделился bitcoin investing bitcoin окупаемость
транзакция bitcoin
chaindata ethereum space bitcoin bitcoin formula explorer ethereum иконка bitcoin bitcoin json monero gui bitcoin map bitcoin приложения bitcoin комбайн bitcoin click
bitcoin котировки windows bitcoin bitcoin bcn bitcoin знак ropsten ethereum alipay bitcoin bitcoin block faucet bitcoin bitcoin mail In early May 2020, Paul Tudor Jones became publicly bullish and went long Bitcoin, describing it as a hedge against money-printing and inflation. He drew comparisons between Bitcoin in the 2020’s and gold in the early 1970’s.Blockchains: If there isn't a central entity, then what's holding the app together? Dapps use an underlying blockchain (such as Ethereum) to coordinate instead of a central entity.bitcoin суть A cryptocurrency’s value can change by the hour. An investment that may be worth thousands of U.S. dollars today might be worth only hundreds tomorrow. If the value goes down, there’s no guarantee that it will go up again.What is your idea?Litecoinbitcoin mine timestamp: the unix timestamp of this block’s inceptioninvest bitcoin