Name: bk70084 Date: 07/20/98
This is a request to invest in an effort to reduce the memory
footprint for classes at runtime, and please not restrict this
effort to PJava or JavaOS.
I recently put some printfs into the VM and discovered that the
memory size of classes is approximately 2 times that of the size
of the class file. That seems overly expensive, and the result
is that it's impossible to write full-fledge Java applications
which aren't HUGE (e.g., 10M) in size.
One possible area of optimization is with method signatures, where
you are penalized for having long class names. Imagine a method
which takes three class arguments, and those classes are defined
in the "com.marimba.apps.transmitter.workspace" package. The method
signature in that situation could contain:
Lcom.marimba.apps.transmitter.workspace.Channel;Lcom.marimba.apps.transmitter.workspace.Workspace;Lcom.marimba.apps.transmitter.ServerContext;
whereas it's theoretically possible to represent that method signature
as an array of references into the constant pool or something of that
nature.
NOTE: I don't actually know what I am talking about here, but I do
believe that method signatures are stored in memory and it is true that
they can be quite large for innocuous looking methods.
(Review ID: 34227)
======================================================================
- duplicates
-
JDK-4185368 Garbage collector pages in a lot of the class files
-
- Closed
-