I analysed simple heap dump from Java program containing only this in main method.
public static void main(String[] args) throws IOException {
System.in.read();
}
Using HPROF parser library, my output is that:
Done, found:
Classes: 473
Instances: 13161
Namespace java
Classes: 251
Instances: 9033
How is that possible that there are so many instances without me creating any of them. Are these java runtime instances?