Confirmed users
328
edits
(→Profiling tools: oops, don't need to mention gprof twice) |
No edit summary |
||
| Line 1: | Line 1: | ||
= Profiling tools = | == Profiling tools == | ||
The following tools are used to measure product performance. | The following tools are used to measure product performance. | ||
* [https://developer.mozilla.org/Profiling_with_AMD_CodeAnalyst AMD CodeAnalyst] | === Platform-independent === | ||
* Xperf | |||
* vtune | * [http://www.mozilla.org/performance/measureStartup.html MOZ_TIMELINE] Timing instrumentation. Extremely useful for app startup measurements. | ||
* [https://developer.mozilla.org/en/Profiling_JavaScript_with_Shark Shark] (Mac) | * [http://www.mozilla.org/performance/jsprofiler.html JS Runtime Profiler]. Profile JavaScript usage, dumps output to a file. | ||
* [http://blog.mozilla.com/dmandelin/2009/02/26/tracevis-performance-visualization-for-tracemonkey/ TraceVis] and [http://code.google.com/p/ethogram/ Ethograms] - [https://developer.mozilla.org/en/TraceVis TraceVis usage] and [https://bugzilla.mozilla.org/show_bug.cgi?id=497999 ethogram bug] | |||
* [[Perfomatic|Mozilla graph server]] | |||
* [[Buildbot/Talos]] - really nice setup where various performance tests are run automatically and compared against previous builds. Results are posted to the [news://news.mozilla.org/mozilla.dev.tree-management mozilla.dev.tree-management] newsgroup | |||
* [[Dromaeo]] - in-browser Javascript tests | |||
* [https://developer.mozilla.org/en/Mochitest mochitests] - test harness for writing tests in js using full browser | |||
* Various internal tools/settings/whatever | |||
** bug 568863 - provide access to hw perf counters | |||
** bug 507012 (not landed) - Javascript callback for function entry/exit | |||
=== Platform-specific === | |||
''Windows'' | |||
* [https://developer.mozilla.org/Profiling_with_AMD_CodeAnalyst AMD CodeAnalyst] | |||
* Xperf | |||
* vtune | |||
* [http://www.sysinternals.com/ Sysinternals utilities]. Win9x/Me/NT/2K utilites for monitoring system usage. CPU/Mon, Diskmon, Filemon, Regmon, etc. | |||
''Mac'' | |||
* [https://developer.mozilla.org/en/Profiling_JavaScript_with_Shark Shark] | |||
* The Metrowerks Profiler (on subsets of the codebase), or Apple's Instrumentation SDK. For details, see the [http://www.mozilla.org/performance/mac-performance.html Mac performance page]. | |||
''Linux'' | |||
* oprofile | |||
* sysprof | |||
* [http://www.mozilla.org/performance/jprof.html jprof]. Sampling profiling tool by [mailto:jim_nance@yahoo.com Jim Nance] that runs on 32-bit Linux. | |||
* [http://www.mozilla.org/performance/eazel.html eazel profilers]. Two profiling tools from Eazel/gnome.org. | |||
* [https://perf.wiki.kernel.org/index.php/Main_Page perf] - originally just for the kernel itself, now has decent user-space capabilities | |||
* [http://sourceware.org/systemtap/wiki SystemTap] - similar to perf, but different. They share quite a bit of infrastructure. | |||
More about perf and SystemTap: | |||
SystemTap has a scripting language that gets converted to kernel modules, so is extremely customizable. It is not in the kernel tree, so may not work on the latest greatest kernel. Perf is the current Chosen One within the kernel developer community, and is in the tree. | |||
Both are useful at seeing what the kernel is doing as a result of a user-space process or processes. Both have some ability to look directly at user processes and report only on them. SystemTap is attempting to be compatible with Solaris's excellent dtrace toolkit, but is still pretty rough. (eg I can't get it to link successfully right now. Taras ran into many different issues.) Both support dynamic probes as well as statically inserted probes. Static probes in user space have rough edges. | |||
''Other'' | |||
* dtrace - excellent dynamic tracing framework for Solaris. SystemTap is attempting to port and extend its capabilities to Linux. | |||
* [http://alisa.ucsd.edu/cgi/webman?SEARCH+man5+hiprof.5.gz hiprof]. A hierarchical instruction profiler for Digital Unix. There is an [http://www.mozilla.org/performance/atom/atom.html online tutorial], courtesy [mailto:jim_nance@yahoo.com 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." [news://news.mozilla.org/slrn7jop6f.jlq.jlnance%40Bessie.acs.uncwil.edu *]'' | |||
''Multiple'' | |||
* [http://valgrind.org/docs/manual/cl-manual.html callgrind] (part of valgrind) | * [http://valgrind.org/docs/manual/cl-manual.html callgrind] (part of valgrind) | ||
* [http://www.ibm.com/software/awdtools/purifyplus/ Rational PurifyPlus]. (Commercial) Used to be called Rational Quantify. | * [http://www.ibm.com/software/awdtools/purifyplus/ Rational PurifyPlus]. (Commercial) Used to be called Rational Quantify. | ||
** [http://www.mozilla.org/performance/qfy2html.pl 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. | ** [http://www.mozilla.org/performance/qfy2html.pl 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. | ||
** [http://www.mozilla.org/unix/quantify.html Quantifying Mozilla on Solaris]. Instructions on how to make Quantify play nicely with Mozilla on Solaris. | ** [http://www.mozilla.org/unix/quantify.html Quantifying Mozilla on Solaris]. Instructions on how to make Quantify play nicely with Mozilla on Solaris. | ||
* [http://www.gnu.org/software/binutils/manual/gprof-2.9.1/gprof.html gprof]. Part of the [http://www.gnu.org/software/binutils/ GNU Binutils]. Back in May 1999 there were rumors that gprof had trouble with dynamically linked and loaded objects (like Mozilla). Currently (March 2006) gprof is still being developed, so hopefully that's no longer true (assuming it ever was). The link to the gprof manual above is *years* out of date but, at the time of writing, it's the latest version of the [http://www.gnu.org/manual/ manual on gnu.org]. To get an up to date version of the manual, get the gprof source and run |. configure; make html| in the gprof source directory. | * [http://www.gnu.org/software/binutils/manual/gprof-2.9.1/gprof.html gprof]. Part of the [http://www.gnu.org/software/binutils/ GNU Binutils]. Back in May 1999 there were rumors that gprof had trouble with dynamically linked and loaded objects (like Mozilla). Currently (March 2006) gprof is still being developed, so hopefully that's no longer true (assuming it ever was). The link to the gprof manual above is *years* out of date but, at the time of writing, it's the latest version of the [http://www.gnu.org/manual/ manual on gnu.org]. To get an up to date version of the manual, get the gprof source and run |. configure; make html| in the gprof source directory. | ||
= Other References = | == Other References == | ||
* [[Performance:Leak_Tools|Leak Tools]] | * [[Performance:Leak_Tools|Leak Tools]] | ||