Skip to main content

Module stall

Module stall 

Source
Expand description

stall submodule. Per-FD socket backpressure classifier — poll each socket FD’s kernel send/recv buffer occupancy over successive samples and classify the direction of the stall.

Verdicts, per (pid, fd):

  • TX-STALLED — the send buffer stays persistently near capacity and is not draining. The local process keeps writing but the kernel cannot hand the bytes off: the peer (or the network) is not reading.
  • RX-STARVED — the receive buffer stays persistently high (and often grows). Bytes have arrived but the local process is not read()-ing them fast enough.
  • HEALTHY — neither buffer is persistently backed up.

On macOS all four inputs (recv_queue/send_queue/recv_buf_size/ send_buf_size) are available, so classification is fill-ratio based. On Linux /proc/net/tcp exposes the queue occupancies but not the socket buffer limits, so the classifier falls back to a trend rule (persistently non-zero and non-draining/growing).

Structs§

StallDetector
StallDetector — tracks per-(pid, fd) socket buffer occupancy history and classifies backpressure direction.

Enums§

Verdict
Directional backpressure verdict for a single (pid, fd).