Skip to main content

RuntimeSwitchPlan

Struct RuntimeSwitchPlan 

Source
pub struct RuntimeSwitchPlan { /* private fields */ }
Expand description

Move-only runtime transaction for one committed scheduler switch.

ax-task constructs this value only after the scheduler has committed two distinct live endpoints and released its internal locks. The execution contexts and logical address spaces travel through one runtime call, so a provider cannot activate an mm and then fail before preparing the matching architecture context. Consuming the transaction prevents replay.

Implementations§

Source§

impl RuntimeSwitchPlan

Source

pub const fn previous_context(&self) -> ExecutionContextHandle

Returns the outgoing runtime context.

Source

pub const fn previous_address_space(&self) -> AddressSpaceHandle

Returns the outgoing logical address space, canonicalized to the incoming live token when both endpoints select the same mm.

Source

pub const fn next_context(&self) -> ExecutionContextHandle

Returns the incoming runtime context.

Source

pub const fn next_address_space(&self) -> AddressSpaceHandle

Returns the incoming scheduler-selected logical address space.

Source

pub const fn same_address_space(&self) -> bool

Returns whether both scheduler endpoints select the same logical mm.

Trait Implementations§

Source§

impl Debug for RuntimeSwitchPlan

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for RuntimeSwitchPlan

Source§

impl PartialEq for RuntimeSwitchPlan

Source§

fn eq(&self, other: &RuntimeSwitchPlan) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for RuntimeSwitchPlan

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.