Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • RT-PROOFS/rt-proofs
  • sophie/rt-proofs
  • fstutz/rt-proofs
  • sbozhko/rt-proofs
  • fradet/rt-proofs
  • mlesourd/rt-proofs
  • xiaojie/rt-proofs
  • LailaElbeheiry/rt-proofs
  • ptorrx/rt-proofs
  • proux/rt-proofs
  • LasseBlaauwbroek/rt-proofs
  • krathul/rt-proofs
12 results
Show changes
Commits on Source (4)
Showing
with 65 additions and 65 deletions
...@@ -155,7 +155,7 @@ spell-check: ...@@ -155,7 +155,7 @@ spell-check:
extends: extends:
- .not_in_wip_branches - .not_in_wip_branches
stage: build stage: build
image: bbbrandenburg/aspell-ci image: bbbrandenburg/hunspell:2022-08
script: script:
- scripts/flag-typos-in-comments.sh `find . -iname '*.v' ! -path './classic/*'` - scripts/flag-typos-in-comments.sh `find . -iname '*.v' ! -path './classic/*'`
......
...@@ -123,7 +123,7 @@ Section Abstract_RTA. ...@@ -123,7 +123,7 @@ Section Abstract_RTA.
Variable t1 t2: instant. Variable t1 t2: instant.
Hypothesis H_busy_interval: busy_interval j t1 t2. Hypothesis H_busy_interval: busy_interval j t1 t2.
(** Let's define A as a relative arrival time of job j (with respect to time t1). *) (** Let's define [A] as a relative arrival time of job [j] (with respect to time [t1]). *)
Let A := job_arrival j - t1. Let A := job_arrival j - t1.
(** In order to prove that R is a response-time bound of job j, we use hypothesis H_R_is_maximum. (** In order to prove that R is a response-time bound of job j, we use hypothesis H_R_is_maximum.
...@@ -164,7 +164,7 @@ Section Abstract_RTA. ...@@ -164,7 +164,7 @@ Section Abstract_RTA.
interval remains completed. *) interval remains completed. *)
Section FixpointOutsideBusyInterval. Section FixpointOutsideBusyInterval.
(** By assumption, suppose that t2 is less than or equal to [t1 + A_sp + F_sp]. *) (** By assumption, suppose that [t2] is less than or equal to [t1 + A_sp + F_sp]. *)
Hypothesis H_big_fixpoint_solution : t2 <= t1 + (A_sp + F_sp). Hypothesis H_big_fixpoint_solution : t2 <= t1 + (A_sp + F_sp).
(** Then we prove that [job_arrival j + R] is no less than [t2]. *) (** Then we prove that [job_arrival j + R] is no less than [t2]. *)
...@@ -198,7 +198,7 @@ Section Abstract_RTA. ...@@ -198,7 +198,7 @@ Section Abstract_RTA.
[t1 + A_sp + F_sp] lies inside the busy interval. *) [t1 + A_sp + F_sp] lies inside the busy interval. *)
Section FixpointInsideBusyInterval. Section FixpointInsideBusyInterval.
(** So, assume that [t1 + A_sp + F_sp] is less than t2. *) (** So, assume that [t1 + A_sp + F_sp] is less than [t2]. *)
Hypothesis H_small_fixpoint_solution : t1 + (A_sp + F_sp) < t2. Hypothesis H_small_fixpoint_solution : t1 + (A_sp + F_sp) < t2.
(** Next, let's consider two other cases: *) (** Next, let's consider two other cases: *)
...@@ -221,7 +221,7 @@ Section Abstract_RTA. ...@@ -221,7 +221,7 @@ Section Abstract_RTA.
Variable F : duration. Variable F : duration.
(** (a) the sum of [A_sp] and [F_sp] is equal to the sum of [A] and [F]... *) (** (a) the sum of [A_sp] and [F_sp] is equal to the sum of [A] and [F]... *)
Hypothesis H_Asp_Fsp_eq_A_F : A_sp + F_sp = A + F. Hypothesis H_Asp_Fsp_eq_A_F : A_sp + F_sp = A + F.
(** (b) [F] is at mo1st [F_sp]... *) (** (b) [F] is at most [F_sp]... *)
Hypothesis H_F_le_Fsp : F <= F_sp. Hypothesis H_F_le_Fsp : F <= F_sp.
(** (c) and [A + F] is a solution for the response-time recurrence for [A]. *) (** (c) and [A + F] is a solution for the response-time recurrence for [A]. *)
Hypothesis H_A_F_fixpoint: Hypothesis H_A_F_fixpoint:
......
...@@ -220,7 +220,7 @@ Section Sequential_Abstract_RTA. ...@@ -220,7 +220,7 @@ Section Sequential_Abstract_RTA.
Hypothesis H_j2_from_tsk: job_of_task tsk j2. Hypothesis H_j2_from_tsk: job_of_task tsk j2.
Hypothesis H_j1_cost_positive: job_cost_positive j1. Hypothesis H_j1_cost_positive: job_cost_positive j1.
(** Consider the busy interval <<[t1, t2)>> of job j1. *) (** Consider the busy interval <<[t1, t2)>> of job [j1]. *)
Variable t1 t2 : instant. Variable t1 t2 : instant.
Hypothesis H_busy_interval : busy_interval j1 t1 t2. Hypothesis H_busy_interval : busy_interval j1 t1 t2.
...@@ -241,7 +241,7 @@ Section Sequential_Abstract_RTA. ...@@ -241,7 +241,7 @@ Section Sequential_Abstract_RTA.
Qed. Qed.
(** Next we prove that if a job is pending after the beginning (** Next we prove that if a job is pending after the beginning
of the busy interval <<[t1, t2)>> then it arrives after t1. *) of the busy interval <<[t1, t2)>> then it arrives after [t1]. *)
Lemma arrives_after_beginning_of_busy_interval: Lemma arrives_after_beginning_of_busy_interval:
forall t, forall t,
t1 <= t -> t1 <= t ->
...@@ -280,14 +280,14 @@ Section Sequential_Abstract_RTA. ...@@ -280,14 +280,14 @@ Section Sequential_Abstract_RTA.
Variable t1 t2 : instant. Variable t1 t2 : instant.
Hypothesis H_busy_interval : busy_interval j t1 t2. Hypothesis H_busy_interval : busy_interval j t1 t2.
(** Let's define A as a relative arrival time of job j (with respect to time t1). *) (** Let's define [A] as a relative arrival time of job [j] (with respect to time [t1]). *)
Let A : duration := job_arrival j - t1. Let A : duration := job_arrival j - t1.
(** Consider an arbitrary time x ... *) (** Consider an arbitrary time x ... *)
Variable x : duration. Variable x : duration.
(** ... such that (t1 + x) is inside the busy interval... *) (** ... such that [(t1 + x)] is inside the busy interval... *)
Hypothesis H_inside_busy_interval : t1 + x < t2. Hypothesis H_inside_busy_interval : t1 + x < t2.
(** ... and job j is not completed by time (t1 + x). *) (** ... and job [j] is not completed by time [(t1 + x)]. *)
Hypothesis H_job_j_is_not_completed : ~~ completed_by sched j (t1 + x). Hypothesis H_job_j_is_not_completed : ~~ completed_by sched j (t1 + x).
(** In this section, we show that the cumulative interference of job j in the interval <<[t1, t1 + x)>> (** In this section, we show that the cumulative interference of job j in the interval <<[t1, t1 + x)>>
...@@ -549,8 +549,8 @@ Section Sequential_Abstract_RTA. ...@@ -549,8 +549,8 @@ Section Sequential_Abstract_RTA.
Qed. Qed.
(** Finally, we show that the cumulative interference of job j in the interval <<[t1, t1 + x)>> (** Finally, we show that the cumulative interference of job j in the interval <<[t1, t1 + x)>>
is bounded by the sum of the task workload in the interval [t1, t1 + A + ε) and is bounded by the sum of the task workload in the interval <<[t1, t1 + A + ε)>> and
the cumulative interference of [j]'s task in the interval [t1, t1 + x). *) the cumulative interference of [j]'s task in the interval <<[t1, t1 + x)>>. *)
Lemma cumulative_job_interference_le_task_interference_bound: Lemma cumulative_job_interference_le_task_interference_bound:
cumul_interference j t1 (t1 + x) cumul_interference j t1 (t1 + x)
<= (task_workload_between t1 (t1 + A + ε) - job_cost j) <= (task_workload_between t1 (t1 + A + ε) - job_cost j)
......
...@@ -96,7 +96,7 @@ Section AbstractRTADefinitions. ...@@ -96,7 +96,7 @@ Section AbstractRTADefinitions.
(forall t, t1 < t < t2 -> ~ quiet_time j t). (forall t, t1 < t < t2 -> ~ quiet_time j t).
(** Next, we say that an interval <<[t1, t2)>> is a busy interval iff (** Next, we say that an interval <<[t1, t2)>> is a busy interval iff
[t1, t2) is a busy-interval prefix and t2 is a quiet time. *) <<[t1, t2)>> is a busy-interval prefix and [t2] is a quiet time. *)
Definition busy_interval (j : Job) (t1 t2 : instant) := Definition busy_interval (j : Job) (t1 t2 : instant) :=
busy_interval_prefix j t1 t2 /\ busy_interval_prefix j t1 t2 /\
quiet_time j t2. quiet_time j t2.
......
...@@ -57,9 +57,9 @@ Section AbstractRTARunToCompletionThreshold. ...@@ -57,9 +57,9 @@ Section AbstractRTARunToCompletionThreshold.
Hypothesis H_busy_interval : busy_interval j t1 t2. Hypothesis H_busy_interval : busy_interval j t1 t2.
(** First, we prove that job [j] completes by the end of the busy interval. (** First, we prove that job [j] completes by the end of the busy interval.
Note that the busy interval contains the execution of job j, in addition Note that the busy interval contains the execution of job j, in addition
time instant t2 is a quiet time. Thus by the definition of a quiet time time instant [t2] is a quiet time. Thus by the definition of a quiet time
the job should be completed before time t2. *) the job should be completed before time [t2]. *)
Lemma job_completes_within_busy_interval: Lemma job_completes_within_busy_interval:
completed_by sched j t2. completed_by sched j t2.
Proof. Proof.
...@@ -74,7 +74,7 @@ Section AbstractRTARunToCompletionThreshold. ...@@ -74,7 +74,7 @@ Section AbstractRTARunToCompletionThreshold.
the total time where job [j] is scheduled inside the busy interval. *) the total time where job [j] is scheduled inside the busy interval. *)
Section InterferenceIsComplement. Section InterferenceIsComplement.
(** Consider any sub-interval <<[t, t + delta)>> inside the busy interval [t1, t2). *) (** Consider any sub-interval <<[t, t + delta)>> inside the busy interval <<[t1, t2)>>. *)
Variables (t : instant) (delta : duration). Variables (t : instant) (delta : duration).
Hypothesis H_greater_than_or_equal : t1 <= t. Hypothesis H_greater_than_or_equal : t1 <= t.
Hypothesis H_less_or_equal: t + delta <= t2. Hypothesis H_less_or_equal: t + delta <= t2.
......
...@@ -275,7 +275,7 @@ Section ArrivalSequencePrefix. ...@@ -275,7 +275,7 @@ Section ArrivalSequencePrefix.
Qed. Qed.
(** Next, we prove that if a job belongs to the prefix (** Next, we prove that if a job belongs to the prefix
(jobs_arrived_before t), then it arrives in the arrival [(jobs_arrived_before t)], then it arrives in the arrival
sequence. *) sequence. *)
Lemma in_arrivals_implies_arrived: Lemma in_arrivals_implies_arrived:
forall j t1 t2, forall j t1 t2,
...@@ -291,16 +291,16 @@ Section ArrivalSequencePrefix. ...@@ -291,16 +291,16 @@ Section ArrivalSequencePrefix.
Proof. by move=> t ? ?; exists t. Qed. Proof. by move=> t ? ?; exists t. Qed.
(** Next, we prove that if a job belongs to the prefix (** Next, we prove that if a job belongs to the prefix
(jobs_arrived_between t1 t2), then it indeed arrives between t1 and [(jobs_arrived_between t1 t2)], then it indeed arrives between [t1] and
t2. *) [t2]. *)
Lemma in_arrivals_implies_arrived_between: Lemma in_arrivals_implies_arrived_between:
forall j t1 t2, forall j t1 t2,
j \in arrivals_between arr_seq t1 t2 -> j \in arrivals_between arr_seq t1 t2 ->
arrived_between j t1 t2. arrived_between j t1 t2.
Proof. by move=> ? ? ? /mem_bigcat_nat_exists[t0 [/job_arrival_at <-]]. Qed. Proof. by move=> ? ? ? /mem_bigcat_nat_exists[t0 [/job_arrival_at <-]]. Qed.
(** Similarly, if a job belongs to the prefix (jobs_arrived_before t), (** Similarly, if a job belongs to the prefix [(jobs_arrived_before t)],
then it indeed arrives before time t. *) then it indeed arrives before time [t]. *)
Lemma in_arrivals_implies_arrived_before: Lemma in_arrivals_implies_arrived_before:
forall j t, forall j t,
j \in arrivals_before arr_seq t -> j \in arrivals_before arr_seq t ->
...@@ -308,7 +308,7 @@ Section ArrivalSequencePrefix. ...@@ -308,7 +308,7 @@ Section ArrivalSequencePrefix.
Proof. by move=> ? ? /in_arrivals_implies_arrived_between. Qed. Proof. by move=> ? ? /in_arrivals_implies_arrived_between. Qed.
(** Similarly, we prove that if a job from the arrival sequence arrives (** Similarly, we prove that if a job from the arrival sequence arrives
before t, then it belongs to the sequence (jobs_arrived_before t). *) before t, then it belongs to the sequence [(jobs_arrived_before t)]. *)
Lemma arrived_between_implies_in_arrivals: Lemma arrived_between_implies_in_arrivals:
forall j t1 t2, forall j t1 t2,
arrives_in arr_seq j -> arrives_in arr_seq j ->
......
...@@ -94,7 +94,7 @@ Section Composition. ...@@ -94,7 +94,7 @@ Section Composition.
Proof. move=> ?; exact: service_during_last_plus_before. Qed. Proof. move=> ?; exact: service_during_last_plus_before. Qed.
(** Finally, we deconstruct the service received during an interval <<[t1, t3)>> (** Finally, we deconstruct the service received during an interval <<[t1, t3)>>
into the service at a midpoint t2 and the service in the intervals before into the service at a midpoint [t2] and the service in the intervals before
and after. *) and after. *)
Lemma service_split_at_point: Lemma service_split_at_point:
forall t1 t2 t3, forall t1 t2 t3,
......
...@@ -242,7 +242,7 @@ Section RequestBoundFunctions. ...@@ -242,7 +242,7 @@ Section RequestBoundFunctions.
(** Let [max_arrivals] be a family of valid arrival curves, i.e., for any task [tsk] in [ts] (** Let [max_arrivals] be a family of valid arrival curves, i.e., for any task [tsk] in [ts]
[max_arrival tsk] is (1) an arrival bound of [tsk], and (2) it is a monotonic function [max_arrival tsk] is (1) an arrival bound of [tsk], and (2) it is a monotonic function
that equals 0 for the empty interval Δ = 0. *) that equals 0 for the empty interval [Δ = 0]. *)
Context `{MaxArrivals Task}. Context `{MaxArrivals Task}.
Hypothesis H_valid_arrival_curve : valid_arrival_curve (max_arrivals tsk). Hypothesis H_valid_arrival_curve : valid_arrival_curve (max_arrivals tsk).
Hypothesis H_is_arrival_curve : respects_max_arrivals arr_seq tsk (max_arrivals tsk). Hypothesis H_is_arrival_curve : respects_max_arrivals arr_seq tsk (max_arrivals tsk).
...@@ -388,10 +388,10 @@ Section TotalRBFMonotonic. ...@@ -388,10 +388,10 @@ Section TotalRBFMonotonic.
End TotalRBFMonotonic. End TotalRBFMonotonic.
(** ** RBFs Equal to Zero for Duration ε *) (** ** RBFs Equal to Zero for Duration [ε] *)
(** In the following section, we derive simple properties that follow in (** In the following section, we derive simple properties that follow in
the pathological case of an RBF that yields zero for duration ε. *) the pathological case of an RBF that yields zero for duration [ε]. *)
Section DegenerateTotalRBFs. Section DegenerateTotalRBFs.
(** Consider a set of tasks characterized by WCETs and arrival curves ... *) (** Consider a set of tasks characterized by WCETs and arrival curves ... *)
......
...@@ -45,7 +45,7 @@ Section FullyPreemptiveModel. ...@@ -45,7 +45,7 @@ Section FullyPreemptiveModel.
by rewrite H1; compute. by rewrite H1; compute.
Qed. Qed.
(** ... or ε when [job_cost j > 0]. *) (** ... or [ε] when [job_cost j > 0]. *)
Lemma job_max_nps_is_ε: Lemma job_max_nps_is_ε:
forall j, forall j,
job_cost j > 0 -> job_cost j > 0 ->
......
...@@ -47,7 +47,7 @@ Section TaskRTCThresholdFullyNonPreemptive. ...@@ -47,7 +47,7 @@ Section TaskRTCThresholdFullyNonPreemptive.
by rewrite H3; compute. by rewrite H3; compute.
Qed. Qed.
(** ... and ε otherwise. *) (** ... and [ε] otherwise. *)
Fact job_rtc_threshold_is_ε: Fact job_rtc_threshold_is_ε:
forall j, forall j,
job_cost j > 0 -> job_cost j > 0 ->
......
...@@ -97,7 +97,7 @@ Section FindSwapCandidateFacts. ...@@ -97,7 +97,7 @@ Section FindSwapCandidateFacts.
(** Since we are considering a uniprocessor model, only one job is (** Since we are considering a uniprocessor model, only one job is
scheduled at a time. Hence once we know that a job is scheduled scheduled at a time. Hence once we know that a job is scheduled
at the time that [find_swap_candidate] returns, we can conclude at the time that [find_swap_candidate] returns, we can conclude
that it arrives not later than at time t1. *) that it arrives not later than at time [t1]. *)
Corollary fsc_found_job_arrival: Corollary fsc_found_job_arrival:
forall j2, forall j2,
scheduled_at sched j2 (find_swap_candidate sched t1 j1) -> scheduled_at sched j2 (find_swap_candidate sched t1 j1) ->
......
...@@ -219,7 +219,7 @@ Section FSCWorkConservationLemmas. ...@@ -219,7 +219,7 @@ Section FSCWorkConservationLemmas.
- by apply (non_idle_swap_maintains_work_conservation_t1 arr_seq _ _ _ j2). - by apply (non_idle_swap_maintains_work_conservation_t1 arr_seq _ _ _ j2).
- case: (boolP(t == t2)) => [/eqP EQ'| /eqP NEQ']. - case: (boolP(t == t2)) => [/eqP EQ'| /eqP NEQ'].
+ by apply (non_idle_swap_maintains_work_conservation_t2 arr_seq _ _ _ j1). + by apply (non_idle_swap_maintains_work_conservation_t2 arr_seq _ _ _ j1).
+ case: (boolP((t <= t1) || (t2 < t))) => [NOT_BET | BET]. (* t <> t2 *) + case: (boolP((t <= t1) || (t2 < t))) => [NOT_BET | BET].
* move: NOT_BET; move/orP => [] => NOT_BET. * move: NOT_BET; move/orP => [] => NOT_BET.
{ by apply (non_idle_swap_maintains_work_conservation_LEQ_t1 arr_seq _ _ _ H_range _ _ H_not_idle t2_not_idle j). } { by apply (non_idle_swap_maintains_work_conservation_LEQ_t1 arr_seq _ _ _ H_range _ _ H_not_idle t2_not_idle j). }
{ by apply (non_idle_swap_maintains_work_conservation_GT_t2 arr_seq _ _ _ H_range _ _ H_not_idle t2_not_idle j). } { by apply (non_idle_swap_maintains_work_conservation_GT_t2 arr_seq _ _ _ H_range _ _ H_not_idle t2_not_idle j). }
......
...@@ -18,11 +18,11 @@ Section SwappedFacts. ...@@ -18,11 +18,11 @@ Section SwappedFacts.
Variable t1 t2: instant. Variable t1 t2: instant.
(** In the following, let [sched'] denote the schedule in which the (** In the following, let [sched'] denote the schedule in which the
allocations at [t1] and [t2] have been swapped. *) allocations at [t1] and [t2] have been swapped. *)
Let sched' := swapped sched t1 t2. Let sched' := swapped sched t1 t2.
(** First, we note that the trivial case where t1 == t2 is not interesting (** First, we note that the trivial case where [t1 == t2] is not interesting
because then the two schedules are identical. *) because then the two schedules are identical. *)
Lemma trivial_swap: Lemma trivial_swap:
t1 = t2 -> t1 = t2 ->
forall t, forall t,
...@@ -58,8 +58,8 @@ Section SwappedFacts. ...@@ -58,8 +58,8 @@ Section SwappedFacts.
by rewrite /sched' /swapped !rest_of_schedule_invariant //. by rewrite /sched' /swapped !rest_of_schedule_invariant //.
Qed. Qed.
(** By definition, if a job is scheduled at t2 in the original (** By definition, if a job is scheduled at [t2] in the original
schedule, then it is found at t1 in the new schedule. *) schedule, then it is found at [t1] in the new schedule. *)
Lemma swap_job_scheduled_t1: Lemma swap_job_scheduled_t1:
forall j, forall j,
scheduled_at sched' j t1 = scheduled_at sched' j t1 =
...@@ -72,8 +72,8 @@ Section SwappedFacts. ...@@ -72,8 +72,8 @@ Section SwappedFacts.
- by rewrite ifT. - by rewrite ifT.
Qed. Qed.
(** Similarly, a job scheduled at t1 in the original schedule is (** Similarly, a job scheduled at [t1] in the original schedule is
scheduled at t2 after the swap. *) scheduled at [t2] after the swap. *)
Lemma swap_job_scheduled_t2: Lemma swap_job_scheduled_t2:
forall j, forall j,
scheduled_at sched' j t2 = scheduled_at sched' j t2 =
...@@ -189,11 +189,11 @@ Section SwappedFacts. ...@@ -189,11 +189,11 @@ Section SwappedFacts.
service received. *) service received. *)
(** To avoid dealing with symmetric cases, assume in the following (** To avoid dealing with symmetric cases, assume in the following
that t1 and t2 are ordered. *) that [t1] and [t2] are ordered. *)
Hypothesis H_well_ordered: t1 <= t2. Hypothesis H_well_ordered: t1 <= t2.
(** As another trivial invariant, we observe that nothing has changed (** As another trivial invariant, we observe that nothing has changed
before time t1. *) before time [t1]. *)
Lemma swap_before_invariant: Lemma swap_before_invariant:
forall t, forall t,
t < t1 -> t < t1 ->
...@@ -205,7 +205,7 @@ Section SwappedFacts. ...@@ -205,7 +205,7 @@ Section SwappedFacts.
[move: t_lt_t1|move: t_lt_t2]; rewrite ltnn. [move: t_lt_t1|move: t_lt_t2]; rewrite ltnn.
Qed. Qed.
(** Similarly, nothing has changed after time t2. *) (** Similarly, nothing has changed after time [t2]. *)
Lemma swap_after_invariant: Lemma swap_after_invariant:
forall t, forall t,
t2 < t -> t2 < t ->
...@@ -217,7 +217,7 @@ Section SwappedFacts. ...@@ -217,7 +217,7 @@ Section SwappedFacts.
[move: t1_lt_t|move: t2_lt_t]; rewrite ltnn. [move: t1_lt_t|move: t2_lt_t]; rewrite ltnn.
Qed. Qed.
(** Thus, we observe that, before t1, the two schedules are identical with (** Thus, we observe that, before [t1], the two schedules are identical with
regard to the service received by any job because they are identical. *) regard to the service received by any job because they are identical. *)
Corollary service_before_swap_invariant: Corollary service_before_swap_invariant:
forall t, forall t,
...@@ -232,7 +232,7 @@ Section SwappedFacts. ...@@ -232,7 +232,7 @@ Section SwappedFacts.
by apply ltnW. by apply ltnW.
Qed. Qed.
(** Likewise, we observe that, *after* t2, the swapped schedule again does not (** Likewise, we observe that, *after* [t2], the swapped schedule again does not
differ with regard to the service received by any job. *) differ with regard to the service received by any job. *)
Lemma service_after_swap_invariant: Lemma service_after_swap_invariant:
forall t, forall t,
...@@ -379,8 +379,8 @@ Section EDFSwap. ...@@ -379,8 +379,8 @@ Section EDFSwap.
(** ...that are ordered. *) (** ...that are ordered. *)
Hypothesis H_well_ordered: t1 <= t2. Hypothesis H_well_ordered: t1 <= t2.
(** Further, assume that, if there are jobs scheduled at times t1 and t2, then (** Further, assume that, if there are jobs scheduled at times [t1] and [t2], then
they either have the same deadline or violate EDF, ... *) they either have the same deadline or violate EDF, ... *)
Hypothesis H_not_EDF: Hypothesis H_not_EDF:
forall j1 j2, forall j1 j2,
scheduled_at sched j1 t1 -> scheduled_at sched j1 t1 ->
...@@ -388,14 +388,14 @@ Section EDFSwap. ...@@ -388,14 +388,14 @@ Section EDFSwap.
job_deadline j1 >= job_deadline j2. job_deadline j1 >= job_deadline j2.
(** ...and that we don't move idle times or deadline misses earlier, (** ...and that we don't move idle times or deadline misses earlier,
i.e., if t1 is not an idle time, then neither is t2 and whatever i.e., if [t1] is not an idle time, then neither is [t2] and whatever
job is scheduled at time t2 has not yet missed its deadline. *) job is scheduled at time [t2] has not yet missed its deadline. *)
Hypothesis H_no_idle_time_at_t2: Hypothesis H_no_idle_time_at_t2:
forall j1, forall j1,
scheduled_at sched j1 t1 -> scheduled_at sched j1 t1 ->
exists j2, scheduled_at sched j2 t2 /\ job_deadline j2 > t2. exists j2, scheduled_at sched j2 t2 /\ job_deadline j2 > t2.
(** Consider the schedule obtained from swapping the allocations at times t1 and t2. *) (** Consider the schedule obtained from swapping the allocations at times [t1] and [t2]. *)
Let sched' := swapped sched t1 t2. Let sched' := swapped sched t1 t2.
(** The key property of this transformation is that, for any job that (** The key property of this transformation is that, for any job that
...@@ -423,7 +423,7 @@ Section EDFSwap. ...@@ -423,7 +423,7 @@ Section EDFSwap.
Qed. Qed.
(** Next, we observe that a swap is unproblematic for the job scheduled at (** Next, we observe that a swap is unproblematic for the job scheduled at
time t2. *) time [t2]. *)
Lemma moved_earlier_implies_deadline_met: Lemma moved_earlier_implies_deadline_met:
scheduled_at sched j t2 -> scheduled_at sched j t2 ->
job_meets_deadline sched' j. job_meets_deadline sched' j.
...@@ -453,7 +453,7 @@ Section EDFSwap. ...@@ -453,7 +453,7 @@ Section EDFSwap.
(** From the above case analysis, we conclude that no deadline misses (** From the above case analysis, we conclude that no deadline misses
are introduced in the schedule obtained from swapping the are introduced in the schedule obtained from swapping the
allocations at times t1 and t2. *) allocations at times [t1] and [t2]. *)
Theorem edf_swap_no_deadline_misses_introduced: Theorem edf_swap_no_deadline_misses_introduced:
forall j, job_meets_deadline sched j -> job_meets_deadline sched' j. forall j, job_meets_deadline sched j -> job_meets_deadline sched' j.
Proof. Proof.
......
...@@ -81,16 +81,16 @@ Section ArrivalTimeProperties. ...@@ -81,16 +81,16 @@ Section ArrivalTimeProperties.
(** Let j be any job. *) (** Let j be any job. *)
Variable j: Job. Variable j: Job.
(** We say that job j has arrived at time t iff it arrives at some time t_0 (** We say that job j has arrived at time [t] iff it arrives at some time [t_0]
with t_0 <= t. *) with [t_0 <= t]. *)
Definition has_arrived (t : instant) := job_arrival j <= t. Definition has_arrived (t : instant) := job_arrival j <= t.
(** Next, we say that job j arrived before t iff it arrives at some time t_0 (** Next, we say that job j arrived before t iff it arrives at some time t_0
with t_0 < t. *) with t_0 < t. *)
Definition arrived_before (t : instant) := job_arrival j < t. Definition arrived_before (t : instant) := job_arrival j < t.
(** Finally, we say that job j arrives between t1 and t2 iff it arrives at (** Finally, we say that job j arrives between [t1] and [t2] iff it arrives at
some time t with t1 <= t < t2. *) some time [t] with [t1 <= t < t2]. *)
Definition arrived_between (t1 t2 : instant) := t1 <= job_arrival j < t2. Definition arrived_between (t1 t2 : instant) := t1 <= job_arrival j < t2.
End ArrivalTimeProperties. End ArrivalTimeProperties.
......
...@@ -15,7 +15,7 @@ Definition get_horizon_of_task (tsk : Task) : duration := ...@@ -15,7 +15,7 @@ Definition get_horizon_of_task (tsk : Task) : duration :=
Definition get_time_steps_of_task (tsk : Task) : seq duration := Definition get_time_steps_of_task (tsk : Task) : seq duration :=
time_steps_of (get_arrival_curve_prefix tsk). time_steps_of (get_arrival_curve_prefix tsk).
(** ... a function that yields the same time steps, offset by δ, ...**) (** ... a function that yields the same time steps, offset by [δ], ...**)
Definition time_steps_with_offset tsk δ := [seq t + δ | t <- get_time_steps_of_task tsk]. Definition time_steps_with_offset tsk δ := [seq t + δ | t <- get_time_steps_of_task tsk].
(** ... and a generalization of the previous function that repeats the time (** ... and a generalization of the previous function that repeats the time
......
...@@ -84,7 +84,7 @@ Section Definitions. ...@@ -84,7 +84,7 @@ Section Definitions.
Definition get_time_steps_of_task_T (tsk : task_T) : seq T := Definition get_time_steps_of_task_T (tsk : task_T) : seq T :=
time_steps_of_T (get_extrapolated_arrival_curve_T tsk). time_steps_of_T (get_extrapolated_arrival_curve_T tsk).
(** ... a function that yields the same time steps, offset by δ, ... *) (** ... a function that yields the same time steps, offset by [δ], ... *)
Definition time_steps_with_offset_T tsk δ := Definition time_steps_with_offset_T tsk δ :=
[seq t + δ | t <- get_time_steps_of_task_T tsk]%C. [seq t + δ | t <- get_time_steps_of_task_T tsk]%C.
......
...@@ -7,8 +7,8 @@ Require Export prosa.behavior.all. ...@@ -7,8 +7,8 @@ Require Export prosa.behavior.all.
"EDF schedule". "EDF schedule".
Note that the "proper" way to define an EDF schedule in Prosa is to use the Note that the "proper" way to define an EDF schedule in Prosa is to use the
EDF priority policy defined in model.priority.edf and the notion of EDF priority policy defined in [model.priority.edf] and the notion of
priority-compliant schedules defined in model.schedule.priority_driven, as priority-compliant schedules defined in [model.schedule.priority_driven], as
well as the general notion of work-conservation provided in well as the general notion of work-conservation provided in
model.schedule.work_conserving, which will have the benefit of taking into model.schedule.work_conserving, which will have the benefit of taking into
account issues such as various readiness models (e.g., jitter) and diverse account issues such as various readiness models (e.g., jitter) and diverse
......
...@@ -30,7 +30,7 @@ Section TaskRTCThresholdFullyNonPreemptive. ...@@ -30,7 +30,7 @@ Section TaskRTCThresholdFullyNonPreemptive.
(** In the fully non-preemptive model, no job can be preempted prior to its (** In the fully non-preemptive model, no job can be preempted prior to its
completion. In other words, once a job starts running, it is guaranteed completion. In other words, once a job starts running, it is guaranteed
to finish. Thus, we can set the task-level run-to-completion threshold to finish. Thus, we can set the task-level run-to-completion threshold
to ε. *) to [ε]. *)
Definition fully_nonpreemptive_rtc_threshold : TaskRunToCompletionThreshold Task := Definition fully_nonpreemptive_rtc_threshold : TaskRunToCompletionThreshold Task :=
fun tsk : Task => ε. fun tsk : Task => ε.
......
...@@ -11,7 +11,7 @@ Section FullyPreemptiveModel. ...@@ -11,7 +11,7 @@ Section FullyPreemptiveModel.
Context {Task : TaskType}. Context {Task : TaskType}.
(** In the fully preemptive model, any job can be preempted at any (** In the fully preemptive model, any job can be preempted at any
time. Thus, the maximal non-preemptive segment has length at most ε time. Thus, the maximal non-preemptive segment has length at most [ε]
(i.e., one time unit such as a processor cycle). *) (i.e., one time unit such as a processor cycle). *)
Definition fully_preemptive_task_model : TaskMaxNonpreemptiveSegment Task := Definition fully_preemptive_task_model : TaskMaxNonpreemptiveSegment Task :=
fun tsk : Task => ε. fun tsk : Task => ε.
......
...@@ -231,17 +231,17 @@ Section AbstractRTAforEDFwithArrivalCurves. ...@@ -231,17 +231,17 @@ Section AbstractRTAforEDFwithArrivalCurves.
Hypothesis H_busy_interval : Hypothesis H_busy_interval :
definitions.busy_interval sched interference interfering_workload j t1 t2. definitions.busy_interval sched interference interfering_workload j t1 t2.
(** Let's define A as a relative arrival time of job j (with respect to time t1). *) (** Let's define A as a relative arrival time of job j (with respect to time [t1]). *)
Let A := job_arrival j - t1. Let A := job_arrival j - t1.
(** Consider an arbitrary shift Δ inside the busy interval ... *) (** Consider an arbitrary offset [Δ] inside the busy interval ... *)
Variable Δ : duration. Variable Δ : duration.
Hypothesis H_Δ_in_busy : t1 + Δ < t2. Hypothesis H_Δ_in_busy : t1 + Δ < t2.
(** ... and the set of all arrivals between [t1] and [t1 + Δ]. *) (** ... and the set of all arrivals between [t1] and [t1 + Δ]. *)
Let jobs := arrivals_between arr_seq t1 (t1 + Δ). Let jobs := arrivals_between arr_seq t1 (t1 + Δ).
(** We define a predicate [EDF_from tsk].Predicate [EDF_from tsk] (** We define a predicate [EDF_from tsk]. The predicate [EDF_from tsk]
holds true for any job [jo] of task [tsk] such that holds true for any job [jo] of task [tsk] such that
[job_deadline jo <= job_deadline j]. *) [job_deadline jo <= job_deadline j]. *)
Let EDF_from (tsk : Task) := fun (jo : Job) => EDF jo j && (job_task jo == tsk). Let EDF_from (tsk : Task) := fun (jo : Job) => EDF jo j && (job_task jo == tsk).
...@@ -355,7 +355,7 @@ Section AbstractRTAforEDFwithArrivalCurves. ...@@ -355,7 +355,7 @@ Section AbstractRTAforEDFwithArrivalCurves.
(** Given any job j of task [tsk] that arrives exactly A units after the beginning of (** Given any job j of task [tsk] that arrives exactly A units after the beginning of
the busy interval, the bound of the total interference incurred by j within an the busy interval, the bound of the total interference incurred by j within an
interval of length Δ is equal to [task_rbf (A + ε) - task_cost tsk + IBF_other(A, Δ)]. *) interval of length [Δ] is equal to [task_rbf (A + ε) - task_cost tsk + IBF_other(A, Δ)]. *)
Let total_interference_bound tsk (A Δ : duration) := Let total_interference_bound tsk (A Δ : duration) :=
task_rbf (A + ε) - task_cost tsk + IBF_other A Δ. task_rbf (A + ε) - task_cost tsk + IBF_other A Δ.
......