Repository navigation
Releases
Releases · golang-design/lockfree
v0.1.0
First release of the rewritten package — a near-complete overhaul of the 2019 v0.0.1 snapshot (which shipped only a root-package queue, stack, and AddFloat64). Every data structure is now generic (Go 1.26+), documents its precise non-blocking progress guarantee, and is grounded in a cited, peer-reviewed source (see REFERENCES.md).
Breaking changes
- Reorganized by progress guarantee into two subpackages: lock-free in
golang.design/x/lockfree/lf, wait-free ingolang.design/x/lockfree/wf. The old root concrete types are removed (not aliased) —lockfree.NewQueuebecomeslf.NewQueue, etc. The root now holds only shared helpers (Less,BinarySearch,AddFloat64) and the shared ADT interfaces. - Requires Go 1.26+ (generics).
Added — lock-free (lf)
Stack[T](Treiber)EliminationStack[T](Hendler, Shavit & Yerushalmi elimination backoff)Queue[T](Michael & Scott)Deque[T](Sundell & Tsigas, single-word CAS)SkipList[K,V]/OrderedMap[K,V](Herlihy & Shavit;Get/Searchwait-free)List[K,V](Harris / Michael),HashMap[K,V](Michael),SplitHashMap[K,V](Shalev & Shavit, resizable)
Added — wait-free (wf)
Queue[T](Kogan & Petrank)Stack[T](Herlihy universal construction)Deque[T]andMap[K,V](universal construction over a persistent AVL tree; O(maxHandles · log n))RingBuffer[T](bounded SPSC)
Added — quality and tooling
- Shared conformance suite running identical behavioral tests across every implementation of an ADT
- Contention-swept benchmarks (mutex vs lock-free vs wait-free)
- Differential and fuzz tests; CI runs build,
-race, fuzz, and benchmark jobs REFERENCES.mdciting every implemented algorithm, verified against primary sources
Deferred
- Lock-free bounded MPMC ring (Tsigas & Zhang, SPAA 2001): attempted, but the port is not yet faithful — it passes single-threaded and single-producer tests while reordering and stranding values under concurrent producers. Held back rather than shipping an unverified guarantee; see TODO.md.
Full changelog: v0.0.1...v0.1.0