Arctic: A Practical Lock-Free Adaptive Radix Tree
Arctic is a lock-free adaptive radix tree that achieves high performance and range scans, improving write throughput in RocksDB and Turso.
read it The OSDI paper details a novel concurrent data structure design, freezing-based coordination protocol, and memory reclamation scheme that systems engineers can study and apply.
summary
Arctic is a novel lock-free adaptive radix tree (ART) designed to simultaneously deliver high performance, lock freedom, and range scans. It achieves non-blocking operation through a freezing-based coordination protocol and an operation-key memory reclamation scheme. Integrating Arctic into RocksDB and Turso improved write-heavy benchmark throughput by up to 40% and 12% relative to default skiplist indexes.
key points
- Arctic uses a freezing-based coordination protocol and 16-byte atomics to guarantee non-blocking operations without locks.
- It introduces a safe memory reclamation scheme using operation keys to approximate reachable pointers.
- Integration into RocksDB and Turso demonstrates up to 40% and 12% throughput gains on write-heavy workloads over default skiplists.
who should read it
Systems engineers and database developers working on high-performance concurrency and indexing.
discussion warm
consensus
Commenters are highly enthusiastic about a rare lock-free tree that successfully outperforms lock-based alternatives, with the first author actively engaging on implementation details.
pushback
A commenter notes a prior lock-free ART implementation called flock that the authors missed in their initial literature review.
The most subtle bug I've been able to reproduce with shuttle-based testing is [this race in Node47](https://github.com/nwtnni/arctic/blob/efad26c696f28cfdbeec11...), with [this test](https://github.com/nwtnni/arctic/blob/efad26c696f28cfdbeec11...). I did run into some issues trying to compose proptest with shuttle, i.e., writing a test that exercises both random inputs and random interleavings on that input.
For non-concurrent code, the [state machine tests](https://github.com/nwtnni/arctic/blob/efad26c696f28cfdbeec11...) comparing arctic against std::collections::BTreeMap was invaluable for …
The author shares specific subtle race conditions uncovered during shuttle-based concurrency testing and the state-machine testing framework used for validation.
Generated by an LLM from the article and thread. Check the sources before relying on it.