YACLib
C++ library for concurrent tasks execution
|
Namespaces | |
namespace | detail |
namespace | fault |
namespace | fiber |
Classes | |
class | FairThreadPool |
TODO(kononovk) Doxygen docs. More... | |
class | Future |
Provides a mechanism to access the result of async operations. More... | |
class | FutureBase |
Provides a mechanism to access the result of async operations. More... | |
class | FutureOn |
Provides a mechanism to access the result of async operations. More... | |
class | IExecutor |
class | IFunc |
Callable interface. More... | |
class | IntrusivePtr |
A intrusive pointer to objects with an embedded reference count. More... | |
class | IRef |
Reference counting interface. More... | |
class | Job |
Callable that can be executed in an IExecutor. More... | |
class | ManualExecutor |
TODO(mkornaukhov03) Doxygen. More... | |
class | Mutex |
Mutex for coroutines. More... | |
struct | NoRefTag |
class | OneShotEvent |
This class useful to wait or co_await some event. More... | |
class | Promise |
class | Result |
Encapsulated return value from caller. More... | |
struct | ResultEmpty |
class | ResultError |
class | SharedGuard |
class | SharedMutex |
SharedMutex for coroutines. More... | |
class | StickyGuard |
struct | StopError |
Default error. More... | |
class | Strand |
class | Task |
Provides a mechanism to schedule the some async operations TODO(MBkkt) add description. More... | |
class | UniqueGuard |
class | WaitGroup |
An object that allows you to Add some amount of async operations and then Wait for it to be Done. More... | |
Enumerations | |
enum class | FailPolicy : unsigned char { None = 0 , FirstFail = 1 , LastFail = 2 } |
This Policy describe how algorithm interpret if Future will be fulfilled by fail (exception or error) More... | |
enum class | OrderPolicy : unsigned char { Fifo = 0 , Same = 1 } |
This Policy describe how algorithm produce result. More... | |
enum class | ResultState : unsigned char { Value = 0 , Exception = 1 , Error = 2 , Empty = 3 } |
Functions | |
template<typename V = void, typename E = StopError> | |
Contract< V, E > | MakeContract () |
Creates related future and promise. | |
template<typename V = void, typename E = StopError> | |
ContractOn< V, E > | MakeContractOn (IExecutor &e) |
template<typename V = Unit, typename E = StopError, typename... Args> | |
auto | MakeFuture (Args &&... args) |
Function for create Ready Future. | |
template<typename E = StopError, typename Func > | |
auto | Run (Func &&f) |
Execute Callable func on Inline executor. | |
template<typename E = StopError, typename Func > | |
auto | Run (IExecutor &e, Func &&f) |
Execute Callable func on executor. | |
template<typename V = void, typename E = StopError, typename Func > | |
auto | AsyncContract (Func &&f) |
Execute Callable func on Inline executor. | |
template<typename V = void, typename E = StopError, typename Func > | |
auto | AsyncContract (IExecutor &e, Func &&f) |
Execute Callable func on executor. | |
template<typename Event = detail::DefaultEvent, typename... V, typename... E> | |
YACLIB_INLINE void | Wait (FutureBase< V, E > &... fs) noexcept |
Wait until Ready becomes true. | |
template<typename Event = detail::DefaultEvent, typename It > | |
YACLIB_INLINE std::enable_if_t<!is_future_base_v< It >, void > | Wait (It begin, It end) noexcept |
Wait until Ready becomes true. | |
template<typename Event = detail::DefaultEvent, typename It > | |
YACLIB_INLINE void | Wait (It begin, std::size_t count) noexcept |
Wait until Ready becomes true. | |
template<typename Event = detail::MutexEvent, typename Rep , typename Period , typename... V, typename... E> | |
YACLIB_INLINE bool | WaitFor (const std::chrono::duration< Rep, Period > &timeout_duration, FutureBase< V, E > &... fs) noexcept |
Wait until the specified timeout duration has elapsed or Ready becomes true. | |
template<typename Event = detail::MutexEvent, typename Rep , typename Period , typename Iterator > | |
YACLIB_INLINE std::enable_if_t<!is_future_base_v< Iterator >, bool > | WaitFor (const std::chrono::duration< Rep, Period > &timeout_duration, Iterator begin, Iterator end) noexcept |
Wait until the specified timeout duration has elapsed or Ready becomes true. | |
template<typename Event = detail::MutexEvent, typename Rep , typename Period , typename Iterator > | |
YACLIB_INLINE bool | WaitFor (const std::chrono::duration< Rep, Period > &timeout_duration, Iterator begin, std::size_t count) noexcept |
Wait until the specified timeout duration has elapsed or Ready becomes true. | |
template<typename Event = detail::MutexEvent, typename Clock , typename Duration , typename... V, typename... E> | |
YACLIB_INLINE bool | WaitUntil (const std::chrono::time_point< Clock, Duration > &timeout_time, FutureBase< V, E > &... fs) noexcept |
Wait until specified time has been reached or Ready becomes true. | |
template<typename Event = detail::MutexEvent, typename Clock , typename Duration , typename Iterator > | |
YACLIB_INLINE std::enable_if_t<!is_future_base_v< Iterator >, bool > | WaitUntil (const std::chrono::time_point< Clock, Duration > &timeout_time, Iterator begin, Iterator end) noexcept |
Wait until specified time has been reached or Ready becomes true. | |
template<typename Event = detail::MutexEvent, typename Clock , typename Duration , typename Iterator > | |
YACLIB_INLINE bool | WaitUntil (const std::chrono::time_point< Clock, Duration > &timeout_time, Iterator begin, std::size_t count) noexcept |
Wait until specified time has been reached or Ready becomes true. | |
template<FailPolicy F = FailPolicy::FirstFail, OrderPolicy O = OrderPolicy::Fifo, typename It , typename T = typename std::iterator_traits<It>::value_type> | |
auto | WhenAll (It begin, std::size_t count) |
Create Future which will be ready when all futures are ready. | |
template<FailPolicy F = FailPolicy::FirstFail, OrderPolicy O = OrderPolicy::Fifo, typename It , typename T = typename std::iterator_traits<It>::value_type> | |
YACLIB_INLINE auto | WhenAll (It begin, It end) |
Create Future which will be ready when all futures are ready. | |
template<FailPolicy F = FailPolicy::FirstFail, OrderPolicy O = OrderPolicy::Fifo, typename V , typename... E> | |
auto | WhenAll (FutureBase< V, E > &&... futures) |
Create Future which will be ready when all futures are ready. | |
template<FailPolicy P = FailPolicy::LastFail, typename It , typename T = typename std::iterator_traits<It>::value_type> | |
auto | WhenAny (It begin, std::size_t count) |
Create Future that is ready when any of futures is ready. | |
template<FailPolicy P = FailPolicy::LastFail, typename It , typename T = typename std::iterator_traits<It>::value_type> | |
YACLIB_INLINE auto | WhenAny (It begin, It end) |
Create Future that is ready when any of futures is ready. | |
template<FailPolicy P = FailPolicy::LastFail, typename V , typename... E> | |
auto | WhenAny (FutureBase< V, E > &&... futures) |
Create Future that is ready when any of futures is ready. | |
template<typename V , typename E > | |
YACLIB_INLINE auto | Await (Task< V, E > &task) noexcept |
TODO(mkornaukhov03) Add doxygen docs. | |
template<typename... V, typename... E> | |
YACLIB_INLINE auto | Await (FutureBase< V, E > &... fs) noexcept |
TODO(mkornaukhov03) Add doxygen docs. | |
template<typename Iterator > | |
YACLIB_INLINE auto | Await (Iterator begin, std::size_t count) noexcept -> std::enable_if_t<!is_future_base_v< Iterator >, detail::AwaitAwaiter< false > > |
TODO(mkornaukhov03) Add doxygen docs. | |
template<typename Iterator > | |
YACLIB_INLINE auto | Await (Iterator begin, Iterator end) noexcept -> std::enable_if_t<!is_future_base_v< Iterator >, detail::AwaitAwaiter< false > > |
TODO(mkornaukhov03) Add doxygen docs. | |
template<typename V , typename E > | |
YACLIB_INLINE auto | operator co_await (FutureBase< V, E > &&future) noexcept |
template<typename V , typename E > | |
YACLIB_INLINE auto | operator co_await (Task< V, E > &&task) noexcept |
template<typename... V, typename... E> | |
YACLIB_INLINE auto | AwaitOn (IExecutor &e, FutureBase< V, E > &... fs) noexcept |
template<typename Iterator > | |
YACLIB_INLINE auto | AwaitOn (IExecutor &e, Iterator begin, std::size_t count) noexcept -> std::enable_if_t<!is_future_base_v< Iterator >, detail::AwaitOnAwaiter< false > > |
TODO(mkornaukhov03) Add doxygen docs. | |
template<typename BeginIt , typename EndIt > | |
YACLIB_INLINE auto | AwaitOn (IExecutor &e, BeginIt begin, EndIt end) noexcept -> std::enable_if_t<!is_future_base_v< BeginIt >, detail::AwaitOnAwaiter< false > > |
TODO(mkornaukhov03) Add doxygen docs. | |
YACLIB_INLINE detail::CurrentAwaiter< false > | CurrentExecutor () noexcept |
Get current executor. | |
YACLIB_INLINE detail::CurrentAwaiter< true > | Yield () noexcept |
Instead of. | |
YACLIB_INLINE detail::OnAwaiter | On (IExecutor &e) noexcept |
TODO(mkornaukhov03) Add doxygen docs. | |
IExecutor & | MakeInline () noexcept |
Get Inline executor singleton object. | |
IExecutor & | MakeInline (StopTag) noexcept |
IExecutorPtr | MakeManual () |
IExecutorPtr | MakeStrand (IExecutorPtr e) |
Strand is the asynchronous analogue of a mutex. | |
template<typename Func > | |
void | Submit (IExecutor &executor, Func &&f) |
Submit given func for details. | |
void | SetFaultFrequency (std::uint32_t freq) noexcept |
Sets frequency with which fault will be injected. | |
void | SetSeed (std::uint32_t seed) noexcept |
Sets seed for random, which will be used when deciding when to yield, for fibers scheduler and random wrapper for tests. | |
void | SetFaultSleepTime (std::uint32_t ns) noexcept |
Sets sleep time if sleep is used instead of yield for interrupting thread execution for fault injection. | |
std::uint32_t | GetFaultSleepTime () noexcept |
void | SetAtomicFailFrequency (std::uint32_t k) noexcept |
Sets frequency with which compare_exchange_weak would fail. | |
detail::Injector * | GetInjector () noexcept |
void | InjectFault () noexcept |
std::uint64_t | GetInjectedCount () noexcept |
YACLIB_DEFINE_VOID_TYPE (Unit) | |
YACLIB_DEFINE_VOID_TYPE (StopTag) | |
template<typename V = Unit, typename E = StopError, typename... Args> | |
auto | MakeTask (Args &&... args) |
TODO(MBkkt) add description. | |
template<typename E = StopError, typename Func > | |
auto | Schedule (Func &&f) |
Execute Callable func on Inline executor. | |
template<typename E = StopError, typename Func > | |
auto | Schedule (IExecutor &e, Func &&f) |
Execute Callable func on executor. | |
template<typename V = void, typename E = StopError, typename Func > | |
auto | LazyContract (Func &&f) |
Execute Callable func on Inline executor. | |
template<typename V = void, typename E = StopError, typename Func > | |
auto | LazyContract (IExecutor &e, Func &&f) |
Execute Callable func on executor. | |
IntrusivePtr< FairThreadPool > | MakeFairThreadPool (std::uint64_t threads=yaclib_std::thread::hardware_concurrency()) |
template<typename To , typename From > | |
constexpr auto * | UpCast (From *from) noexcept |
template<typename To , typename From , typename = std::enable_if_t<!std::is_pointer_v<From>>> | |
constexpr auto & | UpCast (From &from) noexcept |
template<typename To , typename From > | |
constexpr auto * | DownCast (From *from) noexcept |
template<typename To , typename From > | |
constexpr auto & | DownCast (From &from) noexcept |
template<typename Func > | |
IFuncPtr | MakeFunc (Func &&f) |
Create shared IFunc object from any Callable func. | |
template<typename ObjectT , typename... Args> | |
auto | MakeUnique (Args &&... args) |
template<typename ObjectT , typename... Args> | |
auto | MakeShared (std::size_t n, Args &&... args) |
template<typename T , typename U > | |
bool | operator== (const IntrusivePtr< T > &lhs, const IntrusivePtr< U > &rhs) noexcept |
template<typename T , typename U > | |
bool | operator!= (const IntrusivePtr< T > &lhs, const IntrusivePtr< U > &rhs) noexcept |
template<typename T , typename U > | |
bool | operator== (const IntrusivePtr< T > &lhs, U *rhs) noexcept |
template<typename T , typename U > | |
bool | operator!= (const IntrusivePtr< T > &lhs, U *rhs) noexcept |
template<typename T , typename U > | |
bool | operator== (T *lhs, const IntrusivePtr< U > &rhs) noexcept |
template<typename T , typename U > | |
bool | operator!= (T *lhs, const IntrusivePtr< U > &rhs) noexcept |
template<typename T > | |
bool | operator== (const IntrusivePtr< T > &lhs, std::nullptr_t) noexcept |
template<typename T > | |
bool | operator== (std::nullptr_t, const IntrusivePtr< T > &rhs) noexcept |
template<typename T > | |
bool | operator!= (const IntrusivePtr< T > &lhs, std::nullptr_t) noexcept |
template<typename T > | |
bool | operator!= (std::nullptr_t, const IntrusivePtr< T > &rhs) noexcept |
template<typename T > | |
bool | operator< (const IntrusivePtr< T > &lhs, const IntrusivePtr< T > &rhs) noexcept |
template<bool Condition, typename T > | |
decltype(auto) | move_if (T &&arg) noexcept |
template<typename T > | |
constexpr bool | Check () noexcept |
Variables | |
constexpr detail::Yield | kYield |
Reschedule current job to it executor Useful for timeout checks, or if you job very big and doing only cpu not suspend work. | |
template<typename Func , typename... Arg> | |
constexpr bool | is_invocable_v = detail::IsInvocable<Func, Arg...>::Value |
template<typename T > | |
constexpr bool | is_result_v = detail::IsInstantiationOf<Result, T>::Value |
template<typename T > | |
constexpr bool | is_future_base_v |
template<typename T > | |
constexpr bool | is_task_v = detail::IsInstantiationOf<Task, T>::Value |
Describes channel with future and promise.
Definition at line 13 of file contract.hpp.
Definition at line 16 of file contract.hpp.
using yaclib::future_base_error_t = typedef typename detail::FutureBaseTypes<T>::Error |
Definition at line 47 of file type_traits.hpp.
using yaclib::future_base_value_t = typedef typename detail::FutureBaseTypes<T>::Value |
Definition at line 44 of file type_traits.hpp.
using yaclib::head_t = typedef typename detail::Head<Args...>::Type |
Definition at line 13 of file type_traits.hpp.
Definition at line 54 of file executor.hpp.
Definition at line 28 of file shared_func.hpp.
using yaclib::invoke_t = typedef typename detail::Invoke<Func, Arg...>::Type |
Definition at line 19 of file type_traits.hpp.
using yaclib::result_error_t = typedef typename detail::InstantiationTypes<Result, T>::Error |
Definition at line 28 of file type_traits.hpp.
using yaclib::result_value_t = typedef typename detail::InstantiationTypes<Result, T>::Value |
Definition at line 25 of file type_traits.hpp.
using yaclib::task_error_t = typedef typename detail::InstantiationTypes<Task, T>::Error |
Definition at line 34 of file type_traits.hpp.
using yaclib::task_value_t = typedef typename detail::InstantiationTypes<Task, T>::Value |
Definition at line 31 of file type_traits.hpp.
|
strong |
This Policy describe how algorithm interpret if Future will be fulfilled by fail (exception or error)
None – fail same as ok, another words save all fails FirstFail – save first fail, default for WhenAll LastFail – save last fail, default for WhenAny
Enumerator | |
---|---|
None | |
FirstFail | |
LastFail |
Definition at line 12 of file fail_policy.hpp.
|
strong |
This Policy describe how algorithm produce result.
Fifo – order of results is fifo Note: non-deterministic in multithreading environment Note: now it's default for WhenAll because it allow call delete early Same – order of results same as order of input
Enumerator | |
---|---|
Fifo | |
Same |
Definition at line 13 of file order_policy.hpp.
|
strong |
Enumerator | |
---|---|
Value | |
Exception | |
Error | |
Empty |
Definition at line 16 of file result.hpp.
Execute Callable func on Inline executor.
f | func to execute |
Definition at line 64 of file run.hpp.
References MakeContract(), and MakeInline().
Execute Callable func on executor.
e | executor to be used to execute f and saved as callback executor for return Future |
f | func to execute |
Definition at line 76 of file run.hpp.
References yaclib::IExecutor::Inline, MakeContract(), and YACLIB_WARN.
|
noexcept |
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 23 of file await.hpp.
References MakeContract(), and YACLIB_ASSERT.
|
noexcept |
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 41 of file await.hpp.
References Await(), and MakeContract().
|
noexcept |
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 32 of file await.hpp.
References MakeContract().
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 14 of file await.hpp.
References MakeContract(), and YACLIB_ASSERT.
Referenced by Await().
|
noexcept |
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 28 of file await_on.hpp.
References AwaitOn(), and MakeContract().
|
noexcept |
|
noexcept |
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 19 of file await_on.hpp.
References MakeContract().
Definition at line 59 of file type_traits.hpp.
References MakeContract().
|
noexcept |
Get current executor.
Definition at line 41 of file current_executor.hpp.
Definition at line 39 of file cast.hpp.
References MakeContract().
Definition at line 26 of file cast.hpp.
References MakeContract(), and YACLIB_ASSERT.
|
noexcept |
Definition at line 23 of file config.cpp.
References yaclib::detail::Injector::GetSleepTime().
Referenced by yaclib::fault::Scheduler::SleepPreemptive().
|
noexcept |
Definition at line 15 of file inject.cpp.
References yaclib::detail::Injector::GetInjectedCount().
|
noexcept |
Definition at line 6 of file inject.cpp.
References MakeContract().
Referenced by yaclib::fiber::GetInjectorState(), InjectFault(), and yaclib::fiber::SetInjectorState().
|
noexcept |
Definition at line 11 of file inject.cpp.
References GetInjector(), and yaclib::detail::Injector::MaybeInject().
Execute Callable func on Inline executor.
f | func to execute |
Definition at line 58 of file schedule.hpp.
References MakeContract(), and MakeInline().
Execute Callable func on executor.
e | executor to be used to execute f and saved as callback executor for return Future |
f | func to execute |
Definition at line 70 of file schedule.hpp.
References yaclib::IExecutor::Inline, MakeContract(), and YACLIB_WARN.
Contract< V, E > yaclib::MakeContract | ( | ) |
Creates related future and promise.
Definition at line 25 of file contract.hpp.
References MakeContract().
Referenced by yaclib::detail::AtomicCounter< CounterBase, Deleter >::Add(), yaclib::detail::AllCombinator< O, R, E >::AddInput(), yaclib::detail::AllCombinator< OrderPolicy::Same, R, E >::AddInput(), yaclib::detail::AnyCombinator< V, E, P >::AddInput(), yaclib::detail::fiber::DefaultAllocator::Allocate(), AsyncContract(), AsyncContract(), yaclib::WaitGroup< Event >::Attach(), yaclib::WaitGroup< Event >::Attach(), yaclib::WaitGroup< Event >::Attach(), Await(), Await(), Await(), Await(), yaclib::detail::Destroy::await_suspend(), yaclib::detail::MutexImpl< FIFO, Batching >::AwaitLock(), yaclib::detail::SharedMutexImpl< FIFO, ReadersFIFO >::AwaitLock(), yaclib::detail::SharedMutexImpl< FIFO, ReadersFIFO >::AwaitLockShared(), AwaitOn(), AwaitOn(), AwaitOn(), yaclib::detail::AwaitOnAwaiter< false >::AwaitOnAwaiter(), yaclib::detail::AwaitOnAwaiter< false >::AwaitOnAwaiter(), yaclib::detail::AwaitOnEvent< Single >::AwaitOnEvent(), yaclib::detail::MutexImpl< FIFO, Batching >::AwaitUnlock(), yaclib::detail::MutexImpl< FIFO, Batching >::AwaitUnlockOn(), yaclib::detail::BaseCore::BaseCore(), yaclib::detail::MutexImpl< FIFO, Batching >::BatchingPossible(), yaclib::detail::fiber::BiList::BiList(), yaclib::OneShotEvent::Call(), yaclib::detail::ReadyCore< V, E >::Call(), yaclib::detail::BaseCore::CallInline(), yaclib::Task< V, E >::Cancel(), yaclib::Mutex< Batching, FIFO >::Cast(), yaclib::SharedMutex< FIFO, ReadersFIFO >::Cast(), Check(), yaclib::detail::AtomicFlag< Impl >::clear(), yaclib::detail::AtomicFlag< Impl >::clear(), yaclib::detail::AnyCombinatorBase< V, E, FailPolicy::LastFail >::Combine(), yaclib::detail::AnyCombinatorBase< V, E, FailPolicy::FirstFail >::Combine(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_strong(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_strong(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_strong(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_strong(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_strong(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_strong(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_strong(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_strong(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_weak(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_weak(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_weak(), yaclib::detail::AtomicBase< Impl, T >::compare_exchange_weak(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_weak(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_weak(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_weak(), yaclib::detail::fiber::AtomicBase< T >::compare_exchange_weak(), yaclib::detail::fiber::AtomicBase< T >::CompareExchangeHelper(), yaclib::WaitGroup< Event >::Consume(), yaclib::WaitGroup< Event >::Consume(), yaclib::WaitGroup< Event >::Consume(), yaclib::detail::CVStatusFrom(), yaclib::detail::CVStatusFrom(), yaclib::detail::PromiseTypeDeleter< Lazy >::Delete(), yaclib::FutureBase< V, E >::Detach(), yaclib::Task< V, E >::Detach(), yaclib::FutureOn< V, E >::Detach(), yaclib::Task< V, E >::Detach(), yaclib::FutureBase< V, E >::Detach(), yaclib::FutureBase< V, E >::DetachInline(), DownCast(), DownCast(), yaclib::ManualExecutor::Drain(), yaclib::detail::ReadyCore< V, E >::Drop(), yaclib::detail::BaseCore::Empty(), yaclib::detail::fiber::Node::Erase(), yaclib::detail::AtomicBase< Impl, T >::exchange(), yaclib::detail::AtomicBase< Impl, T >::exchange(), yaclib::detail::fiber::AtomicBase< T >::exchange(), yaclib::detail::fiber::AtomicBase< T >::exchange(), yaclib::detail::fiber::ExecutionContext::Exit(), yaclib::FairThreadPool::FairThreadPool(), yaclib::detail::Atomic< Impl, U * >::fetch_add(), yaclib::detail::Atomic< Impl, U * >::fetch_add(), yaclib::detail::fiber::Atomic< U * >::fetch_add(), yaclib::detail::fiber::Atomic< U * >::fetch_add(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::fetch_add(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::fetch_add(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::fetch_add(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::fetch_add(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::fetch_and(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::fetch_and(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::fetch_and(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::fetch_and(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::fetch_or(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::fetch_or(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::fetch_or(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::fetch_or(), yaclib::detail::Atomic< Impl, U * >::fetch_sub(), yaclib::detail::Atomic< Impl, U * >::fetch_sub(), yaclib::detail::fiber::Atomic< U * >::fetch_sub(), yaclib::detail::fiber::Atomic< U * >::fetch_sub(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::fetch_sub(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::fetch_sub(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::fetch_sub(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::fetch_sub(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::fetch_xor(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::fetch_xor(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::fetch_xor(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::fetch_xor(), yaclib::fiber::ForwardToFaultRandomCount(), yaclib::detail::ForwardToRandCount(), yaclib::detail::fiber::SystemClock::from_time_t(), yaclib::detail::FuncCore< Func >::FuncCore(), yaclib::Future< V, E >::Future(), yaclib::FutureBase< V, E >::FutureBase(), yaclib::FutureOn< V, E >::FutureOn(), yaclib::FutureBase< V, E >::Get(), yaclib::detail::PromiseType< V, E, Lazy >::get_return_object(), yaclib::detail::fiber::BiList::GetElement(), yaclib::detail::fiber::GetImpl(), GetInjector(), yaclib::detail::fiber::GetMap(), yaclib::detail::GetRandCount(), yaclib::detail::GetRandNumber(), yaclib::detail::fiber::FiberBase::GetTLS(), yaclib::detail::Guard< M, Shared >::Guard(), yaclib::detail::Guard< M, Shared >::Guard(), yaclib::detail::Guard< M, Shared >::Guard(), yaclib::detail::Guard< M, Shared >::Guard(), yaclib::detail::GuardState::GuardState(), yaclib::detail::GuardState::GuardState(), yaclib::detail::PromiseType< V, E, Lazy >::Handle(), yaclib::FairThreadPool::HardStop(), yaclib::detail::ReadyCore< V, E >::Here(), yaclib::detail::ResultCore< V, E >::Here(), yaclib::detail::PromiseType< V, E, Lazy >::initial_suspend(), yaclib::IntrusivePtr< T >::IntrusivePtr(), yaclib::IntrusivePtr< T >::IntrusivePtr(), yaclib::IntrusivePtr< T >::IntrusivePtr(), yaclib::IntrusivePtr< T >::IntrusivePtr(), yaclib::IntrusivePtr< T >::IntrusivePtr(), yaclib::IntrusivePtr< T >::IntrusivePtr(), LazyContract(), LazyContract(), yaclib::detail::List::List(), yaclib::detail::AtomicBase< Impl, T >::load(), yaclib::detail::AtomicBase< Impl, T >::load(), yaclib::detail::Guard< M, Shared >::Lock(), yaclib::StickyGuard< M >::Lock(), yaclib::detail::LogMessage(), yaclib::detail::Loop(), yaclib::detail::AllCombinator< O, R, E >::Make(), yaclib::detail::AllCombinator< OrderPolicy::Same, R, E >::Make(), yaclib::detail::AnyCombinator< V, E, P >::Make(), MakeContract(), MakeContractOn(), yaclib::detail::MakeCore(), yaclib::detail::MakeDrop(), MakeFairThreadPool(), MakeFunc(), MakeFuture(), MakeInline(), MakeInline(), MakeManual(), MakeShared(), MakeStrand(), MakeTask(), MakeUnique(), yaclib::detail::MakeUniqueJob(), move_if(), yaclib::detail::BaseCore::MoveExecutorTo(), yaclib::detail::MoveToCaller(), yaclib::detail::Guard< M, Shared >::Mutex(), yaclib::detail::Noop(), yaclib::detail::fiber::FiberQueue::NotifyAll(), On(), operator co_await(), operator co_await(), operator!=(), operator!=(), operator!=(), yaclib::detail::fiber::operator!=(), yaclib::detail::fiber::operator!=(), yaclib::detail::fiber::operator!=(), operator!=(), yaclib::detail::fiber::operator!=(), operator!=(), yaclib::detail::fiber::operator!=(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator&=(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::operator&=(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator&=(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::operator&=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator*(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator++(), yaclib::detail::Atomic< Impl, U * >::operator++(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator++(), yaclib::detail::Atomic< Impl, U * >::operator++(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator++(), yaclib::detail::Atomic< Impl, U * >::operator++(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator++(), yaclib::detail::Atomic< Impl, U * >::operator++(), yaclib::detail::Atomic< Impl, U * >::operator+=(), yaclib::detail::fiber::Atomic< U * >::operator+=(), yaclib::detail::Atomic< Impl, U * >::operator+=(), yaclib::detail::fiber::Atomic< U * >::operator+=(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::operator+=(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::operator+=(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::operator+=(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::operator+=(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator--(), yaclib::detail::Atomic< Impl, U * >::operator--(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator--(), yaclib::detail::Atomic< Impl, U * >::operator--(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator--(), yaclib::detail::Atomic< Impl, U * >::operator--(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator--(), yaclib::detail::Atomic< Impl, U * >::operator--(), yaclib::detail::Atomic< Impl, U * >::operator-=(), yaclib::detail::fiber::Atomic< U * >::operator-=(), yaclib::detail::Atomic< Impl, U * >::operator-=(), yaclib::detail::fiber::Atomic< U * >::operator-=(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::operator-=(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::operator-=(), yaclib::detail::AtomicFloatingBase< Impl, T, true >::operator-=(), yaclib::detail::fiber::AtomicFloatingBase< T, true >::operator-=(), operator<(), yaclib::detail::fiber::operator<(), yaclib::detail::fiber::operator<(), yaclib::detail::fiber::operator<(), yaclib::detail::fiber::operator<(), yaclib::detail::fiber::operator<(), yaclib::detail::fiber::operator<=(), yaclib::detail::fiber::operator<=(), yaclib::detail::fiber::operator<=(), yaclib::detail::fiber::operator<=(), yaclib::detail::fiber::operator<=(), yaclib::Result< ValueT, E >::operator=(), yaclib::detail::fiber::BiList::operator=(), yaclib::IntrusivePtr< V, E >::operator=(), yaclib::IntrusivePtr< T >::operator=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator=(), yaclib::detail::fiber::FiberQueue::operator=(), yaclib::detail::Guard< M, Shared >::operator=(), yaclib::detail::GuardState::operator=(), yaclib::IntrusivePtr< T >::operator=(), yaclib::IntrusivePtr< T >::operator=(), yaclib::detail::fiber::Stack::operator=(), yaclib::StickyGuard< M >::operator=(), yaclib::detail::AtomicBase< Impl, T >::operator=(), yaclib::detail::fiber::AtomicWait< T >::operator=(), yaclib::detail::AtomicBase< Impl, T >::operator=(), yaclib::detail::fiber::AtomicWait< T >::operator=(), yaclib::detail::fiber::Thread::operator=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator=(), operator==(), operator==(), operator==(), yaclib::detail::fiber::operator==(), yaclib::detail::fiber::operator==(), yaclib::detail::fiber::operator==(), operator==(), yaclib::detail::fiber::operator==(), operator==(), yaclib::detail::fiber::operator==(), yaclib::detail::fiber::operator>(), yaclib::detail::fiber::operator>(), yaclib::detail::fiber::operator>(), yaclib::detail::fiber::operator>(), yaclib::detail::fiber::operator>(), yaclib::detail::fiber::operator>=(), yaclib::detail::fiber::operator>=(), yaclib::detail::fiber::operator>=(), yaclib::detail::fiber::operator>=(), yaclib::detail::fiber::operator>=(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::operator[](), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator^=(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::operator^=(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator^=(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::operator^=(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator|=(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::operator|=(), yaclib::detail::AtomicIntegralBase< Impl, T, true >::operator|=(), yaclib::detail::fiber::AtomicIntegralBase< T, true >::operator|=(), yaclib::detail::fiber::PollRandomElementFromList(), yaclib::detail::fiber::BiList::PopBack(), yaclib::detail::List::PopFront(), yaclib::Promise< V, E >::Promise(), yaclib::detail::fiber::BiList::PushAll(), yaclib::detail::List::PushBack(), yaclib::detail::Stack::PushBack(), yaclib::detail::fiber::BiList::PushBack(), yaclib::detail::List::PushFront(), yaclib::detail::Stack::PushFront(), yaclib::detail::ReadyCore< V, E >::ReadyCore(), yaclib::detail::Guard< M, Shared >::Release(), yaclib::IntrusivePtr< T >::Release(), yaclib::detail::fiber::DefaultAllocator::Release(), yaclib::detail::GuardState::ReleaseState(), yaclib::detail::BaseCore::Reset(), yaclib::OneShotEvent::Reset(), yaclib::IntrusivePtr< T >::Reset(), yaclib::Result< ValueT, E >::Result(), yaclib::Result< ValueT, E >::Result(), yaclib::ResultError< Error >::ResultError(), yaclib::detail::fiber::FiberBase::Resume(), yaclib::detail::PromiseType< V, E, Lazy >::return_value(), Run(), yaclib::detail::Run(), Run(), Schedule(), yaclib::detail::Schedule(), Schedule(), yaclib::OneShotEvent::Set(), yaclib::Promise< V, E >::Set(), yaclib::fault::Scheduler::Set(), yaclib::detail::fiber::Set(), SetAtomicFailFrequency(), yaclib::detail::SetAtomicWeakFailFrequency(), yaclib::detail::fiber::DefaultAllocator::SetCacheSize(), yaclib::detail::BaseCore::SetCallback(), yaclib::detail::SetCallback(), yaclib::detail::SetCallback(), yaclib::detail::fiber::SetDefault(), SetFaultFrequency(), yaclib::fiber::SetFaultRandomListPick(), SetFaultSleepTime(), yaclib::fiber::SetFaultTickLength(), yaclib::detail::Injector::SetFrequency(), yaclib::fiber::SetHardwareConcurrency(), yaclib::fiber::SetInjectorState(), yaclib::detail::BaseCore::SetInline(), yaclib::detail::fiber::FiberBase::SetJoiningFiber(), yaclib::detail::fiber::DefaultAllocator::SetMinStackSize(), yaclib::detail::fiber::SetRandomListPick(), yaclib::detail::BaseCore::SetResult(), yaclib::detail::SetSeed(), SetSeed(), yaclib::detail::Injector::SetSleepTime(), yaclib::fiber::SetStackCacheSize(), yaclib::fiber::SetStackSize(), yaclib::detail::fiber::FiberBase::SetState(), yaclib::detail::Injector::SetState(), yaclib::fault::Scheduler::SetTickLength(), yaclib::detail::fiber::FiberBase::SetTLS(), yaclib::detail::fiber::ExecutionContext::Setup(), yaclib::detail::ShouldFailAtomicWeak(), yaclib::fault::Scheduler::Sleep(), yaclib::fault::Scheduler::SleepPreemptive(), yaclib::detail::Stack::Stack(), yaclib::detail::fiber::ExecutionContext::Start(), yaclib::detail::Start(), yaclib::detail::Start(), yaclib::detail::Step(), yaclib::StickyGuard< M >::StickyGuard(), yaclib::detail::ResultCore< V, E >::Store(), yaclib::detail::AtomicBase< Impl, T >::store(), yaclib::detail::AtomicBase< Impl, T >::store(), yaclib::detail::fiber::AtomicBase< T >::store(), yaclib::detail::fiber::AtomicBase< T >::store(), yaclib::detail::BaseCore::StoreCallback(), yaclib::Strand::Strand(), yaclib::detail::AtomicCounter< CounterBase, Deleter >::Sub(), yaclib::detail::AtomicCounter< CounterBase, Deleter >::SubEqual(), Submit(), yaclib::ManualExecutor::Submit(), yaclib::Strand::Submit(), yaclib::detail::Guard< M, Shared >::Swap(), yaclib::detail::GuardState::Swap(), yaclib::IntrusivePtr< T >::Swap(), yaclib::StickyGuard< M >::Swap(), yaclib::detail::fiber::Thread::swap(), yaclib::detail::fiber::ExecutionContext::SwitchTo(), yaclib::detail::Tag(), yaclib::Task< V, E >::Task(), TEST(), TEST(), yaclib::detail::AtomicFlag< Impl >::test_and_set(), yaclib::detail::AtomicFlag< Impl >::test_and_set(), yaclib::detail::fiber::AtomicFlag::test_and_set(), yaclib::detail::fiber::AtomicFlag::test_and_set(), yaclib::FutureOn< V, E >::Then(), yaclib::Task< V, E >::Then(), yaclib::FutureBase< V, E >::Then(), yaclib::Task< V, E >::Then(), yaclib::Future< V, E >::ThenInline(), yaclib::FutureOn< V, E >::ThenInline(), yaclib::Task< V, E >::ThenInline(), yaclib::detail::fiber::Thread::Thread(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::ThreadLocalPtrProxy(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::ThreadLocalPtrProxy(), yaclib::detail::fiber::ThreadLocalPtrProxy< Type >::ThreadLocalPtrProxy(), yaclib::Task< V, E >::ToFuture(), yaclib::FutureBase< V, E >::Touch(), yaclib::Task< V, E >::Touch(), yaclib::detail::fiber::Fiber< Args >::Trampoline(), yaclib::detail::Mutex< Impl >::try_lock(), yaclib::detail::fiber::RecursiveTimedMutex::try_lock_for(), yaclib::detail::fiber::SharedTimedMutex::try_lock_for(), yaclib::detail::fiber::TimedMutex::try_lock_for(), yaclib::detail::SharedTimedMutex< Impl >::try_lock_for(), yaclib::detail::TimedMutex< Impl >::try_lock_for(), yaclib::detail::SharedMutex< Impl >::try_lock_shared(), yaclib::detail::fiber::SharedTimedMutex::try_lock_shared_for(), yaclib::detail::SharedTimedMutex< Impl >::try_lock_shared_for(), yaclib::detail::fiber::SharedTimedMutex::try_lock_shared_until(), yaclib::detail::SharedTimedMutex< Impl >::try_lock_shared_until(), yaclib::detail::fiber::RecursiveTimedMutex::try_lock_until(), yaclib::detail::fiber::SharedTimedMutex::try_lock_until(), yaclib::detail::fiber::TimedMutex::try_lock_until(), yaclib::detail::SharedTimedMutex< Impl >::try_lock_until(), yaclib::detail::TimedMutex< Impl >::try_lock_until(), yaclib::OneShotEvent::TryAdd(), yaclib::detail::Guard< M, Shared >::TryLock(), yaclib::detail::MutexImpl< FIFO, Batching >::TryLockAwait(), yaclib::detail::SharedMutexImpl< FIFO, ReadersFIFO >::TryLockAwait(), yaclib::detail::SharedMutexImpl< FIFO, ReadersFIFO >::TryLockShared(), yaclib::detail::MutexImpl< FIFO, Batching >::TryUnlockAwait(), yaclib::detail::Guard< M, Shared >::Unlock(), yaclib::StickyGuard< M >::Unlock(), yaclib::detail::Guard< M, Shared >::UnlockHere(), yaclib::detail::SharedMutexImpl< FIFO, ReadersFIFO >::UnlockHere(), yaclib::detail::SharedMutexImpl< FIFO, ReadersFIFO >::UnlockHereShared(), yaclib::detail::Guard< M, Shared >::UnlockOn(), yaclib::Mutex< Batching, FIFO >::UnlockOn(), UpCast(), UpCast(), yaclib::OneShotEvent::Wait(), yaclib::FairThreadPool::Wait(), yaclib::detail::fiber::FiberQueue::Wait(), Wait(), Wait(), Wait(), yaclib::detail::ConditionVariableAny< Impl >::wait(), yaclib::detail::fiber::ConditionVariable::wait(), yaclib::detail::ConditionVariable< Impl >::wait(), yaclib::detail::ConditionVariable< Impl >::wait(), yaclib::detail::MutexEvent::Wait(), yaclib::detail::MutexEvent::Wait(), yaclib::detail::MutexEvent::Wait(), yaclib::detail::ConditionVariableAny< Impl >::wait_for(), yaclib::detail::ConditionVariableAny< Impl >::wait_for(), yaclib::detail::fiber::ConditionVariable::wait_for(), yaclib::detail::ConditionVariable< Impl >::wait_for(), yaclib::detail::ConditionVariable< Impl >::wait_for(), yaclib::detail::ConditionVariableAny< Impl >::wait_until(), yaclib::detail::ConditionVariableAny< Impl >::wait_until(), yaclib::detail::fiber::ConditionVariable::wait_until(), yaclib::detail::ConditionVariable< Impl >::wait_until(), yaclib::detail::ConditionVariable< Impl >::wait_until(), yaclib::detail::WaitCore(), yaclib::OneShotEvent::WaitFor(), yaclib::WaitGroup< Event >::WaitFor(), WaitFor(), WaitFor(), WaitFor(), yaclib::detail::WaitIterator(), yaclib::detail::WaitRange(), yaclib::OneShotEvent::WaitUntil(), yaclib::WaitGroup< Event >::WaitUntil(), WaitUntil(), WaitUntil(), WaitUntil(), WhenAll(), WhenAll(), WhenAll(), WhenAny(), WhenAny(), WhenAny(), yaclib::detail::WhenImpl(), yaclib::detail::WhenImpl(), yaclib::detail::WhenSetResult(), yaclib::detail::AllCombinator< O, R, E >::~AllCombinator(), yaclib::detail::AllCombinator< OrderPolicy::Same, R, E >::~AllCombinator(), yaclib::detail::AnyCombinatorBase< V, E, FailPolicy::FirstFail >::~AnyCombinatorBase(), yaclib::detail::fiber::Fiber< Args >::~Fiber(), yaclib::Promise< V, E >::~Promise(), and yaclib::detail::ResultCore< V, E >::~ResultCore().
ContractOn< V, E > yaclib::MakeContractOn | ( | IExecutor & | e | ) |
Definition at line 33 of file contract.hpp.
References MakeContract().
IntrusivePtr< FairThreadPool > yaclib::MakeFairThreadPool | ( | std::uint64_t | threads = yaclib_std::thread::hardware_concurrency() | ) |
Definition at line 109 of file fair_thread_pool.cpp.
References MakeContract().
Create shared IFunc object from any Callable func.
f | Callable object |
Definition at line 36 of file shared_func.hpp.
References MakeContract().
Function for create Ready Future.
V | if not default value, it's type of Future value |
E | type of Future error, by default its |
Args | if single, and V default, then used as type of Future value |
args | for fulfill Future |
Definition at line 25 of file make.hpp.
References MakeContract().
|
noexcept |
Get Inline executor singleton object.
This executor immediately executes given Callable object in the same OS thread without any overhead. So it always return false from Submit, we only call Call, no submit
Definition at line 34 of file inline.cpp.
References MakeContract().
Referenced by AsyncContract(), yaclib::Task< V, E >::Cancel(), LazyContract(), Run(), and Schedule().
Definition at line 38 of file inline.cpp.
References MakeContract().
IExecutorPtr yaclib::MakeManual | ( | ) |
Definition at line 28 of file manual.cpp.
References MakeContract().
Definition at line 32 of file helper.hpp.
References MakeContract().
IExecutorPtr yaclib::MakeStrand | ( | IExecutorPtr | e | ) |
Strand is the asynchronous analogue of a mutex.
It guarantees that the tasks scheduled for it will be executed strictly sequentially. Strand itself does not have its own threads, it decorates another executor and uses it to run its tasks.
e | executor to decorate |
Definition at line 71 of file strand.cpp.
References MakeContract().
Referenced by TEST().
Definition at line 27 of file helper.hpp.
References MakeContract().
Definition at line 50 of file type_traits.hpp.
References MakeContract().
|
noexcept |
TODO(mkornaukhov03) Add doxygen docs.
Definition at line 11 of file on.hpp.
References MakeContract().
|
noexcept |
Definition at line 49 of file await.hpp.
References MakeContract(), and YACLIB_ASSERT.
|
noexcept |
Definition at line 55 of file await.hpp.
References MakeContract(), and YACLIB_ASSERT.
|
inlinenoexcept |
Definition at line 69 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 104 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 79 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 109 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 89 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 114 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 64 of file intrusive_ptr.hpp.
References yaclib::IntrusivePtr< T >::Get(), and MakeContract().
|
inlinenoexcept |
Definition at line 94 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 74 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 99 of file intrusive_ptr.hpp.
References MakeContract().
|
inlinenoexcept |
Definition at line 84 of file intrusive_ptr.hpp.
References MakeContract().
Execute Callable func on Inline executor.
f | func to execute |
Definition at line 38 of file run.hpp.
References MakeContract(), and MakeInline().
Referenced by CalculatorService::Double(), CalculatorService::Increment(), TEST(), TEST(), TEST(), TEST(), and TEST().
Execute Callable func on executor.
e | executor to be used to execute f and saved as callback executor for return Future |
f | func to execute |
Definition at line 50 of file run.hpp.
References yaclib::IExecutor::Inline, MakeContract(), and YACLIB_WARN.
Execute Callable func on Inline executor.
f | func to execute |
Definition at line 32 of file schedule.hpp.
References MakeContract(), and MakeInline().
Execute Callable func on executor.
e | executor to be used to execute f and saved as callback executor for return Future |
f | func to execute |
Definition at line 44 of file schedule.hpp.
References yaclib::IExecutor::Inline, MakeContract(), and YACLIB_WARN.
|
noexcept |
Sets frequency with which compare_exchange_weak would fail.
Default is 13
Definition at line 27 of file config.cpp.
References MakeContract(), and yaclib::detail::SetAtomicWeakFailFrequency().
|
noexcept |
Sets frequency with which fault will be injected.
Default is 16.
Definition at line 15 of file config.cpp.
References MakeContract(), and yaclib::detail::Injector::SetFrequency().
|
noexcept |
Sets sleep time if sleep is used instead of yield for interrupting thread execution for fault injection.
Default is 200
Definition at line 19 of file config.cpp.
References MakeContract(), and yaclib::detail::Injector::SetSleepTime().
|
noexcept |
Sets seed for random, which will be used when deciding when to yield, for fibers scheduler and random wrapper for tests.
Default is 1239.
Definition at line 33 of file config.cpp.
References MakeContract(), and yaclib::detail::SetSeed().
Submit given func for details.
This method creates Job with one allocation and call Submit(Job)
f | func to execute |
Definition at line 17 of file submit.hpp.
References MakeContract(), and yaclib::detail::MakeUniqueJob().
Definition at line 21 of file cast.hpp.
References MakeContract().
Definition at line 9 of file cast.hpp.
References MakeContract().
|
noexcept |
Wait until Ready becomes true.
fs | one or more futures to wait |
Definition at line 18 of file wait.hpp.
References MakeContract(), and YACLIB_ASSERT.
Referenced by yaclib::FutureBase< V, E >::Get().
|
noexcept |
Wait until Ready becomes true.
begin | iterator to futures to wait |
end | iterator to futures to wait |
Definition at line 30 of file wait.hpp.
References MakeContract().
|
noexcept |
Wait until Ready becomes true.
begin | iterator to futures to wait |
count | of futures to wait |
Definition at line 43 of file wait.hpp.
References MakeContract().
|
noexcept |
Wait until the specified timeout duration has elapsed or Ready becomes true.
The behavior is undefined if Valid is false before the call to this function. This function may block for longer than timeout_duration due to scheduling or resource contention delays.
timeout_duration | maximum duration to block for |
fs | futures to wait |
Definition at line 23 of file wait_for.hpp.
References MakeContract(), and YACLIB_ASSERT.
|
noexcept |
Wait until the specified timeout duration has elapsed or Ready becomes true.
The behavior is undefined if Valid is false before the call to this function. This function may block for longer than timeout_duration due to scheduling or resource contention delays.
timeout_duration | maximum duration to block for |
begin | iterator to futures to wait |
end | iterator to futures to wait |
Definition at line 40 of file wait_for.hpp.
References MakeContract().
|
noexcept |
Wait until the specified timeout duration has elapsed or Ready becomes true.
The behavior is undefined if Valid is false before the call to this function. This function may block for longer than timeout_duration due to scheduling or resource contention delays.
timeout_duration | maximum duration to block for |
begin | iterator to futures to wait |
count | of futures to wait |
Definition at line 58 of file wait_for.hpp.
References MakeContract().
|
noexcept |
Wait until specified time has been reached or Ready becomes true.
The behavior is undefined if Valid is false before the call to this function. This function may block for longer than until after timeout_time has been reached due to scheduling or resource contention delays.
timeout_time | maximum time point to block until |
fs | futures to wait |
Definition at line 23 of file wait_until.hpp.
References MakeContract(), and YACLIB_ASSERT.
|
noexcept |
Wait until specified time has been reached or Ready becomes true.
The behavior is undefined if Valid is false before the call to this function. This function may block for longer than until after timeout_time has been reached due to scheduling or resource contention delays.
timeout_time | maximum time point to block until |
begin | iterator to futures to wait |
end | iterator to futures to wait |
Definition at line 41 of file wait_until.hpp.
References MakeContract().
|
noexcept |
Wait until specified time has been reached or Ready becomes true.
The behavior is undefined if Valid is false before the call to this function. This function may block for longer than until after timeout_time has been reached due to scheduling or resource contention delays.
timeout_time | maximum time point to block until |
begin | iterator to futures to wait |
count | of futures to wait |
Definition at line 60 of file wait_until.hpp.
References MakeContract().
auto yaclib::WhenAll | ( | FutureBase< V, E > &&... | futures | ) |
Create Future which will be ready when all futures are ready.
V | type of value all passed futures |
E | type of error all passed futures |
futures | two or more futures to combine |
Definition at line 66 of file when_all.hpp.
References Error, LastFail, yaclib::detail::AllCombinator< O, R, E >::Make(), MakeContract(), and yaclib::detail::WhenImpl().
YACLIB_INLINE auto yaclib::WhenAll | ( | It | begin, |
It | end | ||
) |
Create Future which will be ready when all futures are ready.
It | type of passed iterator |
T | type of all passed futures |
begin,end | the range of futures to combine |
Definition at line 49 of file when_all.hpp.
References LastFail, and MakeContract().
auto yaclib::WhenAll | ( | It | begin, |
std::size_t | count | ||
) |
Create Future which will be ready when all futures are ready.
It | type of passed iterator |
T | type of all passed futures |
begin,count | the range of futures to combine |
Definition at line 27 of file when_all.hpp.
References LastFail, yaclib::detail::AllCombinator< O, R, E >::Make(), MakeContract(), yaclib::detail::WhenImpl(), and YACLIB_WARN.
auto yaclib::WhenAny | ( | FutureBase< V, E > &&... | futures | ) |
Create Future that is ready when any of futures is ready.
P | policy WhenAny errors |
V | type of value all passed futures |
E | type of error all passed futures |
futures | two or more futures to combine |
Definition at line 69 of file when_any.hpp.
References MakeContract(), and yaclib::detail::WhenImpl().
YACLIB_INLINE auto yaclib::WhenAny | ( | It | begin, |
It | end | ||
) |
Create Future that is ready when any of futures is ready.
P | policy WhenAny errors |
It | type of passed iterator |
T | type of all passed futures |
begin,end | the range of futures to combine |
Definition at line 52 of file when_any.hpp.
References MakeContract().
auto yaclib::WhenAny | ( | It | begin, |
std::size_t | count | ||
) |
Create Future that is ready when any of futures is ready.
P | policy WhenAny errors |
It | type of passed iterator |
T | type of all passed futures |
begin,count | the range of futures to combine |
Definition at line 26 of file when_any.hpp.
References yaclib::detail::AnyCombinator< V, E, P >::Make(), MakeContract(), yaclib::detail::WhenImpl(), and YACLIB_WARN.
yaclib::YACLIB_DEFINE_VOID_TYPE | ( | StopTag | ) |
yaclib::YACLIB_DEFINE_VOID_TYPE | ( | Unit | ) |
|
noexcept |
Instead of.
or
you can write auto& executor = co_await yaclib::Yield();
Definition at line 59 of file current_executor.hpp.
Definition at line 37 of file type_traits.hpp.
|
inlineconstexpr |
Definition at line 16 of file type_traits.hpp.
|
inlineconstexpr |
Definition at line 22 of file type_traits.hpp.
|
inlineconstexpr |
Definition at line 41 of file type_traits.hpp.
|
inlineconstexpr |