Performance:Tinderbox Tests: Difference between revisions

Line 49: Line 49:
   ac_add_options --enable-logrefcnt
   ac_add_options --enable-logrefcnt


and reconfigure and rebuild. Then run the app on the bloaturls list of urls with the environment variable XPCOM_MEM_REFCNT_LOG set to 1 to dump bloat and leak summaries to stdout:
and reconfigure and rebuild. Then run the app on the bloaturls list of urls with the environment variable XPCOM_MEM_BLOAT_LOG set to 1 to dump bloat and leak summaries to stdout:


   export XPCOM_MEM_REFCNT_LOG=1
   export XPCOM_MEM_BLOAT_LOG=1
   <appname> resource:///res/bloatcycle.html > bloat.log
   <appname> resource:///res/bloatcycle.html > bloat.log


If you want to compare two runs (e.g. test a change) do something like this:
If you want to compare two runs (e.g. test a change) do something like this:


   export XPCOM_MEM_REFCNT_LOG=1
   export XPCOM_MEM_BLOAT_LOG=1
   cvs co mozilla/tools/tinderbox/bloatdiff.pl
   cvs co mozilla/tools/tinderbox/bloatdiff.pl
   <appname> resource:///res/bloatcycle.html > a.out
   <appname> resource:///res/bloatcycle.html > a.out
Line 63: Line 63:
   bloatdiff.pl a.out b.out
   bloatdiff.pl a.out b.out


With a non-debug browser build on Linux from CVS tip as of 2007-07-05 the dump of bloatcycle.html test exceeds 10 GB. Thus if 20+ GB of the disk space is not available, use gzip when running the tests to compress the dumps down to 100 MB or so:
See http://www.mozilla.org/projects/xpcom/MemoryTools.html for details.
 
  export XPCOM_MEM_REFCNT_LOG=1
  cvs co mozilla/tools/tinderbox/bloatdiff.pl
  <appname> resource:///res/bloatcycle.html | gzip > a.out.gz
    **make change**
  <appname> resource:///res/bloatcycle.html | gzip > b.out.gz
  bloatdiff.pl 'zcat a.out.gz|' 'zcat b.out.gz|'


= Trace-Malloc Bl/Lk: Bloat & Leak numbers =
= Trace-Malloc Bl/Lk: Bloat & Leak numbers =
15

edits