11.07.2015 Views

Chapter 2 Real-Time Systems Concepts Foreground/Background ...

Chapter 2 Real-Time Systems Concepts Foreground/Background ...

Chapter 2 Real-Time Systems Concepts Foreground/Background ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Assigning Task Priorities• Rate Monotonic Scheduling (RMS)– The highest rate of execution are given the highest priority• RMS makes a number of assumptions:– All tasks are periodic (they occur at regular intervals).– Tasks do not synchronize with one another, share resources, orexchange data.– The CPU must always execute the highest priority task that is ready torun. In other words, preemptive scheduling must be used.• If meet the following inequality equation, all task HARD real-timedeadlines will be met∑iETii⎛≤ n × ⎜2⎝1n⎟ ⎞−1⎠CPU utilization of all timecriticaltasks should be less than70%Other 30% can be used by nontimecritical tasks2-23Mutual Exclusion• Multiple tasks access same area (critical section) mustensure that each task has exclusive access to the data toavoid contention and data corruption• The method of exclusive access– Disabling interrupts– Performing test-and-set operations– Disabling scheduling– Using semaphores2-24

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!