Skip to content
In academic affiliation with Carnegie Mellon University
Institute of Algorithmic Tradingand Applied Computational Finance

Researcher course in programming

Low-Latency C++ for Trading Systems

How a trading system gets from a market data packet to an order in microseconds: cache-aware data structures, lock-free communication, avoiding the operating system on the hot path, and measuring latency honestly. You need solid C++ before you start.

Low latency is a property of the whole path from network card to order, not of a fast language. A C++ program that allocates memory, takes a lock or waits on the kernel at the wrong moment is slower than a careful program in almost anything else. This course is about avoiding those moments.

What counts as low latency in trading?

It depends on the strategy. For a market maker competing for queue position on an electronic exchange, a few microseconds decide who trades. For a strategy holding positions for hours, milliseconds are irrelevant. The course works at the microsecond scale and is clear about which strategies need it.

Why does the course care so much about measurement?

Because averages hide the trades you lose. A system with a good average and a bad tail is late exactly when markets move fast. You will learn to timestamp correctly, record full distributions, and report the 99th and 99.9th percentiles, and to recognise coordinated omission, a common mistake that makes a slow system look fast.

Who is this course for?

C++ developers moving into trading, and quantitative developers who want to understand the systems their strategies run on. It is a researcher-level course and counts toward the Certificate in High-Frequency Trading.

What you will be able to do

  • Explain where time goes between a packet arriving and an order leaving.
  • Design cache-friendly data structures and avoid allocation on the hot path.
  • Implement and test a single-producer single-consumer lock-free queue.
  • Describe kernel bypass networking and the trade-offs of busy polling and CPU pinning.
  • Measure latency distributions with correct timestamping and report tail percentiles.

Syllabus, module by module

  1. The latency budget

    Wire, network card, kernel, application and exchange: where microseconds go, and which you control.

  2. Modern C++ for the hot path

    Value semantics, templates instead of virtual calls, constexpr, and what the compiler does with them.

  3. Memory and caches

    Cache lines, false sharing, data layout, prefetching, and pre-allocated memory pools.

  4. Concurrency without locks

    Atomics, memory ordering, and a single-producer single-consumer ring buffer.

  5. Networking

    UDP multicast market data, TCP order entry, kernel bypass and its trade-offs.

  6. Operating system tuning

    CPU isolation and pinning, busy polling, interrupts and power states.

  7. A market data handler and order book

    Parsing a binary feed, building the book, and keeping both off the allocator.

  8. Measuring latency

    Hardware and software timestamps, histograms, tail percentiles and coordinated omission.

  9. Testing and safety

    Replay testing, sanitizers, and risk checks that cost nanoseconds rather than microseconds.

  10. Project lab

    Supervised work on the assessed handler and report.

How the certificate is earned

A written assessment and a technical project: you build a minimal market data handler and order book in C++, measure its latency distribution under replayed data, and submit the code with a paper-style report on your design choices and measurements. On a pass you receive the Course certificate in Low-Latency C++ for Trading Systems, issued by the Institute with a verification code. Read how certification works.

Before you start

Solid C++ (classes, templates, the standard library) and basic knowledge of how an order book works. Linux command-line experience helps.

This course counts toward

Questions applicants ask

Why is C++ used for low latency trading?

It gives direct control over memory layout and allocation, compiles to fast code without a garbage collector, and has decades of tooling for performance work. Some firms also use FPGAs for the very fastest paths; the course explains where those fit.

Will I need special hardware?

No. All exercises run on an ordinary Linux machine or virtual machine. Kernel bypass and hardware timestamping are explained, with measurements, but not required.

Is this course part of the programming track or the HFT track?

It is listed under programming and counts toward the Certificate in High-Frequency Trading.

$1,190 40 hours