Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PROSA - Formally Proven Schedulability Analysis
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RT-PROOFS
PROSA - Formally Proven Schedulability Analysis
Merge requests
!371
Define periodic and average resource model
Code
Review changes
Check out branch
Download
Patches
Plain diff
Expand sidebar
Open
Define periodic and average resource model
sbozhko/rt-proofs:prm
into
master
Overview
32
Commits
1
Pipelines
21
Changes
5
Open
Define periodic and average resource model
Sergey Bozhko
requested to merge
sbozhko/rt-proofs:prm
into
master
May 2, 2024
Overview
1
Commits
1
Pipelines
21
Changes
5
0
0
Merge request reports
Compare
master
version 32
a9d15560
1 month ago
version 31
f8099eda
1 month ago
version 30
179066a5
1 month ago
version 29
fbeead66
1 month ago
version 28
5c8e087e
1 month ago
version 27
5300d7ab
2 months ago
version 26
e51cde69
2 months ago
version 25
1fd46851
2 months ago
version 24
a6892db1
2 months ago
version 23
23befe79
2 months ago
version 22
c29bcd70
3 months ago
version 21
9e0a8c4a
May 29, 2024
version 20
92bbc58c
May 29, 2024
version 19
ff347d2c
May 23, 2024
version 18
ff347d2c
May 23, 2024
version 17
ff347d2c
May 23, 2024
version 16
ff347d2c
May 23, 2024
version 15
099038b9
May 23, 2024
version 14
099038b9
May 23, 2024
version 13
099038b9
May 23, 2024
version 12
099038b9
May 23, 2024
version 11
581f1780
May 23, 2024
version 10
581f1780
May 23, 2024
version 9
581f1780
May 23, 2024
version 8
581f1780
May 23, 2024
version 7
77e815c9
May 23, 2024
version 6
d86d5aba
May 22, 2024
version 5
d24844c6
May 22, 2024
version 4
bcfcd798
May 21, 2024
version 3
31c9419c
May 17, 2024
version 2
ae8b6019
May 6, 2024
version 1
20c73c7d
May 2, 2024
master (base)
and
latest version
latest version
a9d15560
1 commit,
1 month ago
version 32
a9d15560
1 commit,
1 month ago
version 31
f8099eda
1 commit,
1 month ago
version 30
179066a5
1 commit,
1 month ago
version 29
fbeead66
1 commit,
1 month ago
version 28
5c8e087e
29 commits,
1 month ago
version 27
5300d7ab
25 commits,
2 months ago
version 26
e51cde69
20 commits,
2 months ago
version 25
1fd46851
19 commits,
2 months ago
version 24
a6892db1
18 commits,
2 months ago
version 23
23befe79
17 commits,
2 months ago
version 22
c29bcd70
13 commits,
3 months ago
version 21
9e0a8c4a
12 commits,
May 29, 2024
version 20
92bbc58c
11 commits,
May 29, 2024
version 19
ff347d2c
10 commits,
May 23, 2024
version 18
ff347d2c
10 commits,
May 23, 2024
version 17
ff347d2c
10 commits,
May 23, 2024
version 16
ff347d2c
10 commits,
May 23, 2024
version 15
099038b9
9 commits,
May 23, 2024
version 14
099038b9
9 commits,
May 23, 2024
version 13
099038b9
9 commits,
May 23, 2024
version 12
099038b9
9 commits,
May 23, 2024
version 11
581f1780
8 commits,
May 23, 2024
version 10
581f1780
8 commits,
May 23, 2024
version 9
581f1780
8 commits,
May 23, 2024
version 8
581f1780
8 commits,
May 23, 2024
version 7
77e815c9
7 commits,
May 23, 2024
version 6
d86d5aba
6 commits,
May 22, 2024
version 5
d24844c6
5 commits,
May 22, 2024
version 4
bcfcd798
4 commits,
May 21, 2024
version 3
31c9419c
3 commits,
May 17, 2024
version 2
ae8b6019
2 commits,
May 6, 2024
version 1
20c73c7d
1 commit,
May 2, 2024
5 files
+
551
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
5
analysis/facts/model/processor/average_resource_model.v
0 → 100644
+
97
−
0
View file @ a9d15560
Edit in single-file editor
Open in Web IDE
Require
Export
prosa
.
model
.
priority
.
classes
.
Require
Export
prosa
.
model
.
processor
.
supply
.
Require
Export
prosa
.
model
.
processor
.
platform_properties
.
Require
Export
prosa
.
analysis
.
definitions
.
sbf
.
plain
.
Require
Export
prosa
.
model
.
processor
.
average_resource_model
.
(** In this section, we define a valid SBF for the average resource model. *)
Section
AverageResourceModelValidSBF
.
(** Consider any type of tasks ... *)
Context
{
Task
:
TaskType
}
.
(** ... and any type of jobs associated with these tasks. *)
Context
{
Job
:
JobType
}
.
Context
`{
JobTask
Job
Task
}
.
Context
`{
JobArrival
Job
}
.
Context
`{
JobCost
Job
}
.
(** Consider any kind of processor state. *)
Context
{
PState
:
ProcessorState
Job
}
.
(** Consider a JLFP policy, ... *)
Context
`{
JLFP_policy
Job
}
.
(** ... any arrival sequence, ... *)
Variable
arr_seq
:
arrival_sequence
Job
.
(** ... and any schedule. *)
Variable
sched
:
schedule
PState
.
(** Assume the average resource model with a resource period [Π],
resource allocation time [Θ], and supply delay [ν]. *)
Variable
Π
Θ
ν
:
duration
.
Hypothesis
H_average_resource_model
:
average_resource_model
Π
Θ
ν
sched
.
(** We define SBF for the average resource model as
[((Δ - ν) - (Π - Θ)) * Θ / Π]. *)
#[
local
]
Instance
sbf
:
SupplyBoundFunction
:=
fun
Δ
=>
((
Δ
-
ν
)
-
(
Π
-
Θ
))
*
Θ
%/
Π
.
(** We show that [sbf] is monotone. *)
Lemma
arm_sbf_monotone
:
sbf_is_monotone
sbf
.
Proof
.
move
=>
δ1
δ2
LE
;
rewrite
/
sbf
.
interval_to_duration
δ1
δ2
Δ
.
set
(
A
:=
Π
-
Θ
)
.
have
[
LEA
|
LEA
]
:=
leqP
(
δ1
-
ν
)
A
.
{
by
move
:
LEA
;
rewrite
-
subn_eq0
=>
/
eqP
EQ
;
rewrite
EQ
div0n
.
}
{
have
->
:
δ1
+
Δ
-
ν
-
A
=
δ1
-
ν
-
A
+
Δ
by
lia
.
by
rewrite
mulnDl
;
apply
leq_div2r
;
lia
.
}
Qed
.
(** The introduced SBF is also a unit-supply SBF. *)
Lemma
arm_sbf_unit
:
unit_supply_bound_function
sbf
.
Proof
.
move
:
H_average_resource_model
=>
[
LEΠ
_]
.
move
=>
δ
;
rewrite
/
sbf
.
have
[
Z
|
POS
]
:=
posnP
Π
;
first
by
subst
;
lia
.
set
(
A
:=
Π
-
Θ
)
.
have
[
LEν
|
LEν
]
:=
leqP
δ
ν
.
{
move
:
(
LEν
);
rewrite
-
subn_eq0
=>
/
eqP
->
.
have
[
EQ
|
EQ
]:
(
δ
.
+
1
-
ν
=
0
)
\/
(
δ
.
+
1
-
ν
=
1
)
by
lia
.
{
by
rewrite
EQ
.
}
{
rewrite
EQ
//=
;
clear
EQ
.
have
[
EQ
|
EQ
]:
1
-
A
=
0
\/
1
-
A
=
1
by
lia
.
{
by
rewrite
EQ
.
}
{
rewrite
EQ
mul1n
sub0n
mul0n
-
addn1
div0n
add0n
.
move
:
LEΠ
;
rewrite
leq_eqVlt
=>
/
orP
[
/
eqP
T
|
LT
];
subst
.
{
by
rewrite
divnn
POS
.
}
{
by
rewrite
divn_small
.
}
}
}
}
{
rewrite
-
addn1
-
addnBAC
?addn1
;
last
by
lia
.
have
[
LEA
|
LEA
]
:=
leqP
(
δ
-
ν
).
+
1
A
.
{
by
move
:
LEA
;
rewrite
-
subn_eq0
=>
/
eqP
EQ
;
rewrite
EQ
div0n
.
}
by
rewrite
-
addn1
-
addnBAC
//
mulnDl
mul1n
-
addn1
-
divnDMl
//
;
apply
leq_div2r
;
lia
.
}
Qed
.
(** Finally, we show that the defined [sbf] is a valid SBF. *)
Lemma
arm_sbf_valid
:
valid_supply_bound_function
arr_seq
sched
sbf
.
Proof
.
have
FS
:
forall
a
,
0
-
a
=
0
by
lia
.
split
;
first
by
rewrite
/
sbf
!
FS
mul0n
div0n
.
move
=>
j
t1
t2
ARR
_
t
/
andP
[
LE1
LE2
]
.
move
:
H_average_resource_model
=>
[
LE
SUP
]
.
interval_to_duration
t1
t
Δ
.
rewrite
-
(
leqRW
(
SUP
_
_))
/
sbf
.
have
->
:
t1
+
Δ
-
t1
=
Δ
by
lia
.
by
rewrite
subnBA
//
;
apply
leq_div2r
,
leq_mul
=>
//
;
lia
.
Qed
.
End
AverageResourceModelValidSBF
.
Loading