- Information
- AI Chat
Was this document helpful?
Timing analysis
Course: Software Engineering (CSPC 111)
140 Documents
Students shared 140 documents in this course
University: STI West Negros University
Was this document helpful?
Timing analysis
As I discussed in the introduction to this chapter, the correctness of a real-time system
depends not just on the correctness of its outputs but also on the time at which these
outputs were produced. Therefore, timing analysis is an important activity in the
embedded, real-time software development process. In such an analysis, you calculate
how often each process in the system must be executed to ensure that all inputs are
processed and all system responses are produced in a timely way. The results of the
timing analysis are used to decide how frequently each process should execute and
how these processes should be scheduled by the real-time operating system.
Timing analysis for real-time systems is particularly difficult when the system has to deal
with a mixture of periodic and aperiodic stimuli and responses. Because aperiodic
stimuli are unpredictable, you have to make assumptions about the probability of these
stimuli occurring and therefore requiring service at any particular time. These
assumptions may be incorrect, and system performance after delivery may not be
adequate. Cooling’s book (Cooling 2003) discusses techniques for real-time system
performance analysis that takes aperiodic events into account.
As computers have become faster, it has become possible in many systems to design
using only periodic stimuli. When processors were slow, aperiodic stimuli had to be
used to ensure that critical events were processed before their deadline, as delays in
processing usually involved some loss to the system. For example, the failure of a
power supply in an embedded system may mean that the system has to shut down
attached equipment in a controlled way, within a very short time (say 50 milliseconds).
This could be implemented as a “power fail” interrupt. However, it can also be
implemented using a periodic process that runs frequently and checks the power. As
long as the time between process invocations is short, there is still time to perform a
controlled shutdown of the system before the lack of power causes damage. For this
reason, I only discuss timing issues for periodic processes.
When you are analyzing the timing requirements of embedded real-time systems and
designing systems to meet these requirements, you have to consider three key factors: