Eliminating Abstraction Overhead of Java']Java Stream Pipelines using Ahead-of-Time Program Optimization

被引:3
|
作者
Moller, Anders [1 ]
Veileborg, Oskar Haarklou [1 ]
机构
[1] Aarhus Univ, Aarhus, Denmark
基金
欧洲研究理事会;
关键词
program optimization; static program analysis; !text type='Java']Java[!/text] 8; ESCAPE ANALYSIS;
D O I
10.1145/3428236
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Java 8 introduced streams that allow developers to work with collections of data using functional-style operations. Streams are often used in pipelines of operations for processing the data elements, which leads to concise and elegant program code. However, the declarative data processing style comes at a cost. Compared to processing the data with traditional imperative language mechanisms, constructing stream pipelines requires extra heap objects and virtual method calls, which often results in significant run-time overheads. In this work we investigate how to mitigate these overheads to enable processing data in the declarative style without sacrificing performance. We argue that ahead-of-time bytecode-to-bytecode transformation is a suitable approach to optimization of stream pipelines, and we present a static analysis that is designed to guide such transformations. Experimental results show a significant performance gain, and that the technique works for realistic stream pipelines. For 10 of 11 micro-benchmarks, the optimizer is able to produce bytecode that is as effective as hand-written imperative-style code. Additionally, 77% of 6 879 stream pipelines found in real-world Java programs are optimized successfully.
引用
收藏
页数:29
相关论文
共 15 条
  • [1] Loop transformations in the ahead-of-time optimization of Java']Java bytecode
    Hammond, Simon
    Lacey, David
    COMPILER CONSTRUCTION, PROCEEDINGS, 2006, 3923 : 109 - 123
  • [2] Design and Optimization of a Java']Java Ahead-of-Time Compiler for Embedded Systems
    Jung, Dong-Heon
    Moon, Soo-Mook
    Bae, Sung-Hwan
    EUC 2008: PROCEEDINGS OF THE 5TH INTERNATIONAL CONFERENCE ON EMBEDDED AND UBIQUITOUS COMPUTING, VOL 1, MAIN CONFERENCE, 2008, : 169 - 175
  • [3] Java']Java client ahead-of-time compiler for embedded systems
    Hong, Sunghyun
    Kim, Jin-Chul
    Shin, Jin Woo
    Moon, Soo-Mook
    Oh, Hyeong-Seok
    Lee, Jaemok
    Choi, Hyung-Kyu
    ACM SIGPLAN NOTICES, 2007, 42 (07) : 63 - 72
  • [4] On real-time performance of ahead-of-time compiled Java']Java
    Nilsson, A
    Robertz, SG
    ISORC 2005: Eighth IEEE International Symposium on Object-Oriented Real-Time Distributed Computing, Proceedings, 2005, : 372 - 381
  • [5] Evaluation of a Java']Java Ahead-of-Time Compiler for Embedded Systems
    Jung, Dong-Heon
    Moon, Soo-Mook
    Bae, Sung-Hwan
    COMPUTER JOURNAL, 2012, 55 (02): : 232 - 252
  • [6] Client ahead-of-time compiler for embedded Java']Java platforms
    Hong, Sunghyun
    Kim, Jin-Chul
    Moon, Soo-Mook
    Shin, Jin Woo
    Lee, Jaemok
    Oh, Hyeong-Seok
    Choi, Hyung-Kyu
    SOFTWARE-PRACTICE & EXPERIENCE, 2009, 39 (03): : 259 - 278
  • [7] Java']Java Client Ahead-of-Time Compiler for Embedded Systems
    Hong, Sunghyun
    Kim, Jin-Chul
    Shin, Jin Woo
    Moon, Soo-Mook
    Oh, Hyeong-Seok
    Lee, Jaemok
    Choi, Hyung-Kyu
    LCTES'07: PROCEEDINGS OF THE 2007 ACM SIGPLAN-SIGBED CONFERENCE ON LANGUAGES, COMPILERS, AND TOOLS FOR EMBEDDED SYSTEMS, 2007, : 63 - 72
  • [8] Ahead-of-time compilation of Java']JavaScript programs
    Zhuykov, R.
    Sharygin, E.
    PROGRAMMING AND COMPUTER SOFTWARE, 2017, 43 (01) : 51 - 59
  • [9] On Java']JavaScript Ahead-of-Time Compilation Performance (Keynote)
    Serrano, Manuel
    PROCEEDINGS OF THE 19TH INTERNATIONAL CONFERENCE ON MANAGED PROGRAMMING LANGUAGES AND RUNTIMES, MPLR 2022, 2022, : 1 - 1
  • [10] Augmenting Java']JavaScript JIT with Ahead-of-Time Compilation
    Zhuykov, Roman
    Vardanyan, Vahagn
    Melnik, Dmitry
    Buchatskiy, Ruben
    Sharygin, Eugeniy
    TENTH INTERNATIONAL CONFERENCE ON COMPUTER SCIENCE AND INFORMATION TECHNOLOGIES REVISED SELECTED PAPERS CSIT-2015, 2015, : 116 - 120