| Authors | GMX Team |
|---|---|
| Year | 2021 |
| Project | GMX |
| License | MIT |
| Official Source | https://gmxio.gitbook.io/gmx/ |
This page is an educational summary and analysis of an official whitepaper or technical paper, written for reference purposes. It is not a verbatim reproduction. CryptoGloss does not claim authorship of the original work. All intellectual property rights remain with the original author(s). The official document is linked above.
GMX is a decentralized spot and perpetual futures exchange described in its 2021–2022 protocol documentation, initially deployed on Arbitrum (September 2021) and Avalanche (January 2022). GMX’s defining innovation is the GLP (GMX Liquidity Provider) model: a single multi-asset liquidity pool that earns trading fees while acting as the collective counterparty to all trader positions — aligning liquidity provision with protocol revenue.
GMX uses Chainlink oracles (and in v2, Pyth/Chainlink aggregation) for pricing rather than AMM discovery, enabling zero-slippage/zero-price-impact execution for trades within position limits.
> Documentation: Available at gmxio.gitbook.io/gmx.
Publication and Context
In 2021, decentralized perpetuals faced a trade-off:
- AMM-based perps (dYdX v2): Slippage on large trades; AMM price discovery can be manipulated
- Order book perps (dYdX v3): Fast, but centralized off-chain matching engine
GMX took a different approach: use oracle-based pricing with a liquidity pool as counterparty. This eliminated slippage for the trader (they trade at the oracle price regardless of trade size, up to open interest limits) but put price risk on GLP holders.
GLP: The Liquidity Pool
GLP is a basket of assets: approximately 50–55% stablecoins (USDC, DAI, USDT, FRAX) and 45–50% blue-chip assets (ETH, BTC, LINK, UNI). Users can mint GLP by depositing any of these assets (in exchange for a GLP index token) and can redeem GLP for any constituent asset.
GLP mechanics:
- Mint GLP: deposit USDC, ETH, or other assets → receive GLP tokens
- Redeem GLP: return GLP → receive a constituent asset at current oracle prices
GLP as counterparty:
When a trader opens a leveraged long on ETH:
- GMX reserves the trader’s collateral + borrows capital from GLP to fund leverage
- If the trade profits, GLP pays out
- If the trade loses, GLP collects the loss
GLP holders are therefore in the inverse position to aggregate trader PnL. When traders collectively lose, GLP gains; when traders collectively win, GLP loses.
Zero-Price-Impact Execution
In a standard AMM (Uniswap), buying a large amount of ETH moves the price against you. GMX executes at oracle price regardless of trade size (within open interest limits):
- A $10M long ETH position opens at the exact Chainlink oracle price, with no slippage
- Gas costs and a small spread fee (~0.1%) are the only costs
Risk: If oracle prices can be manipulated, GMX positions can be exploited. GMX uses multiple Chainlink oracles with deviation thresholds and position limits to mitigate this.
v2 changes: GMX v2 switched to a more sophisticated oracle aggregation (Pyth + Chainlink) and introduced funding rates (periodic payments between longs and shorts to prevent sustained open interest imbalances).
Revenue Distribution
GMX generates protocol fees from:
- Position opening/closing fees (0.1%)
- Borrowing fees (positions pay per-hour based on utilization)
- Swap fees (spot trades in GLP assets)
Fee distribution:
- 70% → GLP holders (distributed in ETH/AVAX)
- 30% → GMX token stakers (distributed in ETH/AVAX)
esGMX (Escrowed GMX): As an alternative to cash distributions, some fees are distributed as esGMX (escrowed GMX tokens). esGMX can be vested over 1 year into real GMX, or staked immediately for esGMX rewards. This reduces sell pressure while rewarding longer-term holders.
GMX v2: GM Pools
GMX v2 (2023) introduced GM tokens (GMX Market tokens) — isolated liquidity pools for individual trading pairs (e.g., ETH/USD pool, BTC/USD pool) rather than a single GLP basket:
- Each pair has its own GM pool with separate risk exposure
- A GM ETH/USD holder only has exposure to ETH/USD trader PnL, not BTC or LINK
- This allows more sophisticated risk management and enables synthetic pairs (assets priced by oracle without underlying in the pool)
v2 also introduced proper funding rates — longs pay shorts (or vice versa) based on open interest imbalance, a missing v1 feature.
Reality Check
GMX reached peak TVL of >$600M in 2023 and became the dominant DeFi perp protocol for a period. GLP provided attractive yield (10–30% APY in bull market periods) funded by trader losses.
Caveats:
- GLP PnL risk: In strong directional markets where traders are mostly right (e.g., all longs during a bull run), GLP loses. GLP’s performance is inversely correlated to successful trading.
- Oracle manipulation risk: In 2022, GMX was targeted by oracle manipulation attacks on smaller assets (AVAX, near-threshold positions). GMX responded by increasing oracle deviation thresholds.
- v1 limitations: No funding rates in v1 meant open interest could be heavily imbalanced without correction — a design limitation vs. centralized perp exchanges.
- Competition: Hyperliquid, dYdX Chain, and other on-chain order books have captured perp market share since 2023.
Legacy
GMX proved the pool-as-counterparty oracle-priced perp model with billions in trading volume. The GLP model (yield-generating liquidity that acts as a house in a casino) became influential — clones include Gains Network (gTrade), MUX, and many others. The esGMX vesting mechanism for reward distribution has been widely adopted.
Related Terms
Research
- GMX Team. (2021–2022). GMX Protocol Documentation. GMX Exchange.
— Primary documentation. Covers GLP mechanics, fee distribution, oracle pricing, and open interest limits.
- Posen, A.S., & Sheppard, O. (2022). DeFi Risk and AMM Design. Peterson Institute for International Economics.
— Analysis of AMM and oracle-based DEX risk models; context for GMX’s oracle-priced execution design.
- Qin, K., Zhou, L., & Gervais, A. (2022). Quantifying Blockchain Extractable Value: How Dark Is the Forest? IEEE S&P 2022.
— MEV analysis relevant to oracle-based exchange manipulation; covers front-running and price manipulation in DeFi.