Buffering problems Moran Feldman Technion Based on joint work with Seffi Naor.

Slides:



Advertisements
Similar presentations
Ulams Game and Universal Communications Using Feedback Ofer Shayevitz June 2006.
Advertisements

Routing and Congestion Problems in General Networks Presented by Jun Zou CAS 744.
Seminar in Auctions and Mechanism Design Based on J. Hartline’s book: Approximation in Economic Design Presented by: Miki Dimenshtein & Noga Levy.
Lecture 24 Coping with NPC and Unsolvable problems. When a problem is unsolvable, that's generally very bad news: it means there is no general algorithm.
Online Algorithms Amrinder Arora Permalink:
Online Scheduling with Known Arrival Times Nicholas G Hall (Ohio State University) Marc E Posner (Ohio State University) Chris N Potts (University of Southampton)
Outline. Theorem For the two processor network, Bit C(Leader) = Bit C(MaxF) = 2[log 2 ((M + 2)/3.5)] and Bit C t (Leader) = Bit C t (MaxF) = 2[log 2 ((M.
An Optimal Lower Bound for Buffer Management in Multi-Queue Switches Marcin Bieńkowski.
Dynamic Wavelength Allocation in All-optical Ring Networks Ori Gerstel and Shay Kutten Proceedings of ICC'97.
EE 685 presentation Optimal Control of Wireless Networks with Finite Buffers By Long Bao Le, Eytan Modiano and Ness B. Shroff.
June 3, 2015Windows Scheduling Problems for Broadcast System 1 Amotz Bar-Noy, and Richard E. Ladner Presented by Qiaosheng Shi.
1 Introduction to Computability Theory Lecture12: Reductions Prof. Amos Israeli.
Dynamic Internet Congestion with Bursts Stefan Schmid Roger Wattenhofer Distributed Computing Group, ETH Zurich 13th International Conference On High Performance.
Worst-case Fair Weighted Fair Queueing (WF²Q) by Jon C.R. Bennett & Hui Zhang Presented by Vitali Greenberg.
Tirgul 10 Rehearsal about Universal Hashing Solving two problems from theoretical exercises: –T2 q. 1 –T3 q. 2.
Algorithm Orals Algorithm Qualifying Examination Orals Achieving 100% Throughput in IQ/CIOQ Switches using Maximum Size and Maximal Matching Algorithms.
Generalized Processing Sharing (GPS) Is work conserving Is a fluid model Service Guarantee –GPS discipline can provide an end-to-end bounded- delay service.
1 Ecole Polytechnque, Nov 7, 2007 Scheduling Unit Jobs to Maximize Throughput Jobs:  all have processing time (length) = 1  release time r j  deadline.
Online Algorithms Motivation and Definitions Paging Problem Competitive Analysis Online Load Balancing.
Energy-Efficient Rate Scheduling in Wireless Links A Geometric Approach Yashar Ganjali High Performance Networking Group Stanford University
October 5th, 2005 Jitter Regulation for Multiple Streams David Hay and Gabriel Scalosub Technion, Israel.
CSE 421 Algorithms Richard Anderson Lecture 6 Greedy Algorithms.
Packet Scheduling with Bounded Buffers A router can send one packet at a time Arriving packets must be queued in a finite buffer B (though we often ignore.
Job Scheduling Lecture 19: March 19. Job Scheduling: Unrelated Multiple Machines There are n jobs, each job has: a processing time p(i,j) (the time to.
Competitive Analysis of Incentive Compatible On-Line Auctions Ron Lavi and Noam Nisan SISL/IST, Cal-Tech Hebrew University.
DAST 2005 Week 4 – Some Helpful Material Randomized Quick Sort & Lower bound & General remarks…
Theory of Computing Lecture 20 MAS 714 Hartmut Klauck.
Online Packet Switching Techniques and algorithms Yossi Azar Tel Aviv University.
A General Approach to Online Network Optimization Problems Seffi Naor Computer Science Dept. Technion Haifa, Israel Joint work: Noga Alon, Yossi Azar,
Online Function Tracking with Generalized Penalties Marcin Bieńkowski Institute of Computer Science, University of Wrocław, Poland Stefan Schmid Deutsche.
Called as the Interval Scheduling Problem. A simpler version of a class of scheduling problems. – Can add weights. – Can add multiple resources – Can ask.
Fair Real-time Traffic Scheduling over Wireless Local Area Networks Insik Shin Joint work with M. Adamou, S. Khanna, I. Lee, and S. Zhou Dept. of Computer.
Competitive On-Line Admission Control and Routing By: Gabi Kliot Presentation version.
Yossi Azar Tel Aviv University Joint work with Ilan Cohen Serving in the Dark 1.
© 2009 IBM Corporation 1 Improving Consolidation of Virtual Machines with Risk-aware Bandwidth Oversubscription in Compute Clouds Amir Epstein Joint work.
Scheduling policies for real- time embedded systems.
Department of Computer Science Stanley P. Y. Fung Online Preemptive Scheduling with Immediate Decision or Notification and Penalties.
The Selection Problem. 2 Median and Order Statistics In this section, we will study algorithms for finding the i th smallest element in a set of n elements.
1 Chapters 8 Overview of Queuing Analysis. Chapter 8 Overview of Queuing Analysis 2 Projected vs. Actual Response Time.
1 Online algorithms Typically when we solve problems and design algorithms we assume that we know all the data a priori. However in many practical situations.
Competitive Queue Policies for Differentiated Services Seminar in Packet Networks1 Competitive Queue Policies for Differentiated Services William.
A Optimal On-line Algorithm for k Servers on Trees Author : Marek Chrobak Lawrence L. Larmore 報告人:羅正偉.
Loss-Bounded Analysis for Differentiated Services. By Alexander Kesselman and Yishay Mansour Presented By Sharon Lubasz
Submodular Maximization with Cardinality Constraints Moran Feldman Based On Submodular Maximization with Cardinality Constraints. Niv Buchbinder, Moran.
Frequency Capping in Online Advertising Moran Feldman Technion Joint work with: Niv Buchbinder,The Open University of Israel Arpita Ghosh,Yahoo! Research.
Improved Competitive Ratios for Submodular Secretary Problems ? Moran Feldman Roy SchwartzJoseph (Seffi) Naor Technion – Israel Institute of Technology.
Hedonic Clustering Games Moran Feldman Joint work with: Seffi Naor and Liane Lewin-Eytan.
© The McGraw-Hill Companies, Inc., Chapter 12 On-Line Algorithms.
A Unified Continuous Greedy Algorithm for Submodular Maximization Moran Feldman Roy SchwartzJoseph (Seffi) Naor Technion – Israel Institute of Technology.
Maximization Problems with Submodular Objective Functions Moran Feldman Publication List Improved Approximations for k-Exchange Systems. Moran Feldman,
Minimizing Delay in Shared Pipelines Ori Rottenstreich (Technion, Israel) Joint work with Isaac Keslassy (Technion, Israel) Yoram Revah, Aviran Kadosh.
Buffered Crossbars With Performance Guarantees Shang-Tse (Da) Chuang Cisco Systems EE384Y Thursday, April 27, 2006.
Non-Preemptive Buffer Management for Latency Sensitive Packets Moran Feldman Technion Seffi Naor Technion.
Topics in Internet Research: Project Scope Mehreen Alam
Virtual-Channel Flow Control William J. Dally
Spring Computer Networks1 Congestion Control Sections 6.1 – 6.4 Outline Preliminaries Queuing Discipline Reacting to Congestion Avoiding Congestion.
11 -1 Chapter 12 On-Line Algorithms On-Line Algorithms On-line algorithms are used to solve on-line problems. The disk scheduling problem The requests.
Competitive Queueing Policies for QoS Switches Nir Andelman Yishay Mansour An Zhu TAUTAUStanford.
Unconstrained Submodular Maximization Moran Feldman The Open University of Israel Based On Maximizing Non-monotone Submodular Functions. Uriel Feige, Vahab.
Algorithms for Big Data: Streaming and Sublinear Time Algorithms
Randomized Queue Management for DiffServ
Moran Feldman The Open University of Israel
Maximum Matching in the Online Batch-Arrival Model
Framework for the Secretary Problem on the Intersection of Matroids
Chapter 6: CPU Scheduling
Coverage Approximation Algorithms
The Byzantine Secretary Problem
Submodular Maximization with Cardinality Constraints
An Optimal Lower Bound for Buffer Management in Multi-Queue Switches
Presentation transcript:

Buffering problems Moran Feldman Technion Based on joint work with Seffi Naor

Outline Introduction to Buffering Problems Known Results – Results for standard buffering problems – A few proofs Our Contribution – The problem we consider – Our results – A few proofs 2

Buffering Problems A router in a communication network receives, buffers and transmits packets. Often the router has to drop some of the packets arriving: – Not enough memory to keep waiting packets. – Packets have deadline, and they expire before transmission. A buffering problem: – Describes a model of a router. – Asks for a policy for managing the packets (how to decide which packets to transmit/accept/drop). – The objective is to maximize (or minimize) some function over set of packets transmitted. 3

Standard Buffering Problems 4 Common Properties Packets arrive continuously. One packet can be transmitted at every given time unit. Every packet d has an internal value w(d). The objective is to maximize the total value of transmitted packets (throughput). Bounded Delay Each packet has a deadline. A packet can be transmitted only before its deadline. Any buffered packet can be transmitted. Preemptive FIFO Packets are buffered in a limited size FIFO queue. The first packet in the queue is transmitted. At any time, packets can be preempted from the queue. Non-Preemptive FIFO Packets are buffered in a limited size FIFO queue. The first packet in the queue is transmitted. A packet must be either accepted to the queue or rejected upon arrival.

Online Problems Buffering problems are online problems. What makes a problem online? The input arrives on the fly. An algorithm for the problem has to make irrevocable decisions before “seeing” all the input. Game against an adversary Online problems are often viewed as a game between the algorithm and a malicious adversary. 5 The adversary gives the input step by step. The algorithm responds to every piece of input.

Competitive Ratio Standard performance measure for online algorithms. Notation I – An instance of an online problem. ALG( I ) – The value of the online algorithm ALG on I. OPT( I ) – The value of an optimal offline algorithm on I. 6 Deterministic Algorithms The competitive ratio is: Intuitively: the adversary inspects the algorithm, and chooses the worst input for it. Remark: Usually exponential time does not improve the achievable competitive ratio. Time complexity is less important in online settings.

Competitive Ratio (cont.) 7 Randomized Algorithms There are three adversary types with different powers. Most works assume an oblivious adversary, i.e., an adversary that can inspect the algorithm, but not its random coins. The competitive ratio against oblivious adversary is: Intuitively: the adversary choose the entire input beforehand, and then feeds it to the algorithm step by step. Randomization often improves the achievable competitive ratio.

Outline Introduction to Buffering Problems Known Results –R–Results for standard buffering problems –A–A few proofs Our Contribution –T–The problem we consider –O–Our results –A–A few proofs 8

Known Results – Bounded Delay 9 “Agreeable deadlines” assumption: the packets arrive in a non-decreasing deadline order. Competitive ratio of φ [SS05]. Other assumptions yielding improved competitive ratios: – s – bounded: at most s time units between packet’s arrival and deadline. – s – uniform: exactly s time units between packet’s arrival and deadline.

Known Results – Preemptive FIFO 10 Results for this model tend to be better than for the previous one. DeterministicRandomized Best Competitive Ratio [LP02]1.25 [A05] Lower Bound1.281 [KLMP04]1.197 [A05] The worst case is usually a buffer of size 2. Improved competitive ratios are known for larger buffers. If only two packet values are allowed: 1 and α.

Known Results – Non-Preemptive FIFO 11 The optimal algorithm never preempts. Therefore, results in this model are much worse. If packets take values from the set {1, α} only. – Tight competitive ratio of (2α – 1) / α for both deterministic and randomized algorithms [AMZ03, AMRR00]. If packets take values from the range [1, α]: – Deterministic competitive ratio of e ∙  ln α  [AMZ03]. – Deterministic lower bound of 1 + ln α [AMZ03]. Remark: Our results are for a variant of this problem allowing better results.

Other Buffering Problems Most buffering problems are variants of the standard problems. 12 Variants of the model Multiple input queues General output bandwidth: W packets transmitted per time unit Variants of the objective Minimize the maximum delay Minimize the total delay

Greedy Algorithm for Bounded Delay Algorithm [KLMPSS01] At every time unit: 1.Discard packets that expired. 2.Transmit the remaining packet with maximum value. Notation ALG t - the value ALG gains till time t. OPT t - the value OPT gains starting from time t if given ALG’s configuration at time t (also denotes the corresponding schedule). t’ - a time after the deadline of the last packet. Goal Prove 2ALG t’ ≥ OPT 0. 13

Greedy Algorithm for Bounded Delay (cont.) Lemma For every time t, 2(ALG t+1 – ALG t ) ≥ OPT t – OPT t+1. Proof Let d OPT (d ALG ) be the packet OPT t (respectively, ALG) transmits at time t. OPT t+1 can use the schedule of OPT t without d ALG and d OPT. OPT t – OPT t+1 ≤ w(d OPT ) + w(d ALG ) ≤ 2w(d ALG ) = 2(ALG t+1 – ALG t ). Corollary 2(ALG t’ – ALG 0 ) ≥ OPT 0 – OPT t’. 14 Q.E.D.

Algorithm for Agreeable Deadlines Algorithm [LSS05] 15 Discard all but a schedulable set of packets of maximum value. Sort the packets in non-decreasing deadline order. Every time a packet arrives e – The most valuable packet among the packets with the earliest deadline. h – The packet with the earliest deadline among the most valuable packets. Definitions If w(e) ≥ w(h) / φ, transmit e. Otherwise, transmit the first packet f with w(f) ≥ w(h) / φ and w(f) ≥ w(e) ∙ φ. Decide which packet to transmit

Algorithm Analysis Analysis We want to prove that ALG is φ competitive. We keep the buffers of OPT and ALG identical, at the cost of increasing OPT’s value. Assume OPT transmits packets in non-decreasing deadline order. Events to Consider A packet is transmitted. A packet arrives. Packet Transmission - (A Bit Tedious) Case Analysis 1.If both OPT and ALG transmit the same packet, their buffers remain identical. In the other cases, we use the following notation: d ALG – The packet ALG transmits. d OPT – The packet OPT transmits. 16

Packet Transmission (cont.) 2.If d ALG comes before d OPT. – The deadline of d ALG is before that of d OPT. – OPT does not transmit d ALG, therefore, w(d OPT ) ≥ w(d ALG ). – On the other hand, w(d ALG ) ≥ w(h) / φ ≥ w(d OPT ) / φ. We let OPT transmit d OPT, and then replace d ALG in its buffer with d OPT. – ALG’s gain is at least φ -1 times OPT’s gain. – The future gain of OPT only improves by the replacement. 3.If d OPT = e. – w(d ALG ) ≥ w(e) ∙ φ Let OPT transmit both e and d ALG, and keep e in its buffer. – Clearly, we just helped OPT. – ALG’s gain is w(d ALG ). – OPT’s gain is w(e) + w(d ALG ) ≤ (1 + φ -1 ) w(d ALG ) = w(d ALG ) ∙ φ. 17 The common buffer: d ALG d OPT

Packet Transmission (cont.) 4.If d OPT ≠ e appears before d ALG. – d ALG is better than d OPT : later deadline and higher value. – OPT is guaranteed to transmit d ALG in the future. – OPT is not going to transmit e. We make OPT transmit d ALG now, and then continue as before. – Only the transmission times (by OPT) of packets appearing before d ALG are effected. – Each such packet d is still transmittable even after transmitting all earlier packets in the range e…d. – The modified OPT sends d ALG and a subset of e…d excluding e. Hence, d remains transmittable. 18 The common buffer: d OPT d ALG ed

Packet Arrival What Happens When a Packet Arrives? The algorithm discards all but a schedulable set of packets of maximum value. Can be reduced to bipartite matching (nodes on the left side are the packets, and on the right side are the transmission slots). Our Objective Let D be the set of packets dismissed. We want to show that: – There is a schedule for OPT that does not contain any packet of D. – Hence, OPT can dismiss D, and keep the same buffer as ALG. Proof Let B be the set of packets ALG keeps, and let S be a schedule for transmitting all of them. Assume the next transmission time is 1, and OPT first transmits a packet outside of B  D in time t. 19

Packet Arrival (cont.) Observe that OPT transmits: – Till time t-1: only packets of B  D. – Starting from time t: only packets outside B  D. Case 1: t > |B| Replace OPT with the following schedule: Mimic S till time |B|. Mimic the original OPT starting from time t. Case 2: t  |B| Consider the schedules of OPT and S for packets of B  D. 20 1|B||B| OPT: S:S: t

Packet Arrival (cont.) Assume OPT transmits a packet d  D. S transmits on the same time a packet d’  B such that: – w(d’)  w(d) because S could transmit d instead. If OPT does not transmit d’, we just replace d with d’. Otherwise, during the time when OPT transmits d’, S transmits a packet d’’  B such that: – w(d’’) + w(d’)  w(d’) + w(d) because S could transmit d instead of d’ and d’ instead of d’’. If OPT does not transit d’’, we do these replacemts. Otherwise, continue in the same way till d is removed. 21 1|B||B| OPT: S:S: d d’ d'’ t

Outline Introduction to Buffering Problems Known Results –R–Results for standard buffering problems –A–A few proofs Our Contribution –T–The problem we consider –O–Our results –A–A few proofs 22

Motivation Consider a path in a communication network: 23 Router A packet going through the path often has a deadline. The deadline refers to the arrival of the packet to its destination. An online model of a router must deal with these deadlines: ‐The standard models assume a deadline for leaving the router. ‐A new model (proposed by Fiat, Mansour and Nadav [SODA 2008]), associates each packet with a value that diminishes over time.

2 The Model Our model is based on the model of Fiat et. al. 24 Router’s queue Unlimited size Packets Arrive online, each has an associated value w(d). Must be rejected or accepted immediately. Time Continues, starting at time 0 Packets arrive at fractional times and are transmitted at integral ones. At each integral time the first packet of the queue is transmitted. Its revenue is w(d) minus the delay it suffered in the queue. 43

Results for this Model Sub models Unrestricted model – A packet can have any positive value. Real valued model – A packet can have any value ≥ 1. Integral valued model – A packet can have any positive integral value. 25 Unrestricted Model Real Valued Model Integral Valued Model Deterministic Lower bound 333 Upper bound Randomized Lower bound φ ≈ Upper bound Known results inferred from Fiat et. al. Unrestricted Model Real Valued Model Integral Valued Model Deterministic Lower bound ∞ (3)φ 3 ≈ (3)4 (3) Upper bound (4.24) Randomized Lower bound ∞ (φ)4 (φ) Upper bound -4 (4.24) New results appear in red.

Unrestricted Model – Lower Bound Consider any algorithm ALG and a constant c. Our job: Show that ALG is not c-competitive. Plan of Adversary 1.For i = 1 to 2c do: 2.Give ALG a packet of value (1/2c) 2c+1-i. 3.If the probability that ALG accepted any packet, so far, is less than i/2c, terminate. 4.Give ALG a packet of value 1. Proof Idea Packets have exponentially increasing values, but all values are at most 1, so only one packet gives revenue. ALG must accept each packet with some probability. OPT accepts with probability 1 the last packet. 26

The Dual-Fitting Method Offline Primal Program 27 y(d,t) – Indicates whether packet d was transmitted at time t. w(d) – The value of packet d. a(d) – The time when packet d arrived. Remark The LP contains no FIFO constraint because this is no constraint from the offline point of view.

The Dual-Fitting Method (cont.) 28 Offline Dual Program Method Every dual solution is an upper bound on OPT. To show that an algorithm is c-competitive we do the following:  Consider any input sequence σ.  Calculate the revenue R σ of the algorithm on σ.  Find a dual solution of value D σ for σ.  Prove that D σ /R σ ≤ c.

Deterministic Reduction to Simple Inputs Definition An input sequence is simple if all packets in it arrive before time Reduction If there is a deterministic R-competitive algorithm A on simple input sequences, then there exists a deterministic R-competitive algorithm B on all input sequences. Definition of B B’s Input: A’s Input: 1.B simulates A and maps each input packets to A’s input.2.Map each packet to time before time 1, and increase its value by the number of transmissions so far Reset the algorithm when the queue empties.

Deterministic Reduction to Simple Inputs (cont.) Why Does It Work? Let an interval be the time between two consecutive resets. B (and A) transmit packets at all integral times in an interval. Moving packets to earlier time: – Does not effect the transmission times. – Increase the delay that the packets suffer. Increasing the value of the packets counters the additional delay

Deterministic Algorithm for Integral Simple Inputs Algorithm (NDT) 1.Let Q be the number of packets in the router’s queue. 2.Accept a new packet d if and only if w(d) ≥ 2Q Remark The algorithm also works for general integral inputs, although it is more difficult to show that. Reduction Assume that if a packet d is accepted, then its value is exactly 2Q+1. Proof This is the lowest value that will get the packet accepted.

Analyzing NDT Assume k packets have been received: 32 Value for the Algorithm Packet Value Delay Assignment to the Dual LP z d = 0x t = max{2k - t, 0} Value of solution: The competitive ratio of NDT is:

Randomized Reduction to Simple Inputs Difficulty The previous reduction does not work for randomized algorithms: If we restart each time the queue empties, the simulated algorithm A will face a non-oblivious adversary. If we do not restart, the algorithm will not necessarily have a packet to send at each integral time of an interval. 33 Definition A randomized algorithm is good if at all times an external observer can give a number P such that: The algorithm has either P or P+1 packets in its queue. P does not depend on the random decisions of the algorithm. Remark In a sense, a good algorithm is a randomized algorithm with minimal randomness.

Randomized Reduction to Simple Inputs (cont.) 34 Idea We reset A’s simulation after every integral time in which we might not have a packet to transmit. This ensures that the queue is empty after every reset. Either: – The queue was empty before the integral time. – The last packet was sent during the integral time. A faces an oblivious adversary. – The reduction does not depend on A’s randomized decisions. The algorithm transmits at each integral time between resets. Objective Make the previous reduction work for good randomized algorithms.

Randomized Algorithm for Real Valued Simple Inputs Algorithm (RNDT) 1.Let Q be a random variable of the size of the queue. 2.Keep the invariant Q =  E(Q)  or Q =  E(Q) . 3.Accept a new packet d with probability: To keep the invariant, true acceptances probability depends on the actual value of the random variable Q. 35 d first packetw(d) ≤ 2E(Q)+0.52E(Q)+0.5 ≤ w(d) ≤ 2E(Q)+2.5w(d) ≥ 2E(Q)+2.5 ½0w(d) / 2 – 0.25 – E(Q)1 Reduction Let E f be the final value of E[Q]. No packet had value over 2E f + ½. Proof For rejected packets: implied by the acceptance probabilities. For packets d accepted with probability p: We can assume w(d)  2E[Q] p. E[Q] increases following the arrival by p.

Analyzing RNDT 36 Value for the Algorithm First Packet The packet which caused E[Q] to exceed x must have value of at least 2x Assignment to the Dual LP z d = 0x t = max{2E f t, 0} Value of solution: The competitive ratio of RNDT is:

Open Problems Adversary that draws from a malicious distribution. – Competitive analysis provides too pessimistic a view. – Classic queuing theory analyzes Poisson distributed source. – Provides a middle ground between the two approaches. A sub-model where all values above some constant c are allowed. – Generalizes the unrestricted and real-valued models. – The constant c represent the ratio between the shortest deadlines and the speed of the network. – The main question is finding the relation between c and the competitive ratio. 37

38