PROFESSIONAL TRADING INFRASTRUCTURE
T
TOME
C++ ORDER MATCHING ENGINE
ULTRA-LOW LATENCY
PRICE-TIME PRIORITY

Interactive Bloomberg Terminal interface to the real TOME matching engine. Submit LIMIT and MARKET orders. Observe the book, tape, and fills in real time. Powered by compiled C++ (WASM) or high-fidelity JS simulation.

WASM • REAL-TIME • NO SERVER REQUIRED
QUICK PREVIEWLIVE DEMO
101.00350
100.50250
100200100.90
150300101.50
LAST FILL 101.00 × 350
MATCHING • SPREAD 0.90
O(1)
BEST BID/ASK
PRICE × TIME
PRIORITY MATCHING
LIMIT + MARKET
ORDER TYPES
C++ / WASM
REAL ENGINE AVAILABLE
BUILT FOR SPEED AND CORRECTNESS

Engine Features

Real-Time Matching
Instant fills using price-time priority. Market and limit orders supported with partial fills.
Native C++ Core
Core matching logic in modern C++. Optional high-fidelity execution via WebAssembly in the browser.
Full Order Book
Aggregated depth, best bid/ask, trade tape, and CSV export. Cancel support on simulated path.
Bloomberg Terminal UI
Dense, professional interface modeled on real trading terminals. Command line + form entry.
Mirror + WASM Sync
JS simulation mirrors the exact C++ behavior for zero-config use. Full WASM when binaries present.
Deterministic & Auditable
Predictable matching rules. Trade records with buy/sell IDs, timestamps, and quantities.
CORE ENGINE

TOME C++ Matching Engine

PRICE-TIME PRIORITY FIFO

Full limit order book with strict price priority then time priority. MARKET orders sweep the book instantly. LIMIT orders rest on the book until filled or cancelled. Real matching logic runs in compiled C++.

• Bids sorted highest price first
• Asks sorted lowest price first
• Same-price: arrival order (FIFO)
• Partial fills supported
ORDER BOOK
Aggregated depth at each price level. Instant snapshot of liquidity. Click rows in terminal to inspect (sim mode).
TRADE TAPE
Every matched trade logged with buyer/seller order ids, price and quantity. Exportable as CSV for analysis.
WASM / SIM MODES
When WASM present: full native C++ speed + identical behavior. Fallback to pure TS mirror keeps full functionality for demos.
Command syntax: buy 100 limit 101.50sell 250 market
WHAT IS TOME?

TOME — Tiny Order Matching Engine — is a minimal, correct C++17 limit order book running live inside a Bloomberg-style terminal built with Next.js and WebAssembly.

Prices execute according to strict price-time priority: the highest bid or lowest ask matches first, and within each price level, orders are processed in the exact sequence they arrived.

The entire matching engine is authentic compiled C++ code delivered to the browser via Emscripten. No toy simulation. Submit LIMIT and MARKET orders, watch the book move, and review every trade that crosses.

HOW IT WORKS

4 Simple Steps to Live Matching

SUBMIT ORDER
Use the form or command line. LIMIT or MARKET on BUY/SELL. Price in ticks (e.g. 10150 = 101.50).
STEP 1
MATCH IN ENGINE
C++ core matches using price-time priority. MARKET sweeps best available. LIMIT rests if no cross.
STEP 2
LIVE SNAPSHOT
Book updates instantly. Bids/asks panels, depth bars, best bid/ask, spread, last trade.
STEP 3
AUDIT & EXPORT
Trade tape shows every fill with IDs. Export CSV. Reset or run demos anytime.
STEP 4
All execution happens client-side. Real C++ when WASM loaded. Full fidelity mirror otherwise.
Ready to interact with the real engine?
Submit orders, watch the book move, export trades. All in your browser.
TRY THE TERMINAL NOW