The contributions of the disser- tation include: i we developed several advanced power-aware scheduling al- gorithms for hard real-time systems with emphasis on reducing both dynamic an
Computing The LST for The EDF-Based JobSet
As related work, Chetto et al [31] introduced a strategy to compute the processor idle times for tasks scheduled with so-called earliest deadline as late as possible (EDL) scheme Note that EDL is different from the job delay strategy here EDL requires that the priorities of the jobs be ordered by their deadlines and executed as late as possible, even when the processor is not idle, which may introduce un- desirable extra idle intervals Also their techniques focus on computing the total amount of idle time (not necessary continuous) and cannot be readily applied to determine the latest starting time for a job set Mochocki et al.[108] introduced a method that can be applied to find out the longest time that the future jobs can be delayed if the job set is scheduled according to EDF Their method is based on the following lemma
Lemma 1 [108] Let job set (7) be executed with a constant speed s* Then,
JprEhp( Ji) where hp(J;) is the jobs with the same or higher priorities than that of J; Furthermore,
The rationale behind Lemma 1 is that if the accumulated workload from a job J; and all the higher priority jobs can be finished before d;, the deadline of J; will be satisfied In addition, the minimal latest starting time of all the jobs can cer- tainly guarantee all the deadlines However, a straightforward implementation of Lemma 1 has computational complexity as O(N’), where N is the total number of jobs For a periodic job set, N is the number of all the jobs within the least common multiple (LCM) of the periods It can be considerably large, especially when the pe- riods of the tasks are co-prime, and cannot be applied on-line or can be extremely costly for large periodic task sets
Recall that, in Algorithm 1, the longest time that a job set can be delayed is bounded by the delay bound (Ts) It is therefore desirable to identify the LST for the whole job set by simply taking the minimum of the LSTs for the jobs arriving before Tg Unfortunately, this may not guarantee the deadlines for all jobs Note that equation (2.9) guarantees that the deadline of job J, can be met by requiring
Jn, be finished at its deadline However, even though J, can meet its deadline, other lower priority jobs may miss their deadlines if J,, completes exactly at d; For example, as seen in Figure 2.2(b), J3 has deadline of dj = 23 However, assuming
Jz to finish at t = 23 will block the execution of the lower priority job, i.e., Je, during the interval [22, 23] and cause it to miss its deadline This indicates that to guarantee the deadlines for the lower priority jobs, a higher priority job may need to finish much earlier than its deadline Specifically, we introduce a new concept, i.e., the effective deadline, to capture this characteristic
Definition 2 The effective deadline for J, € J is the latest time t such that if J, and all the higher priority jobs arriving before t are completes by t, J, and all the lower priority jobs can meet their deadlines
The LST (Last Start Time) of a set of jobs can be calculated by examining the maximal delays of the jobs that arrive earlier than a specified target time (Tg) This is because the LST effectively determines the scheduling constraints for the entire job set By identifying the latest possible start times for jobs based on known effective deadlines, we can establish a cohesive schedule that meets the overall project requirements.
Theorem 1 Let Tz and s;,, are the delay bound and the threshold speed, respectively The LST for J can be computed as follows:
T us(Z) = min(Ta, mớn (đ; = d; — ằ (Se) — (2.10) 2
Jpehp( Ji) where J, consists of jobs with arrival times earlier than Tp, s; = max(Sz,, $;), and s, and d* are required processor speed and effective deadline for job Jn, respectively
Proof: Let J, € J, and tra(J,) =dụT— DD = (2.11)
Since Trs(Z7) 3 trs(dJ„), therefore J, and all the jobs with priorities lower than that of J, can meet their deadline For any job J; with priority higher than that of Jn, we consider two cases: (a) r; < Tp, (b) r; > Tg When r; < Tz, similarly as Jp, its schedulability is guaranteed This also guarantees the schedulability for the jobs arriving later than T; with priorities higher than that of J, but lower than that of J; Finally, for jobs arriving later than Tg with priorities higher than that of any job in J,, they must be schedulable since delaying the job set till trs(Jn) < Tp has no impact to their schedulability at all L1
The problem is then transformed to how to determine the effective deadlines for the jobs arriving before the delay bound Given the fact that, the DVS voltage schedule can guarantee the schedulability of all the task deadlines [161], one intu- itive way is thus to use the completion time of a job based on the corresponding voltage schedule as its effective deadline A job completes at the time defined in this way will ensure that it will not cause any lower priority job to miss its dead- line Accordingly, Figure 2.2(c) shows the effective deadlines for the jobs arriving earlier than 7b, i.e., J1, J3, J4 and the result LST for the job set It can be readily verified that all the jobs can meet their deadlines
However, since the jobs with required speeds less than s,, are executed with
To accurately estimate effective deadlines, a heuristic strategy considers speed requirements and threshold speeds This approach ensures that intervals are merged effectively, avoiding small inter-intervals that do not merge effectively The strategy aims to merge idle intervals into a single interval, as illustrated in Figure 2.2(d), rather than having multiple idle intervals like in Figure 2.2(c).
To identify the effective deadline for a job, Algorithm 2 starts from its original deadline and iteratively restrain its value based on the schedulability requirements from other low priority jobs To demonstrate the effectiveness of Algorithm 2, we have the following Lemma
Lemma 2 If J, € J, completes no later than d*, which is computed with Algorithm 2,
Algorithm 2 Compute the effective deadline of a job 1: Input: Jn, 3,1 = 1,2, ,N according to the optimal DVS voltage sched- ule [161], Ts, and s¢p;
2: Output: The estimated effective deadline of J,,, i.e.,d},
3: Let st = max(Sq, Sin), k = 1, , N;
5: Let ƒ„,k = 1, , N be the completion time of Jy according to the DVS voltage schedule;
9: d;, = min(d;, max(fn + bi, ryt ỗ;));
11: end for then J,, and all the lower priority jobs can meet their deadlines
Proof: Let J, € J, and a low priority job J; € 7,7; > Tn, di > dn We want to prove that J; will not miss its deadline if J,, and all the higher priority jobs arriving before d* complete no later than d*, which is computed from Algorithm 2 (Note that the schedulability of J; € 7,7: < Tn, d; > d, is unchanged no matter how the execution of J, is moved around within [r,,, d,].) We have two possibilities, ie., s, < s;, and
Sn > s; We consider each case separately and show that it is impossible for J; to miss its deadline in each case ® S„ < Sj
According to line 9 in Algorithm 2, if we ignore the term ô;, the đ; can be either the completion time of J,, according to the DVS schedule, or the ar- rival time of J;, or even smaller Note that using the completion time of J, according to the DVS schedule can ensure J; is still schedulable On the other hand, if we assume there is no other job having deadline within [d,,, d;], then requiring J,, and all the higher priority jobs arriving before the arrival of J; can certainly ensure the schedulability of J, If there are indeed jobs having deadlines with [đ„, đ,], the effective deadline computed through the loop in
Algorithm 2 (line 7-11) will be the earliest arrival time of such jobs As Jn and all the higher priority jobs are required to finish before the result effec- tive deadline, they will not increase the preemption for the job arriving later Therefore, J; should still be schedulable
For the slack time 6; (defined in line 4) in line 9, it is generated when a higher speed than s; has to be used to execute J; This slack can be exploited to further delay the effective deadline for J, since it has a higher priority than
J; Therefore, the effective deadline computed in Algorithm 2 will ensure the schedulability of J;
Computing The LST for The FP-Based Job Set
So far, we are assuming that the real-time jobs are scheduled by the EDF scheme
In what follows, we study the real-time systems scheduled based on FP scheme, such as rate monotonic scheduling (RMS) [100] policy Because of their high pre- dictability, low overhead, and ease of implementation, FP schemes are among the most popular in real-time embedded applications [101]
The general strategy to control the leakage power and save the overall power consumption has been stated in section 2.4 The problem is, however, to compute the latest starting time for a job set when it is scheduled by an FP scheme Note that accumulating the workload from all the higher priority jobs in equation (2.8)
J3 [A Soy cot bE Ibo d,, £5 T0 13 death 3 | a ome fey TT] 1 tdo 3 th kÌs 4 2b ab
Figure 2.3: (a) A job set with four jobs scheduled with FP, and the LST is computed as 3 according to Lemma 1(s* = 0.5) (b) Delay the job set until t = 6 and every job can meet its deadline (c) Js-scheduling points (marked by “x”) (d) Delay execution of the job set till t = 8 and J, misses its deadline is equivalent to assuming that all the higher priority jobs have to finish before the deadline of current job This is true for job sets scheduled according to EDF, but is not necessarily true for FP job sets since higher priority jobs in a FP job set can arrive much later than the deadline of the current job While using equation (2.9) to compute the starting time for an FP job set can still guarantee the feasibility of this job set, the feasiblestarting time for the FP job set can be far from the latest For example, in Figure 2.3(a), according to equation(2.8) and (2.9), assuming s* = 0.5, we have Ist(J,) = 13, Ist(J2) = 14, lst(J3) = 3, lst(Js) = 6, and therefore, LST(7) = 3 However, as shown in Figure 2.3(b), if the job set is delayed to t = 6, even though all the jobs can meet their deadlines, not all the short idle intervals can be effectively merged as shown in Figure 2.3(a) In what follows, we present a more effective technique to accurately identify the latest starting point for FP job sets Before we explain our strategy in detail, we want to introduce the some terminology
Recall that the jobs with required speeds higher than s,, should run at their re- quired speeds in order to guarantee deadlines These jobs cannot be delayed at all and must be executed within the intervals in the DVS voltage schedule For ease of computation, we “shrink” the intervals during which jobs with a required speed higher than s,, are executed This includes removing all jobs in these intervals, and also adjusting the deadlines and arrival times of the rest of the jobs Specifically, we have the following definition
Definition 3 (Adjusted job set) A job set is called an adjusted job set of 7, if all jobs in J having a speed requirement higher than s,, (as well as the intervals containing these jobs) are removed, and the arrival times and deadlines of the rest of the jobs are adjusted correspondingly
As explained before, a job set is delayed only when the processor is idle Therefore, when identifying the delay that a job can tolerate, we are more interested in the coming job set when the processor is idle
Definition 4 (Reduced job set) An adjusted job set is called a J,-reduced job set if every job J; in the set satisfies r; > Tn
Also, the arrival times and deadlines for the jobs are important factors in making scheduling decision, and usually referred as the scheduling points Specifically, we have the following definition
Definition 5 (Scheduling point) Time t is called a J,-scheduling point if t = d,, ort r,t