Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.
-
Upload
sophie-bell -
Category
Documents
-
view
228 -
download
1
Transcript of Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.
![Page 1: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/1.jpg)
Approximation Algorithms for Task Allocation with QoS and Energy Considerations
Bader N. Alahmad
![Page 2: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/2.jpg)
2
Problems we consider
Task allocation such that QoS score achieved & number of processors minimized
a) Variation 1: number of service classes (QoS levels) fixed, built into platform
b) Variation 2 : Minimum service class should be maintained, arbitrary number of service classes
Task Allocation such that QoS score achieved & Overall Energy minimized
![Page 3: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/3.jpg)
3
Problems are NP-Hard
Reduction from Bin-Packing and PARTITION Bin-Packing (decision): STRONGLY NP-
Complete PARTITION (decision): NP-Complete in the
ordinary (weak) sense
![Page 4: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/4.jpg)
4
Approximability Everywhere !
(Problem Instance)
Algorithm
(error Factor)ππΌ
|π£πππ’π (π )βπππ ( πΌ )|max(π£πππ’π (π ) ,πππ ( πΌ ))
β€π
π (solution)
π¨
PTAS: running time poly in
FPTAS: running time poly in
![Page 5: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/5.jpg)
5
Quality of Service (QoS)
tolerable error minimum precision required
Service providerClient
Service Level Agreement
Service Level Agreement
The service will provide a response of within 300ms for 99.9% of its request for a peak
client load of 500 requests per second
![Page 6: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/6.jpg)
6
QoS example: Search Engines
βWoongki Baek and Trishul M. Chilimbi. 2010. Green: a framework for supporting energy-conscious programming using controlled approximation. In Proceedings of the 2010 ACM SIGPLAN conference on Programming language design and implementation (PLDI '10).β
Accept user querySearch index for matching docsRank docs, return the top N docs in ranked order
QoS Loss metric: % of queries that return
Different set of top N docs
Same set of top N docs in different
RANK order
Tradeoff (Approximation)
Execute less cycles Ranking for faster response
![Page 7: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/7.jpg)
9
Quality of Service
A task comes equipped with service class specifications (utilization, reward)
per processor
π β€π’π‘ππππ§ππ‘πππβ€1πβ€πππ€πππ β€1
1/4
1
![Page 8: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/8.jpg)
10
Task Allocation with Service Classes (TASC)
Tasks associated with resource function.
Task1
Task3
Task2
1Identical processors of unit capacity
General Solution Method: Memoization
![Page 9: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/9.jpg)
11
Fixed Service Classes
Variation 1: Service classes are fixed
(π’2 ,π2)
(π’8 ,π8) (π’5 ,π5)(π’πβ 1 ,ππβ 1)
(ππ ,ππ)(π’6 ,π6)(π’3 ,π3)(π’4 ,π4)
(π’1 ,π1)
(π’7 ,π7)Service classes (pool) predetermined by provider (platform)
Task1Task3
Task2
![Page 10: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/10.jpg)
12
FSC β Assign Tasks to Service Classes
For each assignment of the form , verify that there is a set of tasks such that
There are such assignments (bins and balls)Since is fixed is poly in
![Page 11: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/11.jpg)
13
Verify Assignment β Max Flow in a bipartite graph for each assignment
Example assignment
![Page 12: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/12.jpg)
14
Minimum Makespan & Bin-Packing are DUAL problems
There exists a packing of items with execution times to bins with capacity t each iff there exists a schedule with makespan at
most t.
ππ
ππ
ππππ
ππ
ππ
t
Scheduling Makespan = t
ππππππ
ππππ
ππt
Bin Packing: bin capacity = t
ππ
π
ππ
π/t
ππ
π
1
Bin Packing: bin capacity = 1
Normalize
π6/π‘
π5/π‘
![Page 13: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/13.jpg)
15
Find minimum number of bins for each assignment
Apply bin-packing PTAS for each assignment
n times. Why?
[bin packing: de la Vega and Lueker 81] [minimum makespan: Hochbaum and Shmoys 88]
Result
PTAS for TASC !
![Page 14: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/14.jpg)
16
Minimum Service Class (MSC)
Variation 2: Relax fixed service classes
But: require minimum service class to be maintained. Why?
What is the maximum number of service classes ? Are they bounded?
Solution: Quantize !
Why??
![Page 15: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/15.jpg)
17
Quantize Service Classes - qMSC
(π’ ,π)β(π+πΌπ2 ,π+π½π2)
Setting will do the trick !
ππ‘πππ π‘ β1
π4β π πππ£πππππππ π ππ !
Catch ! Processors may need to have capacity (1+π )
ResultsPTAS for qMSC
![Page 16: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/16.jpg)
18
Incorporate Energy Expenditure and platform heterogeneity !
![Page 17: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/17.jpg)
19
Platform
K heterogeneous processor types: AMD, INTEL , β¦
Processor1
Processor2
K heterogeneous physical processor types
At most S speeds per processorLogical Processors
π 1,1 π 1,2
π 2,1 π 1,2 π 2,3
Distinct physical processors have different speed levels
Processor speeds dynamically adjustable
![Page 18: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/18.jpg)
20
Platform - Continued
Platform consists of M processor βslotsβ to be filled Need to build platform with the available processors.
M Logical processors (physical processor/speed) pairs
possible platform configurations
![Page 19: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/19.jpg)
21
Tasks look like this
Task1
ππππππ π ππ π‘π¦ππ1
Task2
ππππππ π ππ π‘π¦ππ2
ππππππ π ππ π‘π¦ππ3
ππππππ π ππ π‘π¦ππ1
![Page 20: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/20.jpg)
22
Prior attempts related to our work
Closest to our efforts:
C.-Y. Yang, J.-J. Chen, T.-W. Kuo, and L. Thiele. An approximation scheme for energy-efficient scheduling of real-time tasks in heterogeneous multiprocessor systems. In DATE, pages 694β699, 2009
Energy Model is weak utilization scales linearly with speed Cannot capture holistic energy expenditure (devices) Interpolates speed ! Might get very inaccurate
![Page 21: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/21.jpg)
23
Linear Scaling of Utilization: I/O bound Tasks
Our work
Relax all previous assumptions
Completely discrete, arbitrarily structured setting
f
t (cpu)
2f
t/2 (I/O)t/2 (cpu)
t/2
t/2t/4
Task1
Task2
![Page 22: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/22.jpg)
26
Energy Model
Dynamic power consumption per (processor/speed) Static power consumption per physical processor
(independent of speed) Idle power: when processor in dormant mode
Service Level AgreementThe service will provide a response of within 300ms for 99.9% of its
request for a peak client load of 500 requests per second
![Page 23: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/23.jpg)
28
Objectives
Overall Energy Expenditure minimized
Quality of Service Score achieved
![Page 24: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/24.jpg)
29
Offline Dynamic Program
Enumerate platform configurations Iterate through tasks
Assign tasks to processors Build state space per task from states of previous task The solution is the state of last task
![Page 25: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/25.jpg)
30
State space
Each task maintains a set of states State is a partial feasible schedule up to current
task across all processors.
T1T4T2
T3 T5T8
T6
T7
T1T4T2
T3 T5
T8
T6
T7
T8
π π1 1
![Page 26: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/26.jpg)
31
Trimming the state space
How to bring down the size ofthe state space to polynomial, while controlling
the error propagation ?
![Page 27: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/27.jpg)
32
Measure of nearness: Delta-close states
1ΞπΈ πβ
ππβ€πΈπ
π π
β€ Ξ πΈ πβππ
πππππ‘π hπ πππ π Ξππππππππ¦β(1+ π2π )
![Page 28: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/28.jpg)
33
State Space partitioned into -BoxesΞ
ππ ,16
ππ ,11ππ ,10
ππ ,5
ππ ,6ππ ,15
ππ ,9ππ ,4ππ ,8ππ ,13
ππ ,17
ππ ,18
ππ ,1ππ ,22ππ ,20
ππ ,19
ππ ,21
ππ ,12ππ ,2
ππ ,7ππ ,3ππ ,13ππ ,14
![Page 29: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/29.jpg)
34
Choose the dominating state in each -boxΞ
Dominating: has maximum Reward value
![Page 30: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/30.jpg)
35
Results
Quality of SolutionπΈπππππ¦ β€ (1+π )πππ
Running Time
![Page 31: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/31.jpg)
36
Approximation Schemes vs. Heuristics
Approximation Algorithms
Guaranteed worst case bounds on quality of solution
Running time might be too large to be used in practice
Heuristics Stochastic Local Search,
greedy, β¦ Hard to design βgoodβ
ones Hard to obtain
guarantees on quality of returned solution
Might converge quickly, depending on input
![Page 32: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/32.jpg)
38
Heuristics were hard to analyze
Compute Energy Per Processor for each task
Pack the task with the smallest
(ENERGY Per Processor / Reward per same processor ) first
if it fits that processor
Go Greedy !
![Page 33: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/33.jpg)
39
Was it Fun?
Thank you
![Page 34: Approximation Algorithms for Task Allocation with QoS and Energy Considerations Bader N. Alahmad.](https://reader035.fdocuments.net/reader035/viewer/2022062407/56649ea35503460f94ba759b/html5/thumbnails/34.jpg)
40
Mathematical Program