~/talk

Introduction to Wait-free Algorithms in C++ Programming

Talkat CppCon 2024 · on Sunday, 2024-09-15· [rust]
links:none on file
slides:none on file

Claims a concrete wait-free design for a “sticky” atomic counter in C++ that uses atomics (compare-exchange, fetch_add/fetch_sub, exchange), compare-exchange loop avoidance by helping, and the trick to steal two bits from the counter to mark “zero” and a help flag. Implements an atomic shared_ptr using that counter and runs microbenchmarks on a 28‑core machine: read‑heavy workloads show lower tail latency for the wait‑free variant, but mixed/write‑heavy workloads sometimes favor the simpler lock‑free version.

AI-written summary · about

  1. 0:00Introduction
  2. 1:27What we will cover in this talk
  3. 3:14Sticky counter problem
  4. 8:06Lock-based solution limits
  5. 10:12Danger of guessing performance
  6. 11:58Progress guarantees defined
  7. 17:14Wait-free algorithms intro
  8. 21:50Lock-free compare-exchange loops
  9. 24:37Wait-free design principles
  10. 27:26Helping in wait-free algorithms
  11. 32:20Bits for counter state signaling
  12. 34:07Wait-free counter without read
  13. 43:48Adding read to wait-free counter
  14. 52:41Benchmarking wait-free counter
  15. 56:15Summary of progress guarantees
  16. 57:22Q&A
~/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.