Stabilization of Branching Queueing Networks Tom Brzdil 1 Stefan - - PowerPoint PPT Presentation

stabilization of branching queueing networks
SMART_READER_LITE
LIVE PREVIEW

Stabilization of Branching Queueing Networks Tom Brzdil 1 Stefan - - PowerPoint PPT Presentation

Stabilization of Branching Queueing Networks Tom Brzdil 1 Stefan Kiefer 2 1 Masaryk University, Brno, Czech Republic 2 University of Oxford, UK STACS, Paris 02 March 2012 Tom Brzdil, Stefan Kiefer Stabilization of Branching Queueing


slide-1
SLIDE 1

Stabilization of Branching Queueing Networks

Tomáš Brázdil1 Stefan Kiefer2

1Masaryk University, Brno, Czech Republic 2University of Oxford, UK

STACS, Paris 02 March 2012

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-2
SLIDE 2

Motivation

Queueing networks are simple and general. Attractive for modeling parallelism: Hardware, especially large-scale multi-core systems:

Full-system performance simulators do not scale. Queueing theory gives a more abstract analysis.

Software, especially message passing:

asynchronous programs on multi-core computers distributed programs on a network

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-3
SLIDE 3

Example: Router

A S1 S2 D C M ε 0.5 0.25 0.25 0.7 0.3

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-4
SLIDE 4

Example: Router

A S1 S2 D C M ε 0.5 0.25 0.25 0.7 0.3 Textual representation of the same thing:

1

֒ − → A A

0.5

֒ − → D A

0.25

֒ − − → S1 A

0.25

֒ − − → S2 D

0.7

֒ − → M D

0.3

֒ − → C S1

1

֒ − → D S2

1

֒ − → D C

1

֒ − → M M

1

֒ − → ε

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-5
SLIDE 5

Example: Router

A S1 S2 D C M ε 0.5 0.25 0.25 0.7 0.3 Textual representation of the same thing:

1

֒ − → A A

0.5

֒ − → D A

0.25

֒ − − → S1 A

0.25

֒ − − → S2 D

0.7

֒ − → M D

0.3

֒ − → C S1

1

֒ − → D S2

1

֒ − → D C

1

֒ − → M M

1

֒ − → ε Also given: arrival rate αA queue rates µA, µS1, . . . of busy queues Continuous-Time Markov Chain – Infinite-State!

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-6
SLIDE 6

Jackson Networks

A S1 S2 D C M ε 0.5 0.25 0.25 0.7 0.3 Such networks are called Jackson networks (classical model). Nice properties: Stability is easy to determine. product form solutions in “steady state”: Pr(S1 = 3 and D = 2) = Pr(S1 = 3) · Pr(D = 2) But shortcomings in modeling: just one new task per one old task no (dynamic) control of the network

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-7
SLIDE 7

Branching Queueing Networks

New model: Branching Queueing Networks (BQNs)

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Rates as before: αA, µA, µB > 0 Similar models: a bit like pushdown systems, but parallel a bit like stochastic Petri nets, but of a special form

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-8
SLIDE 8

Branching Queueing Networks

New model: Branching Queueing Networks (BQNs)

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Rates as before: αA, µA, µB > 0 A B

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-9
SLIDE 9

Branching Queueing Networks

New model: Branching Queueing Networks (BQNs)

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Rates as before: αA, µA, µB > 0 A B

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-10
SLIDE 10

Branching Queueing Networks

New model: Branching Queueing Networks (BQNs)

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Rates as before: αA, µA, µB > 0 A B Topic of this talk: Is a given BQN stable?? stable def = expected return time to “completely empty” is finite

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-11
SLIDE 11

No Product Form

Consider the BQN

1

֒ − → A A

1

֒ − → B, C B

1

֒ − → ε C

1

֒ − → ε No product form: Take αA = 1, µA = µB = µC = 3. Then in steady-state: Pr(C ≥ 1) = 1/3 Pr(C ≥ 1 | B ≥ 1) ≥ 3/7

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-12
SLIDE 12

No Product Form

Consider the BQN

1

֒ − → A A

1

֒ − → B, C B

1

֒ − → ε C

1

֒ − → ε No product form: Take αA = 1, µA = µB = µC = 3. Then in steady-state: Pr(C ≥ 1) = 1/3 Pr(C ≥ 1 | B ≥ 1) ≥ 3/7 Analysis of BQNs harder than for Jackson networks

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-13
SLIDE 13

Balance Equations

1

֒ − → A αA = 0.2 A

1/5

֒ − − → B, B A

4/5

֒ − − → ε µA = 0.4 B

1/6

֒ − − → A, B B

5/6

֒ − − → ε µB = 0.3 (Pre-)Suppose a form of balance: # tasks processed at X per sec = # tasks arriving at X per sec Here: λA = 0.2 + λB · (1/6) λB = λA · (1/5) · 2 + λB · (1/6) We call the solution λ the “throughput”. Note: the speeds of the queues µA, µB do not occur. Here: λA = 0.22 λB = 0.10

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-14
SLIDE 14

A Stability Result

Proposition Given a BQN. Let λ be the throughput, i.e., λ solves the balance equations λ = α + Mλ. Suppose λ < µ (in all components). Then the BQN is stable. Conversely, if the BQN is stable, then there is λ with λ = α + Mλ < µ.

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-15
SLIDE 15

A Stability Result

Proposition Given a BQN. Let λ be the throughput, i.e., λ solves the balance equations λ = α + Mλ. Suppose λ < µ (in all components). Then the BQN is stable. Conversely, if the BQN is stable, then there is λ with λ = α + Mλ < µ. Theorem Stability of a BQN can be decided in polynomial time. Proposition If a BQN is stable, it is “very much so”: in steady state there is an exponential moment of the total queue size, i.e., there is δ > 0 such that

x∈Nn exp(δ x) Pr(x) exists.

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-16
SLIDE 16

Proof of the Stability Result

The stability result requires a delicate proof (no product form).

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Consider “drift” for all points: xA xB 1 2 3 1 2 3

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-17
SLIDE 17

Proof of the Stability Result

The stability result requires a delicate proof (no product form).

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Consider “drift” for all points: For (0, 0): [0] = αA

  • xA

xB 1 2 3 1 2 3 [0]

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-18
SLIDE 18

Proof of the Stability Result

The stability result requires a delicate proof (no product form).

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Consider “drift” for all points: For (0, 0): [0] = αA

  • For (+, 0): [0A] = [0] + [A] with

[A] = µA · −1

  • +
  • (1/5) · 2
  • xA

xB 1 2 3 1 2 3 [0] [0A]

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-19
SLIDE 19

Proof of the Stability Result

The stability result requires a delicate proof (no product form).

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Consider “drift” for all points: For (0, 0): [0] = αA

  • For (+, 0): [0A] = [0] + [A] with

[A] = µA · −1

  • +
  • (1/5) · 2
  • For (0, +): [0B] = [0] + [B]

xA xB 1 2 3 1 2 3 [0] [0A] [0B]

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-20
SLIDE 20

Proof of the Stability Result

The stability result requires a delicate proof (no product form).

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Consider “drift” for all points: For (0, 0): [0] = αA

  • For (+, 0): [0A] = [0] + [A] with

[A] = µA · −1

  • +
  • (1/5) · 2
  • For (0, +): [0B] = [0] + [B]

For (+, +): [0AB] = [0] + [A] + [B] xA xB 1 2 3 1 2 3 [0] [0A] [0B] [0AB]

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-21
SLIDE 21

Proof of the Stability Result

The stability result requires a delicate proof (no product form).

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε B

1/6

֒ − − → A, B B

5/6

֒ − − → ε Consider “drift” for all points: For (0, 0): [0] = αA

  • For (+, 0): [0A] = [0] + [A] with

[A] = µA · −1

  • +
  • (1/5) · 2
  • For (0, +): [0B] = [0] + [B]

For (+, +): [0AB] = [0] + [A] + [B] Find a Lyapunov function w.r.t. which the drift is negative xA xB 1 2 3 1 2 3 [0] [0A] [0B] [0AB]

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-22
SLIDE 22

Proof of the Stability Result (cont’d)

Key steps: Construct piecewise-linear Lyapunov function w.r.t. which the drift is negative almost everywhere (hard).

use throughput λ and apply Farkas’ lemma (wouldn’t work for general stochastic Petri nets)

Smooth the Lyapunov function (standard) Derive (strong) stability using Foster’s criterion (standard) xA xB 1 2 3 1 2 3

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-23
SLIDE 23

Controlled Networks

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε σ1 : B

1/6

֒ − − → A, B B

5/6

֒ − − → ε σ2 : B

2/3

֒ − − → A B

1/3

֒ − − → ε Continuous-Time Markov Decision Process – Infinite-State Generalize balance equations: Subdivide λB in λB = λB,1 + λB,2. Intention: λB,i = rate of B-tasks processed according to σi. λA = αA + λB,1 · (1/6) + λB,2 · (2/3) λB,1 + λB,2 = · · · Similarly to the uncontrolled case: ∃ stabilizing scheduler ⇐ ⇒ ∃ solution λ with λA < µA and λB,1 + λB,2 < µB

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-24
SLIDE 24

Controlled Networks

1

֒ − → A A

1/5

֒ − − → B, B A

4/5

֒ − − → ε σ1 : B

1/6

֒ − − → A, B B

5/6

֒ − − → ε σ2 : B

2/3

֒ − − → A B

1/3

֒ − − → ε Continuous-Time Markov Decision Process – Infinite-State Generalize balance equations: Subdivide λB in λB = λB,1 + λB,2. Intention: λB,i = rate of B-tasks processed according to σi. λA = αA + λB,1 · (1/6) + λB,2 · (2/3) λB,1 + λB,2 = · · · Similarly to the uncontrolled case: ∃ stabilizing scheduler ⇐ ⇒ ∃ solution λ with λA < µA and λB,1 + λB,2 < µB LP!!

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-25
SLIDE 25

General Main Result

Theorem Given a controlled BQN.

1

It is decidable in polynomial time whether there exists an (arbitrary) stabilizing scheduler.

2

If it exists, one can compute in polynomial time a static randomized scheduler, which is stabilizing in a strong sense, i.e., in steady state there is an exponential moment

  • f the total queue size.

The theorem implies: Any stabilizing scheduler can efficiently be made static and – at the same time – “strongly” stabilizing.

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-26
SLIDE 26

Summary

Queueing networks can be used to model parallelism. Classical Jackson networks lack branching and control. New model: Branching Queueing Networks Stability and existence of stabilizing schedulers can be determined in polynomial time. If a stabilizing scheduler does exist, a static randomized scheduler suffices and can be computed in polynomial time.

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-27
SLIDE 27

Summary

Queueing networks can be used to model parallelism. Classical Jackson networks lack branching and control. New model: Branching Queueing Networks Stability and existence of stabilizing schedulers can be determined in polynomial time. If a stabilizing scheduler does exist, a static randomized scheduler suffices and can be computed in polynomial time. Future work: Performance beyond stability, e.g., long-term average queue size Can non-static schedulers help to minimize it?

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks

slide-28
SLIDE 28

End of Talk

Thank you!

Tomáš Brázdil, Stefan Kiefer Stabilization of Branching Queueing Networks