Download presentation
Presentation is loading. Please wait.
Published byDanuše Bláhová Modified over 6 years ago
1
Memory Management Algorithms Huan Liu, Damon Mosk-Aoyama
for DSM Switches Huan Liu, Damon Mosk-Aoyama
2
Distributed Shared Memory Switch
What is known (for FIFO) 2N is necessary 3N-1 is sufficient Questions: Can we close the gap? Possible to have an implementable algorithm?
3
Our main results On the gap On practical algorithms
Counter example to show 2.25N is necessary A heuristic that uses 2.5N memories On practical algorithms Simulation results on simple algorithms under Bernoulli i.i.d. traffic
4
… … The counter example Consider 4x4 switch
Can generalize to arbitrary N 3 4 1 2 1 2 … 5 5 Output 1 6 … 6 3 4 ? 7 7 8 8 Output 4
5
If we have N/4 more 1 1 1 6 6 Output 1 … 5 2 2 7 … 7 3 5 3 8 8 2 4 4 9 9 Output 4
6
Observation Greedily minimizing the number of memories used can lead to trouble Need to reuse memories later as time slot fills up 1 2 3 1 2 3 1 2 3 1 2 3 1 2 3 4 5 6 7 4
7
Heuristics with 2.5N memories
Minimize intersection between adjacent time slots Minimize intersection between neighboring pairs After N/2 cells arrived in a time slot, reuse memories already assigned to the adjacent time slot. Simulation has been running for 100M+ cycles with no problem Minimize intersection 5 6 1 2 3 4 1 2 1 2 1 6 2 4 3 4
8
…… Random algorithm Assign memories to arriving cells randomly
Drop if another cell using the memory is departing now departing in the future in the same time slot Si …… S2 S1
9
Upper bound on Drop Rate
Suppose there are memories. The drop probability is The drop rate can now be computed as: Use Si distribution from M/M/1
10
Fixed Arrival Rate
11
Fixed Number of Memories
12
Distributed random algorithm
Each packet makes independent decision Pick a random memory that is NOT departing now departing in the same time slot in the future If two arriving packets pick the same memory, we drop one
13
Distributed random algorithm - simulation
14
Centralized random algorithm
Assign each packet in turn Randomly pick a memory that is NOT departing now departing in the same time slot in the future assigned for other packets arriving at the same time
15
Centralized random algorithm - simulation
16
Conclusion Still gap more work
Better counter example? Prove 2.5N is sufficient Also gap between theory and practical algorithm
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.