Language Runtimes · Cluster

Runtime Concurrency

Schedulers, green threads, and event loops.

  1. 01 Readiness Notification and the Single-Threaded Event Loop How one thread watches thousands of file descriptors through epoll or kqueue, why edge-triggered notification forces handlers to drain until EAGAIN, and where the dispatch loop stalls. foundational · Mar 17, 2026
  2. 02 Green Threads and the Cost of a User-Space Context Switch What a green thread actually saves compared with a kernel thread, which registers a switch must preserve, and why a scheduler that lives in user space changes the blocking rules of the whole runtime. foundational · Mar 19, 2025
  3. 03 Yield Points and What Makes a Task Cooperatively Schedulable Why a scheduler that cannot interrupt needs the compiler to place checkpoints, how the choice of checkpoint changes latency, and what a missing yield point does to every task behind it. foundational · Jun 24, 2024
  4. 04 Readiness and Completion: Two Ways to Ask the Kernel for I/O Readiness notification tells a program when an operation can start; completion notification tells it when one has finished. The difference decides how many syscalls a runtime makes and where its buffers live. intermediate · May 21, 2025
  5. 05 Work-Stealing Deques and Why the Thief Takes the Oldest Task Per-worker deques with LIFO local execution and FIFO stealing keep hot data on one core, and the memory-ordering requirements that make the concurrent deque correct are narrower than they look. intermediate · Sep 22, 2024
  6. 06 Stackful and Stackless Coroutines: Where Suspension Is Allowed A stackful coroutine can suspend inside any call; a stackless one can only suspend where the compiler emitted a resume point. The difference is a per-task stack versus a state machine, and it decides which libraries a task may call. intermediate · Nov 6, 2024
  7. 07 When a Blocking Call Enters an Asynchronous Runtime A blocking system call inside a task stalls the carrier thread and every task queued behind it. What detection is possible, what a blocking pool costs, and why the boundary is drawn at the library. intermediate · Sep 8, 2026
  8. 08 Cancellation and Drop at Suspension Points Stopping a task means unwinding or abandoning whatever state it holds at the moment it was suspended. Why cancellation is safe only at suspension points, and what a partially completed operation leaves behind. advanced · Jun 3, 2026
  9. 09 Hierarchical Timing Wheels for Millions of Timeouts A heap of deadlines costs O(log n) per insertion and O(1) to read the next one. A hashed wheel with cascading levels makes insertion O(1) and confines expiry to one bucket, at the price of resolution and a bounded maximum interval. advanced · Jan 11, 2024
  10. 10 Fairness and Tail Latency in Task Schedulers Average latency hides the requests that wait behind a queue. How scheduler policy, queue discipline, and batching each move the tail, and why a fair scheduler can still produce an unfair system. advanced · Dec 6, 2021