Parallel Virtual Memory presanation
Parallel Virtual Memory presanation
7 0 1 2 0 3 0 4 2 3 0 3 1 2 0
7 7 7 2 2 2 2 4 4 4 0 0 0 0 0
0 0 0 0 3 3 3 2 2 2 2 1 1 1
1 1 1 1 0 0 0 3 3 3 3 2 2
7 0 1 2 0 3 0 4 2 3 0 3 1 2 0
7 7 7 2 2 2 2 4 4 4 0 0 0 2 2
0 0 0 0 0 0 0 0 3 3 3 3 3 0
1 1 1 3 3 3 2 2 2 2 1 1 1
OPTIMAL
- Replaces the page that won't be needed for the longest time
- Theoretically optimal, but impractical to implement
- Requires knowledge of future page accesses, which is impossible to
predict
- Used as a benchmark to evaluate other algorithms
7 0 1 2 0 3 0 4 2 3 0 3 2 1 2 0 1 7
7 7 7 2 2 2 2 2 2 2 2 2 2 2 2 2 2 7
0 0 0 0 0 0 4 4 4 0 0 0 0 0 0 0 0
1 1 1 3 3 3 3 3 3 3 3 3 1 1 1 1 1
Thrashing
It is a critical concept in virtual memory management!
- occurs when a system spends more time swapping pages between
memory and disk than executing actual processes.
This leads to
:1. High page fault rates
2. Excessive disk I/O
3. Reduced system performance
4. Increased CPU utilization (due to overhead of page replacement
Causes of Thrashing
1. Insufficient memory
2. Poor page replacement algorithms
3. High page reuse rates
4. Overcommitting memory to processes
Symptoms ofThrashing
:1. System slowdown
2. High disk activity
3. Increased CPU usage
Solutions to Thrashing:
1. Increase physical memory
2. Implement efficient page replacement algorithms (e.g., LRU, Clock)
3. Reduce page size
4. Use memory-mapped files or shared memory
5. Optimize application memory usageThrashing is a common issue in
systems with limited memory or poor memory management.