Lectures 17 & 18 Fast Packet Switching: Eytan Modiano Massachusetts Institute of Technology
Lectures 17 & 18 Fast Packet Switching: Eytan Modiano Massachusetts Institute of Technology
Eytan Modiano
Massachusetts Institute of Technology
Eytan Modiano
Slide 1
Packet switches
Packet
Routing
engine Switch
Scheduler
Packet
Data Header Packet Tag
Eytan Modiano
Slide 2
First Generation Switches
CPU
Eytan Modiano
Slide 3
Second Generation switches
Computer
Bus
LC LC LC LC
Input LC Output LC
N by N
Input LC SWITCH Output LC
FABRIC
Input LC Output LC
Controller
Eytan Modiano
Slide 5
Switch Architectures
• Distributed buffer
• Output buffer
• Input buffer
Eytan Modiano
Slide 6
Distributed buffer
• Modular Architecture
N N
inputs outputs
Eytan Modiano
Slide 7
Interconnection networks
• N input
• Log(N) stages with N/2 modules per stage
• Use a tag: n bit sequence with one bit per stage of the network
– E.g., Tag = b3b2b1
• Module at stage i looks at bit i of the tag (bi), and sends the packet
up if bi=0 and down if bi=1
• In omega network, for destination port with binary address abc the
tag is cba
Eytan Modiano
Slide 9
Baseline network
2x2
N/2 x N/2
2x2
2x2 2x2
N inputs 4 x 4 switch
example
2x2 2x2 2x2
N/2 x N/2
2x2
• Two packets may want to use the same link at the same time
(same output port of a module)
• Solution: Buffering
Eytan Modiano
Slide 11
Throughput analysis of interconnection
networks
• If two packets want to use the same port one of them is dropped
Eytan Modiano
Slide 12
Interconnection Throughput, continued
• P(0) = 1
• P(m+1) = 1 – P(no packet on stage m+1 link (link c) )
• Each input has a packet with probability P(m) and that packet will
choose the link with probability 1/2. Hence,
1 2
P(m + 1) = 1− (1 − P( m))
2
• We can now solve for P(m) recursively
• For an m stage network, throughput (per output link) is P(m),
which is the probability that there is a packet at the output
Eytan Modiano
Slide 13
Interconnection Throughput, continued
1.2
0.8
0.6
0.4
0.2
0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
stages
of multi-stage architecture
• Advantages
– Modular
– Scalable
– Bus (links) only needs to be as fast as the line cards
• Disadvantages
– Delays for going through the stages
Cut-through possible when buffers empty
– Decreased throughput due to internal blocking
Eytan Modiano
Slide 15
Output buffer architecture
N
inputs Interconnect fabric
or
Bus
Eytan Modiano
Slide 16
Queueing Analysis
• Note that the only delay is due to the queueing at the outputs and
none is due to the switch fabric
Eytan Modiano
Slide 17
Advantages/Disadvantages of
Eytan Modiano
Slide 18
Input buffer architecture
1 X
2 X
Scheduler
3 X
4 X
X = connect
1 2 3 4
Eytan Modiano
Slide 20
Throughput analysis, continued
• i
Let Qm be the number of HOL packets destined to node i at the
end of the mth slot
i i i
Qm = max(0,Qm −1 + Am − 1)
• Where
Ami = number of new HOL messages addressed to node i that arrive
to the HOL during slot m. Now,
Cm −1
P( A = l) =
i
m
(1/ N )l (1 − 1/ N )Cm− 1 − l
l
• Where
Cm −1 = number of HOL messages that departed during the m-1 slot =
number of new HOL arrivals
2(1 − A)
=1
i =1
A = utilization = 2 − 2 ≈ 0.58
Eytan Modiano
Slide 22
Summary of input queued switches
Eytan Modiano
Slide 23
Overcoming HOL blocking
• If inputs are allowed to transfer packets that are not at the head of
their queues, throughput can be substantially improved (not
FCFS)
Example: input 1 1 2
input 2 3 2
input 3 4 3
input 4 4 2
Eytan Modiano
Slide 24
Backlog matrix
output
1 2 3
1 3 3 0
input 2 2 0 0
3 0 0 2
1 1
2 2
3 3
• Alternatives
– Sub-optimal solutions
– Maximal matching: A matching that cannot be made any larger for a
given backlog matrix
(1-1,3-3) is maximal
(2-1,1-2,3-3) is maximum
Eytan Modiano
Slide 27
Achieving 100% throughput
Eytan Modiano
Slide 28