Built with Alectryon, running Coq+SerAPI v8.15.0+0.15.0. Bubbles () indicate interactive fragments: hover for details, tap to reveal contents. Use Ctrl+↑Ctrl+↓ to navigate, Ctrl+🖱️ to focus. On Mac, use ⌘ instead of Ctrl.
Notation"[ rel _ _ | _ ]" was already used in scope
fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ : _ | _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ & _ | _ ]" was already used
in scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ & _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ | _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ ]" was already used in scope
fun_scope. [notation-overridden,parsing]
Notation"_ + _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"_ - _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"_ <= _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"_ < _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"_ >= _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"_ > _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"_ <= _ <= _" was already used in scope
nat_scope. [notation-overridden,parsing]
Notation"_ < _ <= _" was already used in scope
nat_scope. [notation-overridden,parsing]
Notation"_ <= _ < _" was already used in scope
nat_scope. [notation-overridden,parsing]
Notation"_ < _ < _" was already used in scope
nat_scope. [notation-overridden,parsing]
Notation"_ * _" was already used in scope nat_scope.
[notation-overridden,parsing]
Notation"[ rel _ _ | _ ]" was already used in scope
fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ : _ | _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ & _ | _ ]" was already used
in scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ & _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ | _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ ]" was already used in scope
fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ | _ ]" was already used in scope
fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ : _ | _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ & _ | _ ]" was already used
in scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ & _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ | _ ]" was already used in
scope fun_scope. [notation-overridden,parsing]
Notation"[ rel _ _ in _ ]" was already used in scope
fun_scope. [notation-overridden,parsing]
(** * Reduction of the search space for Abstract RTA *)(** In this file, we prove that in order to calculate the worst-case response time it is sufficient to consider only values of [A] that lie in the search space defined below. *)SectionAbstractRTAReduction.(** The response-time analysis we are presenting in this series of documents is based on searching over all possible values of [A], the relative arrival time of the job respective to the beginning of the busy interval. However, to obtain a practically useful response-time bound, we need to constrain the search space of values of [A]. In this section, we define an approach to reduce the search space. *)Context {Task : TaskType}.(** First, we provide a constructive notion of equivalent functions. *)SectionEquivalentFunctions.(** Consider an arbitrary type [T]... *)Context {T : eqType}.(** ...and two function from [nat] to [T]. *)Variablesf1f2 : nat -> T.(** Let [B] be an arbitrary constant. *)VariableB : nat.(** Then we say that [f1] and [f2] are equivalent at values less than [B] iff for any natural number [x] less than [B] [f1 x] is equal to [f2 x]. *)Definitionare_equivalent_at_values_less_than :=
forallx, x < B -> f1 x = f2 x.(** And vice versa, we say that [f1] and [f2] are not equivalent at values less than [B] iff there exists a natural number [x] less than [B] such that [f1 x] is not equal to [f2 x]. *)Definitionare_not_equivalent_at_values_less_than :=
existsx, x < B /\ f1 x <> f2 x.EndEquivalentFunctions.(** Let [tsk] be any task that is to be analyzed *)Variabletsk : Task.(** To ensure that the analysis procedure terminates, we assume an upper bound [B] on the values of [A] that must be checked. The existence of [B] follows from the assumption that the system is not overloaded (i.e., it has bounded utilization). *)VariableB : duration.(** Instead of searching for the maximum interference of each individual job, we assume a per-task interference bound function [IBF(tsk, A, x)] that is parameterized by the relative arrival time [A] of a potential job (see abstract_RTA.definitions.v file). *)Variableinterference_bound_function : Task -> duration -> duration -> duration.(** Recall the definition of [ε], which defines the neighborhood of a point in the timeline. Note that [ε = 1] under discrete time. *)(** To ensure that the search converges more quickly, we only check values of [A] in the interval <<[0, B)>> for which the interference bound function changes, i.e., every point [x] in which [interference_bound_function (A - ε, x)] is not equal to [interference_bound_function (A, x)]. *)Definitionis_in_search_spaceA :=
A = 0 \/
0 < A < B /\ are_not_equivalent_at_values_less_than
(interference_bound_function tsk (A - ε)) (interference_bound_function tsk A) B.(** In this section we prove that for every [A] there exists a smaller [A_sp] in the search space such that [interference_bound_function(A_sp,x)] is equal to [interference_bound_function(A, x)]. *)SectionExistenceOfRepresentative.(** Let [A] be any constant less than [B]. *)VariableA : duration.HypothesisH_A_less_than_B : A < B.(** We prove that there exists a constant [A_sp] such that: (a) [A_sp] is no greater than [A], (b) [interference_bound_function(A_sp, x)] is equal to [interference_bound_function(A, x)] and (c) [A_sp] is in the search space. In other words, either [A] is already inside the search space, or we can go to the "left" until we reach [A_sp], which will be inside the search space. *)
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration H_A_less_than_B: A < B
existsA_sp : nat,
A_sp <= A /\
are_equivalent_at_values_less_than
(interference_bound_function tsk A)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration H_A_less_than_B: A < B
existsA_sp : nat,
A_sp <= A /\
are_equivalent_at_values_less_than
(interference_bound_function tsk A)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp
all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t) (iota 0 B) \/
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp ALT: all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t)
(iota 0 B) \/
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp
all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t) (iota 0 B) \/
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp
all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t) (iota 0 B)
|| has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp
~~
(~~
all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t) (iota 0 B) &&
~~
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B))
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp CONTR: ~~
all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t)
(iota 0 B) &&
~~
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
False
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp NALL: ~~
all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t)
(iota 0 B)
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
byrewrite -has_predC /predC in NALL.
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B IHn: n < B ->
existsA_sp : nat,
A_sp <= n /\
are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk A_sp) B /\
is_in_search_space A_sp ALT: all
(funt : duration =>
interference_bound_function tsk n t ==
interference_bound_function tsk n.+1 t)
(iota 0 B) \/
has
(funt : duration =>
interference_bound_function tsk n t
!= interference_bound_function tsk n.+1 t)
(iota 0 B)
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP ALT: exists2 x : nat_eqType,
x \in iota 0 B &
interference_bound_function tsk n x
!= interference_bound_function tsk n.+1 x
is_in_search_space n.+1
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP ALT: exists2 x : nat_eqType,
x \in iota 0 B &
interference_bound_function tsk n x
!= interference_bound_function tsk n.+1 x
0 < n.+1 < B /\
are_not_equivalent_at_values_less_than
(interference_bound_function tsk (n.+1 - ε))
(interference_bound_function tsk n.+1) B
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP ALT: exists2 x : nat_eqType,
x \in iota 0 B &
interference_bound_function tsk n x
!= interference_bound_function tsk n.+1 x
are_not_equivalent_at_values_less_than
(interference_bound_function tsk (n.+1 - ε))
(interference_bound_function tsk n.+1) B
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType IN: y \in iota 0 B N: interference_bound_function tsk n y
!= interference_bound_function tsk n.+1 y
are_not_equivalent_at_values_less_than
(interference_bound_function tsk (n.+1 - ε))
(interference_bound_function tsk n.+1) B
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType IN: y \in iota 0 B N: interference_bound_function tsk n y
!= interference_bound_function tsk n.+1 y
y < B /\
interference_bound_function tsk (n.+1 - ε) y <>
interference_bound_function tsk n.+1 y
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType N: interference_bound_function tsk n y
!= interference_bound_function tsk n.+1 y
0 <= y < B ->
y < B /\
interference_bound_function tsk (n.+1 - ε) y <>
interference_bound_function tsk n.+1 y
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType N: interference_bound_function tsk n y
!= interference_bound_function tsk n.+1 y LT: y < B
y < B /\
interference_bound_function tsk (n.+1 - ε) y <>
interference_bound_function tsk n.+1 y
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType N: interference_bound_function tsk n y
!= interference_bound_function tsk n.+1 y LT: y < B
interference_bound_function tsk (n.+1 - ε) y <>
interference_bound_function tsk n.+1 y
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType N: interference_bound_function tsk n y
!= interference_bound_function tsk n.+1 y LT: y < B
interference_bound_function tsk n y <>
interference_bound_function tsk n.+1 y
Task: TaskType tsk: Task B: duration interference_bound_function: Task ->
duration ->
duration -> duration A: duration n: nat H_A_less_than_B: n.+1 < B ASP: nat NEQ: ASP <= n EQ: are_equivalent_at_values_less_than
(interference_bound_function tsk n)
(interference_bound_function tsk ASP) B SP: is_in_search_space ASP y: nat_eqType LT: y < B CONTR: interference_bound_function tsk n y =
interference_bound_function tsk n.+1 y
interference_bound_function tsk n y ==
interference_bound_function tsk n.+1 y
byrewrite CONTR.}Qed.EndExistenceOfRepresentative.(** In this section we prove that any solution of the response-time recurrence for a given point [A_sp] in the search space also gives a solution for any point A that shares the same interference bound. *)SectionFixpointSolutionForAnotherA.(** Suppose [A_sp + F_sp] is a "small" solution (i.e. less than [B]) of the response-time recurrence. *)VariablesA_spF_sp : duration.HypothesisH_less_than : A_sp + F_sp < B.HypothesisH_fixpoint : A_sp + F_sp >= interference_bound_function tsk A_sp (A_sp + F_sp).(** Next, let [A] be any point such that: (a) [A_sp <= A <= A_sp + F_sp] and (b) [interference_bound_function(A, x)] is equal to [interference_bound_function(A_sp, x)] for all [x] less than [B]. *)VariableA : duration.HypothesisH_bounds_for_A : A_sp <= A <= A_sp + F_sp.HypothesisH_equivalent :
are_equivalent_at_values_less_than
(interference_bound_function tsk A)
(interference_bound_function tsk A_sp) B.(** We prove that there exists a constant [F] such that [A + F] is equal to [A_sp + F_sp] and [A + F] is a solution for the response-time recurrence for [A]. *)