Document deobfuscation of heapprofd profiles.
Change-Id: I97964136404df74f20cdafe22b70dfa9d820b177
diff --git a/docs/data-sources/native-heap-profiler.md b/docs/data-sources/native-heap-profiler.md
index d10d62f..b501ceb 100644
--- a/docs/data-sources/native-heap-profiler.md
+++ b/docs/data-sources/native-heap-profiler.md
@@ -299,6 +299,22 @@
an ELF file with the given build id. This way, you will not have to worry
about correct filenames.
+## Deobfuscation
+
+If your profile contains obfuscated Java methods (like `fsd.a`), you can
+provide a deobfuscation map to turn them back into human readable. You can
+get a deobfuscation map for your trace using `tools/traceconv deobfuscate`.
+
+To do so, use the `PERFETTO_PROGUARD_MAP` environment variable, using the
+format `packagename=filename[:packagename=filename...]`, e.g.
+`PERFETTO_PROGUARD_MAP=com.example.pkg1=foo.txt:com.example.pkg2=bar.txt`.
+Then concatenate the resulting file to your trace.
+
+```
+PERFETTO_PROGUARD_MAP=com.example.pkg tools/traceconv deobfuscate ${TRACE} > deobfuscation_map
+cat ${TRACE} deobfuscation_map > deobfuscated_trace
+```
+
## Troubleshooting
### Buffer overrun