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
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)
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
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
The new version of malloc debug supports using a num field that is more
than one. Modify the parser to handle this case.
Bug: 74361929
Test: Ran on a file that contained non-one numbers and verified the output.
Change-Id: I158922e51ce99afff88f20a80df414d653f95e65
make dumpvar takes forever (~0.45s per variable on my machine), and the
information we want from it is already available in the environment.
Construct the paths we need ourselves, instead of relying on make to do
it for us, shaving off about a second from a gdbclient.py invocation.
Test: gdbclient.py -r ls
Change-Id: I8c563da726c8f61a23e2eb701f2f272a4c71d713
gdbclient.py -r allows to provide an executable to be run on the target.
Before this patch the absolute path of the executable had to be
provided. This was inconvenient as the user has to first look up for the
exe on the target before debuging it.
With this patch, gdbclient.py will look for the executable on the
target if an absolute path is not provided.
Test: gdbserver -r ls
Change-Id: I610fd0a57b034ba8864874eeb1f7345d4a7daad9
Signed-off-by: Kevin Rocard <krocard@google.com>
Users of gdbclient might not know that a new and improved version exist
in the form of gdbclient.py.
Change-Id: I65243a8d25a1ecbe8ff734d0be4dbe40b50db4b2
Signed-off-by: Kevin Rocard <krocard@google.com>
When using logwrapper, there is only a zygote heap. This caused
a divide by zero for the app heap.
Test: native_heapdump_viewer.py --html art/native_heap.txt > test.html
Change-Id: I7defd94935d72ee9c4cb6e53d7a1a308a1030eb3
Properties can include \n so get_props isn't sound, and it's not obvious how
to fix it (without adding something like cat's -v to getprop, which wouldn't
help the intended use case of working with arbitrary old devices).
Bug: https://issuetracker.google.com/37093233
Test: gdbclient -r /system/bin/date
Change-Id: I96042fd44f1de17974968954fab6c916a9d13b61