Real-time multiprocessor locks with nesting: optimizing the common case

In prior work on multiprocessor real-time locking protocols, only protocols within the RNLP family support unrestricted lock nesting while guaranteeing asymptotically optimal priority-inversion blocking bounds. However, these protocols support nesting at the expense of increasing the cost of processing non-nested lock requests, which tend to be the common case in practice. To remedy this situation, a new fast-path mechanism is presented herein that extends prior RNLP variants by ensuring that non-nested requests are processed efficiently. This mechanism yields overhead and blocking costs for such requests that are nearly identical to those seen in the most efficient single-resource locking protocols. In experiments, the proposed fast-path mechanism enabled observed blocking times for non-nested requests that were up to 18 times lower than under an existing RNLP variant and improved schedulability over that variant and a simple group lock.

[1]  James H. Anderson,et al.  Replica-Request Priority Donation: A Real-Time Progress Mechanism for Global Locking Protocols , 2012, 2012 IEEE International Conference on Embedded and Real-Time Computing Systems and Applications.

[2]  Björn B. Brandenburg The FMLP+: An Asymptotically Optimal Real-Time Locking Protocol for Suspension-Aware Analysis , 2014, 2014 26th Euromicro Conference on Real-Time Systems.

[3]  Thomas Nolte,et al.  Per Processor Spin-Based Protocols for Multiprocessor Real-Time Systems , 2017, Leibniz Trans. Embed. Syst..

[4]  Theodore P. Baker,et al.  Stack-based scheduling of realtime processes , 1991, Real-Time Systems.

[5]  Yuh-Jzer Joung,et al.  Asynchronous group mutual exclusion , 2000, Distributed Computing.

[6]  James H. Anderson,et al.  Scheduling and locking in multiprocessor real-time operating systems , 2011 .

[7]  James W. Havender Avoiding Deadlock in Multitasking Systems , 1968, IBM Syst. J..

[8]  Alan Burns,et al.  New schedulability analysis for MrsP , 2017, 2017 IEEE 23rd International Conference on Embedded and Real-Time Computing Systems and Applications (RTCSA).

[9]  Lui Sha,et al.  Priority Inheritance Protocols: An Approach to Real-Time Synchronization , 1990, IEEE Trans. Computers.

[10]  Tommaso Cucinotta,et al.  Analysis and implementation of the multiprocessor bandwidth inheritance protocol , 2012, Real-Time Systems.

[11]  James H. Anderson,et al.  The OMLP family of optimal multiprocessor real-time locking protocols , 2013, Des. Autom. Embed. Syst..

[12]  Bryan C. Ward Relaxing Resource-Sharing Constraints for Improved Hardware Management and Schedulability , 2015, 2015 IEEE Real-Time Systems Symposium.

[13]  James D. Schoeffler Real-time Systems , 1991 .

[14]  Thomas Nolte,et al.  Independently-Developed Real-Time Systems on Multi-cores with Shared Resources , 2011, 2011 23rd Euromicro Conference on Real-Time Systems.

[15]  Michael L. Scott,et al.  Algorithms for scalable synchronization on shared-memory multiprocessors , 1991, TOCS.

[16]  Hennadiy Leontyev,et al.  A Flexible Real-Time Locking Protocol for Multiprocessors , 2007, 13th IEEE International Conference on Embedded and Real-Time Computing Systems and Applications (RTCSA 2007).

[17]  Robert I. Davis,et al.  Reducing Queue Lock Pessimism in Multiprocessor Schedulability Analysis , 2010 .

[18]  Giuseppe Lipari,et al.  Minimizing memory utilization of real-time task sets in single and multi-processor systems-on-a-chip , 2001, Proceedings 22nd IEEE Real-Time Systems Symposium (RTSS 2001) (Cat. No.01PR1420).

[19]  Hiroaki Takada,et al.  Priority inheritance spin locks for multiprocessor real-time systems , 1996, Proceedings Second International Symposium on Parallel Architectures, Algorithms, and Networks (I-SPAN'96).

[20]  Tommaso Cucinotta,et al.  The Multiprocessor Bandwidth Inheritance Protocol , 2010, 2010 22nd Euromicro Conference on Real-Time Systems.

[21]  Ragunathan Rajkumar,et al.  Synchronization in Real-Time Systems: A Priority Inheritance Approach , 1991 .

[22]  Ragunathan Rajkumar,et al.  Coordinated Task Scheduling, Allocation and Synchronization on Multiprocessors , 2009, 2009 30th IEEE Real-Time Systems Symposium.

[23]  S. Vestal Preemptive Scheduling of Multi-criticality Systems with Varying Degrees of Execution Time Assurance , 2007, RTSS 2007.

[24]  Ragunathan Rajkumar,et al.  Synchronization in Real-Time Systems , 1991 .

[25]  James H. Anderson,et al.  Using Lock Servers to Scale Real-Time Locking Protocols: Chasing Ever-Increasing Core Counts , 2018, ECRTS.

[26]  Björn B. Brandenburg,et al.  Feather-Trace : A Light-Weight Event Tracing Toolkit ∗ , 2007 .

[27]  Mark Moir,et al.  A Simple Local-Spin Group Mutual Exclusion Algorithm , 2001, IEEE Trans. Parallel Distributed Syst..

[28]  Maurice Herlihy,et al.  Linearizability: a correctness condition for concurrent objects , 1990, TOPL.

[29]  James H. Anderson,et al.  A Comparison of the M-PCP, D-PCP, and FMLPon LITMUSRT , 2008, OPODIS.

[30]  Thomas Nolte,et al.  Resource sharing among prioritized real-time applications on multiprocessors , 2015, SIGBED.

[31]  Satish K. Tripathi,et al.  Multiprocessor priority ceiling based protocols , 1994 .

[32]  James H. Anderson,et al.  Spin-based reader-writer synchronization for multiprocessor real-time systems , 2010, Real-Time Systems.

[33]  James H. Anderson,et al.  An optimal k-exclusion real-time locking protocol motivated by multi-GPU systems , 2012, Real-Time Systems.

[34]  Sanjoy K. Baruah Techniques for Multiprocessor Global Schedulability Analysis , 2007, 28th IEEE International Real-Time Systems Symposium (RTSS 2007).

[35]  R. Rajkumar Real-time synchronization protocols for shared memory multiprocessors , 1990, Proceedings.,10th International Conference on Distributed Computing Systems.

[36]  Hiroaki Takada,et al.  Real-time scalability of nested spin locks , 1995, Proceedings Second International Workshop on Real-Time Computing Systems and Applications.

[37]  Bryan C. Ward Sharing Non-Processor Resources in Multiprocessor Real-Time Systems , 2016 .

[38]  Thomas Nolte,et al.  Flexible spin-lock model for resource sharing in multiprocessor real-time systems , 2014, Proceedings of the 9th IEEE International Symposium on Industrial Embedded Systems (SIES 2014).

[39]  Alexander Wieder,et al.  On the Complexity of Worst-Case Blocking Analysis of Nested Critical Sections , 2014, 2014 IEEE Real-Time Systems Symposium.

[40]  Giuseppe Lipari,et al.  A comparison of MPCP and MSRP when sharing resources in the Janus multiple-processor on a chip platform , 2003, The 9th IEEE Real-Time and Embedded Technology and Applications Symposium, 2003. Proceedings..

[41]  Alan Burns,et al.  A Schedulability Compatible Multiprocessor Resource Sharing Protocol -- MrsP , 2013, 2013 25th Euromicro Conference on Real-Time Systems.

[42]  David Lorge Parnas,et al.  Concurrent control with “readers” and “writers” , 1971, CACM.

[43]  James H. Anderson,et al.  Real-time resource-sharing under clustered scheduling: mutex, reader-writer, and k-exclusion locks , 2011, 2011 Proceedings of the Ninth ACM International Conference on Embedded Software (EMSOFT).

[44]  Alexander Wieder,et al.  A Blocking Bound for Nested FIFO Spin Locks , 2016, 2016 IEEE Real-Time Systems Symposium (RTSS).

[45]  Alexander Wieder,et al.  Global Real-Time Semaphore Protocols: A Survey, Unified Analysis, and Comparison , 2015, 2015 IEEE Real-Time Systems Symposium.

[46]  Alan Burns,et al.  Supporting Nested Resources in MrsP , 2017, Ada-Europe.

[47]  James H. Anderson,et al.  Supporting Nested Locking in Multiprocessor Real-Time Systems , 2012, 2012 24th Euromicro Conference on Real-Time Systems.

[48]  Alexander Wieder,et al.  On Spin Locks in AUTOSAR: Blocking Analysis of FIFO, Unordered, and Priority-Ordered Spin Locks , 2013, 2013 IEEE 34th Real-Time Systems Symposium.

[49]  James H. Anderson,et al.  Fine-grained multiprocessor real-time locking with improved blocking , 2013, RTNS '13.

[50]  Thomas Nolte,et al.  An optimal spin-lock priority assignment algorithm for real-time multi-core systems , 2017, 2017 IEEE 23rd International Conference on Embedded and Real-Time Computing Systems and Applications (RTCSA).

[51]  James H. Anderson,et al.  Real-time multiprocessor locks with nesting: optimizing the common case , 2017, Real-Time Systems.

[52]  Lui Sha,et al.  Real-time synchronization protocols for multiprocessors , 1988, Proceedings. Real-Time Systems Symposium.

[53]  Kang G. Shin,et al.  Improving Wait-Free Algorithms for Interprocess Communication in Embedded Real-Time Systems , 2002, USENIX Annual Technical Conference, General Track.

[54]  Xue Liu,et al.  Integrating Adaptive Components: An Emerging Challenge in Performance-Adaptive Systems and a Server Farm Case-Study , 2007, 28th IEEE International Real-Time Systems Symposium (RTSS 2007).

[55]  James H. Anderson,et al.  An Implementation of the PCP, SRP, D-PCP, M-PCP, and FMLP Real-Time Synchronization Protocols in LITMUS^RT , 2008, 2008 14th IEEE International Conference on Embedded and Real-Time Computing Systems and Applications.

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

[57]  Thomas Nolte,et al.  Integrating independently developed real-time applications on a shared multi-core architecture , 2013, SIGBED.

[58]  James H. Anderson,et al.  A contention-sensitive fine-grained locking protocol for multiprocessor real-time systems , 2015, RTNS.

[59]  James H. Anderson,et al.  Multi-resource Real-Time Reader/Writer Locks for Multiprocessors , 2014, 2014 IEEE 28th International Parallel and Distributed Processing Symposium.