Don't use AOT code for native methods for java debuggable runtime

For java debuggable runtimes we need the capability to deoptimize
the caller to support debug features such as method redefinitions.
To support this we need the ability to call method entry / exit
hooks. Currently this is supported by instrumenting the stack by
updating the return pcs to instrumentation return pcs and installing
instrumentation entry points. This adds additional complexity when
walking the stack and in other places.

We want to avoid this by adding capability to call method entry / exit
hooks directly from JITed code / generic stubs. For generic stubs it
is OK to check if method entry / exit hooks are required always since
generic stubs are on slow path anyway. For JITed code we would enable
this support only for debuggable runtime to avoid any overhead for
regular runtime. Since AOT compiled code doesn't have the capability
to call method entry / exit hooks we want don't want to use them for
debuggable runtime. For non-native methods we don't use AOT code
This CL avoids using AOT code for native methods too.

Test: art/test.py
Bug: 206029744
Change-Id: I566401ebea6d866e818287ede6f000876cb24240
3 files changed