SlideShare una empresa de Scribd logo
1 de 6
A Partitioning Algorithm
• Let Ti be a task in T such that Pi ≤ Pj for all tasks Ti in T
• S1 = {Ti}, T = T - {Ti}, For i=2..g, Si = φ
• For i=2..g
• For every task Tl in T
• max[Tl] = gcd(S1 ∪ {Tl}) – Σ w over all Tk in (S1 ∪ {Tl})
• For j=2..i-1
– max[Tl] = max{max[Tl] , gcd(Sj ∪ {Tl}) – Σ w over all Tk in (Sj ∪ {Tl})}
• Let Tl be a task in T such that max[Tl] ≤ max[Tk] for every Tk in T
• Si = {Tl}, T = T - {Tl}
• For every Ti in T
• For j=1..g
• Slack[Sj] = gcd(Sj ∪ {Tl}) – Σ w over all Tk in (Sj ∪ {Tl})
• Add Ti to the subset Sj for which Slack[Sj] is maximum
Scheduling for Horizontal
Striping
• Assume wi stripe units for supervideo Vi is stored on
disk 0
• The Problem
• Schedule non-preemptible tasks T1…Tr with periods P1…Pr
on q processors; each task Ti has wi subtasks, with
compute time of 1; interval between consecutive subtasks
is m
• If a task has P=4, w=3 and m=6 is it schedulable?
• Condition for subtasks of a single task Ti to be
schedulable on a single processor:
• For all 1 ≤ j, k ≤ wi, j ≠ k, ((j-1).m) mod Pi ≠ ((k-1).m) mod Pi
• Why?
• What is the corresponding algorithm to test
Testing for Schedulability
• Procedure is_schedulable({T1..Tn},m)
• Let g=gcd(P1..Pn)
• Take g time units 0..(g-1) that are not assigned
• Sort the tasks in decreasing order of wi
• For each task Tiin the sorted order
• j=0
• while (j < g)
– if for k=0…(wi – 1), time unit (j+k.m) mod g is free
• for k=0…(wi – 1), assign time unit (j+k.m) mod g to Ti
• exit while
– else j=j+1
• If j=g return FAIL
• return {(Ti, x): 1 ≤ i ≤ n and the first subtask of Tiis
Scheduling for Horizontal
Striping
• Algorithm schedule_tasks_2 [Ozden 97]
• R=is_schedulable({T1…Tn},m)
• If R=FAIL
• Let gcd(P1...Pn,)=g
• If g=1, return FAIL
• Let T1…Tn be tasks with periods P1/g…Pn/g and w1…wn
subtasks.
• Partition the tasks into g subsets S1…Sg.
• For i=1..g, let Ri= schedule_tasks_2(Si,m/g)
• If for any i Ri= FAIL, return FAIL, else return
{(Ti, x.g+(j-1)): 1 ≤ j ≤ g and (Ti,x) ∈ Rj}
• Return R
Example
• Tasks T1, T2, T3 with periods 6,8,8 have
two subtasks each. The interval between
them is 4.
• Try the algorithm.
Example
• Tasks T1, T2, T3 with periods 6,8,8 have
two subtasks each. The interval between
them is 4.
• Try the algorithm.

Más contenido relacionado

La actualidad más candente

Ee2365 nol part 2
Ee2365 nol part 2Ee2365 nol part 2
Ee2365 nol part 2Arun Kumaar
 
Control system concepts by using matlab
Control system concepts by using matlabControl system concepts by using matlab
Control system concepts by using matlabCharltonInao1
 
Test s velocity_15_5_4
Test s velocity_15_5_4Test s velocity_15_5_4
Test s velocity_15_5_4Kunihiko Saito
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integrationtutorcircle1
 
Application+of+Integration
Application+of+IntegrationApplication+of+Integration
Application+of+Integrationtutorcircle1
 

La actualidad más candente (20)

Ece4510 notes09
Ece4510 notes09Ece4510 notes09
Ece4510 notes09
 
Ee2365 nol part 2
Ee2365 nol part 2Ee2365 nol part 2
Ee2365 nol part 2
 
bode_plot By DEV
 bode_plot By DEV bode_plot By DEV
bode_plot By DEV
 
Control system concepts by using matlab
Control system concepts by using matlabControl system concepts by using matlab
Control system concepts by using matlab
 
Test s velocity_15_5_4
Test s velocity_15_5_4Test s velocity_15_5_4
Test s velocity_15_5_4
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application of Integration
Application of IntegrationApplication of Integration
Application of Integration
 
Application+of+Integration
Application+of+IntegrationApplication+of+Integration
Application+of+Integration
 

Similar a Mmclass9

統計的学習の基礎 4章 前半
統計的学習の基礎 4章 前半統計的学習の基礎 4章 前半
統計的学習の基礎 4章 前半Ken'ichi Matsui
 
Ct signal operations
Ct signal operationsCt signal operations
Ct signal operationsmihir jain
 
SIGNAL OPERATIONS
SIGNAL OPERATIONSSIGNAL OPERATIONS
SIGNAL OPERATIONSmihir jain
 
1_Asymptotic_Notation_pptx.pptx
1_Asymptotic_Notation_pptx.pptx1_Asymptotic_Notation_pptx.pptx
1_Asymptotic_Notation_pptx.pptxpallavidhade2
 
Ray : modeling dynamic systems
Ray : modeling dynamic systemsRay : modeling dynamic systems
Ray : modeling dynamic systemsHouw Liong The
 
Recurrence Relation for Achromatic Number of Line Graph of Graph
Recurrence Relation for Achromatic Number of Line Graph of GraphRecurrence Relation for Achromatic Number of Line Graph of Graph
Recurrence Relation for Achromatic Number of Line Graph of GraphIRJET Journal
 
Quantum factorization.pdf
Quantum factorization.pdfQuantum factorization.pdf
Quantum factorization.pdfssuser8b461f
 
Csm chapters12
Csm chapters12Csm chapters12
Csm chapters12Pamela Paz
 
270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx
270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx
270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docxeugeniadean34240
 
Algorithms - Rocksolid Tour 2013
Algorithms  - Rocksolid Tour 2013Algorithms  - Rocksolid Tour 2013
Algorithms - Rocksolid Tour 2013Gary Short
 
Notes.on.popularity.versus.similarity.model
Notes.on.popularity.versus.similarity.modelNotes.on.popularity.versus.similarity.model
Notes.on.popularity.versus.similarity.modelsun peiyuan
 

Similar a Mmclass9 (20)

統計的学習の基礎 4章 前半
統計的学習の基礎 4章 前半統計的学習の基礎 4章 前半
統計的学習の基礎 4章 前半
 
Ct signal operations
Ct signal operationsCt signal operations
Ct signal operations
 
SIGNAL OPERATIONS
SIGNAL OPERATIONSSIGNAL OPERATIONS
SIGNAL OPERATIONS
 
1_Asymptotic_Notation_pptx.pptx
1_Asymptotic_Notation_pptx.pptx1_Asymptotic_Notation_pptx.pptx
1_Asymptotic_Notation_pptx.pptx
 
Ray : modeling dynamic systems
Ray : modeling dynamic systemsRay : modeling dynamic systems
Ray : modeling dynamic systems
 
002 ray modeling dynamic systems
002 ray modeling dynamic systems002 ray modeling dynamic systems
002 ray modeling dynamic systems
 
002 ray modeling dynamic systems
002 ray modeling dynamic systems002 ray modeling dynamic systems
002 ray modeling dynamic systems
 
Quicksort
QuicksortQuicksort
Quicksort
 
Aaex2 group2
Aaex2 group2Aaex2 group2
Aaex2 group2
 
Recurrence Relation for Achromatic Number of Line Graph of Graph
Recurrence Relation for Achromatic Number of Line Graph of GraphRecurrence Relation for Achromatic Number of Line Graph of Graph
Recurrence Relation for Achromatic Number of Line Graph of Graph
 
Quantum factorization.pdf
Quantum factorization.pdfQuantum factorization.pdf
Quantum factorization.pdf
 
Computer science-formulas
Computer science-formulasComputer science-formulas
Computer science-formulas
 
Recurrences
RecurrencesRecurrences
Recurrences
 
Csm chapters12
Csm chapters12Csm chapters12
Csm chapters12
 
270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx
270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx
270-102-divide-and-conquer_handout.pdfCS 270Algorithm.docx
 
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
 
Algorithms - Rocksolid Tour 2013
Algorithms  - Rocksolid Tour 2013Algorithms  - Rocksolid Tour 2013
Algorithms - Rocksolid Tour 2013
 
Semi markov process
Semi markov processSemi markov process
Semi markov process
 
0-1 knapsack problem
0-1 knapsack problem0-1 knapsack problem
0-1 knapsack problem
 
Notes.on.popularity.versus.similarity.model
Notes.on.popularity.versus.similarity.modelNotes.on.popularity.versus.similarity.model
Notes.on.popularity.versus.similarity.model
 

Más de Hassan Dar

Más de Hassan Dar (12)

Mmclass6
Mmclass6Mmclass6
Mmclass6
 
Mmclass5b
Mmclass5bMmclass5b
Mmclass5b
 
Mmclass5
Mmclass5Mmclass5
Mmclass5
 
Mmclass4
Mmclass4Mmclass4
Mmclass4
 
Mmclass3
Mmclass3Mmclass3
Mmclass3
 
Mmclass2
Mmclass2Mmclass2
Mmclass2
 
Mmclass1
Mmclass1Mmclass1
Mmclass1
 
Lecture1
Lecture1Lecture1
Lecture1
 
Chapter 1
Chapter 1Chapter 1
Chapter 1
 
Ch4
Ch4Ch4
Ch4
 
Msd ch2 issues in multimedia
Msd ch2 issues in multimediaMsd ch2 issues in multimedia
Msd ch2 issues in multimedia
 
Mmclass10
Mmclass10Mmclass10
Mmclass10
 

Último

(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingrakeshbaidya232001
 
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Christo Ananth
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college projectTonystark477637
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...roncy bisnoi
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfKamal Acharya
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...ranjana rawat
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlysanyuktamishra911
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGMANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGSIVASHANKAR N
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Bookingdharasingh5698
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)simmis5
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxfenichawla
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 

Último (20)

(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writing
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college project
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
 
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGMANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 

Mmclass9

  • 1. A Partitioning Algorithm • Let Ti be a task in T such that Pi ≤ Pj for all tasks Ti in T • S1 = {Ti}, T = T - {Ti}, For i=2..g, Si = φ • For i=2..g • For every task Tl in T • max[Tl] = gcd(S1 ∪ {Tl}) – Σ w over all Tk in (S1 ∪ {Tl}) • For j=2..i-1 – max[Tl] = max{max[Tl] , gcd(Sj ∪ {Tl}) – Σ w over all Tk in (Sj ∪ {Tl})} • Let Tl be a task in T such that max[Tl] ≤ max[Tk] for every Tk in T • Si = {Tl}, T = T - {Tl} • For every Ti in T • For j=1..g • Slack[Sj] = gcd(Sj ∪ {Tl}) – Σ w over all Tk in (Sj ∪ {Tl}) • Add Ti to the subset Sj for which Slack[Sj] is maximum
  • 2. Scheduling for Horizontal Striping • Assume wi stripe units for supervideo Vi is stored on disk 0 • The Problem • Schedule non-preemptible tasks T1…Tr with periods P1…Pr on q processors; each task Ti has wi subtasks, with compute time of 1; interval between consecutive subtasks is m • If a task has P=4, w=3 and m=6 is it schedulable? • Condition for subtasks of a single task Ti to be schedulable on a single processor: • For all 1 ≤ j, k ≤ wi, j ≠ k, ((j-1).m) mod Pi ≠ ((k-1).m) mod Pi • Why? • What is the corresponding algorithm to test
  • 3. Testing for Schedulability • Procedure is_schedulable({T1..Tn},m) • Let g=gcd(P1..Pn) • Take g time units 0..(g-1) that are not assigned • Sort the tasks in decreasing order of wi • For each task Tiin the sorted order • j=0 • while (j < g) – if for k=0…(wi – 1), time unit (j+k.m) mod g is free • for k=0…(wi – 1), assign time unit (j+k.m) mod g to Ti • exit while – else j=j+1 • If j=g return FAIL • return {(Ti, x): 1 ≤ i ≤ n and the first subtask of Tiis
  • 4. Scheduling for Horizontal Striping • Algorithm schedule_tasks_2 [Ozden 97] • R=is_schedulable({T1…Tn},m) • If R=FAIL • Let gcd(P1...Pn,)=g • If g=1, return FAIL • Let T1…Tn be tasks with periods P1/g…Pn/g and w1…wn subtasks. • Partition the tasks into g subsets S1…Sg. • For i=1..g, let Ri= schedule_tasks_2(Si,m/g) • If for any i Ri= FAIL, return FAIL, else return {(Ti, x.g+(j-1)): 1 ≤ j ≤ g and (Ti,x) ∈ Rj} • Return R
  • 5. Example • Tasks T1, T2, T3 with periods 6,8,8 have two subtasks each. The interval between them is 4. • Try the algorithm.
  • 6. Example • Tasks T1, T2, T3 with periods 6,8,8 have two subtasks each. The interval between them is 4. • Try the algorithm.

Notas del editor

  1. If the start time for Ti is 0 the j-th subtask is scheduled at times (j-1)m, (j-1).m+Pi, (j-1)m+2Pi …So tasks j and k will be scheduled together iff (j-1)m mod Pi = (k-1)m mod Pi