How to debug the GC
Jost Boekemeier
JBoekemeier@inetsoftware.de
Tue Jun 17 16:16:00 GMT 2003
It seems that when running our application within gcj, it leaks memory.
Basically we instantiate an object, the object then creates an array of java
objects (ca. 100 MB altogether) and then flattens everything into a
byte-array. Within our tests the byte-array and the object itself are
discarded.
For each new round ca. 200K (sometimes more, sometimes less) are missing so
that after some time the GC will allocate a new chunk from the OS. -- This
does not mean that there is a bug within the GC; we use several native
methods which may cause this.
Does anyone have a tip how to debug this kind of problem? In gcj how do I
access the list of referenced objects?
Btw: I've taken a short look at the GC and it seems that the GC does never
release memory back to the operating system, does it?
Jost
More information about the Java
mailing list