Abstract
This paper describes our multi-level compilation techniques implemented in a trace-based Java JIT compiler (trace-JIT). Like existing multi-level compilation for method-based compilers, we start JIT compilation with a small compilation scope and a low optimization level so the program can start running quickly. Then we identify hot paths with a timer-based sampling profiler, generate long traces that capture the hot paths, and recompile them with a high optimization level to improve the peak performance. A key to high performance is selecting long traces that effectively capture the entire hot paths for upgrade recompilations. To do this, we introduce a new technique to generate a directed graph representing the control flow, a TTgraph, and use the TTgraph in the trace selection engine to efficiently select long traces. We show that our multi-level compilation improves the peak performance of programs by up to 58.5% and 22.2% on average compared to compiling all of the traces only at a low optimization level. Comparing the performance with our multi-level compilation to the performance when compiling all of the traces at a high optimization level, our technique can reduce the startup times of programs by up to 61.1% and 31.3% on average without significant reduction in the peak performance. Our results show that our adaptive multi-level compilation can balance the peak performance and startup time by taking advantage of different optimization levels.
- P. Wu, H. Hayashizaki, H. Inoue, and T. Nakatani, "Reducing Trace Selection Footprint for Large-scale Java Applications with no Performance Loss", in Proceedings of the ACM Object-Oriented Programming, Systems, Languages & Applications, pp. 789--804, 2011. Google Scholar
Digital Library
- M. Paleczny, C. Vick, and C. Click, "The Java Hotspot(tm) Server Compiler", in Proceedings of the USENIX Java Virtual Machine Research and Technology Symposium, pp. 1--12, 2001. Google Scholar
Digital Library
- N. Grcevski, A. Kielstra, K. Stoodley, M. Stoodley, and V. Sundaresan. "Java just-in-time compiler and virtual machine improvements for server and middleware applications". In Proceedings of the USENIX Virtual Machine Research and Technology Symposium, pp. 151--162, 2004. Google Scholar
Digital Library
- T. Suganuma, T. Yasue, M. Kawahito, H. Komatsu, and T. Nakatani, "A dynamic optimization framework for a Java just-in-time compiler", in Proceedings of the ACM Conference on Object-Oriented Programming Systems, Languages, and Applications, pp. 180--195, 2001. Google Scholar
Digital Library
- M. Arnold, S. Fink, D. Grove, M. Hind, and P. F. Sweeney. "Adaptive optimization in the Jalapeño JVM", in Proceedings of the ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications. pp. 47--65. 2000. Google Scholar
Digital Library
- H. Inoue, H. Hayashizaki, P. Wu, and T. Nakatani, "A Trace-based Java JIT Compiler Retrofitted from a Method-based Compiler", in Proceedings of the International Symposium on Code Generation and Optimization, pp. 246--256, 2011. Google Scholar
Digital Library
- V. Bala, E. Duesterwald, and S. Banerjia, "Dynamo: A Transparent Runtime Optimization System," in Proceedings of the ACM Programming Language Design and Implementation, pp. 1--12, 2000. Google Scholar
Digital Library
- T. Mytkowicz, A. Diwan, M. Hauswirth, and P. F. Sweeney. "Evaluating the accuracy of Java profilers", in Proceedings of the ACM SIGPLAN conference on Programming language design and implementation. pp. 1879--197, 2010. Google Scholar
Digital Library
- M. Hirzel, and T. M. Chilimbi, "Bursty tracing: a framework for low-overhead temporal profiling", in Proceedings of the 4th Workshop on Feedback-Directed and Dynamic Optimization, pp. 117--126, 2001.Google Scholar
- H. Hayashizaki, P. Wu, H. Inoue, M. Serrano, and T. Nakatani, "Improving the Performance of Trace-based Systems by False Loop Filtering", In Proceedings of Sixteenth International Conference on Architectural Support for Programming Languages and Operating Systems, pp. 405--418, 2011. Google Scholar
Digital Library
- H. Q. Le, W. J. Starke, J. S. Fields, F. P. O'Connell, D. Q. Nguyen, B. J. Ronchetti, W. M. Sauer, E. M. Schwarz, and M. T. Vaden. "IBM POWER6 microarchitecture". IBM Journal of Research and Development, Vol. 51 (6), pp. 639--662, 2007. Google Scholar
Digital Library
- S. M. Blackburn et al., "The DaCapo Benchmarks: Java Benchmarking Development and Analysis", in Proceedings of the ACM conference on Object-Oriented Programming, Systems, Languages, and Applications, pp. 169--190, 2006. Google Scholar
Digital Library
- U. Holzle and D. Ungar, "A third generation self implementation: Reconciling responsiveness with performance", in Proceedings of the ACM Conference on Object-Oriented Programming Systems, Languages, and Applications, pp. 229--243, 1994. Google Scholar
Digital Library
- C. Bolz, A. Cuni, M. Fijalkowski, and A. Rigo, "Tracing the Meta-Level: PyPy's Tracing JIT Compiler" , in Proceedings of the 4th workshop on the Implementation, Compilation, Optimization of Object-Oriented Languages and Programming Systems, pp. 18--25, 2009. Google Scholar
Digital Library
- A. Gal, B. Eich, M. Shaver, D. Anderson, D. Mandelin, M. Haghighat, B. Kaplan, G. Hoare, B. Zbarsky, J. Orendorff, J. Ruderman, E. W. Smith, R. Reitmaier, M. Bebenita, M. Chang, and M. Franz., "Trace-based Just-In-Time Type Specialization for Dynamic Languages", in Proceedings of the ACM SIGPLAN conference on Programming language design and implementation, pp. 465--478, 2009. Google Scholar
Digital Library
- A. Gal, C. Probst, and M. Franz, "HotPathVM: An Effective JIT Compiler for Resource-constrained Devices", in Proceedings of the International Conference on Virtual Execution Environments, pp. 144--153, 2006. Google Scholar
Digital Library
- B. Cheng and B. Buzbee, "A JIT Compiler for Android's Dalvik VM", Google I/O developer conference, 2010. http://www.google.com/events/io/2010/sessions/jit-compiler-androids-dalvik-vm.htmlGoogle Scholar
- C. Häubl and H. Mössenböck, "Trace-based Compilation for the Java HotSpot Virtual Machine", in Proceedings of the International Conference on the Principles and Practice of Programming in Java, pp. 129--138, 2011. Google Scholar
Digital Library
- C. Häubl, C. Wimmer, and H. Mössenböck, "Evaluation of trace inlining heuristics for Java", in Proceedings of the Annual ACM Symposium on Applied Computing, pp. 1971--1876, 2011. Google Scholar
Digital Library
- A. Gal, "Efficient bytecode verification and compilation in a virtual machine", PhD thesis, University of California, Irvine, 2006. Google Scholar
Digital Library
- M. Bebenita, F. Brandner, M. Fahndrich, F. Logozzo, W. Schulte, N. Tillmann, and H. Venter, "SPUR: A trace-based JIT compiler for CIL" , in Proceedings of the ACM international conference on Object oriented programming systems languages and applications, pp. 708--725, 2010. Google Scholar
Digital Library
- M. Bebenita, M. Chang, G. Wagner, A. Gal, C. Wimmer, and M. Franz, "Trace-based compilation in execution environments without interpreters" , in Proceedings of the 8th International Conference on the Principles and Practice of Programming in Java, pp. 59--68, 2010. Google Scholar
Digital Library
Index Terms
Adaptive multi-level compilation in a trace-based Java JIT compiler
Recommendations
Trace-based compilation in execution environments without interpreters
PPPJ '10: Proceedings of the 8th International Conference on the Principles and Practice of Programming in JavaTrace-based compilation is a technique used in managed language runtimes to detect and compile frequently executed program paths. The goal is to reduce compilation time and improve code quality by only considering "hot" parts of methods for compilation. ...
Adaptive multi-level compilation in a trace-based Java JIT compiler
OOPSLA '12: Proceedings of the ACM international conference on Object oriented programming systems languages and applicationsThis paper describes our multi-level compilation techniques implemented in a trace-based Java JIT compiler (trace-JIT). Like existing multi-level compilation for method-based compilers, we start JIT compilation with a small compilation scope and a low ...
A trace-based Java JIT compiler for large-scale applications
VMIL '12: Proceedings of the sixth ACM workshop on Virtual machines and intermediate languagesTrace-based compilation uses dynamically-identified frequently-executed code sequences (traces) as units for compilation. We explore trace-based compilation in Java to see if a trace-based JIT compiler (trace-JIT) can address a limitation of method-...







Comments