scalable scheduling support for loss and delay
play

Scalable Scheduling Support for Loss and Delay Constrained Media - PowerPoint PPT Presentation

Scalable Scheduling Support for Loss and Delay Constrained Media Streams Richard West, Karsten Schwan & Christian Poellabauer Georgia Institute of Technology Rich West (1999) Introduction Real-Time media servers need to support 100s


  1. Scalable Scheduling Support for Loss and Delay Constrained Media Streams Richard West, Karsten Schwan & Christian Poellabauer Georgia Institute of Technology Rich West (1999)

  2. Introduction ■ Real-Time media servers need to support 100s (even 1000s) of clients with individual RT (QoS) constraints. ■ Need fast/efficient scheduling on such servers. ■ We describe Dynamic Window-Constrained Scheduling (DWCS): ■ DWCS limits the number of late packets over finite windows of arrivals requiring service. ■ Focus on a scalable implementation of DWCS. ■ Approximating DWCS trades execution speed for service quality. Rich West (1999)

  3. DWCS Packet Scheduling ■ Two attributes per packet: ■ Deadline (max inter-packet gap). ■ Loss-tolerance, x/y . ■ x late/lost packets every y arrivals for service from same stream. ■ At any time, all packets in the same stream: ■ Have the same current loss-tolerance. ■ Have deadlines offset by a fixed amount from predecessors. Rich West (1999)

  4. DWCS - Conceptual View Network Pipe Higher Priority . = . Lower . Loss-Tolerance EDF-ordered queues Rich West (1999)

  5. Heterogeneous Scheduling 0 loss-tolerance queue EDF-ordered queues Network Pipe Higher Priority . = . Lower . Loss-Tolerance (Time-constrained traffic) Compare first packet with packet at head of 0 loss-tolerance queue to see if schedulable. Lowest loss-tolerance first (Non-time-constrained traffic) Rich West (1999)

  6. Pairwise Packet Ordering Table Precedence amongs t pairs of packets • Lowest loss-tolerance first • Same non-zero loss-tolerance, order EDF • Same non-zero loss-tolerance & deadlines, order lowest loss-numerator first • Zero loss-tolerance and denominators, order EDF • Zero loss-tolerance, order highest loss- denominator first • All other cases: first-come-first-serve Rich West (1999)

  7. Example: L1=1/2, L2=3/4, L3=6/8 D=1, Service Time (C)=1 s1 s2 s1 s3 s s2 s1 s3 s1 s2 s1 s3 s1 s2 s s3 1 1 time, t 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 s1 1/2(0), 1/1(1),1/2(2),1/1(3),1/2(4)... s 3/4(0),2/3(1),2/2(2),1/1(3),3/4(4),2/3(5),2/2(6),1/1(7),3/4(8)... 2 s3 6/8(0),5/7(1),4/6(2),3/5(3),3/4(4),2/3(5),1/2(6),0/1(7),6/8(8)... Rich West (1999)

  8. Example: L1=1/2, L2=1/2, C1=5, C2=3, D1=5, D2=3 s1 s2 s2 s1 time, t 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 s2 s2 s1 s2 time, t 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 s1 1/2(0),1/1(5),1/2(10),0/1(15),1/2(20),0/1(25),1/2(30)... s2 1/2(0),0/1(3),1/4(6),1/3(9),1/2(12),0/1(15),1/4(18), 1/3(21),1/2(24),0/1(27),1/2(30)... Rich West (1999)

  9. Loss-Tolerance Adjustment (A) ■ For stream i whose head packet is serviced before its deadline: ■ if ( y i ’ > x i ’ ) then y i ’ = y i ’ -1; ■ if ( x i ’ = y i ’ =0) then x i ’ = x i ; y i ’ = y i ; ■ Where: ■ x i =Original loss-numerator for stream i ■ y i =Original loss-denominator for stream i ■ x i ’ =Current loss-numerator for stream i ■ y i ’ =Current loss-denominator for stream i Rich West (1999)

  10. Loss-Tolerance Adjustment (B) ■ For stream j whose head packet misses its deadline: ■ if ( x j ’ > 0) then ■ x j ’ = x j ’ -1; y j ’ = y j ’ -1; ■ if ( x j ’ = y j ’ =0) then x j ’ = x j ; y j ’ = y j ; ■ else if ( x j ’ =0) and ( y j > 0) then ■ x j ’=2 x j -1; y j ’ =2 y j +( y j ’ -1); ( method 1 ) ■ x j ’ = x j ; y j ’ = y j ; ( method 2 ) ■ if ( x j > 0) then y j ’ = y j ’ + ( y j - x j )/ x j  ; ( method 3 ) ■ if ( x j =0) then y j ’ = y j ’ + y j ; Rich West (1999)

  11. DWCS Algorithm Outline ■ While TRUE : ■ Find stream i with highest priority (see Table) ■ Service packet at head of stream i ■ Adjust loss-tolerance for i according to (A) ■ Deadline( i ) = Deadline( i ) + Inter-Pkt Gap( i ) ■ For each stream j missing its deadline: ■ While deadline is missed: ■ Adjust loss-tolerance for j according to (B) ■ Drop head packet of stream j if droppable ■ Deadline( j ) = Deadline( j ) + Inter-Pkt Gap( j ) Rich West (1999)

  12. DWCS Implementation Deadline Heap S i Back of Queue S S j k Head Packet (Stream 1) Select next packet To Back for service from head packets in Loss-Tolerance Heap each stream. S x S Sz y Head Packet (Stream n) To Back (a) (b) Rich West (1999)

  13. Missed Deadlines (D=500, C=1) 50000 FIFO 45000 1/80 1/90 Number of Deadlines Missed 40000 1/100 1/110 35000 1/120 1/130 30000 1/140 1/150 25000 DWCS total 20000 15000 10000 5000 0 0 100 200 300 400 500 600 700 800 Number of Streams Rich West (1999)

  14. Loss-Tolerance Violations (D=500, C=1) 12000 FIFO 1/80 Number of Loss-Tolerance Violations 1/90 10000 1/100 1/110 1/120 8000 1/130 1/140 1/150 DWCS total 6000 4000 2000 0 0 100 200 300 400 500 600 700 800 Number of Streams Rich West (1999)

  15. DWCS Spreads Losses 1 2 3 4 5 DWCS FIFO time, t 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Rich West (1999)

  16. Packets Serviced Per Second 480 streams 40 Service Rate (packets per second) 35 30 25 20 1/80 1/90 1/100 15 1/110 1/120 10 1/130 1/140 1/150 5 0 0 50 100 150 200 250 300 350 400 450 Time (seconds) Rich West (1999)

  17. Packets Serviced Per Second 560 streams 25 Service Rate (packets per second) 20 15 1/80 1/90 10 1/100 1/110 1/120 1/130 5 1/140 1/150 0 0 100 200 300 400 500 600 700 Time (seconds) Rich West (1999)

  18. Scheduling Overhead Scheduling Overhead (uS) 1914 2000 Without heaps 1800 1555 1600 With heaps 1307 1400 1200 999 1000 760 800 510 600 400 230 208 157 122 87 200 63 76 57 0 120 240 360 480 600 720 840 Number of Streams Rich West (1999)

  19. Synchronization Costs Cost of Synchronization 5836 6000 5000 3639 3953 4000 (uS) 3000 2000 1437 539 666 804 1000 12 27 0 2 4 6 8 12 16 22 24 32 Number of Streams Rich West (1999)

  20. Approximation Overheads (D=200) 300 Scheduler Overhead (uS) 250 200 150 100 1 2 50 Cycles 4 Between 8 0 Checking 12 840 720 600 Deadlines 480 360 240 120 Number of Streams Rich West (1999)

  21. Approximation Overheads (D=500) 250 Scheduler Overhead (uS) 200 150 100 1 2 50 Cycles 4 Between 8 0 Checking 12 840 720 Deadlines 600 480 360 240 120 Number of Streams Rich West (1999)

  22. Deadlines Missed (D=200) 4500000 4000000 3500000 Deadlines 3000000 Missed 2500000 2000000 1500000 1 2 1000000 4 500000 Y 8 0 12 840 720 600 480 360 240 120 Number of Streams Rich West (1999)

  23. Deadlines Missed (D=500) 800000 700000 600000 Deadlines Missed 500000 400000 300000 1 200000 2 4 100000 Y 8 0 12 840 720 600 480 360 240 120 Number of Streams Rich West (1999)

  24. Loss-Tolerance Violations (D=200) 40000 35000 30000 Violations 25000 20000 15000 1 10000 2 4 5000 Y 8 0 12 840 720 600 480 360 240 120 Number of Streams Rich West (1999)

  25. Loss-Tolerance Violations (D=500) 16000 14000 12000 Violations 10000 8000 6000 1 4000 2 4 2000 Y 8 0 12 840 720 600 480 360 240 120 Number of Streams Rich West (1999)

  26. DWCS Summary ■ Aimed at servicing packets with delay and loss- constraints. ■ Attempts to service each stream so that at most x packets are lost/late for every y packets requiring service. ■ DWCS minimizes the number of consecutive late packets over any finite window of packets in a given stream. ■ Scheduling overhead can be reduced (and scalability increased) by using appropriate data structures (heaps, circular queues) and approximation methods. Rich West (1999)

  27. DWCS - Current Work ■ DWCS is currently being adapted for use as a CPU scheduler (using Linux), for hard real-time threads, so that (y-x) out of y deadlines can be met. ■ Leads to bounded service delay, and guaranteed service in any finite window of service time. ■ Aim is to support coordinated thread/packet scheduling. Rich West (1999)

  28. Scheduling Related Work ■ Fair Scheduling : WFQ/WF 2 Q (Shenker, Keshav, Bennett, Zhang etc), SFQ (Goyal et al), EEVDF/Proportional Share (Stoica, Jeffay et al). ■ (m,k) Deadline Scheduling : Distance-Based Priority (Hamdaoui & Ramanathan), Dual-Priority Scheduling (Bernat & Burns). Rich West (1999)

Recommend


More recommend