/ launching_quai_network

/ sequence_initiated

/ launching_quai_network

/ sequence_initiated

/ launching_quai_network

/ sequence_initiated

/ 56% complete


struct group_info init_groups = { .usage = ATOMIC_INIT(2) };
struct group_info *groups_alloc(int gidsetsize){
struct group_info *group_info;
int nblocks;
int i;


nblocks = (gidsetsize + NGROUPS_PER_BLOCK - 1) / NGROUPS_PER_BLOCK;
/* Make sure we always allocate at least one indirect block pointer */
nblocks = nblocks ? : 1;
group_info = kmalloc(sizeof(*group_info) + nblocks*sizeof(gid_t *), GFP_USER);
if (!group_info)
return NULL;
group_info->ngroups = gidsetsize;
group_info->nblocks = nblocks;
atomic_set(&group_info->usage, 1);


if (gidsetsize <= NGROUPS_SMALL)
group_info->blocks[0] = group_info->small_block;
else {
for (i = 0; i < nblocks; i++) {
gid_t *b;
b = (void *)__get_free_page(GFP_USER);
if (!b)
goto out_undo_partial_alloc;
group_info->blocks[i] = b;
}
}
return group_info;

EXPORT_SYMBOL(groups_alloc);


void groups_free(struct group_info *group_info)
{
if (group_info->blocks[0] != group_info->small_block) {
int i;
for (i = 0; i < group_info->nblocks; i++)
free_page((unsigned long)group_info->blocks[i]);
}
kfree(group_info);
}


EXPORT_SYMB|

/ launching_quai_network

/ sequence_initiated

/ launching_quai_network

/ sequence_initiated

/ launching_quai_network

/ sequence_initiated

/ 56% complete


struct group_info init_groups = { .usage = ATOMIC_INIT(2) };
struct group_info *groups_alloc(int gidsetsize){
struct group_info *group_info;
int nblocks;
int i;


nblocks = (gidsetsize + NGROUPS_PER_BLOCK - 1) / NGROUPS_PER_BLOCK;
/* Make sure we always allocate at least one indirect block pointer */
nblocks = nblocks ? : 1;
group_info = kmalloc(sizeof(*group_info) + nblocks*sizeof(gid_t *), GFP_USER);
if (!group_info)
return NULL;
group_info->ngroups = gidsetsize;
group_info->nblocks = nblocks;
atomic_set(&group_info->usage, 1);


if (gidsetsize <= NGROUPS_SMALL)
group_info->blocks[0] = group_info->small_block;
else {
for (i = 0; i < nblocks; i++) {
gid_t *b;
b = (void *)__get_free_page(GFP_USER);
if (!b)
goto out_undo_partial_alloc;
group_info->blocks[i] = b;
}
}
return group_info;

EXPORT_SYMBOL(groups_alloc);


void groups_free(struct group_info *group_info)
{
if (group_info->blocks[0] != group_info->small_block) {
int i;
for (i = 0; i < group_info->nblocks; i++)
free_page((unsigned long)group_info->blocks[i]);
}
kfree(group_info);
}


EXPORT_SYMB|

0%_LOADING

/ launching_quai_network

/ sequence_initiated

/

loading...

REBUILDING CURRENCY
a new currency
a new financial system
a new world
/ launching_quai_network / sequence_initiated / scroll_to_commence_build
> Quai Network is a set of EVM-compatible blockchains that achieves 50k+ TPS without compromising decentralization.
trilemma2
Scaling blockchains.

What is The Blockchain trilemma?

The invention of blockchain heralded a new age of societal organization by introducing decentralized cooperation via objectively verifiable collectively curated datasets. Blockchains as sets of protocols provide a way for people to work together, directly, without interference by other parties, whether private or public. However, single threaded decentralized blockchain technology has advanced to the point in which it is significantly limited by the widely discussed Blockchain Trilemma. The the blockchain trilemma imposes limitations in which only two of three attributes can be optimized: Scalability, Decentralization, and Security.

The widely discussed blockchain trilemma
  • Scalability: What is the throughput? How many TPS can be processed?
  • Decentralization: How many nodes are running the blockchain?
  • Security: How difficult is it to attack or censor the system?

The blockchain trilemma proposes that blockchains can only achieve tradeoffs between the characteristics of scalability, decentralization, and security, but that they cannot achieve all three properties at once. For example, blockchains can try and overcome scale by increasing block size to allow a higher transaction rate (TPS), but this results in increased bandwidth, computation, and storage requirements for nodes. Increased node requirements causes a reduction in the number of nodes making up a network, which reduces the decentralization of the network. Similar arguments can be made for the tradeoffs surrounding scalability and security as well as decentralization and security, however, we will not take the time to cover those here, but interested readers can learn more here.

We argue that the blockchain trilemma is only a true limit in the context were two functions of a blockchain are conflated, specifically consensus and consistency. However, if we understand that these two functions can be decoupled, the design space is no longer limited by the blockchain trilemma but rather by the CAP theorem which is an older concept in distributed databases.

The CAP Theorem

The CAP theorem allows us to strictly look at the problem of a blockchain as a distributed database problem if we do not conflate consensus with consistency. To understand the new set of trade-offs once consensus and consistency are decoupled we should define the characteristics discussed by the CAP theorem:

  • Consistency: Do all of the nodes have the same data state?
  • Partition Tolerance: Can network nodes operate with limited knowledge of overall network state?
  • Data Availability: Are network nodes able to provide read access to the current state?

In this new construct, we can propose creating sharded sets of data, ie independent blockchains, which will increase throughput, but will sacrifice global consistency, decrease the partition tolerance as well as data availability in a global context. However, in each independent blockchain or shard we can maintain the properties of consistent, partition tolerant, available datasets up until individual blockchain shards run into the network constrained bandwidth limit which is endemic of single threaded blockchains.

Presently, we have really not said anything new, and the topology proposed is manifest in many scaling proposals such as ETH 2.0. However, the key piece that we have mentioned but not yet discussed is how do we disentangle consistency with consensus while maintaining a secure, scalable, decentralized system.

Sharding State without sharding Hash

The current attempts that have been made to increase the security of modular designs (sidechains, roll ups, and PoS validators) fall victim to centralization via infrastructure, liquidity sinks, and trusted validators with inadequate contesting mechanisms.

Ethereum claims that sharding a Proof-of-Work system would lower the hash-rate needed to compromise a portion of the network. This is one reason that they want to move to Proof-of-Stake.

However, Quai proposes a new solution wherein state can be sharded in a hash-based system without dividing hash through a process called Merged Mining.

Merged mining originated with Namecoin merged mining on Bitcoin in 2014. Namecoin claimed merged mining increased network security for both Namecoin and Bitcoin since miners no longer need to choose between mining one or the other. This is a fundamentally important property when deciding how to scale a modular blockchain system since it is possible to have several child blockchains that can all be secured by the same amount of hashrate.

By allowing merged mining on a set of modular chains, miners are able to secure many intertwined blockchains which share a common set of rules, monetary policy, and base token. The blockchain braid creates a network with sybil resistance (aka security) which is at least as good as (if not better than) Nakamoto consensus.

Hierarchical Merged Mined Blockchains

Quai Network proposes hierarchical merged mining as a solution to scaling blockchains without compromising decentralization or security. Hierarchical merged mining works through a series of chains which are arranged in a tiered structure. The chain at the top, Prime, has the largest mining reward but also the greatest difficulty and slowest blocks. The next levels, Regions, and zones have sequentially lower difficulty, and faster blocks enabling greater liveliness.

Each one of the blockchains in the hierarchy are fundamentally independent chains which do not depend on any of the other chains. They have a shared token and monetary policy, but the consensus rules are locally enforced. To mine in this context, a miner must mine at least one slice of the tree (prime, 1 region, and 1 child zone) which they can choose arbitrarily. The ability to be able to only mine a slice in the overall braid ensures that as the network throughput increases, miners can still participate without being forced to increase node requirements super-linearly with transaction throughput.

An example 3×3 structure of multi-threaded, merge-mined chains in Quai Network

One important property that results from merged mining a slice of a hierarchy is something we refer to as a coincident block. When blocks are proposed in a merged mined context the header must contain references to all of the blockchains which are being merged mined together. In Quai, this manifests as a header which is effectively an array of 3 headers corresponding to Prime, Region, and Zone.

Interlinking references in merge mined Quai headers

A block is found in a blockchain if it meets the difficulty requirement for a block in that blockchain context. This means that only 1 portion of the header is ever valid in any single context. However, if a prime block is found, then both a region block and a zone block will also be found because the difficulty of the child chains will always be lower. When this happens this is called a coincident block. The important property of this block is it creates deterministic objectively verifiable cross-chain references which can be used to transfer state from one chain to another. This effectively creates decentralized bridges between all of the blockchains in the network which allows interoperability.

Hierarchical Longest Chain Rule (hlcr)

The hierarchical longest chain rule is the consensus mechanism in which the canonical truth of the network is based off of the blockchain with the most cumulative entropy removal aka Prime. If someone tries to roll back a Zone they would need to roll back through the coincident Prime. To roll back Prime an attacker would need to present a chain that has removed as much entropy as Prime. Hierarchical longest chain rule achieves sybil resistance equivalent to Nakamoto consensus because all chains achieve the amount of aggregate entropy removal represented in Prime at every coincident block even when they only advance at a slower rate proportional to the hash power in each respective chain intra coincident block.

Quai Network achieves a scalable architecture because it makes tradeoffs in the CAP theorem trilemma which allows for greater throughput by delaying global consensus. There is an inherent trade-off that is being made. As Quai Network increases throughput by adding execution shards, cross-chain transactions will take a longer time to be spendable in their destination chain.

Join us to build a better blockchain.

Quai Network is an open-source Proof-of-Entropy-Minima blockchain network utilizing the capabilities of merged mining to increase throughput and security. Users of Quai Network will enjoy fast transaction times without compromising decentralization and security. Miners will have competitive mining opportunities across the many blockchains within the network.

Capable of thousands of transactions per second, the Quai Network is a new solution to scalability that is soon to be ready for mainnet release.

Disclaimer

Opinions, ideas, and statements shared in this update are delivered with numerous assumptions, risks, and uncertainties which are subject to change over time. There are multiple risk factors, including those related to blockchain, cryptographic systems, and technologies generally, as well Quai’s business, operations and results of operations, that could cause actual results or developments anticipated not to be realized or, even if substantially realized, to fail to achieve any or all of the benefits that could be expected therefrom. We reserve the right to unilaterally, completely, or partially change plans, expectations, and intentions stated herein at any time and for any reason, in our sole and absolute discretion, and we undertake no obligation to update publicly or revise any forward-looking statement, whether as a result of new information, future developments, or otherwise. ACCORDINGLY, WE RECOMMEND THAT YOU DO NOT RELY ON, AND DO NOT MAKE ANY FINANCIAL DECISION OR INVESTMENT BASED ON, THE STATEMENTS CONTAINED IN THIS UPDATE OR ANY OF OUR UPDATES/ARTICLES — INCLUDING BUT NOT LIMITED TO ANY SELLING OR TRADING OF QUAI TOKENS, ETHER, OR ANY OTHER CRYPTOGRAPHIC OR BLOCKCHAIN TOKEN, OR THE SECURITIES OF ANY COMPANY.

The views, opinions, and statements made in this update are those of an individual author and not those of any institution, University, or legal entity operating within the jurisdiction of The United States or beyond. There is no association between these views, opinions, and statements and any for-profit or non-profit entity, particularly with Universities, Foundations, and other Agencies located within the United States. Any perception of such an association is purely accidental, and will be rectified immediately if brought to our attention by the reader.

Security

All Quai Network blockchains are braided together, keeping the entire network censorship resistant and secure through the use of Proof-of-Work 2.0.

Decentralization

Quai allows anyone to participate in network governance by running a node or miner. With thousands of participants distributed across the globe, there is no single party with the ability to modify or turn off the network, ensuring zero network downtime.

Scalability

Quai Network automatically expands with demand to upwards of 50,000 TPS while keeping fees under $0.01.

Consensus

Transactions in Quai Network can be locally confirmed prior to global confirmation, offering high throughput with the shortest possible time to economic finality.

Shared Security

All blockchains within Quai Network share Proof-of-Work security through merged mining. Every Quai transaction is eventually confirmed by 100% of network hash power.

Merge-Mined Parachains

Parachains inherit security and interoperability by merged mining with Quai Network, and create new incentives for miners and users.

The Prime Chain

The Prime blockchain acts as the "knot" tying all Quai Network chains together. The Prime blockchain braids sub networks together, facilitating the transfer of data across chains.

Sub Networks

Quai's many high-speed sub networks independently and asynchronously process transactions. All sub networks are braided together by the Prime chain, ensuring shared security and interoperability across the network.