pub enum ContextSwitchReason {
TimeSliceExpired,
VoluntaryYield,
IOBlock,
SyncBlock,
ThreadExit,
PriorityPreemption,
LoadBalance,
}
Expand description
Reasons for context switches.
Variants§
TimeSliceExpired
Time slice expired
VoluntaryYield
Thread voluntarily yielded
IOBlock
Thread blocked on I/O
SyncBlock
Thread blocked on synchronization primitive
ThreadExit
Thread terminated
PriorityPreemption
Priority preemption
LoadBalance
Load balancing
Trait Implementations§
Source§impl Clone for ContextSwitchReason
impl Clone for ContextSwitchReason
Source§fn clone(&self) -> ContextSwitchReason
fn clone(&self) -> ContextSwitchReason
Returns a duplicate of the value. Read more
1.0.0 · 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 ContextSwitchReason
impl Debug for ContextSwitchReason
Source§impl Ord for ContextSwitchReason
impl Ord for ContextSwitchReason
Source§fn cmp(&self, other: &ContextSwitchReason) -> Ordering
fn cmp(&self, other: &ContextSwitchReason) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for ContextSwitchReason
impl PartialEq for ContextSwitchReason
Source§impl PartialOrd for ContextSwitchReason
impl PartialOrd for ContextSwitchReason
impl Copy for ContextSwitchReason
impl Eq for ContextSwitchReason
impl StructuralPartialEq for ContextSwitchReason
Auto Trait Implementations§
impl Freeze for ContextSwitchReason
impl RefUnwindSafe for ContextSwitchReason
impl Send for ContextSwitchReason
impl Sync for ContextSwitchReason
impl Unpin for ContextSwitchReason
impl UnwindSafe for ContextSwitchReason
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