SLIDE 12 CPSC-663: Real-Time Systems Aperiodic and Sporadic Jobs 12
Simple Sporadic Server
- Consumpt ion Rules: The ser ver ’s execut ion budget is consumed at t he r at e of one
at any t ime t af t er t r unt il t he budget is exhaust ed whenever t he f ollowing t wo condit ions are t rue. When t hese condit ions are not t rue, t he ser ver holds it s budget :
– C1: The server is execut ing. – C2: The server has execut ed since t r and is suspended at t he t ime t , and TH is idle.
The execut ion budget is set t o es and t he cur r ent t ime t r is recorded init ially when t he syst em begins execut ion and each t ime when t he budget is replenished.
The next budget replenishment t ime is det ermined at t ime t f when t he ser ver f ir st begins t o execut e since t r. At t ime t f , t e is set t o t he lat est t ime inst ant at which a lower -pr ior it y t ask execut es in (t r, t f ), and set t o t r if TH is busy t hr oughout t his int er val. The next r eplenishment t ime is set at t e + ps.
The next r eplenishment occur s at t he next r eplenishment t ime, except under t he f ollowing condit ions when t he r eplenishment may be done sooner
– (a) I f t he next replenishment t ime t e + ps is earlier t han t f , t he budget is replenished as soon as it is exhaust ed. – (b) The budget is replenished at t ime t whenever t he syst em T has been idle bef ore t and a periodic j ob is released at t .
Simple Sporadic Server: Example
A1(r=3, e=1) A2(r=7, e=2) A3(r=15.5, e=2)
Budget 1.5 1.0 0.5 T1 T2 TS T3
T1 = (3, 0.5) T2 = (4, 1.0) T3 = (19, 4.5) TS = (5, 1.5)