This project is a part of Staticlibs.
This project contains the following concurrency-related templates:
- single producer single consumer non-blocking (wait-free) FIFO queues based on ProducerConsumerQueue from facebook/folly:
spsc_concurrent_queue
wait-free queue with fixed-size heap storagespsc_waiting_queue
the same as previous one with optional blockingtake
operationspsc_inobject_concurrent_queue
wait-free queue with fixed-size in-object (on-stack for stack allocated queue) storagespsc_inobject_waiting_queue
the same as previous one with optional blockingtake
operation
mpmc_blocking_queue
optionally bounded growing FIFO blocking queue with support for blocking and non-blocking multiple consumers and always non-blocking multiple producerscondition_latch
spurious-wakeup-free lock that uses arbitrary "condition" functor to check locked/unlocked statecountdown_latch
synchronization aid that allows one or more threads to wait until a set of operations being performed in other threads completesgrowing_buffer
non-shrinkablechar
heap buffer with non-destructivemove
(the same ascopy
) logic, grows if needed onmove-in
operation
All queues and locks are non-copyable, non-movable and inherit from enable_shared_from_this
to be used inside std::shared_ptr
.
This library is header-only and has no dependencies.
Link to the API documentation.
This project is released under the Apache License 2.0.
2018-06-12
- version 1.0.3
- drop timer wrapper
2017-12-22
- version 1.0.2
- vs2017 support
2017-04-10
- version 1.0.1
- minor cmake fixes
2017-02-24
- initial public version