[−][src]Struct gc_arena::ArenaParameters
Methods
impl ArenaParameters
[src]
pub fn set_pause_factor(self, pause_factor: f64) -> ArenaParameters
[src]
The garbage collector will wait until the live size reaches pause_multiplier
before beginning a new collection. Must be >= 0.0,
setting this to 0.0 causes the collector to never sleep longer than min_sleep
before
beginning a new collection.
pub fn set_timing_factor(self, timing_factor: f64) -> ArenaParameters
[src]
The garbage collector will try and finish a collection by the time timing_factor
additional bytes are allocated. For example, if the collection is started
when the arena has 100KB live data, and the timing_multiplier is 1.0, the collector should
finish its final phase of this collection after another 100KB has been allocated. Must be
= 0.0, setting this to 0.0 causes the collector to behave like a stop-the-world collector.
pub fn set_min_sleep(self, min_sleep: usize) -> ArenaParameters
[src]
The minimum allocation amount during sleep before the arena starts collecting again. This is mostly useful when the heap is very small to prevent rapidly restarting collections.
Trait Implementations
impl Default for ArenaParameters
[src]
Creates a default ArenaParameters with pause_factor
set to 0.5, timing_factor
set to 1.5,
and min_sleep
set to 4096.
fn default() -> ArenaParameters
[src]
impl Clone for ArenaParameters
[src]
fn clone(&self) -> ArenaParameters
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for ArenaParameters
[src]
Auto Trait Implementations
impl Send for ArenaParameters
impl Sync for ArenaParameters
Blanket Implementations
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,