pub struct LaneSchedule { /* private fields */ }Expand description
Validated execution order of a lane-partitioned kernel.
Implementations§
Source§impl LaneSchedule
impl LaneSchedule
Sourcepub fn new(
lanes: u32,
tasks: Vec<LaneTaskSpec>,
) -> Result<Self, LaneScheduleError>
pub fn new( lanes: u32, tasks: Vec<LaneTaskSpec>, ) -> Result<Self, LaneScheduleError>
Validate tasks, listed in a valid sequential order.
Every wait must refer to tasks of another lane that are listed before the waiting task, which makes concurrent execution deadlock free.
Sourcepub fn with_diagnostic_id(self, name: String) -> Self
pub fn with_diagnostic_id(self, name: String) -> Self
Bind this runtime schedule to its compiler diagnostic identity.
pub fn lanes(&self) -> u32
pub fn tasks(&self) -> &[LaneTaskSpec]
Sourcepub fn run_sequential(
&self,
runner: &dyn LaneTaskRunner,
) -> Result<(), LaneTaskFailure>
pub fn run_sequential( &self, runner: &dyn LaneTaskRunner, ) -> Result<(), LaneTaskFailure>
Run every task on the calling thread in list order.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LaneSchedule
impl RefUnwindSafe for LaneSchedule
impl Send for LaneSchedule
impl Sync for LaneSchedule
impl Unpin for LaneSchedule
impl UnsafeUnpin for LaneSchedule
impl UnwindSafe for LaneSchedule
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