pub trait VMBinding{
type VMObjectModel: ObjectModel<Self>;
type VMScanning: Scanning<Self>;
type VMCollection: Collection<Self>;
type VMActivePlan: ActivePlan<Self>;
type VMReferenceGlue: ReferenceGlue<Self>;
type VMSlot: Slot;
type VMMemorySlice: MemorySlice<SlotType = Self::VMSlot>;
const ALIGNMENT_VALUE: usize = 3_735_928_559usize;
const MIN_ALIGNMENT: usize = 4usize;
const MAX_ALIGNMENT: usize = 8usize;
const USE_ALLOCATION_OFFSET: bool = true;
const ALLOC_END_ALIGNMENT: usize = 1usize;
}
Expand description
The VMBinding
trait associates with each trait, and provides VM-specific constants.
Required Associated Types§
sourcetype VMObjectModel: ObjectModel<Self>
type VMObjectModel: ObjectModel<Self>
The binding’s implementation of crate::vm::ObjectModel
.
sourcetype VMScanning: Scanning<Self>
type VMScanning: Scanning<Self>
The binding’s implementation of crate::vm::Scanning
.
sourcetype VMCollection: Collection<Self>
type VMCollection: Collection<Self>
The binding’s implementation of crate::vm::Collection
.
sourcetype VMActivePlan: ActivePlan<Self>
type VMActivePlan: ActivePlan<Self>
The binding’s implementation of crate::vm::ActivePlan
.
sourcetype VMReferenceGlue: ReferenceGlue<Self>
type VMReferenceGlue: ReferenceGlue<Self>
The binding’s implementation of crate::vm::ReferenceGlue
.
sourcetype VMMemorySlice: MemorySlice<SlotType = Self::VMSlot>
type VMMemorySlice: MemorySlice<SlotType = Self::VMSlot>
The type of heap memory slice in this VM.
Provided Associated Constants§
sourceconst ALIGNMENT_VALUE: usize = 3_735_928_559usize
const ALIGNMENT_VALUE: usize = 3_735_928_559usize
A value to fill in alignment gaps. This value can be used for debugging.
sourceconst MIN_ALIGNMENT: usize = 4usize
const MIN_ALIGNMENT: usize = 4usize
Allowed minimal alignment in bytes.
sourceconst MAX_ALIGNMENT: usize = 8usize
const MAX_ALIGNMENT: usize = 8usize
Allowed maximum alignment in bytes.
sourceconst USE_ALLOCATION_OFFSET: bool = true
const USE_ALLOCATION_OFFSET: bool = true
Does the binding use a non-zero allocation offset? If this is false, we expect the binding to always use offset === 0 for allocation, and we are able to do some optimization if we know offset === 0.
sourceconst ALLOC_END_ALIGNMENT: usize = 1usize
const ALLOC_END_ALIGNMENT: usize = 1usize
This value is used to assert if the cursor is reasonable after allocations. At the end of an allocation, the allocation cursor should be aligned to this value. Note that MMTk does not attempt to do anything to align the cursor to this value, but it merely asserts with this constant.