5 Echtzeitsysteme Flashcards
Name the two requirements needed for real time.
- Computation is correct
- Computation finishes in time (before deadline)
Was ist die Hard real time?
after a specific deadline, the results are not nuseful anymore
Was ist die Soft real time?
the usefulness of the results decrease after a specific deadline
OR:
Statistically suffienciently high percentage is availabel before the deadline
How many processes and resources are needed for Deadlock?
- 2 Processes
- 2 Resources
Example: Task A, B and Resources R1, R2 A occupies R1 B occupies R2 B requires R1 A requires R2 --> Deadlock
How many processes and resources are needed for Priority Inversion?
- 3 Processes
- 1 Recource
Example: Tasks A, B, C and Recource R1 Prio(A) > Prio(B) > Prio(C) C occupies R1 A starts, (pre-empting C) A requires R1 B starts B terminates (problem) C continues, terminates A occupies R1, terminates
How to fulfill Real-Time requirements?
► Polling
► Main loop and interrupts
► Real-time operating system
Definition Schedule:
Mapping of an execution sequence to a task system
Definition Feasibility:
A schedule is feasible, if no deadline is violated.
Definition Schedulability:
A task system is schedulable, if a feasible schedule exists.
What is behind the “earliest deadline first scheduling”?
Execute the task with smallest D first.
How can priority inversion be prevented?
- Priority Inheritance Protocol
- Priority Ceiling Protocol
Priority Inheritance Protocol:
► Task A (high priority) needs a resource R
► Task B (low priority) currently holds R
► As soon as A starts waiting for R
▪ B inherits A’s priority
▪ B cannot be preempted by an intermediate priority
▪ No priority inversion possible
► Complex:
▪ Current holder of a resource must be determined
▪ Holder’s priority must be changeable while running
Priority Ceiling Protocol
► Ceiling priorities are assigned to the resources
► A resources priority is the highest priority of all tasks that may use it
► A task is upgraded to the resource’s priority as soon
as the task holds it.
► Can be calculated during design time
► Not optimal: T2 is upgraded to R1’s priority even if T4 is inactive