How to Simulate a Low Latency Exchange in C++
summary
Concrete recipe for a C++ low‑latency exchange simulator: replay packet captures into a matching engine that implements a central order book with add/modify/delete and trade logic, route orders through an order gateway, publish updates via a feed publisher, and drive everything with an event queue plus delay models for switches, fiber and compute (examples: C++ ~10 microseconds, FPGA ~100 ns, switch ~100 ns, fiber ~1 ns/20 cm). Also model colocation topology, ACK/REJECT semantics, sequencing and market impact.
AI-written summary · about
chapters (21)
- 0:00Introduction
- 0:52Who am I
- 1:31What is an Exchange
- 2:14Central Order Book
- 6:03What is a Trading System
- 11:39Landscape
- 11:49Goals
- 12:17Simulating
- 13:01Requirements
- 14:04Strategy
- 15:34Questions to Consider
- 18:07What You Need
- 18:45Feed Data
- 19:33Order Gateway
- 19:58Responses
- 20:18Delay Models
- 20:48Simulation Loop
- 21:33Event Queue
- 22:01Priority Queue
- 22:43Matching Engine
- 24:39Outro
related talks
01h 35mC++ Electronic Trading for Cpp Programmers
01h 11mAsynchronous C++
59mThe Networking TS in Practice: Patterns for Real World Problems
55mAbusing Your Memory Model for Fun and Profit
38mScaling Financial Transaction using 0MQ and JSON
05mMaximising Throughput & Minimising Latency in High-Performance C++ Code
01h 19mBuilding a C++/JS Browser for the Financial Markets
01h 01mGet rich quick! Using Boost.Beast WebSockets and Networking TS
