Daily Shaarli

All links of one day in a single page.

January 4, 2025

Quirks of Human Anatomy by Lewis Held
The Linux Scheduler: a Decade of Wasted Cores - eurosys16-final29.pdf

This is huge:

Cores may stay idle for seconds while ready threads are waiting in runqueues. In our experiments, these performance bugs caused many-fold performance degradation for synchronization-heavy scientific applications, 13% higher latency for kernel make, and a 14-23% decrease in TPC-H throughput for a widely used commercial database.

DOI: https://dl.acm.org/doi/10.1145/2901318.2901326

It may be useful to read it completely.

Fixes:

  • compare the minimum load of each scheduling groups instead of the average
  • Linux spawns threads on the same core as their parent thread: a node can steal threads from a another node by comparing the average load
    and two others

It is useful to read their tools (online sanity checker for invariants such as "No core remains idle while another core is overloaded")

During the 00s,dozens of papers described new schedling algorithms, [... but] a few of them were adopted in mainstream operatin systems, mainly because it is not clear how to integrate all theseideas in scheduler safely.

Similar the part Related Work describes the current state of the research on other domains: performance bugs, kernel correctness, tracing.

The resources are available on Github: https://github.com/jplozi/wastedcores

Fast and Simple Rust Interner

Interning works by ensuring that there’s only one canonical copy of each distinct string in memory.

Context-Generic Programming

CGP makes use of Rust's trait system to define generic component interfaces that decouple code that consumes an interface from code that implements an interface. This is done by having provider traits that are used for implementing a component interface, in addition to consumer traits which are used for consuming a component interface.

How Do You Like What You’ve Built? — Morris Brodersen

A simple question