Copy raw perfetto trace to heap_profile output path.
Change-Id: I783c8a090e48da066f7b949b013a8d3d24134b38
diff --git a/tools/heap_profile b/tools/heap_profile
index 3938b64..5680a68 100755
--- a/tools/heap_profile
+++ b/tools/heap_profile
@@ -22,6 +22,7 @@
import atexit
import hashlib
import os
+import shutil
import signal
import subprocess
import sys
@@ -342,6 +343,7 @@
if os.path.lexists(symlink_path):
os.unlink(symlink_path)
os.symlink(profile_path, symlink_path)
+ shutil.copyfile('/tmp/profile', os.path.join(profile_path, 'raw-trace'))
print("Wrote profiles to {} (symlink {})".format(profile_path, symlink_path))
print("These can be viewed using pprof. Googlers: head to pprof/ and "