skip to main content
10.1145/780732.780741acmconferencesArticle/Chapter ViewAbstractPublication PagescpsweekConference Proceedingsconference-collections
Article

Data size optimizations for java programs

Published: 11 June 2003 Publication History

Abstract

We present a set of techniques for reducing the memory consumption of object-oriented programs. These techniques include analysis algorithms and optimizations that use the results of these analyses to eliminate fields with constant values, reduce the sizes of fields based on the range of values that can appear in each field, and eliminate fields with common default values or usage patterns. We apply these optimizations both to fields declared by the programmer and to implicit fields in the runtime object header. Although it is possible to apply these techniques to any object-oriented program, we expect they will be particularly appropriate for memory-limited embedded systems.We have implemented these techniques in the MIT FLEX compiler system and applied them to the programs in the SPECjvm98 benchmark suite. Our experimental results show that our combined techniques can reduce the maximum live heap size required for the programs in our benchmark suite by as much as 40%. Some of the optimizations reduce the overall execution time; others may impose modest performance penalties.

References

[1]
O. Agesen, D. Detlefs, A. Garthwaite, R. Knippel, Y. Ramakrishna, and D. White. An efficient meta-lock for implementing ubiquitous synchronization. In Proceedings of the 14th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, pages 207--222, Denver, Colorado, November 1999.]]
[2]
Aneesh Aggarwal and Keith H. Randall. Related field analysis. In Proceedings of the ACM SIGPLAN '01 Conference on Programming Language Design and Implementation (PLDI), pages 214--220, Snowbird, Utah, June 2001.]]
[3]
J. Aldrich, C. Chambers, E. Sirer, and S. Eggers. Static analyses for eliminating unnecessary synchronization from Java programs. In Proceedings of the 6th International Static Analysis Symposium, pages 19--38, September 1999.]]
[4]
C. Scott Ananian. Silicon C: A hardware backend for SUIF. Available from http://flexc.lcs.mit.edu/SiliconC/paper.pdf, May 1998.]]
[5]
C. Scott Ananian. The static single information form. Technical Report MIT-LCS-TR-801, Massachusetts Institute of Technology, 1999. Available from http://www.lcs.mit.edu/publications/pubs/pdf/MIT-LCS-TR-801.pdf.]]
[6]
David F. Bacon, Stephen J. Fink, and David Grove. Space- and time-efficient implementation of the Java object model. In B. Magnusson, editor, Proceedings of the 16th European Conference on Object-Oriented Programming, volume 2374 of Lecture Notes in Computer Science, pages 111--132, Máalaga, Spain, June 2002.]]
[7]
David F. Bacon, Ravi Konuru, Chet Murthy, and Mauricio Serrano. Thin locks: Featherweight synchronization for Java. In Proceedings of the ACM SIGPLAN '98 Conference on Programming Language Design and Implementation (PLDI), pages 258--268, Montreal, Canada, 1998.]]
[8]
David F. Bacon and Peter F. Sweeney. Fast static analysis of C++ virtual function calls. In Proceedings of the 11th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, pages 324--341, California, 1996.]]
[9]
Jeff Bogda and Urs H. olzle. Removing unnecessary synchronization in Java. In Proceedings of the 14th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, pages 35--46, Denver, Colorado, November 1999.]]
[10]
Mihai Budiu, Majd Sakr, Kip Walker, and Seth Copen Goldstein. BitValue inference: Detecting and exploiting narrow bitwidth computations. In Proceedings of the 2000 Europar Conference, volume 1900 of Lecture Notes in Computer Science, Munich, Germany, August 2000. Springer Verlag.]]
[11]
Jong-Deok Choi, Manish Gupta, Mauricio Serrano, Vugranam C. Sreedhar, and Sam Midkiff. Escape analysis for Java. In Proceedings of the 14th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, pages 1--19, Denver, Colorado, November 1999.]]
[12]
Sylvia Dieckmann and Urs Hölzle. A study of the allocation behavior of the SPECjvm98 Java benchmarks. In Proceedings of the 13th European Conference on Object-Oriented Programming, August 1999.]]
[13]
Nevin Heintze and Olivier Tardieu. Ultra-fast aliasinganalysis using CLA: A million lines of C code in a second. In Proceedings of the ACM SIGPLAN '01 Conference on Programming Language Design and Implementation (PLDI), pages 254--263, Snowbird, Utah, June 2001.]]
[14]
Darko Marinov and Robert O'Callahan. Object equality profiling. Submitted to OOPSLA '03, 2003.]]
[15]
Tamiya Onodera and Kiyokuni Kawachiya. A study of locking objects with bimodal fields. In Proceedings ofthe 14th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, pages 223--237, Denver, Colorado, November 1999.]]
[16]
Erik Ruf. Effective synchronization removal for Java. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 208--218, Vancouver, Canada, June 2000.]]
[17]
Radu Rugina and Martin Rinard. Symbolic bounds analysis of pointers, array indices, and accessed memory regions. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 182--195, Vancouver, Canada, June 2000.]]
[18]
Vugranam C. Sreedhar, Michael Burke, and Jong-Deok Choi. A framework for interprocedural optimization in the presence of dynamic class loading. In Proceedings of the ACM SIGPLAN '00 conference on Programming language design and implementation, pages 196--207. ACM Press, 2000.]]
[19]
Mark Stephenson, Jonathan Babb, and Saman Amarasinghe. Bitwidth analysis with application to silicon compilation. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 108--120, Vancouver, Canada, June 2000.Mark Stephenson, Jonathan Babb, and Saman Amarasinghe. Bitwidth analysis with application to silicon compilation. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 108--120, Vancouver, Canada, June 2000]]
[20]
Alexandru Salcianu and Martin Rinard. Pointer and escape analysis for multithreaded programs. In Proceedings of the 8th ACM SIGPLAN symposium on Principles and Practice of Parallel Programming (PPoPP), pages 12--23, Snowbird, Utah, June 2001.]]
[21]
Peter F. Sweeney and Frank Tip. A study of dead data members in C++ applications. In Proceedings of the ACM SIGPLAN '98 Conference on Programming Language Design and Implementation (PLDI), pages 324--332, Montreal, Canada, 1998.]]
[22]
Mark N. Wegman and F. Kenneth Zadeck. Constant propagation with conditional branches. ACM Transactions on Programming Languages and Systems, 13(2):181--210, April 1991.]]
[23]
John Whaley and Martin Rinard. Compositional pointer and escape analysis for Java programs. In Proceedings of the 14th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, pages 187--206, Denver, Colorado, November 1999.]]
[24]
Youtao Zhang and Rajiv Gupta. Data compression transformations for dynamically allocated data structures. In International Conference on Compiler Construction, volume 2304 of Lecture Notes in Computer Science, pages 14--28, Grenoble, France, April 2002. Springer Verlag.]]

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
LCTES '03: Proceedings of the 2003 ACM SIGPLAN conference on Language, compiler, and tool for embedded systems
June 2003
304 pages
ISBN:1581136471
DOI:10.1145/780732
  • cover image ACM SIGPLAN Notices
    ACM SIGPLAN Notices  Volume 38, Issue 7
    Special Issue: Proceedings of the 2003 ACM SIGPLAN conference on Language, compiler, and tool support for embedded systems (San Diego, CA).
    July 2003
    293 pages
    ISSN:0362-1340
    EISSN:1558-1160
    DOI:10.1145/780731
    Issue’s Table of Contents
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: 11 June 2003

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. bitwidth analysis
  2. embedded systems
  3. field externalization
  4. field packing
  5. size optimizations
  6. static specialization

Qualifiers

  • Article

Conference

LCTES03
Sponsor:

Acceptance Rates

LCTES '03 Paper Acceptance Rate 29 of 128 submissions, 23%;
Overall Acceptance Rate 116 of 438 submissions, 26%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)8
  • Downloads (Last 6 weeks)4
Reflects downloads up to 17 Jan 2025

Other Metrics

Citations

Cited By

View all

View Options

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