user-image
Ponyo
Research Analyst/
Xangle
Sep 23, 2022
Translated by elcreto
pick

 

Aptos vs. Sui Comparison: Similarities and Differences

One of the hottest topics in the crypto industry at the moment is undisputedly the rivalry between Aptos and Sui. As both are new layer 1 blockchains that draw heavily from Meta's former blockchain initiative Diem (formerly known as Libra), which once grabbed the world’s attention, it is only natural that the industry is setting a high bar for the projects. With the attention being focused on who will take the throne, we will take a look at the similarities and differences between the two L1s.

 

Summary

With the announcements of the token launch of Optimism and Starknet and the release of Polygon zkEVM, modular blockchains are increasingly gaining the upper hand. The powerful monolithic candidates that claim L1s like Solana already suffice, fueling the debate over L1 v. L2. Aptos and Sui are similar in that they both are ultra-high TPS L1 blockchains that seek to find scalability solutions on their base layer chains. The differences, on the other hand, are their vision and approach to scalability enhancement, such as consensus algorithms and architecture design. If Aptos is more of an orthodox type, Sui is branding itself as an object-centered blockchain that offers a freer development environment. Sui’s objects will be covered more in detail in the later part of this publication, Sui Consensus Mechanism.

 

Mission

Aptos, “The Safest and Most Scalable Layer 1 Blockchain”

The mission of Aptos, which is Ohione for “The People,” is to create a safe environment where everyone around the world can freely access cryptocurrencies. The team kicked off the project with the awareness that enhanced security and scalability are the prerequisite for true mass adoption of blockchain. Aptos aims to build the safest and most scalable blockchain and seeks to secure credible neutrality through openness.

Sui, “Build without Boundaries”

The mission of Sui is to build a blockchain where billions of users can develop Web3 services. Specifically, Sui aims to build a platform that is applicable to all industries from game to financial services. To this end, the project seeks to develop a powerful SDK that can configure anything and L1 blockchain that can scale horizontally. If Diem, the former project, used to be a blockchain specializing in processing the payment traffic, Sui aspires to go further and become a smart contract platform where there is no limit to development.

Team

The management of Aptos Labs and Mysten Labs(Sui) are the key developers, researchers, and PMs of Meta’s former blockchain project Diem. The similarities they share, such as technology, programming language, and date of launch, manifest that they did have an influence on each other in the course of the development of the blockchain back then. The key members of the projects are world’s leading cryptology, distributed system, and security specialists from tech giants like Apple, Meta, Yahoo, and MS. The numbers of employees working for Mysten Labs and Aptos Labs are roughly over 35 and 50 respectively.

mysten labs, 수이, 수이 블록체인, sui
Mysten Labs’ Management: Sam Blackshear (CTO), Evan Cheng (CEO), and Adeniyi Abiodun (CPO) from the left
aptos labs, 앱토스, aptos, 앱토스 블록체인
Aptos Labs’ Management: Avery Ching (CTO) and Mo Shaikh (CEO) from the left

 

Investors and Valuation

Major Investments in Aptos and Sui are as follows (Please see the table below for more details): 

The two projects have exhibited a significant gap in the amount of funding and valuation. Recently, however, Mysten Labs has been valued at $2B and proceeded with a plan to raise $200M in a funding round, to which FTX Ventures had already committed more than $140M as the lead investor. If Mysten Labs manages to successfully complete the series B funding round, the gap will shrink significantly. In case of Solana Labs, which is similar to the two projects in the sense that it also aims to build a high-performance blockchain, it has recently raised $335M in investment.

 

Scalability & Performance

1) BlockSTM

Since both projects have roots in Diem, which was a project that had a potential to onboard Meta’s 3 billion users, scalability of the two blockchains is often touted as the biggest benefit. Aptos and Sui claims that they can reach as fast as 160,000 TPS and 120,000 TPS respectively (based on 8-core M1 MacBook Pro, or 25,000 TPS based on 1-core). The speeds are radically high so much so that it even feels unrealistic, given that the throughput rates of Ethereum, Arbitrium, and VISA are 15, 500, and 65,000 TPS respectively. Then, what are the drivers behind such lightning speed?

The key difference lies in the BlockSTM technology that the management of the two projects studied during their years at Meta. BlockSTM is a smart contract parallel execution engine that employs software transactional memory–a methodology that applies database transaction properties that satisfy ACID properties to parallel programming). Unlike traditional processes on blockchains that had to process transactions sequentially, the most notable differences of BlockSTM are as follows:

  • Independent transactions are split into multiple threads and executed in parallel (Solana’s Sealevel is another example of parallel execution)
  • The order of transactions is defined in advance (Pre-defined order)
  • Execution of transactions precedes validation and consensus, preventing a bottleneck on the blockchain as well as significantly increasing the throughput rate

As such, BlockSTM is claimed to be able to reach 60,000 TPS in general and go up to 160,000 TPS. Yet, caution is advised since any conflict that arises during validation may result in a rollback and suspension in block commit, significantly lowering the TPS. The aforementioned concept has long been around in computer science and therefore, may not be considered innovative. But BlockSTM’s profound significance lies in the fact that the mechanism was restructured to become applicable to the blockchains and that additional security features are introduced.

blockSTM 퍼포먼스, 앱토스, 앱토스 랩스, 앱토스 블록체인
BlockSTM' Performance | Source: Aptos Labs

 

The overarching technologies of BlockSTM are as follows:

  • Optimistic Concurrency Control assumes assumes that although conflicts are possible, they will be very rare (hence does not lock every record every time). As such, the method employs STM’s optimistic concurrency control properties that enable multi-thread execution. It first executes transactions in parallel and then, rolls back and re-performs the process if any conflict arises during validation and results in a suspension in block commit. In a sense, the process is similar to optimistic rollups, where the execution of transactions comes first under the assumption that all transactions are valid. Since, most likely, most of the transactions are valid, the TPS can shoot up.
  • Dynamic Dependency Estimation aims to detect a validation failure as soon as possible in order to minimize inefficiency. It also defines the rule on how blocks should be committed on the blockchain. If a validator fails to validate a transaction, the transaction is tagged as ESTIMATION. The process then skips to the next transaction while execution of all the transactions that have a dependency on the transaction is suspended until other validators can successfully validate the transaction. This way, the blockchain prevents a waste of time and resources that could happen if it had to roll back the whole transactions dependent on the transaction that had not been validated yet.
blockstm, aptos, 앱토스
BlockSTM’ Transaction Commit Rule  | Source: BlockSTM Whitepaper
  • Collaborative Scheduler allocates validation and execution workloads to threads, allowing the order of transactions to be pre-defined. Under the BlockSTM structure, where execution and validation are separated, low transactions come earlier in sequence because a successful execution of a transaction does not necessarily mean that the transaction is fully committed. The design avoids to prioritize high transactions for the sake of maximum efficiency. It aims to prevent a possible waste of time caused by a rollback of all subsequent transactions upon a failure in reaching a consensus during a validation process of a transaction. 

 

2) Consensus Algorithm

Aptos - DiemBFT V4

Aptos adopted HotStuff BFT-based DiemBFT v4 as its consensus mechanism. DiemBFT has its root in PBFT (Practical Byzantine Fault Tolerance). It is a model that overcame BFT’s limitation of only allowing consensus in a synchronous network and enables consensus even in an asynchronous network. The gist of PBFT is that if a consensus is reached by a network where the number of Byzantine nodes (or traitor nodes) is f and the number of the entire nodes on the network is 3f+1 or higher, the consensus is deemed credible. Most of the blockchains, including Cosmos, EOS, Ripple, and R3, are using PBFT with some tweaks.

Again, DiemBFT is a consensus algorithm that improved PBFT. It has lowered the load on the network and sped up the process. Largely, these are all thanks to: i) the linear communication and chaining solution that have improved finality (safety), latency, and network efficiency (See below for more details), ii) the pacemaker that speeds up synchronization between validators with the efficiency of timeouts, and iii) the reputation system that analyzes on-chain status and allows for faster screening to rule out faulty validators during the selection of leader nodes.

How Consensus Is Reached Through DiemBFT V4, Linear Communication, and Chaining

In PBFT, the leader broadcasts a block creation proposal to each node, and the nodes get to cross-examine the block. In this cycle of events, DiemBFT V4 comes in to streamline the process and unifies the direction of validation so that nodes can communicate more efficiently.

pbft, 기존 pbft 검증 과정
How validation used to be performed in PBFT | Source: ICONLOOP
diemBTF V1 검증 과정, libra bft
How Validation Is Performed in DiemBFT V1 | Source: LibraBFT

The diagram above describes DiemBFT V1. It is similar to V4 but the difference is that V4 conveys validators’ voting data to the leader of the next round rather than of the present round to lessen the burden on the network.

Under the linear communication and chaining model, the rounds proceed in the following order:

  1. The leader broadcasts a block creation proposal to each validator.

  2. The validators then deliver their votes on the validation result to the leader of the next round.

  3. The leader generates a QC (Quorum Certificate) if more than 2/3 of the validators successfully deliver their votes.

  4. The leader broadcasts to the validators a new proposal as well as the QC for the previous round. One thing to note here is that the leader of the next (or K+1) round issuing and broadcasting a QC does not mean that the block from the K round is committed. In the chaining model, the K+1 round only receives the QC, and the block commit actually takes place in the K+2 round. (Please refer to the diagram below).

As is illustrated below, chaining is a method that splits the block validation process into multiple rounds. Naturally, the advantage of chaining is the lower load on the network compared to the previous PBFT model, where transmission of a proposal and creation and issuance of a QC are all processed in a single round.

chaining 매커니즘, diemBTF V4
Chaining Mechanism | Source: DiemBFT V4 Whitepaper

 

Sui – A Two-Pronged Approach: FastPay + Narwhal and Tusk DAG Based Mempool Along with Efficient BFT Consensus

While Aptos chose to maximize the efficiency of traditional PBFT, Sui’s design is fundamentally different from the structure of traditional blockchains. Sui splits objects into owned and shared objects: it lets simple transactions associated with an owned object (See the types) skip the consensus process, whereas it runs Narwhal and Tusk DAG(Direct Acyclic Graph) consensus algorithm for complex transactions associated with a shared object. When Aptos and Sui might look similar, such difference in their structure draws a clear distinction.

sui 트랜잭션, 수이 트랜잭션, 수이, 수이 트랜잭션 검증과정
Sui’s Transaction Validation Flow | Source: Sui Whitepaper

One thing to note here is that letting simple transactions like P2P fund or message transfer skip the consensus process does not mean they are not subject to any types of validation. Validation of such transactions is handled by a rather simpler algorithm for Byzantine Consistent Broadcast. The algorithm bases itself on Fastpay, which ensures security through peer review. Specializing in payment, Fastpay is a high-performing BFT algorithm, the speed of which can reach as high as 80,000 TPS with latency being as low as 100 ms theoretically. Sui employs a mix of Fastpay and DPoS, which allocates votes in proportion to delegated stakes.

The transaction commit on the Sui network can be summed up as follows:

Fastpay

  1. A sender (similar to a leader node) broadcasts a transaction to all Sui validators.

  2. Sui validators send votes to the sender. Under DPoS arrangements, weights are given in proportion to the validators’ stakes in Sui.

  3. The sender collects votes that meet Byzantine fault tolerance requirements and uses them to form a certificate. Then, the sender sends it back to validators and finalizes the transaction.

Narwhal DAG

  1. A sender (similar to a leader node) broadcasts a transaction to all Sui validators.

  2. Sui validators send votes to the sender. Under DPoS arrangements, weights are given in proportion to the validators’ stakes in Sui.

  3. The sender collects votes that meet Byzantine fault tolerance requirements, uses them to form a certificate, and sends it back to validators. Certificates are processed in sequence (This is the consensus process described in the Sui Transaction Validation Process diagram above).

  4. After certificates are processed in order, the sender once again sends the certificates back to validators for the last time to finalize the transaction.

There are four drivers that enable Sui’s mechanism, which has allowed the network to: i) execute transactions in parallel and ii) maximize the TPS of the blockchain by taking a two-pronged approach to transactions, depending on the type of transactions.

  • Unlike most blockchains that first bundle transactions into a block and validate afterwards, Sui validates and stores transactions right after execution. Since the chain ensures two-way communication between senders and validators, Sui boasts low latency and immediate finality.
  • Sui is a blockchain that stores a group of objects. Sui’s basic storage unit is not an account but an object. Sui is a blockchain to manage objects rather than a cluster of states. The object discussed herein is a programmable object that can be created and managed by a Move package (smart contracts), which is an object itself.
  • There are two types of objects on Sui: i) objects that can be owned by specific owners (owned object) and ii) objects that are not owned by specific owners and can be shared by many users.
  • Each object has a unique ID that contains information about which transaction the object arose from and how the object is caused by, resulted from, or dependent on other objects. It means that an ID of an object carries historical data indicative of the inputs and outputs of the object. This way, the unique identifiers tell Sui validators the input and output transactions of each object so that independent transactions free of the risk of double spending can be processed in parallel.

 

Programming Language: Move

Both chains use Move, a Rust-based programming language. Meta developed this open-source language for its Diem blockchain. Compared to Solidity—the most widely adopted programming language in the Web 3.0 ecosystem, Move i) is more aptly expressive of digital assets, ii) maintains higher security, and iii) can run codes through Move’s formal verification tool Move Prover as intended. Similarly to Rust, Move is also memory-safe, making memory management easier.

There has been a series of hacks in the crypto market that took advantage of loopholes in smart contracts. Once a smart contract is executed, it is hard to modify it. This has been a headache for many projects because multiple rounds of smart contract audits prior to dapp launch do not necessarily prevent unexpected variables until Solidity contract’s dynamic dispatch, or deployment, is performed. The recurring issues surrounding security are fueling demand for less vulnerable languages, making Move more attractive to developers. Apart from Aptos and Sui, there are other networks that use Move as their programming language, such as Pontem Parachain and Celo.

 

What Would the Future of Aptos and Sui Look Like?

This year, Ethereum’s Merge is slated for September. Many predict that once the transition to PoS is complete and L2 technology advances further, Ethereum will become predominantly the winner in the crypto market. Although Ethereum’s ecosystem indeed is one of the largest in the crypto market, it seems premature to make a prediction. From the perspective of mass adoption of Web 3.0, Ethereum has not been mainstreamed yet. Once billions of users come on board Web 3.0, there is a plenty of pie still left for other L1 blockchains. According to Electric Capital Developer Report (2021), the number of EVM developers is around 4,000 among a total of around 18,000 Web 3.0 developers as of end-2021. Given that there are around 27 million software developers as of 2021, the percentage Ethereum developers represents is a mere 0.02%, indicative of the fledgling stage of the Web 3.0 market.

웹3, 웹3 개발자
Source: Electric Capital
코인마켓캡, 앱토스, 수이, aptos, sui
Source: Coinmarketcap

The advantages in security, scalability, and convenience powered by excellent developers, resources, and technological prowess are rendering the two monolithic blockchains fully competitive. Solana, which shares many characteristics in common, once suffered much criticism and shutdowns but has emerged as one of the leading players. On top of that, Meta’s 3 billion users may give Aptos and Sui yet another significant edge. (For your information, the Diem project came to a halt because it sought to issue a stablecoin). It may sound far-fetched, but mounting their blockchains on Meta’s platform can also be their option if they are seeking to provide only the wallet and dapp services to the users. Indeed, multiple projects, including Anchorage, BNB Chain, Coinbase, Paxos, and Rarible, are known to be building their services on the Aptos blockchain even though the network is yet in the testnet stage. At this particular juncture of a transition from Web 2.0 to Web 3.0, it is no surprise that the anticipation is building for Aptos and Sui.

 

Other Related Research Articles

 

Disclaimer
I confirm that I have read and understood the following: The information contained in this article is strictly the opinions of the author(s). This article was authored free from any form of coercion or undue influence. The content represents the author's own views and does not represent the official position or opinions of CrossAngle. This article is intended for informational purposes only and should not be construed as investment advice or solicitation. Unless otherwise specified, all users are solely responsible and liable for their own decisions about investments, investment strategies, or the use of products or services. Investment decisions should be made based on the user’s personal investment objectives, circumstances, and financial situation. Please consult a professional financial advisor for more information and guidance. Past returns or projections do not guarantee future results.
Xangle or its affiliated partners own all copyrights of the written or otherwise produced materials and content provided on the platform. Any illegal reproduction of such content, including, but not limited to, unauthorized editing, copying, reprinting, or redistribution will result in immediate legal actions without prior notice.