Global exit trees
This section provides details of how the mainnet global exit tree and the rollups' global exit trees are constructed. ## New global exit tree Due to the presenc
This section provides details of how the mainnet global exit tree and the rollups' global exit trees are constructed.
New global exit tree
Due to the presence of multiple layers in the uLxLy bridge, it becomes necessary to adjust the global exit tree so as to accommodate exits across all these layers.
The mainnet has a local exit tree built as an append-only tree of 32 levels.
Each rollup has a local exit tree which is also built as an append-only tree of 32 levels.
All the rollups are grouped together in a tree of rollups called the rollup exit tree, which is again built as an append-only tree of 32 levels.
The figure below illustrates how the global exit tree has been modified in order to introduce more than one rollup.
The design of the updated global exit tree has two main branches:
- One containing the root of the mainnet exit tree, and
- The other branch containing the root of the rollup exit tree, which summarizes exit trees of all the rollups. The rollup exit tree has as its leaves all the local exit roots of the different rollups.

Rollup identifiers
Every rollup has a set of distinct identifiers that are essential for its functioning and interaction within the larger network ecosystem.
- The is a unique identifier that distinguishes a rollup from other chains in the Ethereum ecosystem, and it is crucial for preventing replay attacks. See the list of chain IDs of different networks here.
- A identifier defines a rollup in the Polygon ecosystem, allowing network participants to uniquely identify and interact with the rollup. The Ethereum mainnet is identified by , while the is reserved for the Polygon zkEVM, and so on.
- The is an identifier used to identify a rollup within the rollup tree. The first rollup, being the Polygon zkEVM, has . And in general, .
Global index
When creating and verifying proofs, an index called is used to uniquely locate a leaf in the new global exit tree.
A is a 256-bit string composed of unused bits, mainnet flag, rollup index bits, and local root index bits.
globalIndex = (unused bits)_(mainnet flag)_(rollupIndex)_(local root index)
Starting from the most significant bit, a consists of the following bits:
- bits of unused bits: These bits are unused, and can be filled with any value. The best option is to fill them with zeros because zeros are cheaper.
- bit of mainnet flag: This single bit serves as a flag indicating whether an exit pertains to a rollup (represented by ) or the mainnet (indicated by ).
- bit of the rollup Index: These bits indicate the specific rollup being pointed at, within the rollup exit tree. These bits are therefore only used whenever mainnet flag is .
- bits of the local root index: These bits indicate the specific index being pointed at, within each rollup's local exit tree.
The figure below depicts how the is interpreted:
- The mainnet exit tree has the
globalIndex = X_1_X_3, where- the equals to indicates that it's the mainnet, and
- the being points at the fourth leaf in the mainnet exit tree.
- The rollup 9002's exit tree has the
globalIndex = X_0_1_2, where- the is indicating that it's a rollup,
- the means the rollup is the second in the rollup exit tree, and
- the , pointing at the fourth leaf in the rollup 9002's exit tree.

Last updated on
Updating rollups
!!!caution While it is technically imprecise, for the sake of simplicity, we refer to both rollups and validiums as 'rollups'. ### Updating a rollup It is often
Cross-chain exchanges
This covers node configuration parameters, interchange of tokens among chains, and the mention of an issue with CREATE2. ### Node configuration The node configu