Performance:Leak Tools: Difference between revisions

Line 146: Line 146:
Currently the new-style leak stats can be run only on Linux. Hopefully they will work on other platforms soon. They require a build with trace-malloc enabled.
Currently the new-style leak stats can be run only on Linux. Hopefully they will work on other platforms soon. They require a build with trace-malloc enabled.


==== Linux ====
Build with trace-malloc enabled (--enable-trace-malloc in your mozconfig file). Then, once you have a build, use the same steps as the old-style leak tests, except don't set the environment variables, and instead add the command line options when invoking mozilla or firefox: "--trace-malloc=malloc.log" (or, if you want the shutdown leaks report, also add "--shutdown-leaks=sdleak.log").  Then, to process the log, run "./run-mozilla.sh ./leakstats malloc.log".  (Omit the "./run-mozilla.sh" on Windows.)
 
To build with trace-malloc enabled (--enable-trace-malloc in your mozconfig file). Then, once you have a build, you can run:
 
# ./mozilla -f bloaturls.txt --trace-malloc=malloc.log (or, if you want the shutdown leaks report, also add --shutdown-leaks=sdleak.log)
# ./run-mozilla.sh ./leakstats malloc.log


This will produce a report like the following:
This will produce a report like the following:
canmove, Confirmed users, Bureaucrats and Sysops emeriti
1,334

edits