pub enum CpuPlacement {
Inherit,
Auto,
Spread,
Compact,
}Expand description
Controls how Microsandbox places vCPU threads on host processors.
Variants§
Inherit
Preserve the invoking process’s existing scheduler and affinity behavior.
Auto
Spread across cores, then use SMT siblings, then share logical processors under pressure.
Spread
Preserve the widest practical distribution, sharing logical processors when necessary.
Compact
Prefer SMT siblings and fewer physical cores, then share balanced logical processors.
Implementations§
Source§impl CpuPlacement
impl CpuPlacement
Sourcepub const fn is_inherit(&self) -> bool
pub const fn is_inherit(&self) -> bool
Returns whether this policy preserves the inherited host placement.
Trait Implementations§
Source§impl Clone for CpuPlacement
impl Clone for CpuPlacement
Source§fn clone(&self) -> CpuPlacement
fn clone(&self) -> CpuPlacement
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CpuPlacement
Source§impl Debug for CpuPlacement
impl Debug for CpuPlacement
Source§impl Default for CpuPlacement
impl Default for CpuPlacement
Source§fn default() -> CpuPlacement
fn default() -> CpuPlacement
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for CpuPlacement
impl<'de> Deserialize<'de> for CpuPlacement
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for CpuPlacement
impl Display for CpuPlacement
impl Eq for CpuPlacement
Source§impl FromStr for CpuPlacement
impl FromStr for CpuPlacement
Source§impl PartialEq for CpuPlacement
impl PartialEq for CpuPlacement
Source§impl Serialize for CpuPlacement
impl Serialize for CpuPlacement
impl StructuralPartialEq for CpuPlacement
Auto Trait Implementations§
impl Freeze for CpuPlacement
impl RefUnwindSafe for CpuPlacement
impl Send for CpuPlacement
impl Sync for CpuPlacement
impl Unpin for CpuPlacement
impl UnsafeUnpin for CpuPlacement
impl UnwindSafe for CpuPlacement
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
Mutably borrows from an owned value. Read more