OLD | NEW |
1 # Tools for analyzing Chrome's binary size | 1 # Tools for analyzing Chrome's binary size |
2 | 2 |
3 # Super Size | 3 # Super Size |
4 | 4 |
5 Collect, archive, and analyze Chrome's binary size. | 5 Collect, archive, and analyze Chrome's binary size. |
6 | 6 |
7 ## "archive" | 7 ## "archive" |
8 | 8 |
9 Collect size information and dump it into a `.size` file. Mainly consists of | 9 Collect size information and dump it into a `.size` file. Mainly consists of |
10 symbol information parsed from a linker .map file. | 10 symbol information parsed from a linker .map file. |
11 | 11 |
12 ### Example Usage: | 12 ### Example Usage: |
13 | 13 |
14 # Android: | 14 # Android: |
15 gn gen out/Release --args='target_os="android" is_official_build=true' | 15 # Googlers: |
| 16 gn gen out/Release --args='is_official_build=true symbol_level=1 is_chrome_b
randed=true target_os="android"' |
| 17 # Non-Googlers: |
| 18 gn gen out/Release --args='is_official_build=true symbol_level=1 exclude_unw
ind_tables=true ffmpeg_branding="Chrome" proprietary_codecs=true target_os="andr
oid"' |
16 ninja -C out/Release -j 1000 libchrome.so | 19 ninja -C out/Release -j 1000 libchrome.so |
17 tools/binary_size/supersize archive chrome.size --elf-file out/Release/lib.u
nstripped/libchrome.so -v | 20 tools/binary_size/supersize archive chrome.size --elf-file out/Release/lib.u
nstripped/libchrome.so -v |
| 21 |
18 # Linux: | 22 # Linux: |
19 gn gen out/Release --args='is_official_build=true' | 23 LLVM_DOWNLOAD_GOLD_PLUGIN=1 gclient runhooks # One-time download. |
| 24 # Googlers: |
| 25 gn gen out/Release --args='is_official_build=true symbol_level=1 is_chrome_b
randed=true' |
| 26 # Non-Googlers: |
| 27 gn gen out/Release --args='is_official_build=true symbol_level=1 exclude_unw
ind_tables=true ffmpeg_branding="Chrome" proprietary_codecs=true' |
20 ninja -C out/Release -j 1000 chrome | 28 ninja -C out/Release -j 1000 chrome |
21 tools/binary_size/supersize archive chrome.size --elf-file out/Release/chrom
e -v | 29 tools/binary_size/supersize archive chrome.size --elf-file out/Release/chrom
e -v |
22 | 30 |
23 ## "html_report" | 31 ## "html_report" |
24 | 32 |
25 Creates an interactive size breakdown (by source path) as a stand-alone html | 33 Creates an interactive size breakdown (by source path) as a stand-alone html |
26 report. | 34 report. |
27 | 35 |
28 ## Example Usage: | 36 ## Example Usage: |
29 | 37 |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 1. Integrate with `resource_sizes.py` so that it tracks size of major | 91 1. Integrate with `resource_sizes.py` so that it tracks size of major |
84 components separately: chrome vs blink vs skia vs v8. | 92 components separately: chrome vs blink vs skia vs v8. |
85 1. Speed up some steps (like normalizing names) via multiprocessing. | 93 1. Speed up some steps (like normalizing names) via multiprocessing. |
86 1. Add dependency graph info, perhaps just on a per-file basis. | 94 1. Add dependency graph info, perhaps just on a per-file basis. |
87 | 95 |
88 # Roadmap for diagnose_apk_bloat.py: | 96 # Roadmap for diagnose_apk_bloat.py: |
89 1. More `diagnose_apk_bloat.py` features: | 97 1. More `diagnose_apk_bloat.py` features: |
90 | 98 |
91 * Add diffing functionality to see diff stats for two commits. | 99 * Add diffing functionality to see diff stats for two commits. |
92 * Add --cloud option for using artifacts from perf builders. | 100 * Add --cloud option for using artifacts from perf builders. |
OLD | NEW |