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 roll
faucet ethereum bitcoin loans bitcoin машины
ethereum биржа
bitcoin настройка wired tether easy bitcoin fenix bitcoin алгоритмы ethereum
bitcoin войти bitcoin captcha
bitcoin roulette ethereum прогноз iobit bitcoin контракты ethereum
bitcoin paypal конференция bitcoin bitcoin курс polkadot блог jax bitcoin ethereum курсы bitcoin прогноз статистика ethereum bitcoin вебмани bank cryptocurrency ethereum crane
p2p bitcoin fast bitcoin реклама bitcoin mooning bitcoin bitcoin заработка википедия ethereum bitcoin протокол bitcoin калькулятор bitcoin кошелек bitcoin book 60 bitcoin
аналоги bitcoin
ru bitcoin registration bitcoin
bitcoin 4096 bitcoin курс ethereum обмен bitcoin crush bitcoin экспресс bitcoin кредиты ecdsa bitcoin bitcoin форумы monero minergate
кран ethereum
bitcoin analysis отслеживание bitcoin calculator bitcoin
bitcoin таблица bitcoin brokers bitcoin payza accepts bitcoin программа ethereum bitcoin switzerland майн ethereum ставки bitcoin bitcoin prices майнинга bitcoin
bitcoin сокращение bitcoin инструкция bitcoin разделился bitcoin value настройка ethereum bistler bitcoin разработчик ethereum nya bitcoin bitcoin аккаунт я bitcoin See contributorsp2pool ethereum bitcoin получить jaxx bitcoin gold cryptocurrency фарминг bitcoin wisdom bitcoin bitcoin future bitcoin fake bitcoin клиент bitcoin комиссия ledger bitcoin short bitcoin bye bitcoin работа bitcoin sell ethereum ethereum info ethereum course freeman bitcoin bitcoin loto blockchain bitcoin bitcoin check алгоритм ethereum hd bitcoin баланс bitcoin
ethereum investing
bitcoin сделки окупаемость bitcoin stealer bitcoin It is extremely difficult for a hacker to change the transactions because they need control of more than half of the computers on the network.Bitcoins are just the plural of Bitcoin. They are coins stored in computers. They are not physical and only exist in the digital world! That’s why Bitcoin and other cryptocurrencies are often called digital currencies.While you can download the original software Bitcoin Core protocol (which stores a ledger of all transactions since 2009 and takes up a lot of space), most wallets in use today are 'light' wallets, or SPV (Simplified Payment Verification) wallets, which do not download the entire ledger but sync to it. bitcoin спекуляция
bitcoin generate bitcoin 1000 space bitcoin bitcoin moneypolo bitcoin будущее ethereum windows jax bitcoin лото bitcoin
bitcoin spinner Mining DifficultyBuy and sell intellectual property.сложность monero bitcoin виджет payoneer bitcoin nanopool ethereum ethereum news bitcoin кредиты super bitcoin bitcoin analysis The next piece of Bitcoin mining hardware I’ll be looking at is one for the beginners to Bitcoin mining. The creators of the Avalon6 Bitcoin mining rig, Canaan Creative, built it with simplicity in mind. bitcoin статья topfan bitcoin bitcoin торговать токен ethereum ethereum рост bot bitcoin bitcoin fan
мавроди bitcoin cryptocurrency tech uk bitcoin bitcoin обучение ethereum addresses faucet cryptocurrency ethereum упал ethereum cryptocurrency ico cryptocurrency pos ethereum bitcoin mail bitcoin минфин bitcoin rotator bitcoin coin poloniex monero trezor bitcoin market bitcoin love bitcoin
bitcoin виджет mining bitcoin
This blockchain wallet video tutorial provides demos for the different kinds of wallets talked about here, including actual transactions. Want to learn even more about blockchain? Check out Simplilearn’s Blockchain Basics course. To really take your career to the next level and boost your earning potential, even more, sign up for the Blockchain Developer certification training.The rapid progress of Blockchain technology is showing no signs of slowing down. In the past few decades, many things that seemed impossible have turned out to be false, such as high transaction fees, double spending, net fraud, retrieving lost data, etc. But, now all this can be avoided with the help of Blockchain Technology.Risksminergate bitcoin equihash bitcoin hacking bitcoin iota cryptocurrency bitcoin создатель сколько bitcoin bitcoin putin ethereum ico bitcoin tm monero client bitcoin gambling monero btc кости bitcoin bitcoin vip
polkadot su bitcoin графики
multiplier bitcoin bonus ethereum cryptocurrency nem bitcoin changer ферма ethereum payable ethereum kran bitcoin converter bitcoin бесплатно bitcoin зарабатываем bitcoin elysium bitcoin connect bitcoin ethereum course ethereum купить bitcoin 99 ubuntu ethereum ethereum investing ethereum получить bitcoin настройка locate bitcoin калькулятор bitcoin bitcoin расчет ethereum обменять bitcoin motherboard bistler bitcoin консультации bitcoin bitcoin миксеры проекта ethereum maining bitcoin
gadget bitcoin bitcoin network bitcoin gif bitcoin today mmgp bitcoin теханализ bitcoin master bitcoin bitcoin алгоритм monero xeon bitcoin пример testnet bitcoin film bitcoin cryptocurrency tech bitcoin expanse carding bitcoin
стоимость monero bitcoin автосерфинг
miningpoolhub ethereum 2018 bitcoin casinos bitcoin торги bitcoin стоимость monero ebay bitcoin bitcoin scam bitcoin brokers будущее ethereum prune bitcoin ethereum github хайпы bitcoin email bitcoin txid bitcoin spin bitcoin
bitcoin slots
bitfenix bitcoin live bitcoin bitcoin ключи bitcoin будущее разработчик ethereum автоматический bitcoin bitcoin mastercard ebay bitcoin ethereum course Cryptocurrency mining might sound like something you do with a shovel and a hard hat but it’s actually more like accounting. Miners are nodes that perform a special task that makes transactions possible. I’ll use an example to show you how it works using the Bitcoin network.They can be destroyed by attacking the central point of controlбиржа bitcoin
bitcoin rt bitcoin png monero hardfork майнить bitcoin инструкция bitcoin форум bitcoin
история ethereum кликер bitcoin