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

Unified Diff: tools/find_runtime_symbols/prepare_symbol_info.py

Issue 10825075: Classify memory usage by allocated type in Deep Memory Profiler. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 8 years, 3 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 | « tools/find_runtime_symbols/parse_proc_maps.py ('k') | tools/find_runtime_symbols/proc_maps.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/find_runtime_symbols/prepare_symbol_info.py
diff --git a/tools/find_runtime_symbols/prepare_symbol_info.py b/tools/find_runtime_symbols/prepare_symbol_info.py
index 50654b1a74b9234c2f01b78c6559a5478416b16b..4c40b4e961ef2a0159ff161f0bf5dc5a6f1a4882 100755
--- a/tools/find_runtime_symbols/prepare_symbol_info.py
+++ b/tools/find_runtime_symbols/prepare_symbol_info.py
@@ -12,8 +12,7 @@ import subprocess
import sys
import tempfile
-from parse_proc_maps import parse_proc_maps
-from util import executable_condition
+from proc_maps import ProcMaps
def _dump_command_result(command, output_dir_path, basename, suffix, log):
@@ -88,11 +87,11 @@ def prepare_symbol_info(maps_path, output_dir_path=None, loglevel=logging.WARN):
shutil.copyfile(maps_path, os.path.join(output_dir_path, 'maps'))
with open(maps_path, mode='r') as f:
- maps = parse_proc_maps(f)
+ maps = ProcMaps.load(f)
log.debug('Listing up symbols.')
files = {}
- for entry in maps.iter(executable_condition):
+ for entry in maps.iter(ProcMaps.executable):
log.debug(' %016x-%016x +%06x %s' % (
entry.begin, entry.end, entry.offset, entry.name))
nm_filename = _dump_command_result(
@@ -101,7 +100,7 @@ def prepare_symbol_info(maps_path, output_dir_path=None, loglevel=logging.WARN):
if not nm_filename:
continue
readelf_e_filename = _dump_command_result(
- 'readelf -e %s' % entry.name,
+ 'readelf -eW %s' % entry.name,
output_dir_path, os.path.basename(entry.name), '.readelf-e', log)
if not readelf_e_filename:
continue
« no previous file with comments | « tools/find_runtime_symbols/parse_proc_maps.py ('k') | tools/find_runtime_symbols/proc_maps.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698