Pass method signature in exit and entry hooks

Previously app-inspection relied on java relied on
java stacktracing to find which method was called.
But that approach was slow and wasn't able to
differ between method overloads.

Speed.
This approach is noticeably quicker than
using jmvti's stackstraces and allows us
to further cut down overhead per query
in db inspection. In my test case numbers are
100ms with this CL and 300ms with native stacktraces

Downsides.
Currently transformations doesn't take debug
information into the account. As a result when
exit hooks takes over register or scratch registers
are allocated debugger still receives old information
that doesn't match execution. This problem existed
before this change, this CL makes it slightly worse
by using register that was previously used in
"start locals".

Test: sign_exit_hook + tests in tools/base app-inspection
bug: 159250979
bug: 171812449
Change-Id: Idc0ceb01e2ec9f375b2ffef5c57f89209370c223
6 files changed
tree: a75b5e69beba5a07d2f5f1ffc59a1a7d0e534237
  1. dexter/
  2. slicer/
  3. testdata/
  4. .clang-format
  5. Android.bp
  6. OWNERS
  7. README.md
  8. TEST_MAPPING
README.md

This is the home of the .dex manipulation library (slicer) and command line tool (dexter).

Both the command line tool and the library can be built for host and device targets.

To build dexter:

$ m dexter

To test dexter:

# in tools/dexter (and assuming a Linux host)
$ python dexter/dexter_tests.py -cmd ../../out/host/linux-x86/bin/dexter -root testdata