background preloader

VM

Facebook Twitter

Aleksey Shipilëv: one-stop page. Java SE 6 HotSpot[tm] Virtual Machine Garbage Collection Tuning. The Java™ Platform, Standard Edition (Java SE™) is used for a wide variety of applications, from small applets on desktops to web services on large servers.

Java SE 6 HotSpot[tm] Virtual Machine Garbage Collection Tuning

In support of this diverse range of deployments, the Java HotSpot™ virtual machine implementation (Java HotSpot™ VM) provides multiple garbage collectors, each designed to satisfy different requirements. This is an important part of meeting the demands of both large and small applications. However, users, developers and administrators that need high performance are burdened with the extra step of selecting the garbage collector that best meets their needs. A significant step toward removing this burden was made in J2SE™ 5.0: the garbage collector is selected based on the class of the machine on which the application is run. This better choice of the garbage collector is generally an improvement, but is by no means always the best choice for every application. When does the choice of a garbage collector matter?

Eden and two. [JavaSpecialists 174] - Java Memory Puzzle Explained. The Java Specialists' Newsletter Issue 174 Category: Performance Java version: Java 1.0 - 6.0 by Dr.

[JavaSpecialists 174] - Java Memory Puzzle Explained

Heinz M. Abstract:In this newsletter, we reveal the answer to the puzzle from last month and explain the reasons why the first class sometimes fails and why the second always succeeds. Welcome to the 174th issue of The Java(tm) Specialists' Newsletter. Join us on Crete (or via webinar) for advanced Core Java Courses:Concurrency Specialists Course 1-4 April 2014 and Java Specialists Master Course 20-23 May 2014. Java Memory Puzzle Explained The initial JavaMemoryPuzzle was based on a discussion that one of my readers, Dmitry Vyazelenko, had with some friends.

Here is the JavaMemoryPuzzle code again: The easiest way to understand why it fails is to look at the disassembled class file, which we can generate using the javap -c JavaMemoryPuzzle command. Instruction 0 loads the pointer this onto the stack. Public void f() { byte[] data = new byte[dataSize]; byte[] data2 = new byte[dataSize]; } Heinz.

How much memory do I need (part 2) – What is shallow heap? August 27, 2012 by Nikita Salnikov-Tarnovski What is the size of a particular data structure?

How much memory do I need (part 2) – What is shallow heap?

“Can I fit all these objects into my ehCache?” This article is the second post in the series where we try to answer those questions. The last post explained the difference between retained and shallow sizes of an object. In the article we also offered an example of how to calculate retained heap size of a data structure. In the first post we pushed a whole lot of complexity away by stating that calculating shallow heap size is easy – it consists of only the heap occupied by the object itself. Shallow Heap Size = [reference to the class definition] + space for superclass fields + space for instance fields + [alignment] Does not seem too helpful, eh? Frequently Asked Questions About the Java HotSpot VM. This FAQ answers common questions about Java HotSpot Technology and about performance in general.

Frequently Asked Questions About the Java HotSpot VM

Unless otherwise noted, all information on this page applies to both the HotSpot Client VM and the HotSpot Server VM as of Java SE version 1.4. General Memory and Garbage Collection JIT Compiler 64-bit Java Multithreaded Applications. [JavaSpecialists 078] - MemoryCounter for Java 1.4. The Java Specialists' Newsletter Issue 078 Category: Performance Java version: by Dr.

[JavaSpecialists 078] - MemoryCounter for Java 1.4

Heinz M. Welcome to the 78th edition of The Java(tm) Specialists' Newsletter. This past week I taught UML and Java at the Tsinghua University in Beijing, China. China is, well, memorable. Join us on Crete (or via webinar) for advanced Core Java Courses:Concurrency Specialists Course 1-4 April 2014 and Java Specialists Master Course 20-23 May 2014. MemoryCounter for Java 1.4 Before I start, I must warn you that I am using classes that will only work for Java 1.4 onwards. After my newsletter #29, I received a few emails telling me that it would be much easier to serialize the object and then count the bytes. The first class we have is called MemorySizes and will tell my memory counter class how much memory each element takes.

Instrumentation: Modify Applications with Java 5 Class File Transformations. Ergonomics in the 5.0 Java[tm] Virtual Machine. Oracle Technology Network > Java Software Downloads View All Downloads Top Downloads New Downloads What's New Java in the Cloud: Rapidly develop and deploy Java business applications in the cloud.

Ergonomics in the 5.0 Java[tm] Virtual Machine

Essential Links Developer Spotlight Java EE—the Most Lightweight Enterprise Framework? Blogs Technologies Contact Us About Oracle Cloud Events Top Actions News Key Topics Oracle Integrated Cloud Applications & Platform Services. Java Performance Tuning, Profiling, and Memory Management. Java application performance is an abstract word until you face its real implications.

Java Performance Tuning, Profiling, and Memory Management

It may vary depending on your interpretation of the word 'performance'. This article is meant to give the developer a perspective of the various aspects of the JVM internals, the controls and switches that can be altered to optimal effects that suit your application. There is no single size that can fits all. You need to customize to suit your application. You may be facing one of the issues listed below: