Accumulate’s Unique Integration with the Ethereum Virtual Machine

Written by Drew Mailen

On April 20, 2022

The next era of blockchain development will be highlighted by cross-chain interoperability for data, smart contracts, and digital assets. Compatibility with the Ethereum Virtual Machine (EVM) will be core to this era of growth when considering how much of DeFi and NFT projects are built using Ethereum token standards. 

Accumulate’s compatibility with the EVM will offer unique opportunities for the protocol’s ecosystem. Accumulate’s development team has in-depth exposure in this area with lead developer Paul Snow having made contributions to the EVM’s initial development. 

This article discusses some basics on what the EVM is, how it functions, and how Accumulate’s compatibility will extend the protocol’s ecosystem.

Topics that are in this post include: 

  • What is a Virtual Machine? 
  • What is the Ethereum Virtual Machine? 
  • What is the Purpose of the Ethereum Virtual Machine?
  • EVM Compared to Other Existing Technology 
  • Downsides of the Ethereum Virtual Machine
  • Benefits of the Ethereum Virtual Machine
  • How EVM-Compatibility via Accumulate Augments DeFi and NFT projects 

What is a Virtual Machine? 

Virtual machines (VMs) are created on top of operating systems such as iOS or Windows. VMs can run on different types of software so that all the software can be compatible and work together to complete tasks independently without relying on others to function. Virtual machines can determine the computing power of physical machines, and because VMs are so versatile, VMs are essential for a decentralized platform to function correctly.  

What is the Ethereum Virtual Machine?

The Ethereum Virtual Machine was created so that any node (computer) can use its resources no matter where it is located without being dependent on other nodes. The EVM acts as the go-to universal processor that anyone on the Ethereum network can use to make smart contracts or decentralized applications (dApps) function independently. 

The Ethereum blockchain is decentralized, meaning that thousands of computers run its software worldwide. These computers all have different operating systems and are spread out physically. The Ethereum blockchain system runs on a voluntary network and incentivizes participants who run the chain. The EVM is necessary to assist these nodes in building and executing what they want while sharing computing power. 

What is the Purpose of the Ethereum Virtual Machine?

The Ethereum Virtual Machine is embedded in all the nodes on the Ethereum network and keeps the rules consistent throughout every node. It ensures that all the blocks are valid and allows them to continue to the next block and run on their own. 

What is Turing-Completeness? 

A Turing Machine, once called an A-Machine or an Automatic Machine, represents a machine that would only work off algorithms until it got the correct answer. The possibilities are endless with this type of machine and can only be limited by physical restraints, which means the machine can continue forever until an answer is resolved. A Turing Machine relies on ‘statefulness’ as it can only focus on the task at hand or one state at a time. 

Turing-Completeness occurs when a computer can automatically decide a ruleset based on its computer language, instruction set, or advanced automation. It was created by a computer scientist named Alan Turning from his concept where he postulated that because computers do not think or act like humans, they can only function by processing a set of data to solve problems. 

EVM Compared to Other Existing Technology 

EVM is not the only Virtual Machine that exists – there have been many others that function similarly to it. One is the Java Virtual Machine (JVM) which, just like the EVM, is attached to an OS or other hardware to allow a variety of systems to work with each other. 

The main difference between the EVM and the JVM is that the EVM works for a decentralized network and is organized externally, so there is no scheduling capability. Also, the fact that the EVM lacks hardware support means that it runs completely virtual.  

Downsides of the Ethereum Virtual Machine

Many people believe the EVM system is expensive to run – paying for each operation can add up quickly. The environmental impact of Proof-of-Work decentralized systems are criticized quite often. There needs to be power for the EVM to continue blocks.

Benefits of the Ethereum Virtual Machine

The main benefit of the EVM is that it allows the Ethereum blockchain to run on any software. This encourages more nodes worldwide to join the ecosystem and makes it faster and more efficient. The EVM also encourages developers to run their dApps on Ethereum because they’ve created such a powerful system running for years (one of the longest in the crypto industry). Having this central processor lend its computing power is a massive advantage for the Ethereum network compared to other blockchains. 

Turing-complete Programming Languages

Turning-complete programming languages are able to perform any computation and work to process tasks written by developers. Javascript is an excellent example of a well-known programming language that is Turing-complete. JavaScript is a top-rated language that developers use to create websites and applications from scratch. A language like Javascript can be helpful in understanding the syntax of Solidity – Ethereum’s programming language for smart contracts. 

How is Ethereum Virtual Machine Deterministic? 

The Ethereum Virtual Machine was created to be deterministic, meaning its functions will always provide the same output as input. So no matter how many times the code is run, the EVM will always have the same outcome. This feature makes dApps on the Ethereum blockchain reliable because some of these dApps functions are for storing important information or transferring large amounts of money. The code must be flawless. 

What is Solidity?

Solidity is the name of the programming language developers use to create smart contracts or dApps on Ethereum. It is syntactically similar to JavaScript. When developers want to build an application on any computer, they must use a programming language. It looks something like this: 

All of the apps and websites you’ve used throughout your entire life have been created with programming languages. They act as a set of instructions to complete a task. Although Ethereum has a complex structure, its programming language, Solidity, is known to be a user-friendly programming language.

What are Smart Contracts?

A smart contract is an agreement between two parties that can be self-executed on computers anywhere. Smart contracts do not require any human supervision or authority for validation; they are a massive part of how the Ethereum network and EVM work.

Think about what a regular contract is, an agreement between two parties that outlines what each side is responsible for and determines what will happen when the tasks are fulfilled (or not). A smart contract does the same thing, except this type of contract isn’t written by a lawyer and monitored by a judge. A smart contract is written by a developer and monitored by computer code.

What are Opcodes?

Opcodes stand for ‘operational codes’ and are machine instructions that the EVM uses to execute tasks. Opcodes are lower-level codes than Solidity and allow the EVM to compute continuously. 

There are different types of opcodes, such as: 

  • Memory-Manipulating Opcodes
  • Environmental Opcodes
  • Halting Opcodes. 

The website has a table of all the available opcodes the EVM uses, along with stack input, stack output, expression, and notes.

What are Bytecodes? 

If you want to effectively store an opcode you must first turn it into bytecode. Every bytecode is split up into bytes which is a number that contains two hexadecimal characters. Some bytes need to be attached to opcodes if they include push data.

For a task to be completed on a smart contract, a developer will create opcodes that are used for the instructions and then create the bytecodes that will take these instructions, and break them down numerically. This will allow them to function on their own based on the numerical code and the following bytes after it. 

What is the Gas Cost of Interacting with Smart Contracts?

Gas costs on Ethereum represent the amount of computing power smart contracts need to complete their tasks. A smart contract task can use thousands of nodes on the Ethereum blockchain. That’s a lot of computing power! Gas fees are implemented for developers to use this power wisely and to prevent attackers from slowing down the network with unnecessary tasks. 

Each opcode will have a base gas fee (standard fee), as well as a dynamic gas fee (the latter being calculated per word of code). The cost of these transactions varies depending on what the operation is. For example, the “Amount of gas to pay for a JUMPDEST operation” is 1, whereas the “Amount of gas to pay for a SELFDESTRUCT operation” is 5000. All the costs per instruction can be found on the Ethereum Yellowpaper under Appendix G & H.

How Does Gas Relate to the Performance of EVM? 

Gas relates to the performance of EVM because it incentivizes developers to write clean, efficient code that will not clog the network. Before launching smart contracts, the written code should be as efficient as possible to avoid unnecessary fees. This will allow for the performance of the smart contract to run to the best of its ability and not waste unnecessary computing power. 

Gas Cost vs. Gas Price 

Gast cost is a set amount, meaning it stays the same based on what is written in the Fee Schedule above. However, gas prices will change. The cost of gas is paid for in the cryptocurrency called Ether, whose price can fluctuate based on buyer and seller equilibrium. The current price of 1 Ether in April 2022 at the time of this writing is just under $3,000. However, gas is determined in Gwei, which is a denomination of ether; one Wei (singular for Gwei) is one quintillion of ether. 

Now that different aspects of the EVM have been defined, let’s discuss how the EVM integrates with Accumulate. 

How EVM-Compatibility via Accumulate Augments DeFi and NFTs 

Software engineering best practices dictate that software systems are written in layers with clear responsibilities. This best practice results in systems that are less complex and far easier to maintain. The resulting benefit is a significantly lower total cost of ownership (TCO) and fewer software defects and bugs. Within the DeFi space, the second benefit, lower defects, is significant, and recent security breaches in Qubit, MonoX, and Compound illustrate this point.

The Accumulate ecosystem cleanly divides data and application layers by running EVM and other smart contract solutions as layer two protocols running on top of Accumulate.  

Along with our ecosystem partners, Accumulate intends to offer several smart contract solutions, integrated with Accumulate and Accumulate’s unique managed chain approach. The use of managed chains allows for the creation of smart contracts that are highly scalable. In these scenarios, an organization has already made testing on an existing technology stack. 

An EVM-bridge integration connects Accumulate to the larger DeFi and NFT world. However, Accumulate’s ADIs and the corresponding security model can do things that would be impossible in most EVM environments. All of Accumulate Network’s operations are managed by ADIs, which are centered around identities. 

ADIs will or could have capabilities such as: 

  • Sending and receiving tokens like a Bitcoin address.
  • Issuing smart contracts like an Ethereum address.
  • Facilitating a variety of new and complex operations such as on-chain consensus building and key management. 

Each ADI operates as its own independent chain under which all the states for a user’s identity including its keys, data, token accounts, and sub-identities can be managed on the network. In addition to the benefits that Accumulate can bring through an EVM-Ethereum Bridge, ADIs can have tremendous implications to enhance identity-based security issues across the world of DeFi and NFTs. 

Some of the expected outcomes of an Ethereum Bridge can include the ability to: 

  • Transfer digital assets (ERC-20 or ERC-721) from Ethereum to Accumulate EVM and back.
  • Transfer EVM-based digital assets from Accumulate EVM to Accumulate token accounts.
  • Transfer digital assets (ERC-20 or ERC-721) from Ethereum to Accumulate EVM and back through a bridge.
  • Transfer Accumulate-native tokens from Accumulate token accounts to Accumulate EVM.
  • Porting EVM-based smart contracts to Accumulate. 

Related Articles

Inveniam Metachain on Accumulate

Inveniam Metachain on Accumulate

The Inveniam Metachain is designed to create a verifiable Proof of Value™ audit trail for Inveniam’s Valuation-as-a-Service platform....


Submit a Comment

Your email address will not be published. Required fields are marked *