Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Jargon Decoder

The lookup table for the whole book. Skim it once now; return whenever a later chapter drops a term. Grouped by theme; within a group, roughly the order you’ll meet things. “The analogy” column maps each term onto systems you already run.

1. The hardware

TermExpandedPlain EnglishThe analogyWhere it matters
NICNetwork Interface CardThe device that turns wire signals into bytes in RAM and backA sidecar container with its own CPU/memory that owns all network I/OEverything in Part I; the most-tuned hardware in the rack
PHYPhysical layer transceiverAnalog electronics converting light/voltage into digital bitsTLS-terminating proxy, but it terminates physicsFixed tens-of-ns cost; exotic links (microwave) compete here
MACMedia Access Control layerDigital logic framing bits into Ethernet frames, checking addresses + CRCBody-parsing + signature-check middleware; drops garbage earlyHardware timestamping hooks here; MAC-dropped frames are invisible to software
PCIePeripheral Component Interconnect ExpressThe packet-switched network inside the box linking CPU/RAM to cardsThe app-server↔database network, but in-chassis and ~1000× faster~500 ns–1 µs per device round trip; the latency floor after kernel bypass
DMADirect Memory AccessDevices read/write RAM directly; the CPU copies nothingPresigned S3 upload — client writes straight to storage, server just gets notifiedWhy arrival is CPU-free; the enabling trick of kernel bypass
NUMANon-Uniform Memory AccessEach CPU socket has its own RAM; the other socket’s RAM is ~2× slowerRead replica in another region — same schema, hidden extra hopPin hot threads + memory to the NIC’s socket or eat ~50–100 ns per access
Cache lineThe 64-byte unit in which memory actually movesPostgres reads the whole 8 KB page, never one columnStruct layout; two hot variables per line = one fetch; two writers per line = disaster
MTUMaximum Transmission UnitLargest payload one Ethernet frame carries (default 1500 bytes)Max request-body size — bigger payloads get chunkedFrame count per message; fragmentation is a latency tax
Jumbo framesRaising MTU to ~9000 bytesBatch API endpoint — fewer, bigger requestsThroughput plays (snapshots, recovery); irrelevant to small ticks
FPGAField-Programmable Gate ArrayA chip whose circuitry you rewire to be your programCompiling the hot path into custom silicon instead of running on general-purposeThe endgame: parse-and-respond on the NIC itself, sub-µs, skipping PCIe+CPU

2. The kernel packet path

TermExpandedPlain EnglishThe analogyWhere it matters
IRQInterrupt RequestHardware forcing a core to stop and run a handler nowWebhook vs polling — the device pushes~1–2 µs delivery latency; also victimizes whatever thread was running
MSI-XMessage Signaled Interrupts, eXtendedMany independent interrupt vectors per device, each aimed at a chosen coreOne webhook endpoint per event type, each with its own consumerEnables per-queue → per-core steering; keeps IRQs off strategy cores
hardirqHard interrupt (top half)The minimal urgent part: ack device, schedule follow-up, returnWebhook handler that enqueues a job and returns 200 in 2 msRuns with interrupts blocked; must be tiny
softirqSoft interrupt (bottom half)The deferred bulk work: drain ring, run the network stackThe queue worker draining what the webhook enqueuedDeferrable/migratable → classic source of p99.9 jitter
NAPINew API (its real name)Under load, kernel disables the interrupt and polls the ring in batchesSwitching from per-message callbacks to batch-draining a queue under loadThe kernel’s own admission that polling beats interrupts under load
sk_buffSocket bufferKernel’s per-packet metadata object, allocated/freed per packetExpress req — one object per request, annotated by each middlewareHundreds of ns of overhead per packet; bypass frameworks’ objects are ~a pointer
Descriptor ringFixed circular array in RAM where driver posts empty buffers and NIC fills themBounded SPSC queue: consumer pre-posts empty envelopes, producer fillsOverflow = silent drops (rx_missed); the exact interface bypass maps into your process
Page faultCPU trap when code touches an unmapped memory page; kernel intervenesORM lazy loading — touching a field fires a queryµs+ landmine inside innocent code; pre-touch + mlock everything at boot
TLBTranslation Lookaside BufferTiny cache of virtual→physical address translationsRoute cache in front of a slow resolverMiss = ~100 ns page-table walk before your real access starts
Hugepages2 MB / 1 GB memory pages instead of 4 KB, so the TLB covers far moreConnection pooling for address translationFree tail insurance for big state; DPDK requires them

3. Steering and offloads

TermExpandedPlain EnglishThe analogyWhere it matters
RSSReceive Side ScalingNIC hashes each packet’s flow to pick one of several RX queues/coresConsistent-hash sharding across consumers, in siliconPer-flow ordering + multi-core spread; first steering knob you’ll touch
RPS / RFS / XPSReceive/Flow/Transmit Packet SteeringSoftware versions: kernel bounces packet work to chosen cores (RFS: toward the consuming app; XPS: TX side)App-layer load balancer when the hardware one (RSS) is missing or wrongFallback steering; an extra inter-core hop RSS avoids
Flow steeringExplicit NIC rules: “this port/multicast group → this exact queue”Routing rules pinning one tenant’s traffic to a dedicated worker poolDedicate a queue+core to the feed that matters
GRO / LROGeneric/Large Receive OffloadKernel/NIC merges consecutive same-flow packets into one big one before processingBatching webhook deliveries before handlingThroughput win, latency poison — off on hot paths (batching = waiting)
TSOTCP Segmentation OffloadYou hand the NIC one big buffer; it slices into MTU-sized framesChunked upload handled by the storage SDK, not your codeTX CPU saver; fine for bulk, irrelevant-to-harmful for small urgent sends
MulticastOne packet, delivered by the network to every subscribed hostRedis pub-sub, implemented by the switches themselvesHow exchanges publish market data: every subscriber hears simultaneously
UnicastOrdinary one-sender-one-receiver trafficA normal HTTP callYour order-entry path; contrast with multicast feeds

4. Protocol and socket knobs

TermExpandedPlain EnglishThe analogyWhere it matters
NagleNagle’s algorithmKernel delays small TCP writes hoping to coalesce them into fewer packetsAuto-batching outbound webhooks to save requestsAdds up to ~40 ms (!) to small sends; the classic “why is my order slow”
TCP_NODELAYSocket option that turns Nagle off: send every write immediatelyflush: true — deliver now, efficiency be damnedLine one of every low-latency TCP setup
Delayed ACKDelayed acknowledgmentReceiver waits (~40 ms max) hoping to piggyback the ACK on dataBatching read-receiptsInteracts pathologically with Nagle: request/response ping-pong stalls
RTO / dup-ACKsRetransmission TimeOut / duplicate ACKsHow TCP notices loss: a pessimistic timer (~200 ms floor), or the receiver repeating “still waiting for byte N” — three repeats trigger immediate resend (“fast retransmit”)Webhook retry with exponential backoff, unless the receiver actively reports the gapWhy one lost packet can freeze a TCP feed for 200 ms; fast retransmit needs traffic still flowing to generate the repeats
Receive windowTCP flow controlThe receiver advertises how much buffer it has left; at zero the sender must stop sendingStream backpressure — pause() until the consumer drainsHow a slow consumer physically slows the sender; the mechanism behind every “slow subscriber” story
epollEvent poll (Linux)Register N sockets once; one blocking syscall returns whichever are readyWhat libuv and tokio run on — your event loop’s engineThe C10K solution; its wake-up cost is what busy-polling deletes
SO_BUSY_POLLSocket option: busy pollKernel spins on the driver ring for you instead of sleeping and wakingTight queue.tryPop() loop, but the kernel runs itHalfway house: µs savings without bypass frameworks
io_uringI/O user ringSubmit and reap I/O via two shared-memory rings; syscalls optionalJob queue between you and the kernel replacing per-job RPCModern Linux async I/O; amortizes the syscall wall

5. Kernel bypass

TermExpandedPlain EnglishThe analogyWhere it matters
Kernel bypassNIC DMA-writes packets into your process’s memory; kernel never sees themClients write directly to S3; your API server is out of the data pathThe headline move: ~2–10 µs kernel path → ~1 µs
Zero-copyConsume bytes where they landed; never duplicate themStreaming a request body instead of buffering; sendfileDeletes the copy in recv; pairs with bypass
DPDKData Plane Development KitFramework: unbind the NIC from the kernel; your app owns it, polling from userspaceEvicting Express and speaking raw TCP because the framework tax was the bottleneckThe industry-standard bypass toolkit; brings its own drivers + hugepage pools
PMDPoll Mode DriverDPDK’s userspace driver that spins on the ring; no interrupts, everwhile(true) tryPop() as a formal driver modelWhy DPDK cores sit at 100% CPU by design
Onload(Solarflare/AMD product)Transparent bypass: LD_PRELOAD swaps the socket API’s guts for a userspace stackSwapping the DB driver for a faster wire-compatible one; app code unchangedBypass without a rewrite — sockets API in, kernel out
ef_vi(Solarflare API)Onload’s raw layer: direct access to the NIC’s virtual interfaces, no sockets, no TCPDropping the ORM and the driver — hand-rolled wire protocolLowest-latency Solarflare path; you parse raw frames
XDPeXpress Data PathRun a small verified program (eBPF) inside the driver, at the earliest hook: drop/redirect/pass per packetMiddleware at the CDN edge instead of in the appFilter/steer before any sk_buff exists
AF_XDPAddress Family XDPSocket type where XDP redirects raw frames into your process’s ringKernel-sanctioned bypass — the escape hatch that’s still in the buildingBypass-lite: no vendor lock, kernel keeps coexisting
UMEMUser memory (AF_XDP’s buffer region)The chunk of your process’s memory registered so the NIC can DMA into itThe shared S3 bucket both producer and consumer have keys toWhere AF_XDP packets physically land

6. CPU isolation and tuning

TermExpandedPlain EnglishThe analogyWhere it matters
Pinning / affinityCPU affinityLock a thread to one core so its caches stay warm and it never migratesSticky sessions — same server every time, cache stays hotNon-negotiable for every hot thread
isolcpusIsolated CPUs (boot flag)Remove cores from the scheduler entirely; only pinned threads run thereDedicated instances vs shared tenancyThe strategy core shares with nothing
nohz_fullNo HZ (tick-less) fullStop the kernel’s periodic timer tick on chosen coresTurning off a health-check that interrupts the worker every 4 msDeletes the last periodic ~µs of jitter on isolated cores
C-statesCPU idle statesNumbered sleep depths (C0 awake … C6 off); deeper = slower wakeServerless cold starts, in siliconWake from deep sleep = tens of µs on the packet that mattered; HFT caps at C1
Frequency scalingP-states / governorsCPU clocks down when load looks lightAutoscaling that scales in right before the traffic spikePin the governor to performance; determinism over watts

7. Time

TermExpandedPlain EnglishThe analogyWhere it matters
TSCTime Stamp CounterPer-CPU register counting cycles since boot; read in ~10 nsprocess.hrtime() if it cost nearly nothingThe only clock cheap enough for hot-path timestamps
rdtscRead TSC (the instruction)The single instruction that reads the TSCCalling hrtime() directlyHow you instrument ns-scale code without perturbing it
NTPNetwork Time ProtocolClassic clock sync over the network; ~ms accuracyCron-based reconciliation — fine daily, useless intradayToo coarse for trading; regulation and measurement demand better
PTPPrecision Time ProtocolHardware-assisted sync to ~sub-µs across machinesDistributed tracing with clocks good enough to order spans across hostsCross-machine latency measurement; regulatory timestamps (MiFID II)
PHCPTP Hardware ClockThe clock chip on the NIC itself that PTP disciplinesThe DB’s own now() vs your app server’s clockHardware timestamps come from this clock
SO_TIMESTAMPINGSocket option: timestampingAsk for NIC-hardware timestamps on RX/TX packetsTrusting the load balancer’s access log over your app loggerMeasures true wire-to-wire latency, excluding your own software’s lies

8. Memory and CPU micro-architecture

TermExpandedPlain EnglishThe analogyWhere it matters
False sharingTwo cores write different variables that share one 64-byte cache line; the line ping-pongsTwo services hammering the same DB row for unrelated columnsSilent 10–100× slowdown; fix = pad/align to 64 B
MESIModified/Exclusive/Shared/InvalidThe hardware protocol keeping all cores’ caches agreeing on each lineCache-invalidation events between replicas, in silicon, per 64 bytesThe mechanism behind false sharing and atomic-op costs
CASCompare-And-SwapAtomic instruction: “if it still equals X, set to Y” — the basis of lock-free codeOptimistic concurrency: UPDATE … WHERE version = 41Building block of every lock-free queue; ~20 ns, more under contention
Memory orderingacquire / release / seq_cstHow much the CPU/compiler may reorder your reads/writes around an atomicRead-your-writes vs eventual consistency, at nanosecond scaleChoosing correctly is the hard half of lock-free code; seq_cst is the safe-but-slower default
Lock-free vs wait-freeLock-free: someone always progresses. Wait-free: everyone does, bounded stepsAt-least-one-consumer-progresses vs per-request SLAQueues on the hot path; wait-free = no thread can stall another
SPSC / MPSCSingle/Multi Producer, Single ConsumerQueue disciplines; fewer sides = far simpler and fasterOne webhook source vs many, one worker drainingSPSC ring buffers are HFT’s workhorse pipe — the ring, again
IPCInstructions Per CycleHow many instructions the core actually retires per clock (typ. 0.5–4)Requests/sec per worker — utilization vs stallLow IPC = memory-stalled code; the first diagnosis number in perf
PMUPerformance Monitoring UnitOn-chip counters: cache misses, branch misses, stallsBuilt-in APM (application performance monitoring) agent, in hardware, ~freeWhere all real profiling data comes from
perf(Linux tool)Samples the PMU + stacks to show where cycles/misses goThe profiler tab, for native code, off the PMUThe daily driver for “why is this loop 400 ns not 80”
FlamegraphStack-trace samples rendered as stacked flames; width = time shareYou know this one — same picture, now over CPU samplesReading them below the runtime: kernel frames, not just your functions

9. Measurement discipline

TermExpandedPlain EnglishThe analogyWhere it matters
p99.999.9th percentileThe latency 1-in-1000 events exceedYour p99 dashboards, one digit stricterHFT lives in extreme tails: the bad tick is correlated with the valuable tick
Coordinated omissionMeasuring only when the system deigns to respond, so stalls erase their own evidenceUptime checker that skips checks while the site is downThe classic way benchmarks lie; send on schedule, count the waiting
HdrHistogramHigh Dynamic Range HistogramRecords full latency distributions cheaply from ns to secondsPrometheus histogram buckets minus the resolution lies at the tailStandard tool; its docs are the coordinated-omission sermon
Tick-to-tradeMarket-data packet hits your NIC → your order leaves it; the end-to-end numberWebhook-received → outbound-call-sent, measured at the wire both endsThe single metric the whole book optimizes; wire-timestamped, not app-logged
EWMAExponentially Weighted Moving AverageRunning average that weights recent samples more; old data fades geometrically — one multiply per updateThe rolling latency number on your dashboard, computed incrementallyHow routers (and TCP itself) estimate RTT cheaply; the venue-health signal of the broker and mini-market chapters (ch26, ch28)

10. Trading-system architecture

TermExpandedPlain EnglishThe analogyWhere it matters
ColoColocationYour servers racked in the exchange’s own data centerDeploying into the same AZ (availability zone) as the dependency — physicallyPropagation delay is 5 ns/m; distance is bought, not optimized
Cross-connectThe literal dedicated fiber from your cage to the exchange’s, priced per metreVPC peering, except it is an actual cable and metres are nanosecondsThe shortest permitted path to the matching engine
Feed handlerThe component that parses the exchange’s raw feed into your book/eventsThe webhook-ingestion service: decode, validate, order, dedupe, fan outThe receive hot path; where bypass + parsing tricks concentrate
Gap fillDetecting missed sequence numbers in a UDP feed and recovering themIdempotency keys + replay for missed webhooksUDP feeds drop; you own reliability now (level 4 of the Express-to-wire chapter)
Snapshot / recovery channelSide channel serving current-state snapshots so late/gapped joiners can catch upFull resync endpoint alongside the change stream — bootstrap then tailCold start and post-gap recovery for every feed handler
SequencerSingle choke point stamping one global order on all events; everyone replays the same streamKafka single-partition total order, or your matching engine’s inbound queueThe determinism backbone of exchange-grade architectures
Event sourcingState = fold(events); store the events, derive the stateDouble-entry ledger: the journal is truth, balances are a viewReplayable, auditable, deterministic — natural fit downstream of a sequencer
UpcasterTransformer that migrates old stored events to the current schema on readAPI-version adapters for old webhook payloadsEvolving event-sourced systems without rewriting history
Kill switchPre-armed instant flatten-and-halt path, independent of the strategyCircuit breaker + feature-kill flag, drilled and auditedRegulatory requirement and survival tool; must be faster than the thing it stops

11. Orders and execution (the trader vocabulary)

Part V and the broker chapters speak this dialect constantly. None of it is hard — it’s the web-shop vocabulary of markets.

TermExpandedPlain EnglishThe analogyWhere it matters
CLOBCentral Limit Order BookThe venue’s standing list of buy and sell orders, sorted by price, then by arrival time within a priceA sorted job queue per price level, matched first-come-first-served“The book” — the data structure every venue chapter is about
L1 / L2Level 1 / Level 2 dataL1 = best bid and best ask only; L2 = the whole depth ladder, level by levelA summary endpoint vs the full table plus its change streamThe feed tiers venues sell; the market-data and mini-market chapters (ch25, ch28) build both
The touchThe best bid and best ask — the front of the line, where the next trade happensThe head of the queueQueue position at the touch decides who fills first
Spread (tight / wide)The gap between best bid and best ask. Tight = small gap (cheap to trade now); wide = big gapThe convenience fee for immediacy“Deep” = lots of size resting behind the touch; venue quality in the mini-market lab (ch28) is exactly the tight-vs-deep trade-off
Tick size / lot sizeThe smallest price step / smallest quantity step a venue acceptsPrices in integer cents — no $10.001 allowedWhy hot-path prices are integers in ticks; floats never touch a price
NotionalQuantity × price — the total money at stake, ignoring directionThe cart totalRisk limits and caps are set in notional, not share counts
bpsBasis pointsHundredths of a percent; 100 bps = 1%The unit fees and execution quality are quoted in (no relation to Gbps)
Parent / child orderParent = the client’s whole order; children = the venue-sized slices a router cuts it intoOne API request fanned out into N backend calls, results rolled back upThe SOR chapters; fills report child → parent
TIF (IOC / FOK)Time In Force (Immediate-Or-Cancel / Fill-Or-Kill)How long an order may rest. IOC: fill what you can right now, cancel the rest. FOK: fill it all right now or do nothingRequest timeout semantics — partial results accepted vs all-or-nothingFlags every gateway must honor; venues differ in which they truly support
Post-onlyAn order that may only rest in the book (add liquidity); rejected if it would trade immediately on arrivalInsert-only write — abort on conflict instead of updatingMaker-fee strategies; the “rejects on cross” behavior in the mini-market lab (ch28)
IcebergA big resting order that shows only a small visible slice at a time; each fill reveals the next slicePagination — total count hidden from the clientVenue-side feature; the public feed only ever sees the tip
TWAP / VWAP / POVTime-/Volume-Weighted Average Price, Percent Of VolumeExecution algos for working a big parent: drip it out evenly over time / proportional to when the market usually trades / never exceed X% of live volumeA rate-limited batch job: fixed rate / traffic-shaped / capped at a % of cluster loadWhat “algo selection” means in the broker chapters
OMS / SOROrder Management System / Smart Order RouterOMS: the institution’s system of record for orders. SOR: the component that picks which venue gets each childThe CRUD backend of record + a load balancer with a cost modelThe broker-side machine of the SOR and mini-market chapters (ch26, ch28)
Print / the tapeA print = one executed trade published on the public feed; the running public record is “the tape”A row appearing in the public audit log“Printing volume”, “the worst print of the day”, TCA benchmarks
Slippage / TCATransaction Cost AnalysisScore a fill against the mid-price at the moment the order arrived (“arrival mid”); the shortfall is slippagePrice drift between cart and receipt, measured and reportedHow execution quality is judged; the payoff metric of the broker chapters (ch26, ch28)
AlphaInformation you can profitably trade on before the market prices it inKnowing tomorrow’s traffic spike todayWhy brokers must wall off client intent — seeing a client’s big buy is a signal (“alpha leak”)
Drop copyA real-time duplicate stream of your own orders/fills, sent to risk and compliance systemsMirroring prod events into the audit pipelineIndependent risk monitoring; regulator feeds (the venue and risk chapters — ch23, ch27)

12. Data layer and deployment (the part you already half-know)

TermExpandedPlain EnglishThe analogyWhere it matters
WALWrite-Ahead LogAppend the intent durably before applying it; replay after a crashYou run Postgres; this is its heart — and Kafka is a WAL with an APITrading journals/persistence reuse the pattern; append-only is also the fast path
MVCCMulti-Version Concurrency ControlWriters make new versions; readers see a consistent snapshot; no read locksPostgres again — why VACUUM existsThe same trick reappears in lock-free structures: readers never block
Logical replicationShip decoded row-changes (not disk blocks) to subscribersPostgres pub/sub of row deltas — CDC (change data capture)Feeding analytics/risk systems off the trading DB without touching it
Expand-migrate-contractSchema change in 3 deploys: add new alongside, migrate + dual-write, drop oldYour zero-downtime migration playbookThe only way to change a schema under a system that can’t stop
Blue-greenTwo full environments; flip traffic atomically, flip back to roll backYou’ve done thisDeploying a trading system inside a maintenance window measured in seconds
CanaryNew version takes a small traffic slice first, watched closelyYou’ve done this tooFor strategies: small size limits + tight risk rails before full capital
Shadow deployNew version receives real input, its output compared but never acted onDark launch / dual-run diffingThe pattern for validating a rewritten hot path against the incumbent

13. Wire formats

TermExpandedPlain EnglishThe analogyWhere it matters
FIXFinancial Information eXchangeThe venerable text key=value protocol of institutional trading (35=D|55=AAPL|…)JSON-over-HTTP of finance: verbose, universal, slow-ishOrder entry at most venues; parse cost is real
SBESimple Binary EncodingFixed-layout binary messages; fields at known offsets, zero parsingProtobuf taken further: no varints, no decode step — cast the pointer and readModern feeds and gateways; decode in ~ns, and shorter messages serialize faster (level 7 of the Express-to-wire chapter)

What you can now read

Everything. That’s this chapter’s job — it’s the index you return to, not a rung on the ladder. Concretely: Part I (machine + packet path: groups 1–6), the measurement chapters (groups 7 and 9 — read the coordinated-omission row twice), the concurrency chapters (group 8), and the architecture and operations chapters (groups 10–13, where more of your existing experience transfers than any other part of this book — group 11 is the trader dialect Part V speaks). When a later chapter uses a term that isn’t in this table and isn’t defined on the spot, that’s a bug in the book — flag it.