beyond the weakly hard model: measuring the performance ...beyond the weakly hard model: measuring...
TRANSCRIPT
Beyond the Weakly Hard Model: Measuring the Performance Cost
of Deadline Misses
Authors: Paolo Pazzaglia, Luigi Pannocchi, Alessandro Biondi, Marco Di Natale
Scuola Superiore SantโAnna, Pisa
Barcelona, ECRTS, July 6th, 2018
Introduction
2
P. Pazzaglia
โข Embedded systems with control tasks may face overloadconditions (e.g. automotive)
โข Common (practical) approach: running at a high rate and allowing some deadline miss is an acceptable compromise
How to study performance evolution under overload conditions?
โข Weakly Hard real-time systems: allowing a limited number of deadline misses
โ (m,k): at most m deadlines are missed every k activations
โข (m,k) constraints can be extracted with TWCA
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
3
โข (m,k) constraint is not enough descriptiveโฆ
โข (m,k) constraint leads to a binary model (either pass or fail)
โ Easy to define stability guarantees
โ No information about performance of different patterns
โ Difficult to extract an ordering between constraints
โข No relation with the system state:
โ Deadline misses may have different effects (transients vs steady state)
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Weakly hard model limitations
Weakly hard model limitations
4
P. Pazzaglia
Assumption: When a deadline is missed, the control output is not updated
๐ = 50 ๐๐ ; ๐ท = 0.7 โ ๐
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Changing the pattern of H/M deadlines may lead to differentperformance values!
5
โข Goal: Developing a new model for studying:
โ How the performance change with different patterns of missed deadlines that satisfy a given (m,k) constraint
โ Worst guaranteed performance
โ Different policy at deadline miss (continue or kill?)
โข Merging real-time analysis with control system dynamics and performance analysis
P. Pazzaglia
A new model for performance analysis
H/M pattern Control updates
Performance
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
6
โข Linear Time Invariant plant, MIMO
โข Periodic control of period ๐๐ and deadline ๐ท๐ โค ๐๐โข State-feedback control: ๐ข ๐ = ๐พ ๐ ๐ โ ๐ฅ ๐
State update function: x k + 1 = Adx k + Bd1๐ข ๐ โ 1 + ๐ต๐2๐ข[๐]
โข Similar to LET model: trading jitter for latency
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
System model
kT(k+1)TkT+D
๐ ๐ โ ๐ ๐[๐] Active control command
actuationactuation
Control task
Actuator
Read sensor
โข Missing a deadline means missing an actuator command update
โข Chosen strategy: keep the previous actuation value
โข Problem: The actuator uses a control output that is not related with the current state
โ Control output is no more ยซfreshยป
โข The system dynamics changes!7
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Missing a deadline
kT (k+1)TkT+D
XControl task
๐ ๐ โ ๐ ๐ ๐
โข Update freshness ๐ฅ of the control output
โ โ = 0 if job completes before the deadline
โ Otherwise, โ equals to the ยซageing stepsยป of the control output
x k + 1 = Adx k + ๐ต๐1๐ข ๐ โ 1 + ๐ต๐2๐ข[๐]
๐ข ๐ โ 1 = โ๐พ๐๐ฅ[๐ โ 1 โ โ๐]
๐ข ๐ = โ๐พ๐๐ฅ[๐ โ โ๐]
โข Freshness is independent of control law and controlled system!
โข Different effects changing deadline miss handling8
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Update freshness: definition
kT(k+1)TkT+D
๐ ๐ โ ๐ ๐[๐]
Control task
9
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Update freshness: Continue strategy
0,0 0,1
1,11,0
H
H
H
H
M
M
M
M
โ ๐ต๐ถ๐ ๐ โค ๐ท๐
โ ๐๐ถ๐ ๐ < ๐๐ + ๐ท๐
kT (k+1)TkT+D
ฮ๐, ฮ๐
See Algorithm 1 in the paper for more details
โ๐ฒ๐ x ๐ โ ๐ โ ๐๐ โ๐ฒ๐ x ๐ โ ๐๐
10
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Update freshness: Kill strategy
ฮ๐, ฮ๐
kT (k+1)TkT+D
โ๐ฒ๐ x ๐ โ ๐ โ ๐๐ โ๐ฒ๐ x ๐ โ ๐๐
X
0,0 0,1 1,2
1,0
M M M
M HHH
H
2,0
M
H
2,3
3,0
M
H
In this example, maximum number of consecutive deadline misses is equal to 3
โ ๐ต๐ถ๐ ๐ โค ๐ท๐
11
โข System dynamics as a function of freshness pairs
๐ฅ ๐ + 1 = ๐ด๐๐ฅ ๐ โ ๐ต๐1๐พ๐๐ฅ ๐ โ 1 โ ๐ฅ๐ โ ๐ต๐2๐พ๐๐ฅ ๐ โ ๐ฅ๐
โข Augmented state vector ฮพ[๐]
ฮพ[๐] = [๐ฅ ๐ ; ๐ฅ ๐ โ 1 ;โฆ . ๐ฅ ๐ โ โ๐๐๐ฅ โ 1 ]
โข We can write the system dynamics as: ฮพ ๐ + 1 = ะค(๐ฅ๐, ๐ฅ๐ ) ฮพ[๐]
โข State update matrix ะค(๐ฅ๐, ๐ฅ๐ )
ะค(๐ฅ๐, ๐ฅ๐ ) =
๐ด๐ โฏ โ๐ต๐2๐พ๐ โฏ โ ๐ต๐1๐พ๐ โฏ๐ผ๐ 0๐ โฏ โฏ โฏ0๐ ๐ผ๐ 0๐ โฏ โฏโฎ โฎ โฎ โฑ โฏ โฏ
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
State update matrix
Example:
โข Every combination of (๐ฅ๐, ๐ฅ๐) is mapped to a specific dynamic of
the system through the matrix ะค(๐ฅ๐, ๐ฅ๐)
12
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
State update matrix: an example
0,0 0,1
1,11,0
H
H
H
H
M
M
M
M
13
ฮพ ๐ + 1 = ะค(๐ฅ๐, ๐ฅ๐ ) ฮพ[๐]
โข Every ะค(๐ฅ๐, ๐ฅ๐ ) represents an operating mode of the system
โ Different dynamics
โ Constraints on transitions due to (m,k)
โข Constrained switched linear system
โข Even if some operating modes can be unstable, global stability can be still ensured with state of the art analysis
P. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Missing deadlines: effects on control
Hypothesis:
- Every combination of mode switches leads to a stable behavior
- Exponential stability: bounded by an exponential function
14
P. Pazzaglia
Performance analysis
โข Assign a performance value for each sequence of N jobs
โข Value of N is determined by the exponential bound on the dynamics
โข Sum of quadratic error
โข Matrix elements of ฮจ ๐ depends on the ordered sequence of H/M
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
15
P. Pazzaglia
Performance analysis
โข ๐ท ๐ = ฮพ[๐]๐ปฮจ(๐)ฮพ[๐]
โข Scalar performance index independent from initial state
โ ๐ = | ฮจ(๐ ) |2
โข It is possible to extract one single value representing the worstvalue for each (m,k) constraint:
โข Worst Case Normalized Performance: ๐๐ถ๐๐ =๐๐๐ฅ๐ โ ๐
โ ๐๐๐ โ๐๐ก๐
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
16
P. Pazzaglia
Performance state machine WH constraint (1,2)N = 4 steps
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Desired performance region
Transitions marked with Xshould never happen for (m,k) constraints
17
P. Pazzaglia
Case study: Furuta pendulum
โข Furuta pendulum: rotary inverted pendulum
โข Linearized model in the neighbourhood of the upward position
โข Feedback control with ๐๐ = 0.1๐ ๐๐ and ๐ท๐ = 0.2 โ ๐๐
โข Testing different (m,K) values and studying how Worst Case performance changes
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
18
Case study: Furuta pendulum
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline MissesP. PazzagliaBeyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
The lower the better
19
Case study: Furuta pendulum
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
Continue job strategy
Kill job strategy
20
โข This new model can be used as a time contract betweensoftware designers and control engineers
โข Possibility of inserting run-time monitors
P. Pazzaglia
Possible applications
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
(m,k) = (1,2)
21
P. Pazzaglia
Summary
โข New model for studying performance evolution under overloadconditions
1. Creating a state machine for computing freshness of outputs, applicable to different patterns and handling of deadline misses
2. Intergrating freshness information with state evolution of the controlled system: different operating modes
3. Creating a state machine for computing performance valuesrealted to patterns of H/M deadlines
โ Worst case performance guarantees
โ Runtime monitors for performance evolution
โข Case study: Furuta pendulum
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
22
P. Pazzaglia
Future work
โข Extensions:
โ Including additional performance metrics
โ Extending the case study to WCRT>T+D, allowing multiple pending jobs at deadline
โข Finding optimal controller for a system under (m,K) constraints, for achieveing a given performance
โข More complex case studies:
Testing non linear systems performance by simulation
More complex deadline miss handlings
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses
23
P. Pazzaglia
Thank you!
Any questions?
Beyond the Weakly Hard Model: Measuring the Performance Cost of Deadline Misses