Nothing Special   »   [go: up one dir, main page]

skip to main content
10.1145/1356058.1356062acmconferencesArticle/Chapter ViewAbstractPublication PagescgoConference Proceedingsconference-collections
research-article

Phase-based adaptive recompilation in a JVM

Published: 06 April 2008 Publication History

Abstract

Modern JIT compilers often employ multi-level recompilation strategies as a means of ensuring the most used code is also the most highly optimized, balancing optimization costs and expected future performance. Accurate selection of code to compile and level of optimization to apply is thus important to performance. In this paper we investigate the effect of an improved recompilation strategy for a Java virtual machine. Our design makes use of a lightweight, low-level profiling mechanism to detect high-level, variable length phases in program execution. Phases are then used to guide adaptive recompilation choices, improving performance. We develop both an offline implementation based on trace data and a self-contained online version. Our offline study shows an average speedup of 8.7% and up to 21%, and our online system achieves an average speedup of 4.4%, up to 18%. We subject our results to extensive analysis and show that our design achieves good overall performance with high consistency despite the existence of many complex and interacting factors in such an environment.

References

[1]
B. Alpern, C. R. Attanasio, A. Cocchi, D. Lieber, S. Smith, T. Ngo, J. J. Barton, S. F. Hummel, J. C. Sheperd, and M. Mergen. Implementing Jalapeno in Java. In OOPSLA ’99, pages 314--324, Oct. 1999.
[2]
B. Alpern, S. Augart, S. M. Blackburn, M. Butrico, A. Cocchi, P. Cheng, J. Dolby, S. Fink, D. Grove, M. Hind, K. S. McKinley, M. Mergen, J. E. B. Moss, T. Ngo, V. Sarkar, and M. Trapp. The Jikes Research Virtual Machine project: Building an open-source research community. IBM Systems Journal, 44(2):399--417, Apr. 2005.
[3]
M. Arnold, S. Fink, D. Grove, M. Hind, and P. F. Sweeney. Adaptive optimization in the Jalapeno JVM. ACM SIG­PLAN Notices, 35(10):47--65, 2000.
[4]
M. Arnold, A. Welc, and V. T. Rajan. Improving virtual machine performance using a cross-run profile repository. In OOPSLA ’05, pages 297--311, 2005.
[5]
R. Balasubramonian, D. H. Albonesi, A. Buyuktosunoglu, and S. Dwarkadas. Memory hierarchy reconfiguration for energy and performance in general purpose architectures. In MICRO 33rd, pages 245--257, Dec. 2000.
[6]
R. D. Barnes, E. M. Nystrom, M. C. Merten, and W. mei W. Hwu. Vacuum packing: extracting hardware-detected program phases for post-link optimization. In MICRO 35th, pages 233--244, 2002.
[7]
S. Brown, J. Dongarra, N. Garner, K. London, and P. Mucci. PAPI. riptsizehttp://icl.cs.utk.edu/papi.
[8]
D. C. Burger and T. M. Austin. The SimpleScalar tool set, version 2.0. Technical Report CS-TR-1997-1342, 1997.
[9]
D. Buytaert, A. Georges, M. Hind, M. Arnold, L. Eeckhout, and K. D. Bosschere. Using HPM-Sampling to drive dynamic compilation. In OOPLSA ’07, Oct. 2007.
[10]
J. Cavazos, G. Fursin, F. Agakov, E. Bonilla, M. F. P. O’Boyle, and O. Temam. Rapidly selecting good compiler optimizations using performance counters. In CGO ’07, pages 185--197, Washington, DC, USA, 2007. IEEE Computer Society.
[11]
C. Chambers and D. Ungar. Making pure object-oriented languages practical. In OOPSLA ’91, pages 1--15, 1991.
[12]
T. M. Chilimbi and M. Hirzel. Dynamic hot data stream prefetching for general-purpose programs. In PLDI ’02, pages 199--209, New York, NY, USA, 2002. ACM Press.
[13]
M. Cierniak, M. Eng, N. Glew, B. Lewis, and J. Stichnoth. The open runtime platform: a flexible high-performance managed runtime environment: Research articles. Concurr. Comput.: Pract. Exper., 17(5--6):617--637, 2005.
[14]
D. Detlefs and O. Agesen. The case for multiple compilers. In OOPSLA’99 Workshop on Peformance Portability, and Simplicity in Virtual Machine Design, pages 180---194, 1999.
[15]
A. S. Dhodapkar and J. E. Smith. Managing multi-configuration hardware via dynamic working set analysis. In ISCA ’02, pages 233--244, 2002.
[16]
A. S. Dhodapkar and J. E. Smith. Comparing program phase detection techniques. In Proceedings of the 36th Annual IEEE/ACM International Symposium on Microarchitecture, page 217. IEEE Computer Society, 2003.
[17]
A. Georges, D. Buytaert, L. Eeckhout, and K. D. Bosschere. Method-level phase behavior in Java workloads. In OOPSLA ’04, pages 270--287, Oct. 2004.
[18]
D. Gu, C. Verbrugge, and E. Gagnon. Relative factors in performance analysis of Java virtual machines. In VEE ’06, pages 111--121, June 2006.
[19]
G. J. Hansen. Adaptive Systems for the Dynamic Run-time Optimization of Programs. PhD thesis, Carnegie-Mellon University, 1974.
[20]
M. J. Hind, V. T. Rajan, and P. F. Sweeney. Phase shift detection: A problem classification. Technical Report IBM Research Report RC-22887, IBM T. J. Watson, August 2003.
[21]
U. Hölzle and D. Ungar. Reconciling responsiveness with performance in pure object--oriented languages. ACM Trans. Program. Lang. Syst., 18(4):355--400, 1996.
[22]
M. C. Huang, J. Renau, and J. Torrellas. Positional adaptation of processors: application to energy reduction. In ISCA ’03, pages 157--168, New York, NY, USA, 2003. ACM Press.
[23]
H.--S. Kim and J. E. Smith. Dynamic software trace caching. In the 30th International Symposium on Computer Architecture (ISCA 2003), 2003.
[24]
T. Kistler and M. Franz. Continuous program optimization: A case study. ACM Trans. Program. Lang. Syst., 25(4):500---548, 2003.
[25]
C. Krintz. Coupling on-line and off-line profile information to improve program performance. In CGO ’03, pages 69--78, 2003.
[26]
J. Lau, E. Perelman, G. Hamerly, T. Sherwood, and B. Calder. Motivation for variable length intervals to find hierarchical phase behavior. In ISPASS’05, March 2005.
[27]
J. Lau, J. Sampson, E. Perelman, G. Hamerly, and B. Calder. The strong correlation between code signatures and performance. In ISPASS ’05, page 220, March 2005.
[28]
T. Lindholm and F. Yellin. The Java Virtual Machine Specification. Addison-Wesley, second edition, 1999.
[29]
P. Nagpurkar, M. Hind, C. Krintz, P. Sweeney, and V. Rajan. Online phase detection algorithms. In CGO ’06, Washington, DC, USA, March 2006. IEEE Computer Society.
[30]
P. Nagpurkar, C. Krintz, and T. Sherwood. Phase-aware remote profiling. In CGO ’05, pages 191--202, 2005.
[31]
M. Paleczny, C. A. Vick, and C. Click. The Java HotSpot server compiler. In Java Virtual Machine Research and Technology Symposium, pages 1--12, 2001.
[32]
R. M. Rabbah, H. Sandanagobalane, M. Ekpanyapong, and W.-F. Wong. Compiler orchestrated prefetching via speculation and predication. In ASPLOS-XI, pages 189--198, Oct. 2004.
[33]
F. Schneider and T. R. Gross. Using platform-specific performance counters for dynamic compilation. In LCPC’05, October 2005.
[34]
X. Shen, Y. Zhong, and C. Ding. Locality phase prediction. SIGPLAN Not., 39(11):165--176, 2004.
[35]
T. Sherwood, E. Perelman, and B. Calder. Basic block distribution analysis to find periodic behavior and simulation points in applications. In PACT ’01, pages 3--14, 2001.
[36]
M. M. Strout, L. Carter, and J. Ferrante. Compile-time composition of run-time data and iteration reorderings. SIGPLAN Not., 38(5):91--102, 2003.
[37]
T. Suganuma, T. Yasue, M. Kawahito, H. Komatsu, and T. Nakatani. A dynamic optimization framework for a Java just-in-time compiler. In OOPSLA ’01, pages 180---195, 2001.
[38]
P. F. Sweeney, M. Hauswirth, B. Cahoon, P. Cheng, A. Diwan, D. Grove, and M. Hind. Using hardware performance monitors to understand the behavior of Java applications. In VM’04, May 2004.
[39]
R. Vallee-Rai, P. Co, E. Gagnon, L. Hendren, P. Lam, and V. Sundaresan. Soot - a Java bytecode optimization framework. In CASCON ’99, page 13. IBM Press, 1999.
[40]
J. Whaley. Partial method compilation using dynamic profile information. In OOPSLA ’01, pages 166--179, New York, NY, USA, 2001. ACM Press.

Cited By

View all
  • (2023)Software Mining -- Investigating Correlation between Source Code Features and Michrobenchmark's Steady StateCompanion of the 2023 ACM/SPEC International Conference on Performance Engineering10.1145/3578245.3584695(107-111)Online publication date: 15-Apr-2023
  • (2018)Run-time program-specific phase prediction for python programsProceedings of the 15th International Conference on Managed Languages & Runtimes10.1145/3237009.3237011(1-10)Online publication date: 12-Sep-2018
  • (2018)PAYJIT: space-optimal JIT compilation and its practical implementationProceedings of the 27th International Conference on Compiler Construction10.1145/3178372.3179523(71-81)Online publication date: 24-Feb-2018
  • Show More Cited By

Index Terms

  1. Phase-based adaptive recompilation in a JVM

    Recommendations

    Comments

    Please enable JavaScript to view thecomments powered by Disqus.

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    CGO '08: Proceedings of the 6th annual IEEE/ACM international symposium on Code generation and optimization
    April 2008
    235 pages
    ISBN:9781595939784
    DOI:10.1145/1356058
    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]

    Sponsors

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 06 April 2008

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. adaptive optimization
    2. hardware counters
    3. java
    4. runtime technique
    5. virtual machine

    Qualifiers

    • Research-article

    Conference

    CGO '08

    Acceptance Rates

    CGO '08 Paper Acceptance Rate 21 of 66 submissions, 32%;
    Overall Acceptance Rate 312 of 1,061 submissions, 29%

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)6
    • Downloads (Last 6 weeks)1
    Reflects downloads up to 12 Nov 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2023)Software Mining -- Investigating Correlation between Source Code Features and Michrobenchmark's Steady StateCompanion of the 2023 ACM/SPEC International Conference on Performance Engineering10.1145/3578245.3584695(107-111)Online publication date: 15-Apr-2023
    • (2018)Run-time program-specific phase prediction for python programsProceedings of the 15th International Conference on Managed Languages & Runtimes10.1145/3237009.3237011(1-10)Online publication date: 12-Sep-2018
    • (2018)PAYJIT: space-optimal JIT compilation and its practical implementationProceedings of the 27th International Conference on Compiler Construction10.1145/3178372.3179523(71-81)Online publication date: 24-Feb-2018
    • (2016)Real-Time Program-Specific Phase Change Detection for Java ProgramsProceedings of the 13th International Conference on Principles and Practices of Programming on the Java Platform: Virtual Machines, Languages, and Tools10.1145/2972206.2972221(1-11)Online publication date: 29-Aug-2016
    • (2016)Flow-sensitive runtime estimationSoftware—Practice & Experience10.1002/spe.231546:6(841-864)Online publication date: 1-Jun-2016
    • (2014)Finding the limitACM SIGARCH Computer Architecture News10.1145/2654822.254194542:1(607-622)Online publication date: 24-Feb-2014
    • (2014)Finding the limitACM SIGPLAN Notices10.1145/2644865.254194549:4(607-622)Online publication date: 24-Feb-2014
    • (2014)Finding the limitProceedings of the 19th international conference on Architectural support for programming languages and operating systems10.1145/2541940.2541945(607-622)Online publication date: 24-Feb-2014
    • (2013)Exploring single and multilevel JIT compilation policy for modern machines 1ACM Transactions on Architecture and Code Optimization10.1145/2541228.254122910:4(1-29)Online publication date: 1-Dec-2013
    • (2013)Cloud platforms and embedded computingProceedings of the 50th Annual Design Automation Conference10.1145/2463209.2488826(1-6)Online publication date: 29-May-2013
    • Show More Cited By

    View Options

    Get Access

    Login options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media