1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/tools/footprint/README.reports Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,113 @@ 1.4 + Gross Dynamic Footprint Reports 1.5 + Chris Waterson <waterson@netscape.com> 1.6 + November 16, 2000 1.7 + 1.8 +This is a short primer on how to run the ``gross dynamic footprint'' 1.9 +reports. 1.10 + 1.11 +Win32 1.12 +----- 1.13 + 1.14 +I've tried this on Win2K. Should work on NT, probably not 98. 1.15 + 1.16 +1. Configure your machine with a ``standard'' mozilla build 1.17 +environment, as described at: 1.18 + 1.19 + http://www.mozilla.org/build/win32.html 1.20 + 1.21 +Specifically, you'll need the Cygnus tools (GNU make, awk, sed), which 1.22 +can be downloaded from: 1.23 + 1.24 + http://sourceware.cygnus.com/cygwin/download.html 1.25 + 1.26 +2. Install the Win32 version of GNUplot, avaialable from: 1.27 + 1.28 + ftp://ftp.dartmouth.edu/pub/gnuplot/gnuplot3.7cyg.zip 1.29 + 1.30 +3. Configure a web server with the ``buster.cgi'' CGI script contained 1.31 +in this directory. 1.32 + 1.33 +4. Pull and build a ``release'' build. Besides the normal Win32 flags 1.34 +described on the Win32 build instructions, be sure that you've set the 1.35 +following: 1.36 + 1.37 + set BUILD_OPT=1 1.38 + set MOZ_DEBUG= 1.39 + 1.40 +That is, MOZ_DEBUG should be unset. 1.41 + 1.42 +5. To collect data and build the dynamic footprint graph, type the 1.43 +following command from the mozilla/tools/footprint directory: 1.44 + 1.45 + make --unix -fwin32-gdf.mk \ 1.46 + BUSTER_URL="http://myserver/cgi-bin/buster.cgi?refresh=10" 1.47 + 1.48 +(Replace ``myserver'' with the name of the webserver where you 1.49 +installed ``buster.cgi'' in step 3, above.) 1.50 + 1.51 +This should: 1.52 + 1.53 + - Build ``wm.exe'', which will spy on memory usage. 1.54 + - Run the winEmbed program over the top 100 URLs (from top100.txt) 1.55 + to generate a file called ``winEmbed.dat'' 1.56 + - Run mozilla over the top 100 URLs to generate a file called 1.57 + ``mozilla.dat'' 1.58 + - Use gnuplot to create a PNG image file called win32-gdf.png 1.59 + 1.60 +Linux 1.61 +----- 1.62 + 1.63 +1. Configure your machine with a ``standard'' mozilla build 1.64 +environment, as described at: 1.65 + 1.66 + http://www.mozilla.org/build/unix.html 1.67 + 1.68 +2. Install GNUplot, which is available as an RPM on RedHat-6.2 CDs 1.69 +(probably others, as well). 1.70 + 1.71 +3. Configure a web server with the ``buster.cgi'' CGI script contained 1.72 +in this directory. 1.73 + 1.74 +4. Pull and build a ``release build''. Here are the settings you 1.75 +should use in your .mozconfig file: 1.76 + 1.77 + ac_add_options --enable-optimize 1.78 + ac_add_options --disable-debug 1.79 + ac_add_options --enable-strip-libs 1.80 + 1.81 +5. To collect data and build the dynamic footprint graph, type the 1.82 +following command from the mozilla/tools/footprint directory: 1.83 + 1.84 + make -flinux-gdf.mk \ 1.85 + BUSTER_URL="http://myserver/cgi-bin/buster.cgi?refresh=10" 1.86 + 1.87 +(Replace ``myserver'' with the name of the webserver where you 1.88 +installed ``buster.cgi'' in step 3, above.) 1.89 + 1.90 +Details, details, details 1.91 +------------------------- 1.92 + 1.93 +1. When running these tests, you'll probably want to use predictable 1.94 +cache settings. You can modify $(DIST)/bin/defaults/pref/all.js to 1.95 +tweak settings that will be used by [win|gtk]Embed (these programs 1.96 +ignore profile-specific settings AFAIK). For example, I've used these 1.97 +to try to cull out cache usage altogether: 1.98 + 1.99 + pref("browser.cache.disk_cache_size", 0); 1.100 + pref("browser.cache.enable", false); 1.101 + pref("browser.cache.disk.enable", false); 1.102 + pref("browser.cache.memory_cache_size", 0); 1.103 + pref("browser.cache.disk_cache_ssl", false); 1.104 + 1.105 +I think the image cache has a pref that you can use to shut it off as 1.106 +well. Haven't found it yet. 1.107 + 1.108 +2. If you collect data using Mozilla (as Win32 will do, by default), I 1.109 +recommend using a clean profile for consistency's sake. Otherwise, 1.110 +results will vary based on random stuff like how big your bookmarks 1.111 +are, how big your global history is, whether or not you've started 1.112 +mail, etc. 1.113 + 1.114 +3. I removed the ``plugin downloader plugin'' libnullplugin.so, as 1.115 +well as all other plugins, from $(DIST)/bin/plugins so that no plugins 1.116 +would be loaded.