skip to main content
10.1145/1735997.1736005acmconferencesArticle/Chapter ViewAbstractPublication PagesveeConference Proceedingsconference-collections
research-article

Improving compiler-runtime separation with XIR

Published:17 March 2010Publication History

ABSTRACT

Intense research on virtual machines has highlighted the need for flexible software architectures that allow quick evaluation of new design and implementation techniques. The interface between the compiler and runtime system is a principal factor in the flexibility of both components and is critical to enabling rapid pursuit of new optimizations and features. Although many virtual machines have demonstrated modularity for many components, significant dependencies often remain between the compiler and the runtime system components such as the object model and memory management system. This paper addresses this challenge with a carefully designed strict compiler-runtime interface and the XIR language. Instead of the compiler backend lowering object operations to machine operations using hard-wired runtime-specific logic, XIR allows the runtime system to implement this logic, simultaneously simplifying and separating the backend from runtime-system details. In this paper we describe the design and implementation of this compiler-runtime interface and the XIR language in the C1X dynamic compiler, a port of the HotSpotTM Client compiler. Our results show a significant reduction in backend complexity with XIR and an overall reduction in the compiler-runtime interface complexity while still generating comparable quality code with only minor impact on compilation time.

References

  1. Jikes RVM. http://jikesrvm.orgGoogle ScholarGoogle Scholar
  2. The Maxine VM. http://kenai.com/projects/maxineGoogle ScholarGoogle Scholar
  3. M. Arnold, S. Fink, V. Sarkar, and P.F. Sweeney. A Comparative Study of Static and Profile-Based Heuristics for Inlining. In Dynamic and Adaptive Compilation and Optimization (Dynamo '00). Boston, MA. January 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. M. Arnold and D. Grove. Collecting and Exploiting High-Accuracy Call-Graph Profiles in Virtual Machines. In International Symposium on Code Generation and Optimization (CGO '05). San Jose CA. March 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. D. Ancona, M. Ancona, A Cuni, and N. Matsakis. RPython: a Step Towards Reconciling Dynamically and Statically Typed OO Languages. In Dynamic Languages Symposium (DSL '07). Montreal, Canada. October 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. D. Bacon, S. Fink, and D. Grove. Space- and Time-efficient Implementation of the Java Object Model. In ECOOP '02, the 16th European Conference on Object-Oriented Programming, University of Malaga, Spain. June 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Blackburn, S. M., Garner, R., Hoffman, C., Khan, A. M., McKinley, K. S., Bentzur, R., Diwan, A., Feinberg, D., Frampton, D., Guyer, S. Z., Hirzel, M., Hosking, A., Jump, M., Lee, H., Moss, J. E. B., Phansalkar, A., Stefanovic, D., VanDrunen, T., von Dincklage, D., and Wiedermann, B. The DaCapo Benchmarks: Java Benchmarking Development and Analysis. In Object Oriented Programming, Systems, Languages, and Applications (OOPSLA '06). Portland, OR. October 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. C. Bolz and A. Rigo. How not to write Virtual Machines for Dynamic Languages. In Dynamic Languages and Applications (DYLA '07). Berlin, Germany. July 2007.Google ScholarGoogle Scholar
  9. M. Cierniak, N. Glew, S. Triantafyllis, M. Eng, B. Lewis, and J. Stichnoth. Object-Model Independence with Code Implants. In Multiparadigm Programming with Object Oriented Languages (MPOOL '03). Anaheim, CA. October 2003.Google ScholarGoogle Scholar
  10. C. Click and M. Paleczny. A Simple Graph-based Intermediate Representation. In ACM SIGPLAN Workshop on Intermediate Representations. San Francisco, CA. January 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. J. Dean, D. Grove, and C. Chambers. Optimization of Object-Oriented Programs using Static Class Hierarchy Analysis. In ECOOP '95, the 9th European Conference on Object-Oriented Programming. Aarhus, Denmark. August 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. A. Diwan, K. McKinley, and J. E. Moss. Using Types to Analyze and Optimize Object-Oriented Programs. In ACM Transactions on Programming Languages and Systems, 23(1), 30--72. 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. D. Frampton, S. Blackburn, P. Cheng, R. Garner, D. Grove, J. Moss, S. Salishev. Demystifying magic: high-level low-level programming. In Virtual Execution Environments (VEE '09). Washington, DC. March 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. N. Glew, S. Triantafyllis, M. Cierniak, M. Eng, B. Lewis and J. Stichnoth. LIL: An Architecture--Neutral Language for Virtual-Machine Stubs. In 3rd Virtual Machine Research and Technology Symposium. San Jose, CA. May 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. K. Hazelwood and D. Grove. Adaptive online context-sensitive inlining. In International Symposium on Code Generation and Optimization (CGO '03). San Francisco, CA. March, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. D. Ingalls, T. Kaehler, J. Maloney, S. Wallace, and A. Kay. Back to the future: the story of Squeak, a practical Smalltalk written in itself. In Object Oriented Systems, Languages, and Applications (OOPSLA '97). Atlanta, GA. October 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. K. Ishizaki, M. Kawahito, T. Yasue, H. Komatsu, T. Nakatani. A Study of Devirtualization Techniques for a Java Just-in-time Compiler. In OOPSLA '00, the 15th Annual Conference on Object-Oriented Systems, Languages, and Applications. Minneapolis, MN. October 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. T. Kotzmann, C. Wimmer, H. Mossenbock, T. Rodriguez, K. Russell, and D. Cox. Design of the Java HotSpotTM client compiler for Java 6. In ACM Transactions on Architecture and Code Optimization (TACO), Volume 5, Issue 1. May 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. M. Paleczny, C. Vick, and C. Click. The JavaTM HotSpot Server Compiler. In JVM '01. Monterey CA. April 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. A. Rigo and S. Pedroni. PyPy's Approach to Virtual Machine Construction. In Dynamic Languages Symposium (DSL '06). Portland, OR. October 2006.Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. D. Ungar, A. Spitz, and A. Ausch. Constructing a meta-circular virtual machine in an exploratory programming environment. In Object Oriented Systems, Languages, and Applications (OOPSLA '05). San Diego, CA. October 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. D. Weise, R. Crew, M. Ernst, and B. Steensgaard. Value Dependency Graphs: Representation without Taxation. In Principles of Programming Languages (POPL '94). Portland, OR. January 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. C. Wimmer. Linear Scan register allocation for the Java HotSpot client compiler. Master's thesis, Institute for Systems Software, Johannes Kepler University Linz. 2004.Google ScholarGoogle Scholar
  24. G. Wright, M. Seidl, and M. Wolczko. An object-aware memory architecture. Science of Computer Programming 62(2): 145--163 (2006). Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. T. Wuerthinger, C. Wimmer, and H. Mossenbock. Array bounds check elimination in the context of deoptimization. In Science of Computer Programming, Volume 74, Issue 5-6. March 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Improving compiler-runtime separation with XIR

      Recommendations

      Reviews

      Rafael Corchuelo

      Titzer et al. identify that current virtual machines are not modular enough with regard to object models, synchronization mechanisms, and memory management systems, which implies that their runtimes and compilers are too tightly coupled. The conclusion is that it is not easy to evolve them separately, which hinders the work on new code generation techniques and optimizations. The authors propose a set of interfaces and a language called XIR. The interfaces provide a layer of abstraction between runtimes and compilers. In other words, compilers may abstract from the runtime representation of types, classes, methods, and fields; similarly, runtimes may abstract from compilers by means of a number of interfaces that represent intermediate code, exception handler tables, reference maps, and deoptimization information. XIR is an intermediate language that is specifically devised for runtime designers. The authors present a number of experiments that prove that their results do not have a significant impact on compilation times, but do reduce the complexity of the resulting compilers. In summary, this paper is very interesting for researchers who are working on compilers and virtual machines. The authors successfully present their ideas and it is very easy to understand the results. However, it should be noted that, since this is an overview paper, it does not provide too many details. Online Computing Reviews Service

      Access critical reviews of Computing literature here

      Become a reviewer for Computing Reviews.

      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
        VEE '10: Proceedings of the 6th ACM SIGPLAN/SIGOPS international conference on Virtual execution environments
        March 2010
        176 pages
        ISBN:9781605589107
        DOI:10.1145/1735997
        • cover image ACM SIGPLAN Notices
          ACM SIGPLAN Notices  Volume 45, Issue 7
          VEE '10
          July 2010
          161 pages
          ISSN:0362-1340
          EISSN:1558-1160
          DOI:10.1145/1837854
          Issue’s Table of Contents

        Copyright © 2010 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 ACM 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: 17 March 2010

        Permissions

        Request permissions about this article.

        Request Permissions

        Check for updates

        Qualifiers

        • research-article

        Acceptance Rates

        Overall Acceptance Rate28of72submissions,39%

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader