skip to main content
research-article

A study of Java's non-Java memory

Published:17 October 2010Publication History
Skip Abstract Section

Abstract

A Java application sometimes raises an out-of-memory ex-ception. This is usually because it has exhausted the Java heap. However, a Java application can raise an out-of-memory exception when it exhausts the memory used by Java that is not in the Java heap. We call this area non-Java memory. For example, an out-of-memory exception in the non-Java memory can happen when the JVM attempts to load too many classes. Although it is relatively rare to ex-haust the non-Java memory compared to exhausting the Java heap, a Java application can consume a considerable amount of non-Java memory.

This paper presents a quantitative analysis of non-Java memory. To the best of our knowledge, this is the first in-depth analysis of the non-Java memory. To do this we cre-ated a tool called Memory Analyzer for Redundant, Unused, and String Areas (MARUSA), which gathers memory statis-tics from both the OS and the Java virtual machine, break-ing down and visualizing the non-Java memory usage.

We studied the use of non-Java memory for a wide range of Java applications, including the DaCapo benchmarks and Apache DayTrader. Our study is based on the IBM J9 Java Virtual Machine for Linux. Although some of our results may be specific to this combination, we believe that most of our observations are applicable to other platforms as well.

References

  1. }}The Apache Software Foundation. Apache JMeter. http://jakarta.apache.org/jmeter/Google ScholarGoogle Scholar
  2. }}The Apache Software Foundation. Apache DayTrader Benchmark Sample. http://cwiki.apache.org/GMOxDOC20/daytrader.html.Google ScholarGoogle Scholar
  3. }}Chris Bailey. Java technology, IBM style: Introduction to the IBM Developer Kit, 2006. http://www.ibm.com/developerworks/java/library/j-ibmjava1.html.Google ScholarGoogle Scholar
  4. }}Helen Beeken, Daniel Julin, Julie Stalley and Martin Trotter. Java diagnostics, IBM style, Part 1: Introducing the IBM Di-agnostic and Monitoring Tools for Java - Dump Analyzer. http://www.ibm.com/developerworks/java/library/j-ibmtools1/index.htmlGoogle ScholarGoogle Scholar
  5. }}John Berthels. Exmap memory analysis tool. http://www.berthels.co.uk/exmap/Google ScholarGoogle Scholar
  6. }}Stephen M. Blackburna, et al. The DaCapo Benchmarks: Java Benchmarking Development and Analysis. In Proceed-ings of the 21st ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA '06), pp. 169--190, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. }}Sumit Chawla. Getting more memory in AIX for your Java applications, 2003. http://www.ibm.com/developerworks/ eserver/articles/aix4java1.htmlGoogle ScholarGoogle Scholar
  8. }}Yi Feng and Emery D. Berger. A Locality-Improving Dynamic Memory Allocator. In Proceedings of the 2005 work-shop on Memory system performance (MSP '05), pp. 68--77, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. }}Sanjay Ghemawat. TCMalloc : Thread-Caching Malloc. 2007. http://google-perftools.googlecode.com/svn/trunk/doc/tcmalloc.htmlGoogle ScholarGoogle Scholar
  10. }}Nikola Grcevski, Allan Kielstra, Kevin Stoodley, Mark Stoodley, and Vijay Sundaresan. Java Just-In-Time Compiler and Virtual Machine Improvements for Server and Middle-ware Applications. In Proceedings of the 3rd USENIX Vir-tual Machine Research and Technology Symposium (VM '04), pp. 151--162, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. }}Filip Hanik. Inside the Java Virtual Machine, 2007 http://www.springsource.com/files/Inside_the_JVM.pdfGoogle ScholarGoogle Scholar
  12. }}Matthew Hertz, Yi Feng, and Emery D. Berger. Garbage Collection Without Paging. In Proceedings of the 2005 ACM SIGPLAN conference on Programming language design and implementation (PLDI '05), pp. 143--153, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. }}IBM Corporation. AIX 6.1 information, Multiple page size support. http://publib.boulder.ibm.com/infocenter/aix/v6r1/index.jsp?topic=/com.ibm.aix.prftungd/doc/prftungd/multiple_page_size_support.htmGoogle ScholarGoogle Scholar
  14. }}IBM Corporation. IBM Support Assistant. http://www.ibm.com/software/support/isa/Google ScholarGoogle Scholar
  15. }}IBM Corporation. WebSphere Application Server. http://www.ibm.com/software/webservers/appserv/was/.Google ScholarGoogle Scholar
  16. }}Intel Corporation. Intel 64 and IA-32 Architectures Software Developer's Manual. Volume 1: Basic Architecture. Order Number: 253665-033US. 2009.Google ScholarGoogle Scholar
  17. }}The Jikes RVM Project. Jikes RVM. http://jikesrvm.org/Google ScholarGoogle Scholar
  18. }}Maria Jump and Kathryn S. McKinley. Cork: Dynamic Memory Leak Detection for Garbage-Collected Languages. In Proceedings of the 34th ACM Symposium on Principles of Programming Languages (POPL '07), pp. 31--38, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. }}Kiyokuni Kawachiya, Kazunori Ogata, and Tamiya Onodera. Analysis and Reduction of Memory Inefficiencies in Java Strings. In Proceedings of the 23rd ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA '08), pp. 385--401, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. }}Sheng Liang and Deepa Viswanathan. Comprehensive Profiling Support in the Java Virtual Machine. In Proceedings of the 5th USENIX Conference on Object-Oriented Technologies and Systems (COOTS '99), pp. 229--242, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. }}Nick Mitchell and Gary Sevitsky. LeakBot: An Automated and Lightweight Tool for Diagnosing Memory Leaks in Large Java Applications. In Proceedings of the 17th European Conference on Object-Oriented Programming (ECOOP '03), pp. 351--377, 2003.Google ScholarGoogle Scholar
  22. }}Nick Mitchell and Gary Sevitsky. The Causes of Bloat, The Limits of Health. In Proceedings of the 22nd ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA '07), pp. 245--260, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. }}Oracle. JRockit. http://www.oracle.com/appserver/jrockit/index.htmlGoogle ScholarGoogle Scholar
  24. }}Indrajit Poddar and Robbie John Minshall. Memory leak detection and analysis in WebSphere Application Server: Part 1: Overview of memory leaks. http://www.ibm.com/developerworks/websphere/library/techarticles/0606_poddar/0606_poddar.htmlGoogle ScholarGoogle Scholar
  25. }}Power.org. http://www.power.org/Google ScholarGoogle Scholar
  26. }}Sun Microsystems. HPROF: A Heap/CPU Profiling Tool in J2SE 5.0. http://java.sun.com/developer/technicalArticles/Programming/HPROF.htmlGoogle ScholarGoogle Scholar
  27. }}Sun Microsystems. The Java HotSpot Virtual Machine, v1.4.1. http://java.sun.com/products/hotspot/docs/whitepaper/Java_Hotspot_v1.4.1/Java_HSpot_WP_v1.4.1_1002_1.htmlGoogle ScholarGoogle Scholar
  28. }}Sun Microsystems. Java API reference, java.nio.ByteBuffer. http://java.sun.com/j2se/1.4.2/docs/api/java/nio/ByteBuffer.htmlGoogle ScholarGoogle Scholar
  29. }}Sun Microsystems. Java SE HotSpot at a Glance. http://java.sun.com/javase/technologies/hotspot/Google ScholarGoogle Scholar
  30. }}Sun Microsystems. jhat - Java Heap Analysis Tool. http://java.sun.com/javase/6/docs/technotes/tools/share/jhat.htmlGoogle ScholarGoogle Scholar
  31. }}Sun Microsystems. JVM Tool Interface (JVM TI). http://java.sun.com/j2se/1.5.0/docs/guide/jvmti/Google ScholarGoogle Scholar
  32. }}Madhusudhan Talluri and Mark D. Hill. Surpassing the TLB Performance of Superpages with Less Operating System Support. In Proceedings of the sixth international conference on Architectural support for programming languages and operating systems (ASPLOS-VI), pp. 171--182, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. }}Peter W. Wong and Bill Buros. A Performance Evaluation of 64KB Pages on Linux for Power Systems. http://www.ibm.com/developerworks/wikis/display/hpccentral/A+Performance+Evaluation+of+64KB+Pages+on+Linux+for+Power+SystemsGoogle ScholarGoogle Scholar

Index Terms

  1. A study of Java's non-Java memory

        Recommendations

        Comments

        Login options

        Check if you have access through your login credentials or your institution to get full access on this article.

        Sign in

        Full Access

        PDF Format

        View or Download as a PDF file.

        PDF

        eReader

        View online with eReader.

        eReader
        About Cookies On This Site

        We use cookies to ensure that we give you the best experience on our website.

        Learn more

        Got it!