| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
How does price impact differ between an order book (Phoenix) and an AMM (Raydium) on Solana, and why?
A market maker routing size into SOL/USDC needs to know which venue absorbs a given trade without moving the price against it. If an order book holds tighter impact at small size but degrades sharply past its resting depth, while an AMM degrades smoothly but predictably, that shapes how a router should split an order across venues — and at what notional it should stop treating "best quoted price" as a reliable guide to "best executed price."
Venue resolution came back clean on the first pass — both Phoenix and Raydium are present in the current /program-id-to-label list, so no fallback to OpenBook or a two-AMM comparison was needed.
| Size | Phoenix impact | Raydium impact | Phoenix effective price | Raydium effective price |
|---|---|---|---|---|
| $100 | 1.74% | 0.44% | $74.75 | $73.77 |
| $1,000 | 1.70% | 0.46% | $74.72 | $73.79 |
| $10,000 | 7.11% | 0.64% | $79.07 | $73.93 |
| $50,000 | 17.97% | 1.43% | $89.54 | $74.51 |
| $100,000 | 29.51% | 2.39% | $104.20 | $75.25 |
(Baseline unrestricted 1 SOL quote: $73.45.)
Raydium's impact grows slowly and near-linearly across two orders of magnitude of size. Phoenix's impact is already higher than Raydium's at the smallest size tested and accelerates sharply past $10,000 — by $100,000 it is roughly 12x Raydium's impact. There is no crossover in this range: Raydium quotes tighter execution at every size tested, not just at the top end.
The mechanical difference is the shape of the two curves, and it comes from how each venue prices size.
An order book's impact is stepwise: a market order walks through discrete resting orders at successive price levels, and impact stays flat as long as size fits within the liquidity resting near the top of book, then rises in steps as it consumes deeper, worse-priced levels. That is consistent with Phoenix's curve here — flat-ish from $100 to $1,000, then a visible bend upward once size passes whatever was resting near the top of the book, with the steepest step between $10,000 and $100,000.
An AMM's impact is continuous, set by the constant-product curve itself (x·y=k): every trade moves the price along the curve, so impact grows smoothly with size, with no discrete steps. Raydium's near-linear-looking growth across the tested range is that curve behaving as designed — predictable, but never zero, even at $100.
In this snapshot, Raydium's deeper pool dominates Phoenix's order book at every size tested, so there is no crossover point to report — the honest finding is that Phoenix would need meaningfully more resting depth near the top of its book to be competitive with Raydium's pool at these notional sizes, at least at this moment in time.
VERIFIBET's pool design sidesteps this entire question: because all bets on an outcome settle at a single pool-implied price determined at resolution, there is no per-trade price impact curve to walk, no order book to have depth in, and no AMM curve to slide along — the tradeoff analyzed above simply doesn't apply to that market structure.
Time series of impact over a trading day (not a snapshot), a second pair with thinner liquidity, and a note on oracle latency / MEV / LP returns are natural follow-ups — none are in scope here.
The SHA-256 of this README (3e0c029b007f53055417df0425cc502d414d6db40b3d7dc73abc791418e7a745, computed over the file content prior to this section being added) plus the repo URL were sent as a memo transaction on Solana devnet — not mainnet, so this is a free proof-of-timestamp exercise with no real value transferred, and it should be verified with that in mind.
| Back | FazBrowse Home | New Git URL |