Presentation is loading. Please wait.

Presentation is loading. Please wait.

Local-spin, Abortable Mutual Exclusion Joe Rideout.

Similar presentations


Presentation on theme: "Local-spin, Abortable Mutual Exclusion Joe Rideout."— Presentation transcript:

1 Local-spin, Abortable Mutual Exclusion Joe Rideout

2 Outline Review - Mutual Exclusion Current themes Measuring efficiency Abortability Summary of current results Open problems Summary

3 Outline Review - Mutual ExclusionReview - Mutual Exclusion Current themes Measuring efficiency Abortability Summary of current results Open problems Summary

4 Mutual Exclusion a shared resource of critical importance should be used by at most one person at any one time! (exclusion) if someone is waiting to get in, he/she should eventually get access (starvation- freedom)

5 A Violation of Mutual Exclusion

6 More formally… Exclusion - If a process p is in the CS, then no process q≠p is in the CS concurrently with p. Starvation Freedom - If a process p enters the trying protocol, then p eventually enters the CS Bounded Exit - If a process enters the EP, it returns to the NCS in a bounded number of its own steps. while true do Noncritical Section (NCS); Entry Section; Critical Section (CS); Exit Protocol (EP) od

7 Early Solutions Dijkstra, Livelock free Knuth, Starvation free Lamport, Bakery Algorithm

8 Outline Review - Mutual Exclusion Current themesCurrent themes Measuring efficiency Abortability Summary of current results Open problems Summary

9 Hasn’t this been solved? Time efficiency Local-spin, “fast” and adaptive mutual exclusion Use of primitives Read/Write vs. Read-modify-write Variations Group and abortable mutual exclusion

10 Hasn’t this been solved? Time efficiency Local-spin, “fast” and adaptive mutual exclusion Use of primitives Read/Write vs. Read-modify-write Variations Group and abortable mutual exclusion

11 Outline Review - Mutual Exclusion Recent themes Measuring efficiencyMeasuring efficiency Abortability Summary of current results Open problems Summary

12 Time Complexity What is a good measure of efficiency? Number of steps taken in entry/exit sections? No. Busy-waiting will make these unbounded. Better: number of remote memory references

13 Two architectural Paradigms

14 Remote Memory References (RMR) References that cause an interconnect traversal In DSM… reading/writing the memory of another process In CC… writing or reading an updated value We speak of RMR time complexity

15 Local-spin A mutual exclusion algorithm is local- spin if it makes a bounded number of RMRs in its entry and exit protocols In other words, “spin variables” that are repeatedly tested must be local or locally cached

16 Outline Review - Mutual Exclusion Recent themes Measuring efficiency AbortabilityAbortability Summary of current results Open problems Summary

17 Abortable Mutual Exclusion A process can abort its attempt to acquire a lock Need arises in database and realtime systems Bounded abort - after a process p enters the Abort section it leaves the Abort section within a bounded number of its own steps.

18 Outline Review - Mutual Exclusion Recent themes Measuring efficiency Abortability Summary of current resultsSummary of current results Open problems Summary

19 Current Results Read/WriteRead-modify-write Local-spinO(logN) RMR † O(1) RMR ‡ Abortable / Local-spin ?O(logN) RMR ¥ † J.-H. Yang and J. Anderson. A fast, scalable mutual exclusion algorithm. Distributed Computing, 9(1):51- 60, August ‡ J. Mellor-Crummey and M. Scott. Algorithms for scalable synchronization on shared-memory multi- processors. ACM Transactions on Computer Systems, 9(1):21-65, Februaru ¥ P. Jayanti. Adaptive and Efficient Abortable Mutual Exclusion. Proceedings of the 22nd Annual Symposium on Principles of Distributed Computing, July 2003,

20 Current Results + Lower Bounds Read/WriteRead-modify-write Local-spinO(logN) RMR Ω(logN/loglogN) † O(1) RMR Ω(1) Abortable / Local-spin ? Ω(logN/loglogN) † O(logN) RMR Ω(1) † J. Anderson and Y,-J. Kim. An improved lower bound for the time complexity of mutual exclusion. In Proceedings of the 20th Annual ACM Symposium on Principles of Distributed Computing, pages 90-99, August 2001.

21 Outline Review - Mutual Exclusion Recent themes Measuring efficiency Abortability Summary of current results Open problemsOpen problems Summary

22 Open Problems Abortable mutual exclusion with O(1) RMR using read-modify-write primitives? Ω(logN) RMR lower bound for mutual exclusion using only read/write primitives? Abortable mutual exclusion with O(logN) RMR using only read/write primitives Modify the Yang-Anderson algorithm?

23 Open Problems Abortable mutual exclusion with O(1) RMR using read-modify-write primitives? Ω(logN) RMR lower bound for mutual exclusion using only read/write primitives? Abortable mutual exclusion with O(logN) RMR using only read/write primitives Modify the Yang-Anderson algorithm?

24 Outline Review - Mutual Exclusion Recent themes Measuring efficiency Abortability Summary of current results Open problems SummarySummary

25 Summary Mutual exclusion - classic but not dead Efficiency - RMR and local-spin Abortable - a property of interest Primitives - Read/Write vs. other Q: Can local-spin abortable mutual exclusion be achieved using only atomic reads and writes?

26


Download ppt "Local-spin, Abortable Mutual Exclusion Joe Rideout."

Similar presentations


Ads by Google