Skip to content

Results

The timers behind their slot

The measured numbers of this page are a study of kernel 6.6 and redis 7.4. The data comes from lab data file harness-2026-10-13.json of 2026-10-13, on kernel 6.6 and redis 7.4. The oldest data of this page is 41 days old at this build, on 2026-11-23. The age limit of this data is 30 days, from 2026-12-07. The rule for a void run is in the current harness.

A prediction of the algebra is about the timing of the kernel. But the kernel operates in a VM, and the host can stop a vCPU. Then a timer fires late, and the run measures the host.

The prober records each firing of the keepalive and retransmit timers of a socket, from the timer wheel. Each record has three values:

  • Behind. This value is the number of jiffies between the wheel slot and the time that the CPU did the slot. The wheel does a slot in the tick when the slot is due. Thus a delay here comes from the CPU or the VM, not from the kernel.
  • Late. This value is the number of jiffies between the expiry that the socket asked for and the firing. It is the rounding of the wheel, which the algebra predicts.
  • Owned. This flag tells if the timer found its socket held by its owner.

A run is void when the timer that drives its measurement was 2 jiffies or more behind its slot, in the timed interval. A keepalive timer that found its socket held also makes its run void, because such a timer tries again HZ/20 later.

CellFiringsOn the slot1 jiffy late2 jiffies or moreSocket heldVoid runs
Q1 idle, black hole55532000 of 11
Q2 in flight, black hole, tcp_retries2 = 387842100 of 11
Q2 in flight, black hole, tcp_retries2 = 51091036000 of 11
Q3 in flight, frozen process92902000 of 11
Q4 in flight, a 1 s stall55514000 of 11
Q4 in flight, a 3.5 s stall77734000 of 11
ioredis Q1 idle, black hole1421318302 of 11
ioredis Q2 in flight, black hole, tcp_retries2 = 384831000 of 11
ioredis Q3 in flight, frozen process96914100 of 11
server Q1 idle, black hole55550000 of 11
server Q2 reply in flight, black hole, tcp_retries2 = 388844000 of 11
server Q3 idle, frozen client79790000 of 11
All 12 cells101997737502 of 132
  • Most firings were on their slot. In the twelve cells, 977 of 1019 firings were on their slot, and 37 were one jiffy behind. One jiffy is a tick that occurred while the wheel worked, and δ_abs includes it.
  • A few firings show the VM. Five firings were 2 jiffies behind or more. One of them was 103 jiffies (412 ms) behind, a stall of the VM, but it did not meet an interval that a run timed. One run of 132 was void for this reason, in Q1 of ioredis.
  • The harness itself moved a timer. At 8 environments, the client of the harness read its socket with a timeout. Such a read takes the lock of the socket each time that it wakes. A keepalive timer that finds its socket held sends nothing, and it tries again HZ/20 later, which is 52 ms at HZ 250. At this time, the client waits in poll(), which does not take the lock. After that change, no firing found its socket held.