Thread System 0.3.1
High-performance C++20 thread pool with work stealing and DAG scheduling
Loading...
Searching...
No Matches
hazard_pointer.h File Reference

Hazard pointer implementation for lock-free memory reclamation. More...

#include <algorithm>
#include <atomic>
#include <cstddef>
#include <functional>
#include <memory>
#include <vector>
Include dependency graph for hazard_pointer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  kcenon::thread::detail::thread_hazard_list
 Thread-local hazard pointer list Each thread maintains a small array of hazard pointers. More...
 
struct  kcenon::thread::detail::retire_node
 Retire node for pending deletion. More...
 
class  kcenon::thread::detail::hazard_pointer_registry
 Global hazard pointer registry Manages all thread-local hazard lists. More...
 
class  kcenon::thread::detail::global_reclamation_manager
 Global manager for orphaned nodes from terminated threads. More...
 
class  kcenon::thread::hazard_pointer
 Single hazard pointer that protects one object from reclamation Uses RAII pattern - automatically releases protection on destruction. More...
 
class  kcenon::thread::hazard_pointer_domain< T >
 Domain managing hazard pointers and retirement for a specific type. More...
 
struct  kcenon::thread::hazard_pointer_domain< T >::stats
 Get statistics. More...
 
struct  kcenon::thread::hazard_pointer_domain< T >::thread_retire_list
 

Namespaces

namespace  kcenon
 
namespace  kcenon::thread
 Core threading foundation of the thread system library.
 
namespace  kcenon::thread::detail
 

Detailed Description

Hazard pointer implementation for lock-free memory reclamation.

See also
safe_hazard_pointer For the improved thread-local variant
lockfree_job_queue For the primary consumer

Definition in file hazard_pointer.h.