~/talk

Improving CPU Isolation with per-cpu spinlocks: performance cost and analysis

Talkat Linux Plumbers Conference 2023 · 2023-11-13..11-15· [concurrency]
links:none on file
slides:none on file

Work shows replacing queue_work_on(isolated_cpu) with per‑cpu spinlocks avoids IPIs and preserves CPU isolation while costing surprisingly little: a normal spinlock adds ~35 cycles on x86 but an inlined/raw variant cuts that to <15 cycles and a kmalloc-real-world test shows ~9 cycles extra (inlined ~4); remote operations are rare so contention is negligible; preempt_rt already converts local locks to spinlocks and a proposed local_q_work_on helper grabs the remote per‑cpu spinlock instead of scheduling work.

AI-written summary · about

  1. 0:00Introduction to CPU isolation
  2. 1:05Per-CPU caches and global locks
  3. 3:57Problem with IPI in CPU isolation
  4. 4:39Per-CPU spinlocks as a solution
  5. 6:26Performance cost of spinlocks
  6. 8:14Real-world overhead measurements
  7. 9:18Conclusion and benefits
  8. 10:21Addressing PREEMPT_RT concerns
  9. 12:31Q&A on local locks vs spinlocks
  10. 13:16Overhead in non-RT scenarios
  11. 14:41Implementation details and benchmarks
  12. 15:42Q&A on cache data necessity
  13. 16:04Spinlock inlining and kernel size
  14. 17:29Workload and remote operations frequency
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.