mulle_aba is a (pretty much) lock-free, cross-platform solution to the ABA problem written in C.
The ABA problem appears, when you are freeing memory, that is shared by multiple threads and is not protected by a lock. As the subject matter is fairly complicated, please read the Wikipedia article and maybe Preshing: An Introduction to Lock-Free Programming first and then checkout the following items:
Release Version | Release Notes |
---|---|
RELEASENOTES |
This project is a component of the mulle-core library. As such you usually will not add or install it
individually, unless you specifically do not want to link against
mulle-core
.
Use mulle-sde to add mulle-aba to your project:
mulle-sde add github:mulle-concurrent/mulle-aba
To only add the sources of mulle-aba with dependency sources use clib:
clib install --out src/mulle-concurrent mulle-concurrent/mulle-aba
Add -isystem src/mulle-concurrent
to your CFLAGS
and compile all the sources that were downloaded with your project.
Use mulle-sde to build and install mulle-aba and all dependencies:
mulle-sde install --prefix /usr/local \
https://github.com/mulle-concurrent/mulle-aba/archive/latest.tar.gz
Install the requirements:
Requirements | Description |
---|---|
mulle-allocator | 🔄 Flexible C memory allocation scheme |
mulle-thread | 🔠Cross-platform thread/mutex/tss/atomic operations in C |
mulle-linkedlist | 🔂 mulle-linkedlist a wait and lock-free linked list |
Download the latest tar or zip archive and unpack it.
Install mulle-aba into /usr/local
with cmake:
cmake -B build \
-DCMAKE_INSTALL_PREFIX=/usr/local \
-DCMAKE_PREFIX_PATH=/usr/local \
-DCMAKE_BUILD_TYPE=Release &&
cmake --build build --config Release &&
cmake --install build --config Release
Nat! for Mulle kybernetiK