pub(super) struct ReadyToRunQueue<Fut> {
    pub(super) waker: AtomicWaker,
    pub(super) head: AtomicPtr<Task<Fut>>,
    pub(super) tail: UnsafeCell<*const Task<Fut>>,
    pub(super) stub: Arc<Task<Fut>>,
}

Fields§

§waker: AtomicWaker§head: AtomicPtr<Task<Fut>>§tail: UnsafeCell<*const Task<Fut>>§stub: Arc<Task<Fut>>

Implementations§

source§

impl<Fut> ReadyToRunQueue<Fut>

An MPSC queue into which the tasks containing the futures are inserted whenever the future inside is scheduled for polling.

source

pub(super) fn enqueue(&self, task: *const Task<Fut>)

The enqueue function from the 1024cores intrusive MPSC queue algorithm.

source

pub(super) unsafe fn dequeue(&self) -> Dequeue<Fut>

The dequeue function from the 1024cores intrusive MPSC queue algorithm

Note that this is unsafe as it required mutual exclusion (only one thread can call this) to be guaranteed elsewhere.

source

pub(super) fn stub(&self) -> *const Task<Fut>

Trait Implementations§

source§

impl<Fut> Drop for ReadyToRunQueue<Fut>

source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

§

impl<Fut> !Freeze for ReadyToRunQueue<Fut>

§

impl<Fut> !RefUnwindSafe for ReadyToRunQueue<Fut>

§

impl<Fut> !Send for ReadyToRunQueue<Fut>

§

impl<Fut> !Sync for ReadyToRunQueue<Fut>

§

impl<Fut> Unpin for ReadyToRunQueue<Fut>

§

impl<Fut> !UnwindSafe for ReadyToRunQueue<Fut>

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>,

§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

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

§

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.