www.ti.com
Execution Time
Figure 4-1. Execution Timeline for Two Periodic Tasks
A
B
3 ms |
| 3 ms |
| 3 ms |
| 3 ms |
Idle
In this case, both task A and B meet their deadlines and we have more than 18% (1 ms every 6 ms) of the CPU idle.
Suppose we now increase the amount of processing that task B must perform very slightly, say to 1.0000001 ms every 3 ms. Notice that task B will miss its first deadline because task A consumes 2 ms of the available 3 ms of task B'speriod. This leaves only 1 ms for B but B needs just a bit more than 1 ms to complete its work. If we make task B higher priority than task A, task A will miss its deadline line because task B will consume more than 1 ms of task A's2 ms period.
In this example, we have a system that has over 18% of the CPU MIPS unused but we cannot complete both task A and B within their
The good news is that this
Finally, designing with
4.4.2 Execution Time Model
In this section, we describe a simple execution time model that applies to all
All algorithms must be characterized as periodic execution of one or more functions. For example, a voice encoder may be implemented to operate on a frame of data that represents 22.5 ms of voice data. In this case, the period is 22.5 ms (because every 22.5 ms a new frame of data is available for processing) and the deadline is also 22.5 ms (because there is no need to complete the processing ahead of the time that the next frame of data is available).
Rule 24
All algorithms must characterize the typical period and
42 | Algorithm Performance Characterization | SPRU352G |
|
| Submit Documentation Feedback |