Efficient Lock Algorithm for Shared Objects in SMP Environments

We propose a new algorithm that is effective for objects that are shared among threads but are not contended for in SMP environments. We can remove the overhead of the serialization between lock and other non-lock operations and avoid the latency of complex atomic operations in most cases. We established the safety of the algorithm by using a software tool called Spin. The experimental results from our benchmarking on an SMP machine using Intel Xeon processors revealed that our algorithm could significantly improve efficiency by 80% on average compared to using complex atomic instruction.

[1]  David Dice,et al.  Implementing Fast Java Monitors with Relaxed-Locks , 2001, Java Virtual Machine Research and Technology Symposium.

[2]  Kiyokuni Kawachiya,et al.  Lock reservation: Java locks can mostly do without atomic operations , 2002, OOPSLA '02.

[3]  Rajiv Arora,et al.  Java server performance: A case study of building efficient, scalable Jvms , 2000, IBM Syst. J..

[4]  Kiyokuni Kawachiya,et al.  A study of locking objects with bimodal fields , 1999, OOPSLA '99.

[5]  Erez Petrank,et al.  Thread-local heaps for Java , 2002, MSP/ISMM.

[6]  James H. Anderson,et al.  Shared-memory mutual exclusion: major research trends since 1986 , 2003, Distributed Computing.

[7]  Toshio Nakatani,et al.  TO-Lock: removing lock overhead using the owners' temporal locality , 2004, Proceedings. 13th International Conference on Parallel Architecture and Compilation Techniques, 2004. PACT 2004..

[8]  Michael H. Kalantar,et al.  Java server benchmarks , 2000, IBM Syst. J..

[9]  Mauricio J. Serrano,et al.  Thin locks: featherweight synchronization for Java , 1998, PLDI '98.

[10]  Leslie Lamport,et al.  A fast mutual exclusion algorithm , 1987, TOCS.

[11]  Laurie J. Hendren,et al.  SableVM: A Research Framework for the Efficient Execution of Java Bytecode , 2001, Java Virtual Machine Research and Technology Symposium.

[12]  Mike Johnson,et al.  Superscalar microprocessor design , 1991, Prentice Hall series in innovative technology.

[13]  Y. S. Ramakrishna,et al.  An efficient meta-lock for implementing ubiquitous synchronization , 1999, OOPSLA '99.

[14]  Kiyokuni Kawachiya,et al.  Lock Reservation for Java Reconsidered , 2004, ECOOP.