skip to main content
10.1145/3281287.3281293acmconferencesArticle/Chapter ViewAbstractPublication PagessplashConference Proceedingsconference-collections
research-article

Efficient VM-independent runtime checks for parallel programming

Published:04 November 2018Publication History

ABSTRACT

Many concurrent or parallel programming languages rely on runtime checking to ensure safety. To implement such a language on a virtual machine (VM), such runtime checks are often implemented in a VM-independent way, using source-to-source translation or bytecode instrumentation. This approach avoids modifying complex VM components like the just-in-time (JIT) compiler and offers great portability. However, obtaining good performance is challenging, as the approach cannot profit from custom JIT optimizations to eliminate redundant checks.

In this paper, we present and evaluate two techniques to make the VM-independent approach efficient, using the example of a parallel programming language called Rolez. To guarantee that concurrent threads do not interfere, Rolez relies heavily on runtime checks: for every field access, the runtime system checks that the state of the target object currently permits this operation (unless the check is optimized away). The Rolez compiler we present here generates standard Java source code and the runtime system is implemented as a Java library. Nevertheless, many Rolez programs deliver performance roughly on par with manually synchronized Java implementations, which is achieved using these two techniques: 1) code-managed runtime data, which improves runtime check efficiency by passing performance-critical information from method to method, and 2) an interprocedural but modular concurrency analysis, which eliminates many runtime checks that are actually redundant.

References

  1. Martin Bättig and Thomas R. Gross. 2017. Synchronized-by-Default Concurrency for Shared-Memory Systems. In Proceedings of the 22Nd ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP ’17) . ACM, New York, NY, USA, 299–312. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Robert L. Bocchino, Vikram S. Adve, Sarita V. Adve, and Marc Snir. 2009. Parallel Programming Must Be Deterministic by Default. In Proceedings of the 1st USENIX Conference on Hot Topics in Parallelism (HotPar ’09) . USENIX Association, Berkeley. http://dl.acm.org/citation. cfm?id=1855591.1855595 Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Jack W. Davidson and Anne M. Holler. 1992. Subprogram Inlining: A Study of Its Effects on Program Execution Time. IEEE Trans. Softw. Eng. 18, 2 (Feb. 1992), 89–102. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Eclipse Foundation. 2006. Xtext. http://www.eclipse.org/Xtext/Google ScholarGoogle Scholar
  5. Michael Faes and Thomas R. Gross. 2017. Parallel Roles for Practical Deterministic Parallel Programming. In Proceedings of the 30th International Workshop on Languages and Compilers for Parallel Computing (LCPC ’17) .Google ScholarGoogle Scholar
  6. Maurice Herlihy and J. Eliot B. Moss. 1993. Transactional Memory: Architectural Support for Lock-Free Data Structures. In Proceedings of the 20th Annual International Symposium on Computer Architecture (ISCA ’93) . ACM, New York, 289–300. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Benjamin Hindman and Dan Grossman. 2006. Atomicity via Sourceto-Source Translation. In Proceedings of the 2006 Workshop on Memory System Performance and Correctness (MSPC ’06) . ACM, New York, NY, USA, 82–91. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. Guy Korland, Nir Shavit, and Pascal Felber. 2010. Noninvasive Concurrency with Java STM. In Programmability Issues for Heterogeneous Multicores (MultiProg 2010) . https://sites.google.com/site/deucestm/ documentationGoogle ScholarGoogle Scholar
  9. Flemming Nielson, Hanne R. Nielson, and Chris Hankin. 1999. Principles of Program Analysis . Springer-Verlag New York, Inc., Secaucus, NJ, USA. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Filip Pizlo, Erez Petrank, and Bjarne Steensgaard. 2008. Path Specialization: Reducing Phased Execution Overheads. In Proceedings of the 7th International Symposium on Memory Management (ISMM ’08) . ACM, New York, NY, USA, 81–90. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Stephen Richardson and Mahadevan Ganapathi. 1989. Interprocedural Analysis vs. Procedure Integration. Inf. Process. Lett. 32, 3 (Aug. 1989), 137–142. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Atanas Rountev. 2005. Component-Level Dataflow Analysis. In Proceedings of the 8th International Conference on Component-Based Software Engineering (CBSE’05) . Springer-Verlag, Berlin, Heidelberg, 82–89. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Atanas Rountev, Scott Kagan, and Thomas Marlowe. 2006. Interprocedural Dataflow Analysis in the Presence of Large Libraries. In Proceedings of the 15th International Conference on Compiler Construction (CC’06) . Springer-Verlag, Berlin, Heidelberg, 2–16. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Micha Sharir and Amir Pnueli. 1981. Two Approaches to Interprocedural Data Flow Analysis. In Program Flow Analysis: Theory and Applications . 189–234.Google ScholarGoogle Scholar
  15. Nir Shavit and Dan Touitou. 1995. Software Transactional Memory. In Proceedings of the 14th Annual ACM Symposium on Principles of Distributed Computing (PODC ’95) . ACM, New York, 204–213. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. L. A. Smith, J. M. Bull, and J. Obdrzálek. 2001. A Parallel Java Grande Benchmark Suite. In Proceedings of the 2001 ACM/IEEE Conference on Supercomputing (SC ’01) . ACM, New York, NY, USA, 8–8. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Richard M. Yoo, Yang Ni, Adam Welc, Bratin Saha, Ali-Reza AdlTabatabai, and Hsien-Hsin S. Lee. 2008. Kicking the Tires of Software Transactional Memory: Why the Going Gets Tough. In Proceedings of the 20th Annual Symposium on Parallelism in Algorithms and Architectures (SPAA ’08) . ACM, New York, NY, USA, 265–274. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Efficient VM-independent runtime checks for parallel programming

            Recommendations

            Comments

            Login options

            Check if you have access through your login credentials or your institution to get full access on this article.

            Sign in
            • Published in

              cover image ACM Conferences
              VMIL 2018: Proceedings of the 10th ACM SIGPLAN International Workshop on Virtual Machines and Intermediate Languages
              November 2018
              66 pages
              ISBN:9781450360715
              DOI:10.1145/3281287

              Copyright © 2018 ACM

              Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 4 November 2018

              Permissions

              Request permissions about this article.

              Request Permissions

              Check for updates

              Qualifiers

              • research-article

              Acceptance Rates

              Overall Acceptance Rate4of4submissions,100%

              Upcoming Conference

            • Article Metrics

              • Downloads (Last 12 months)6
              • Downloads (Last 6 weeks)0

              Other Metrics

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader