Struct FiberQueueImpl

Implementation of the fiber queue.

struct FiberQueueImpl(bool Volatile) ;

A fiber queue supports two basic operations: suspend, which causes a fiber to stop execution and wait in the queue, and resume, which wakes up one (or more) suspended fibers.

As the name suggests, the queue maintains a strict FIFO order.

This should not, typically, be used directly by client code. Instead, it is a helper for developing synchronization objects.

Properties

NameTypeDescription
empty[get] boolReports whether there are pending fibers in the queue.

Methods

NameDescription
resumeAll Resumes execution of all pending fibers
resumeOne Resumes execution of one fiber.
suspend Suspends the current fiber until it is awoken.

Parameters

NameDescription
Volatile Sets whether suspend is supported in the case where the fiber queue itself goes out of context before all fibers wake up.