Roadmap Start learning
QD06AdvancedQuant DeveloperHard
Concurrency and Networking
Mutexes, atomics, lock-free ideas, TCP, UDP and asynchronous I/O, with the latency costs of each.
1.4 h of lessons~0 min of practice across 0 problems
Prerequisites not done
Lessons0 / 5 lessons
Mastery · target 80%0 / 0 solved
Completing the lessons finishes the module. Mastery also needs 80% of its problems solved.
What you will be able to do
- Identify data races and fix them with mutexes or atomics
- Explain memory ordering and when acquire/release is enough
- Describe a single-producer single-consumer queue and why it can be lock-free
- Compare TCP and UDP and explain why market data often uses multicast UDP
- Design event loops with asynchronous I/O
Before you start
Prerequisites: this module uses their material directly.
Lessons
1.Threads and SynchronisationWhat a data race is and why it is undefined behaviour, std::thread, mutexes and the three lock wrappers, condition variables and spurious wakeups, deadlock and lock ordering, and a producer–consumer queue built from them.18m2.Atomics and Memory Orderingstd::atomic and read-modify-write operations, what seq_cst, acquire/release and relaxed actually guarantee, happens-before through a message-passing example, a litmus test showing the difference on real hardware, and the ABA problem.18m3.Lock-Free QueuesA single-producer single-consumer ring buffer with acquire/release indices, implemented and tested across two threads, padding against false sharing with a measured effect, and why multi-producer multi-consumer queues are much harder.17m4.TCP, UDP and MulticastWhat TCP guarantees and what it costs (handshake, Nagle with delayed ACK, head-of-line blocking), UDP datagrams, why market data is published over multicast UDP with sequence numbers, how gap recovery works, and TCP_NODELAY.17m5.Asynchronous I/OBlocking versus non-blocking sockets, how select, poll, epoll and kqueue differ and scale, the event-loop pattern, a runnable selectors loop and an asyncio quote server, the rule never to block the loop, and a brief look at kernel bypass.16m
Where this module fits
- Quant Developer: Required; optional for Python Research Engineering