pub enum CpuTopologyError {
EmptyAllowedCpuSet,
AffinityUnavailable,
InvalidCpuList {
list: String,
reason: &'static str,
},
DuplicateNode {
node: NumaNodeId,
},
OverlappingNodes {
first: NumaNodeId,
second: NumaNodeId,
cpus: CpuSet,
},
}Expand description
Failure to canonicalize discovered NUMA topology.
§Examples
use tenferro_cpu::{CpuTopologyError, NumaNodeId};
let error = CpuTopologyError::DuplicateNode { node: NumaNodeId::new(2) };
assert!(error.to_string().contains("2"));Variants§
EmptyAllowedCpuSet
The process affinity mask contained no logical CPU.
The process CPU affinity mask could not be obtained.
InvalidCpuList
A Linux sysfs CPU-list value was malformed or unreasonably large.
Fields
DuplicateNode
Discovery reported the same OS NUMA node more than once.
Fields
§
node: NumaNodeIdThe duplicated OS NUMA node ID.
OverlappingNodes
Two usable NUMA nodes contained at least one common logical CPU.
Fields
§
first: NumaNodeIdThe first overlapping OS node ID.
§
second: NumaNodeIdThe second overlapping OS node ID.
Trait Implementations§
Source§impl Clone for CpuTopologyError
impl Clone for CpuTopologyError
Source§fn clone(&self) -> CpuTopologyError
fn clone(&self) -> CpuTopologyError
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 moreSource§impl Debug for CpuTopologyError
impl Debug for CpuTopologyError
Source§impl Display for CpuTopologyError
impl Display for CpuTopologyError
Source§impl Error for CpuTopologyError
impl Error for CpuTopologyError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for CpuTopologyError
impl PartialEq for CpuTopologyError
Source§fn eq(&self, other: &CpuTopologyError) -> bool
fn eq(&self, other: &CpuTopologyError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for CpuTopologyError
impl StructuralPartialEq for CpuTopologyError
Auto Trait Implementations§
impl Freeze for CpuTopologyError
impl RefUnwindSafe for CpuTopologyError
impl Send for CpuTopologyError
impl Sync for CpuTopologyError
impl Unpin for CpuTopologyError
impl UnsafeUnpin for CpuTopologyError
impl UnwindSafe for CpuTopologyError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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>
Converts
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>
Converts
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