Back

ArbOS

By
HackQuest
May 13, 2024
3 min read

Welcome to the Web3 world, where digital finance and applications are shown in a revolutionary way through the fusion of blockchain technology, cryptocurrencies, and a pioneering spirit. Are you overwhelmed by the wealth of terms in the Web3 world that you don’t understand? Are those slangs barriers for you to learn about Web3? Don’t worry! We’re here to explain the obscure terms to guide your learning. Today, we're diving into an exciting development in the world of Ethereum scaling solutions: [ArbOS].

Overview

ArbOS serves as the Layer 2 EVM hypervisor that creates the operational environment for L2 Arbitrum. It oversees and allocates network resources, forms blocks from received messages, and runs its modified version of Geth to execute smart contracts.

image
Preview

Source: Medium

Precompiles

ArbOS equips L2-specific precompiles with functions that smart contracts can invoke in the same manner as Solidity functions.

The installation process utilizes runtime reflection to ensure each implementer possesses the correct methods and signatures. This process includes limiting access to stateful elements like the EVM and statedb, based on the purity specified. Furthermore, the installer checks and assigns event function pointers to give each precompile the capability to emit logs and calculate their gas costs. The invocation, routing, and logging of precompile methods also rely on runtime reflection. This approach minimizes human errors that could occur from manually parsing and entering bytes, using Geth’s reliable APIs to handle value packing and unpacking efficiently.

Whenever a transaction invokes a method from an L2-specific precompile, a call context is generated to monitor and record the gas consumed. For added convenience, it also allows access to the public attributes of the underlying TxProcessor. To prevent issues arising from sub-transactions that may revert, the TxProcessor exposes only safe data, such as the amount of L1 calldata paid by the main transaction.

image
Preview

Source: Medium

Messages

A message may contain one or several user transactions based on the current load and is converted into a distinct L2 block. This L2 block might also incorporate extra system transactions during the processing of the user transactions from the message, yet the connection between them remains bijective.

Retryables

A Retryable represents a unique message type designed to facilitate atomic messages from L1 to L2.

Conclusion

ArbOS plays a crucial role in managing network resources, creating blocks from incoming messages, and executing smart contracts through a modified version of Geth. It also equips L2-specific precompiles that allow smart contracts to invoke functions similarly to Solidity, ensuring the correct execution through runtime reflection. This process helps to minimize errors, efficiently manages gas usage, and restricts access based on the purity of operations. Additionally, ArbOS handles messages and transactions efficiently, converting them into distinct L2 blocks and incorporating necessary system transactions to maintain a one-to-one relationship between messages and blocks. Furthermore, ArbOS introduces a special message type called Retryable, aimed at facilitating atomic messages from L1 to L2, showcasing its integral role in the evolving landscape of Ethereum scaling solutions. This comprehensive suite of features solidifies ArbOS's position as a pivotal enhancement in the Ethereum ecosystem, driving forward the scalability and efficiency of blockchain technology.

💡
If you would like to learn more about slang in Web3, let’s explore more in our HackQuest Web3 Glossary and check out our courses on Arbitrum!
Stay connected with us

More Glossary about ’Arbitrum‘

loading...