Module rayon_core::scope

source ·
Expand description

Methods for custom fork-join scopes, created by the scope() and in_place_scope() functions. These are a more flexible alternative to join().

Structs§

  • Represents a fork-join scope which can be used to spawn any number of tasks. See scope() for more information.
  • ScopeBase 🔒
  • Represents a fork-join scope which can be used to spawn any number of tasks. Those spawned from the same thread are prioritized in relative FIFO order. See scope_fifo() for more information.
  • ScopePtr 🔒
    Used to capture a scope &Self pointer in jobs, without faking a lifetime.

Functions§

  • Creates a “fork-join” scope s and invokes the closure with a reference to s. This closure can then spawn asynchronous tasks into s. Those tasks may run asynchronously with respect to the closure; they may themselves spawn additional tasks into s. When the closure returns, it will block until all tasks that have been spawned into s complete.
  • Creates a “fork-join” scope s with FIFO order, and invokes the closure with a reference to s. This closure can then spawn asynchronous tasks into s. Those tasks may run asynchronously with respect to the closure; they may themselves spawn additional tasks into s. When the closure returns, it will block until all tasks that have been spawned into s complete.
  • Creates a “fork-join” scope s and invokes the closure with a reference to s. This closure can then spawn asynchronous tasks into s. Those tasks may run asynchronously with respect to the closure; they may themselves spawn additional tasks into s. When the closure returns, it will block until all tasks that have been spawned into s complete.
  • Creates a “fork-join” scope s with FIFO order, and invokes the closure with a reference to s. This closure can then spawn asynchronous tasks into s. Those tasks may run asynchronously with respect to the closure; they may themselves spawn additional tasks into s. When the closure returns, it will block until all tasks that have been spawned into s complete.