Module mmtk::scheduler::worker

source ·

Structs§

  • A GC worker. This part is privately owned by a worker thread.
  • The struct has one instance per worker, but is shared between workers via the scheduler instance. This structure is used for communication between workers, e.g. adding designated work packets, stealing work packets from other workers, and collecting per-worker statistics.
  • A worker group to manage all the GC workers.
  • A special error type that indicate a worker should exit. This may happen if the VM needs to fork and asks workers to exit.

Enums§

Constants§

Functions§

Type Aliases§

  • PollResult 🔒
    The result type of GCWorker::pool. Too many functions return Option<Box<dyn GCWork<VM>>>. In most cases, when None is returned, the caller should try getting work packets from another place. To avoid confusion, we use Err(WorkerShouldExit) to clearly indicate that the worker should exit immediately.
  • Represents the ID of a GC worker thread.