Presentation is loading. Please wait.

Presentation is loading. Please wait.

System-Wide Energy Minimization for Real-Time Tasks: Lower Bound and Approximation Xiliang Zhong and Cheng-Zhong Xu Dept. of Electrical & Computer Engg.

Similar presentations


Presentation on theme: "System-Wide Energy Minimization for Real-Time Tasks: Lower Bound and Approximation Xiliang Zhong and Cheng-Zhong Xu Dept. of Electrical & Computer Engg."— Presentation transcript:

1 System-Wide Energy Minimization for Real-Time Tasks: Lower Bound and Approximation Xiliang Zhong and Cheng-Zhong Xu Dept. of Electrical & Computer Engg. Wayne State University Detroit, Michigan http://www.cic.eng.wayne.edu

2 2 Outline Introduction Processor and system energy model Related Work System-Wide Energy Optimization for periodic tasks The optimal algorithm A fully polynomial time approximation scheme Performance Evaluation System-Wide Energy Optimization for sporadic Tasks Solution and evaluation Conclusions

3 3 Introduction Mobile/Embedded devices are power critical, with limited battery capacity Software assisted power management Dynamic power management (DPM) Resource shutdown after a timeout Dynamic voltage/frequency scaling (DVS) Processing speed designed for peak performance Slowdown the processor voltage / speed when not fully utilized

4 4 Dynamic voltage scaling (DVS) The dynamic CPU power is, P ∝ v 2 f Reducing v also reduce the maximum processors frequency Approximately, energy per cycle ∝ f 2 Processor slowdown leads to super-linear energy savings, while linear execution time increase Energy per cycle of PXA processor

5 5 System-Wide Energy Processor also has leakage power Applications may use other components such as memory and peripheral devices Can be in active, standby, sleep, and shutdown states System-wide energy consumed in running a task CPU, resource standby and active energy Lowering CPU frequency can increase overall energy expenditure due to prolonged resource standby time of other components

6 6 System-Wide Energy (cont.) critical speed, the speed with minimum energy per cycle Not energy efficient using lower speed Execute a task at speed no lower than its critical speed, then put the devices into low power state A combined use of slowdown and shutdown Energy per cycle of PXA processor with different standby power

7 7 Related Work CPU energy minimization for periodic tasks: Heuristics [Mejia-Alvarez ’ 04], approximations [Chen and Kuo ’ 05] Few studies on system-wide energy minimization Applications w/o deadlines Subject to a performance loss [Choi et al. ’ 04] Real-time periodic tasks on CPU w/ continuous speed levels Heuristics [Zhuo and Chakrabarti ’ 05] Real-time periodic tasks on CPU w/ discrete speed levels Heuristics [Jejurikar and Gupta ’ 04] This work Pseudo-polynomial algorithm for optimal solutions and polynomial approximated schemes Applicable to both offline periodic tasks and online sporadic tasks in processors with practical discrete levels

8 8 System-wide energy optimization Periodic Tasks (Offline) : worst case execution time under max speed : task period and deadline : normalized speed of task Sporadic Tasks (Online) Task releases have irregular intervals Online scheduling based on uncompleted tasks, no assumption about future task releases The objective is to minimize overall energy consumption including CPU and all other system components while meeting deadline constraints of all the tasks

9 9 Energy Minimization for Periodic Tasks Minimization of energy consumption for n periodic tasks in a hyper-period, Feasible constraint under EDF Boundary constraint Practical processors with discrete speed levels The minimization is an NP-hard Multiple Choice KnapSack (MCKP) problem There exist pseudo-polynomial solutions to MCKP with integer coefficients, not applicable in this problem

10 10 An Example Basic idea: first solve subprobs with fewer #tasks A system with an PXA processor with 5 normalized speed [0.15 0.4 0.6 0.8 1] System with memory, flash, and WNIC An example real-time workload w/ 4 periodic tasks TaskExecution time PeriodUtilizationRequired resources Critical speed 16.4160.4cpu0.4 21.6200.08cpu,memory0.4 31.2120.1cpu,mem,flash0.6 41.0890.12cpu,mem, WNIC0.6

11 11 Solution to task 1 Task 1, execution time 6.4; deadline 16; utilization 0.4 Branch on four normalized speeds [0.4 0.6 0.8 1] f: pruned by feasibility condtion e: pruned by energy condition (utilization, energy) State pruning Feasibility condition: The 1 st node at speed 0.4 removed with utilization already 1 Energy condition Task 1 at the smallest speed (2 nd, 0.6); tasks 2-4 at the max. Total Energy=7.6 (upper bound) Task 1 at 3 rd or 4 th speed (0.8 or 1); tasks 2-4 at the min. The required energy exceeds 7.6. The two states can be removed

12 12 Solution to the first three tasks pairs of (utilization, energy) f: pruned by feasibility condtion e: pruned by energy condition d: pruned by dominance Dominance condition The states (0.867, 9.107) and (0.87, 9.4) of task 3 First one leads to smaller utilization Any feasible schedule by the second can also be satisfied by the first First one uses less energy; the second can be removed

13 (utilization, energy) f: pruned by feasibility condtion e: pruned by energy condition d: pruned by dominance optimal state Maximum state number reduced to 6/4*4*3*3 = 0.4 %

14 14 A fully polynomial approximation scheme (FPTAS) State # is pseudo-polynomial in task number. can be reduced by providing approximated solutions Approximated with worst case perf. guarantee An algorithm is said to be an approximation scheme if for a given in (0,1), we have A more desirable approximation scheme (FPTAS) has a polynomial running time in both the number of tasks and the performance ratio

15 15 A fully polynomial approximation scheme (cont.) Divide the energy values into a number of groups each of size r, Each value scaled and rounded to Energy values in the same group are treated equally Find the group size r, subject to a given performance bound Energy value of each task introduces an error no larger than group size r Accumulated errors of n tasks no larger than n*r A lower bound of E* is when all tasks run at their critical speeds (E min ), i.e., E*≥ E min Solving derives group size r

16 16 Performance Evaluation Simulation Settings A system with an PXA processor memory: standby power 0.2W, standby time 20%~60% of task execution flash drive: 0.4W and 10%~25% wireless interface: 1W and 5%~20% Periodic Tasks Randomly generated deadlines w/ utilization from 0.1~1 Each task randomly chooses a subset of resources Algorithms implemented CPU-DVS, speed control for CPU energy consumption CS-DVS, a heuristic algorithm for system-wide energy savings [Jejurikar and Gupta ISLPED2004], OPT-P, the proposed optimal solution Approximated scheme with perf. bounds 0.01, 0.1, 0.5

17 17 Performance Evaluation (Periodic tasks) Energy consumption up to 16% more efficient than CS-DVS 16% 23% 8% Proposed algorithms 23% less energy than CPU-only solutions Approximation algorithms effectively bound the performance errors

18 18 Energy Minimization for Sporadic Tasks Online energy minimization for all uncompleted tasks n feasible constraints under EDF boundary constraint On a processor with discrete speed levels Prove the problem is an instance of Multi- dimensional MCKP (NP-hard in the strong sense, any optimal solution has exponential running time)

19 19 Consider three tasks released at time 0 with deadlines 3, 5, 7 Feasibility of a task (e.g. J 2 ) is not affected by tasks finished later (tasks in a non-decreasing order of deadlines) Satisfy one constraint (e.g. J 3 ) at each iteration Can be solved by a pseudo-polynomial algorithm for the optimal solution and an approximation scheme (FPTAS) Sporadic Tasks (cont.)

20 20 Performance Evaluation (Sporadic tasks) Experimental Settings Varied number of tasks Task inter-release times generated by an exponential dist. Algorithms implemented TV-DVS, adaptive speed scaling for CPU energy consumption on processors w/ continuous levels [Zhong and Xu RTSS2005] DVSST, CPU energy consumption with only frequency scaling available (continuous levels) [Qadi et al. RTSS2003] OPT-S, the proposed optimal solution 0.1, 0.5-approximation, approximated solutions with different performance settings

21 21 Energy consumption (Sporadic tasks) Large task number: 23% more efficient 56% 23% Small task number: Energy consumption up to 56% more efficient than TVDVS and DVSST

22 22 Conclusion System-wide energy minimization for periodic tasks pseudo-polynomial algorithm for the optimal solution approximated solution in moderate running time with bounded performance degradation (FPTAS) Minimization for online sporadic tasks Pseudo-polynomial algorithm and an FPTAS by exploiting inherent properties of online task scheduling On-going work Implementation of the policies in an embedded system with PXA270 processor Energy/Time overhead voltage and speed switches; overhead in putting a resource into low power state

23 23 Thank you! System-Wide Energy Minimization for Real-Time Tasks: Lower Bound and Approximation

24 24 Algorithm running time Running time measured in a Pentium 4 machine with 2 GHz processor OPT-P has a higher complexity than CS- DVS Below 90 ms for systems with up to 50 tasks All approximation algorithms require no more than 0.4 s to finish Algorithm running time for schedules in a 10-minutes run OPT-S has higher running time, but <1% task execution time Comparable time for approximation algorithms with TV-DVS


Download ppt "System-Wide Energy Minimization for Real-Time Tasks: Lower Bound and Approximation Xiliang Zhong and Cheng-Zhong Xu Dept. of Electrical & Computer Engg."

Similar presentations


Ads by Google