Struct mmtk::plan::global::BasePlan[][src]

pub struct BasePlan<VM: VMBinding> {
    pub initialized: AtomicBool,
    pub gc_status: Mutex<GcStatus>,
    pub last_stress_pages: AtomicUsize,
    pub stacks_prepared: AtomicBool,
    pub emergency_collection: AtomicBool,
    pub user_triggered_collection: AtomicBool,
    pub allocation_success: AtomicBool,
    pub max_collection_attempts: AtomicUsize,
    pub cur_collection_attempts: AtomicUsize,
    pub oom_lock: Mutex<()>,
    pub control_collector_context: ControllerCollectorContext<VM>,
    pub stats: Stats,
    pub vm_map: &'static VMMap,
    pub options: Arc<UnsafeOptionsWrapper>,
    pub heap: HeapMeta,
    pub scanned_stacks: AtomicUsize,
    pub mutator_iterator_lock: Mutex<()>,
    pub allocation_bytes: AtomicUsize,
    // some fields omitted
}

BasePlan should contain all plan-related state and functions that are fundamental to all plans. These include VM-specific (but not plan-specific) features such as a code space or vm space, which are fundamental to all plans for a given VM. Features that are common to many (but not intrinsically all) plans should instead be included in CommonPlan.

Fields

initialized: AtomicBoolgc_status: Mutex<GcStatus>last_stress_pages: AtomicUsizestacks_prepared: AtomicBoolemergency_collection: AtomicBooluser_triggered_collection: AtomicBoolallocation_success: AtomicBoolmax_collection_attempts: AtomicUsizecur_collection_attempts: AtomicUsizeoom_lock: Mutex<()>control_collector_context: ControllerCollectorContext<VM>stats: Statsvm_map: &'static VMMapoptions: Arc<UnsafeOptionsWrapper>heap: HeapMetascanned_stacks: AtomicUsizemutator_iterator_lock: Mutex<()>allocation_bytes: AtomicUsize

Implementations

impl<VM: VMBinding> BasePlan<VM>[src]

pub fn new(
    vm_map: &'static VMMap,
    mmapper: &'static Mmapper,
    options: Arc<UnsafeOptionsWrapper>,
    heap: HeapMeta,
    constraints: &'static PlanConstraints
) -> BasePlan<VM>
[src]

pub fn gc_init(
    &mut self,
    heap_size: usize,
    vm_map: &'static VMMap,
    scheduler: &Arc<MMTkScheduler<VM>>
)
[src]

pub fn get_pages_used(&self) -> usize[src]

pub fn trace_object<T: TransitiveClosure, C: CopyContext>(
    &self,
    _trace: &mut T,
    _object: ObjectReference
) -> ObjectReference
[src]

pub fn prepare(&self, _tls: OpaquePointer, _primary: bool)[src]

pub fn release(&self, _tls: OpaquePointer, _primary: bool)[src]

pub fn set_collection_kind(&self)[src]

pub fn set_gc_status(&self, s: GcStatus)[src]

pub fn stacks_prepared(&self) -> bool[src]

pub fn gc_in_progress(&self) -> bool[src]

pub fn gc_in_progress_proper(&self) -> bool[src]

pub fn increase_allocation_bytes_by(&self, size: usize)[src]

Auto Trait Implementations

impl<VM> !RefUnwindSafe for BasePlan<VM>

impl<VM> Send for BasePlan<VM>

impl<VM> Sync for BasePlan<VM>

impl<VM> Unpin for BasePlan<VM> where
    VM: Unpin

impl<VM> !UnwindSafe for BasePlan<VM>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Downcast for T where
    T: Any
[src]

impl<T> DowncastSync for T where
    T: Any + Send + Sync
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.