The Mozilla
Organization
At A Glance
Feedback
Get Involved
Newsgroups
License Terms
Newsbot
Developer Docs
Roadmap
Projects
Ports
Module Owners
Hacking
Get the Source
Build It
Testing
Download
Bugzilla
Bug Writing
Tools
View Source
Tree Status
New Checkins
Submit A Bug
FAQ
Search

performance: tools

Contact: Chris Waterson (waterson@netscape.com)
$Id: tools.html,v 1.13 2000/02/10 02:47:42 dmose%mozilla.org Exp $

Memory Leaks

The following tools are used to track down memory leaks in the product. See also How to debug Memory Leaks.

  • Rational Purify®. (Commercial)

  • GlowCode. (Commercial)

  • ElectricFence.

      "Electric Fence ... uses the virtual memory hardware of your system to detect when software overruns the boundaries of a malloc() buffer. It will also detect any accesses of memory that has been released by free(). Because it uses the VM hardware for detection, Electric Fence stops your program on the first instruction that causes a bounds violation."
    Specifically, it works by placing each heap allocation on its own VM page. Since the dynamic footprint of the browser is pretty large, this may make it tough to use "in real life".

  • Leaky. This is a home-grown tool that Kipp put together:

      "Its a tool called leaky. What it does it help you track down memory leaks and some kinds of memory corruption. It also has entry pointers for logging addref/release calls. The key thing that leaky does is this: it logs all calls to malloc/free/realloc/new/delete into a log file. The logging data includes information about size and address, as well as the *call stack of the operation*. The leaky program then can translate the call stack data from addresses into symbols and then dump the data out." *

  • refcount balancer. This is another home-grown tool that does finer-grained instrumentation and allows you to focus on specific objects rather than entire runs.

  • Insure++®. (Commercial) Free Linux version.

  • LeakTracer.
  • ccmalloc.
  • debauch.
  • memwatch.
  • Geodesic Systems' GreatCircle. Scott Furman has done some preliminary work to get this product working with Mozilla.

Profiling

The following tools are used to measure product performance.

  • Rational Quantify. (Commercial)

    • qfy2html.pl. A Perl script for munging Quantify 6.0 output into hyperlinked HTML to share with your friends. Run Quantify, save your results as text, and then let this thing rip.
    • Quantifying Mozilla on Solaris. Instructions on how to make Quantify play nicely with Mozilla on Solaris.
  • Mac Instrumentation SDK. The Instrumentation SDK allows you to do code performance analysis, collecting time-based data, and other data by putting instrumentation points in your code, and running. Check out the InstrumentationHelpers.h header file for more information on how to use it with Mozilla.

  • hiprof. A hierarchical instruction profiler for Digital Unix. There is an online tutorial, courtesy Jim Nance (jim_nance@yahoo.com):

      "I like it because it does not require you to recompile the program, because it give accurate times for callers, and because it comes with DU so that everyone developing there should already have it." *

  • jprof. Sampling profiling tool by Jim Nance that runs on RedHat 6.1.

  • gprof. There are rumors that this has trouble with dynamically linked and loaded objects (like Mozilla).

Copyright © 1998-2000 The Mozilla Organization.
Last modified February 10, 2000.