addr2line may abort and "result" may be incomplete. This leads to
"index out of range" exceptions. Enclose this in a try & except block
and on exception, default to function:location = ---:---
Test: "python native_heapdump_viewer_tests.py" (after CL:780974)
passes.
BUG: 117306194
Change-Id: I4fd5c784949f279550aec95b68045df4a671da74
fca3084 introduced an additional argument to ParseNativeHeap().
This CL updates the test to reflect the same.
Test: "python native_heapdump_viewer_tests.py" executes without
any errors.
Change-Id: I6c196205ead2cb6abd4a646a3ac53e62ae3e5038
This topic removes ashmem from ART. Changes the names in development/
too. It only affects "dalvik-" ashmem regions which are the majority.
Change-Id: I1186eb60087384847892f655bec8174169ffd6c4
Signed-off-by: Joel Fernandes <joelaf@google.com>
Bug: 112357697
Test: Verified that this doesn't cause any issues with a stack.
Test: Faked an exception and verified no crash.
Change-Id: I61982dbd44ac4f52b008bc35bbff2d9687f6ae25
Fixed backward calculation of mapping offset.
Added logic to page align the data offset for uncompressed shared
objects. This fixes symbolization.
Bug: 111268230
Test: inspect native heap dump for the Camera app
Change-Id: If1af41e7265f017c1a691008309c8a002d5f588e
For zip files, try to open the file in the current directory and
insert the files as mappings. This enables the script to pick up
embedded .so files.
Added a check to look in current directory before the symbol dir.
Added --app-symbols option to specify the directory containing the
app APK and so files.
Test: manual
Bug: 111268230
(cherry picked from commit b284c20247)
Merged-In: Id1b1f13bac78911daa6a72c35ebfadfdc9c1700f
Change-Id: Ia8d3dd64f16e1d06d929b4023292cb98a438ea3e
For zip files, try to open the file in the current directory and
insert the files as mappings. This enables the script to pick up
embedded .so files.
Added a check to look in current directory before the symbol dir.
Added --app-symbols option to specify the directory containing the
app APK and so files.
Test: manual
Bug: 111268230
Change-Id: Id1b1f13bac78911daa6a72c35ebfadfdc9c1700f
Fix a bug where processes that didn't have a leading space from right
justification of the pid column would return the process name instead
of the pid, by switching to pgrep.
Bug: http://b/111748205
Test: manual
Change-Id: I3493474540ccfa89f5bb3e66153d9e96ec8bf1d9
This only includes a few tests to start with.
Bug: 62492960
Test: Ran new unit tests.
Test: Ran with all different options and verified it produces the same
Test: output as the previous script.
Change-Id: Iad29a5f04f49986139c92030a3259cae512859af
In Android P, the version field did not get incremented properly in
all places. So if a file with a v1.0 version is found, do a further check
to verify if the num field is really valid.
Test: Verified that a file with v1.0 gets checked and the valid num field
Test: is set correctly.
Test: Verified that a file with v1.1 automatically gets num field set to
Test: valid.
Change-Id: I7f828294c833e334cad76a866bbaa1d78ac02cfb
Merged-In: I7f828294c833e334cad76a866bbaa1d78ac02cfb
(cherry picked from commit b558fe4d53)
In Android P, the version field did not get incremented properly in
all places. So if a file with a v1.0 version is found, do a further check
to verify if the num field is really valid.
Test: Verified that a file with v1.0 gets checked and the valid num field
Test: is set correctly.
Test: Verified that a file with v1.1 automatically gets num field set to
Test: valid.
Change-Id: I7f828294c833e334cad76a866bbaa1d78ac02cfb
Switching from remote to extended-remote allows the program being
debugged to be restarted like a normal non-remote program.
Test: Used gdbclient debugging ICU things for a while, restarted often
Bug: None
Change-Id: Ia295749b9aa86727479d760d7c743f98a06fa6d4
Make it so that these can be used in other scripts by moving them from
functions defined in envsetup.sh to standalone scripts.
Test: stacks zygote64
Change-Id: I55ba76b248c54d9193fb019b7f4aca2f4c3a05bd
`pid zygote` will match zygote64 as well, but someone using `stacks
zygote` clearly wants the 32-bit version. Attempt an exact match before
we try a nonexact one.
Test: stacks zygote
Test: stacks zygote64
Change-Id: I5fd75cdbe4982c7ea831749c9ba823a2451e5490
- Take a heapdump and open it with ahat on the browser:
runhat2 PID_OR_PROCESS_NAME
- Take thread stacktrace dump
stacktrace PID_OR_PROCESS_NAME
TODO: Remove runhat? Is there anyone still using it?
Bug: 110088132
Test: stacktrace system_server
Test: stacktrace $(pid system_server)
Test: stacktrace com.android.systemui
Test: runhat2 system_server
Change-Id: I8ee4b51ac9097d5342d2d4209407a4b8ac4d5945
Update for newer debuggerd output marking the memory dump around
the currently executed code.
Add a hack for ARM assembly: override the assembler-emitted $d
symbol marking all our .byte data, so that objdump will disassemble
as instructions.
Test: manual
Change-Id: I100ed9e0ce39c073d5885cc430d78c24fef38882