Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(114)

Unified Diff: tools/binary_size/README.md

Issue 2785483002: Reland of V2 of //tools/binary_size rewrite (diffs). (Closed)
Patch Set: add missing name= Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/binary_size/analyze.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/binary_size/README.md
diff --git a/tools/binary_size/README.md b/tools/binary_size/README.md
index e545b33e1c69da055df159ab19e4fb3f14089910..192070c9d3913331f0116e079ac75948a8174688 100644
--- a/tools/binary_size/README.md
+++ b/tools/binary_size/README.md
@@ -1,17 +1,17 @@
-# analyze.py
+# map2size.py
-Parses and processes a linker .map file and outputs the result as a .size file.
+Parses a linker .map(.gz) file and outputs the result as a .size(.gz) file.
## Example Usage:
# Android:
gn gen out/Release --args='target_os="android" is_official_build=true'
ninja -C out/Release -j 1000 libchrome.so
- tools/binary_size/analyze.py out/Release/lib.unstripped/libchrome.so.map.gz --output chrome.size -v
+ tools/binary_size/map2size.py out/Release/lib.unstripped/libchrome.so.map.gz chrome.size -v
# Linux:
gn gen out/Release --args='is_official_build=true'
ninja -C out/Release -j 1000 chrome
- tools/binary_size/analyze.py out/Release/chrome.map.gz --output chrome.size -v
+ tools/binary_size/map2size.py out/Release/chrome.map.gz chrome.size -v
# create_html_breakdown.py
@@ -22,35 +22,37 @@ Creates an interactive size breakdown as a stand-alone html report.
tools/binary_size/create_html_breakdown.py chrome.size --report-dir size-report -v
xdg-open size-report/index.html
-# query.py
+# console.py
Starts a Python interpreter where you can run custom queries.
## Example Usage:
- # Run a single query and exit rather than entering interactive mode:
- tools/binary_size/query.py chrome.size --query 'all_syms.WhereBiggerThan(1000)'
+ # Runs a single diff and exits (does not enter interactive mode).
+ tools/binary_size/console.py without_patch.size with_patch.size --query='Diff(size_info2, size_info1)'
- # Enters a Python REPL:
- tools/binary_size/query.py chrome.size
+ # Enters a Python REPL (it will print more guidance).
+ tools/binary_size/console.py chrome.size
# Roadmap:
Tracked in https://crbug.com/681694
- 1. Convert explain_binary_size_delta.py to use new data model.
- 1. More query.py features:
+ 1. Better serialization format (finalize it before people start to use it).
+ * Store only mangled names.
+ * Save space by clustering by path (in addition to section_name).
+ 1. More console.py features:
* Template Symbols - shows when templates lead to code bloat.
* Duplicate Symbols - shows when statics in headers are an issue.
* Overloaded Symbols - shows when overloads are excessive.
* Per-class / namespace size (no way to distinguish class vs namespace).
* Per-Chrome package (Chrome-specific grouping. e.g. name prefixes).
- * An interactive UI (either drop into python or use a web server).
+ * CSV output (for pasting into a spreadsheet).
1. More create_html_breakdown.py features:
* Convert paths from .o path to .cc path (better breakdowns).
- * Break down by query.py groupings (use query.py to define GroupBy()s,
- then render to html graph)
- 1. More analysis.py features:
+ * Via "ninja -t commands libchrome.so" (3 seconds on my machine).
+ * Break down by other groupings (e.g. create from nested `SymbolGroups`)
+ 1. More `map2size.py` features:
* Find out more about 0xffffffffffffffff addresses, and why such large
gaps exist after them.
* Use nm to get the full list of symbols that share the same address.
« no previous file with comments | « no previous file | tools/binary_size/analyze.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698