A hybrid thread/fiber task scheduler for C++11 that enables efficient execution of blocking tasks.
Marl is a hybrid thread and fiber task scheduler written in C++11 that enables efficient execution of tasks across multiple threads. It solves the problem of blocking tasks by using fibers to yield execution, allowing other tasks to run while waiting, thus maximizing hardware thread utilization.
C++ developers building high-performance applications that require efficient task scheduling, such as game engines, servers, or real-time systems needing to handle blocking operations without wasting threads.
Developers choose Marl for its hybrid approach that combines threads and fibers, providing efficient blocking task handling with a simple API, cross-platform support, and no external dependencies, making it a lightweight yet powerful concurrency solution.
A hybrid thread / fiber task scheduler written in C++ 11
Combines threads and fibers to yield on blocking tasks, preventing thread wastage and maximizing hardware utilization as highlighted in the key features.
Runs on multiple OSes including Windows, macOS, Linux, and mobile platforms across various architectures, as listed in the README's supported systems.
Self-contained library with no required external dependencies for core functionality, simplifying integration, though unit tests need googletest.
Provides an intuitive interface with marl::schedule() and defer() for minimal boilerplate, demonstrated in the example code for task management.
Requires precise binding and unbinding of the scheduler to threads to avoid undefined behavior or destructor blocking, as warned in usage recommendations.
Cannot safely use standard blocking functions like std::mutex::lock in tasks without risking deadlocks, necessitating workarounds like marl::blocking_call.
Recommends a single scheduler instance per process lifetime, which can be limiting for modular or dynamic application architectures.
A fast multi-producer, multi-consumer lock-free concurrent queue for C++11
A General-purpose Task-parallel Programming System in C++
A simple C++11 Thread Pool implementation
ArrayFire: a general purpose GPU library.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.