Status Report: Broken Dependency Orderings in the Linux Kernel
summary
A compiler-integrated checker named lkm dependency checker annotates LLVM IR in an annotation pass and later verifies those annotations in a verification pass to detect broken address and control dependencies that can let weakly-ordered CPUs observe illegal reorderings. It already finds real kernel cases: an assignment of &migrate_node that the optimizer drops, and an RCU return value replaced by a placeholder, both breaking address dependencies interprocedurally. Control-dependency detection is WIP, back-end/LTO and loops cause gaps, and false positives remain a practical limitation.
AI-written summary · about
chapters (14)
- 0:00Introduction
- 0:23Linux kernel memory model
- 1:49Dependency ordering fears
- 3:59Dependency checker design
- 5:44Address dependencies explained
- 10:17Real kernel code example
- 12:41Control dependencies overview
- 15:49Control dependency challenges
- 23:57Defining control dependencies
- 26:47Breaking control dependencies
- 29:37Evidence of problems
- 31:45Tool limitations
- 32:50Future plans
- 33:57Q&A
related talks
39mControl Flow Integrity in the Linux Kernel
45mControl Flow Integrity in the Linux Kernel
53mDocumenting the Design of the Linux Kernel
36mLinux Kernel Developer Panel
19mKeynote: MDS, Fallout, Zombieland, and Linux
20mDLOS: Effective Static Detection of Deadlocks in OS Kernels
41mObject Lifetime Issues - a Threat for Safety?
35mRecursive Read Deadlocks and Where to Find Them
