pub struct Curve { /* private fields */ }
Expand description
The WCET curve model of a task’s cumulative execution-time
demand. Similar to arrival curves, the cost of n
consecutive
jobs is specified by a vector of cumulative WCET for 1,2,3,…
jobs and extrapolated from there.
Implementations§
Source§impl Curve
impl Curve
Sourcepub fn new(wcet_of_n_jobs: Vec<Service>) -> Self
pub fn new(wcet_of_n_jobs: Vec<Service>) -> Self
Create a new WCET curve model based on the given finite prefix of cumulative demand.
The reference input wcet_of_n_jobs
is assumed to start at
one job, i.e., the first element of the vector (at offset
zero) holds the maximum cost of any one job, the second
element of the vector (at offset one) holds the cumulative
cost of any two consecutive jobs, the third element of the
vector (at offset two) holds the cumulative cost of any three
consecutive jobs, etc.
Note: the constructor currently doesn’t check whether the input is well-formed, so garbage in => garbage out…
Trait Implementations§
Source§impl FromIterator<Service> for Curve
impl FromIterator<Service> for Curve
Source§impl JobCostModel for Curve
impl JobCostModel for Curve
Source§fn cost_of_jobs(&self, n: usize) -> Service
fn cost_of_jobs(&self, n: usize) -> Service
n
consecutive jobs.Source§fn job_cost_iter<'a>(&'a self) -> Box<dyn Iterator<Item = Service> + 'a>
fn job_cost_iter<'a>(&'a self) -> Box<dyn Iterator<Item = Service> + 'a>
Source§fn least_wcet(&self, n: usize) -> Service
fn least_wcet(&self, n: usize) -> Service
n
consecutive jobs.Auto Trait Implementations§
impl Freeze for Curve
impl RefUnwindSafe for Curve
impl Send for Curve
impl Sync for Curve
impl Unpin for Curve
impl UnwindSafe for Curve
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
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>
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