Module Await_blocking_futexSource

Sourcetype t : immediate

A handle to a linux futex for waiting on a trigger.

Sourcetype count : immediate
Sourceval get : unit -> t @@ portable

Returns a futex that may be used to wait on a trigger. A new futex may or may not be returned by each call to get.

Sourceval count : t -> count @@ portable

Returns the current count of the futex.

Sourceval signal : t -> unit @@ portable

Increments the count of the futex. Any call to wait on the same futex will check whether the associated trigger has been signaled before suspending the thread.

Sourceval wait : t -> count:count -> count @@ portable

Wait until the count of the futex changes by suspending the thread until the futex is signaled, then return the current count.