llarp::util::Barrier

Barrier class that blocks all threads until the high water mark of threads (set during construction) is reached, then releases them all.

#include <barrier.hpp>

Public Functions

Name
Barrier(unsigned threads)
bool Block()
Returns true if this Block call is the one that releases all of them; returns false (i.e.

Public Functions Documentation

function Barrier

inline Barrier(
    unsigned threads
)

function Block

inline bool Block()

Returns true if this Block call is the one that releases all of them; returns false (i.e.

after unblocking) if some other thread triggered the released.


Updated on 2026-01-10 at 22:49:45 +0000