文档介绍:CSE 237B Fall 2004Tasks and Task Scheduling for Real Time
Rajesh puter Science and Engineering
University of California, San Diego.
1
Overview
The goal of task modeling and management is to understand the requirements of embedded software for application programming as well as for the operating system needs.
Task management
Task interaction
Embedded Software as Tasks
Static and Dynamic Aspects of Task scheduling
Memory Management: Stack and Heap
Real-time mercial and research real-time operating systems
2
Tasks
An embedded system typically has many activities (or tasks) occurring in parallel.
A task represents an activity in the system.
Historically, one task represents one sequential thread of execution;
however, multithreading allows multiple threads of control in the same task.
We will assume a single thread of control.
The principles of concurrency are fundamental regardless of the granularity of the concurrent units (processes, tasks, or threads).
We will examine concurrency in terms of tasks.
3
Concurrency
Concurrent tasking means structuring a system into concurrent tasks.
Advantages of concurrent tasking
a natural model for many real-time applications.
results in a separation of concerns of what each task does from when it does it. This usually makes the system easier to understand, manage, and construct.
can result in an overall reduction in system execution time by overlapping executions of independent tasks.
allows greater scheduling flexibility since time critical tasks with hard deadlines may be given a higher priority than less critical tasks.
identifying the concurrent tasks early in the design can allow an early performance analysis of the system.
However, concurrent tasking plexity because of task interactions.
4
Task Interaction
Often, tasks execute asynchronously, ., at different speeds, but may need to interact with each other.
Three types of interactions are munication
synchronization
mutual munication is simply used to tr