Enum mmtk::scheduler::WorkBucketStage
source · pub enum WorkBucketStage {
Show 19 variants
Unconstrained,
Prepare,
ClearVOBits,
TPinningClosure,
PinningRootsTrace,
Closure,
SoftRefClosure,
WeakRefClosure,
FinalRefClosure,
PhantomRefClosure,
VMRefClosure,
CalculateForwarding,
SecondRoots,
RefForwarding,
FinalizableForwarding,
VMRefForwarding,
Compact,
Release,
Final,
}
Expand description
This enum defines all the work bucket types. The scheduler will instantiate a work bucket for each stage defined here.
Variants§
Unconstrained
This bucket is always open.
Prepare
Preparation work. Plans, spaces, GC workers, mutators, etc. should be prepared for GC at this stage.
ClearVOBits
Clear the VO bit metadata. Mainly used by ImmixSpace.
TPinningClosure
Compute the transtive closure starting from transitively pinning (TP) roots following only strong references. No objects in this closure are allow to move.
PinningRootsTrace
Trace (non-transitively) pinning roots. Objects pointed by those roots must not move, but their children may. To ensure correctness, these must be processed after TPinningClosure
Closure
Compute the transtive closure following only strong references.
SoftRefClosure
Handle Java-style soft references, and potentially expand the transitive closure.
WeakRefClosure
Handle Java-style weak references.
FinalRefClosure
Resurrect Java-style finalizable objects, and potentially expand the transitive closure.
PhantomRefClosure
Handle Java-style phantom references.
VMRefClosure
Let the VM handle VM-specific weak data structures, including weak references, weak collections, table of finalizable objects, ephemerons, etc. Potentially expand the transitive closure.
NOTE: This stage is intended to replace the Java-specific weak reference handling stages above.
CalculateForwarding
Compute the forwarding addresses of objects (mark-compact-only).
SecondRoots
Scan roots again to initiate another transitive closure to update roots and reference after computing the forwarding addresses (mark-compact-only).
RefForwarding
Update Java-style weak references after computing forwarding addresses (mark-compact-only).
NOTE: This stage should be updated to adapt to the VM-side reference handling. It shall
be kept after removing {Soft,Weak,Final,Phantom}RefClosure
.
FinalizableForwarding
Update the list of Java-style finalization cadidates and finalizable objects after computing forwarding addresses (mark-compact-only).
VMRefForwarding
Let the VM handle the forwarding of reference fields in any VM-specific weak data structures, including weak references, weak collections, table of finalizable objects, ephemerons, etc., after computing forwarding addresses (mark-compact-only).
NOTE: This stage is intended to replace Java-specific forwarding phases above.
Compact
Compact objects (mark-compact-only).
Release
Work packets that should be done just before GC shall go here. This includes releasing resources and setting states in plans, spaces, GC workers, mutators, etc.
Final
Resume mutators and end GC.
Implementations§
source§impl WorkBucketStage
impl WorkBucketStage
sourcepub fn first_stw_stage() -> Self
pub fn first_stw_stage() -> Self
The first stop-the-world bucket.
Trait Implementations§
source§impl Clone for WorkBucketStage
impl Clone for WorkBucketStage
source§fn clone(&self) -> WorkBucketStage
fn clone(&self) -> WorkBucketStage
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for WorkBucketStage
impl Debug for WorkBucketStage
source§impl Enum for WorkBucketStage
impl Enum for WorkBucketStage
source§impl<V> EnumArray<V> for WorkBucketStage
impl<V> EnumArray<V> for WorkBucketStage
source§impl PartialEq for WorkBucketStage
impl PartialEq for WorkBucketStage
source§fn eq(&self, other: &WorkBucketStage) -> bool
fn eq(&self, other: &WorkBucketStage) -> bool
self
and other
values to be equal, and is used
by ==
.impl Copy for WorkBucketStage
impl Eq for WorkBucketStage
impl StructuralPartialEq for WorkBucketStage
Auto Trait Implementations§
impl RefUnwindSafe for WorkBucketStage
impl Send for WorkBucketStage
impl Sync for WorkBucketStage
impl Unpin for WorkBucketStage
impl UnwindSafe for WorkBucketStage
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more