xml-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arkin <ar...@exoffice.com>
Subject Re: DOM size
Date Thu, 11 May 2000 21:59:55 GMT
General notes about measuring memory consumption. Check how much memory
is consumed before the operation and immediately aftewards, then call
System.gc() and go to sleep for a second or more, then measure it again.
What you get are two numbers that you compare against the base number
(before the operation) telling you:

* What is the size of the DOM document (last value - base value)

* How much memory was consumed by the parser to construct the DOM (value
before gc - last value)

The latter one is claimed memory and does not measure the size of the
document. Depending on the machine you run you'll probably need some
sleep period after calling gc() and before getting a measurement.


Joseph Shraibman wrote:
> Mike Pogue wrote:
> > How did you measure the memory consumption?  Did you also account for
> > gc?
> >
> > Mike
> >
> I viewed the size in kpm. And I explicitly did System.gc(); System.runFinalization();
> System.gc();

Assaf Arkin                                           www.exoffice.com
CTO, Exoffice Technologies, Inc.                        www.exolab.org

View raw message