• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1memory_watcher is a library that can be linked into chromium to trace the
2memory allocations. It works by hooking the system allocation/deallocation
3functions, and recording the actions.
4
5To use memory_watcher in chromium:
6
7(1) Compile the memory_watcher library (it is part of the solution by default)
8
9(2) Run chromium with these flags "--memory-profile -no-sandbox"
10(The instrumentation doesn't work with the sandbox)
11
12(3) Hit ctrl-alt-D  to generate a dump of the memory allocations.
13This will create a log file called memorywatcher.logXXXX for every
14chromium process (where XXXX is the pid).
15
16The log file is a human readable text format, which can be further analyzed
17using the helpers in the "scripts/" directory.
18