Wednesday, June 3, 2015

Class Data Sharing in J2SE 1.5

Class Data Sharing

Class Data Sharing is a new feature in Java 1.5. It is used to reduce the start up time for Java applications.
When the JRE is installed on a 32-bit platform using the Sun-provided installer, the installer loads a set of classes from the System jar file into a private internal representation, and dumps that representation to a file, called a "shared archive".
In J2SE1.5, class data sharing is supported only with the Java HotSpot Client VM, and only with the serial garbage collector.
The primary motivation for including Class Data Sharing in the 5.0 release is the decrease in startup time it provides. CDS produces better results for smaller applications because it eliminates a fixed cost: that of loading certain core classes. The smaller the application relative to the number of core classes it uses, the larger the saved fraction of startup time.

No comments: