Lecture 09
Lecture 09
Process
Process Process
receive message
But what if …
read page 5
Process
Process Process
read page 5
In fact …
1. Message-passing can be implemented over DSM!
– Use a common page as buffer to read/write messages
2. DSM can be implemented over a message-passing network!
Process
Process Process
read page 5
DSM over Message-Passing Network
• Cache maintained at each process
– Cache stores pages accessed recently by that process
• Read/write first goes to cache
Process Process
Process
Cache Cache
Cache Process
Cache
DSM over Message-Passing Network (2)
Process 2 Process 3
Process 1
Process 2 Process 3
Process 1
page (R)
Process 1 Attempting a Read: Scenario 4
• Process 1 has page in R state
• Other processes also have page in R state, and someone else is owner
• Read from cache. No messages sent.
Process 2 Process 3
Process 1
page (R)
page (R) Process 4
Process 4
Process 2 Process 3
Process 1
page (R)
End State: Write Scenario 2
• Process 1 is owner (O) has page in R state
• Other processes may also have page in R state
• Ask other processes to invalidate their copies of page. Use multicast.
• Mark page as (W).
• Do write. Process 2
Process 1
page (W)(O)
Process 1 Attempting a Write: Scenario 3