From 1b404a8b34f6fa80342955cb0a61673503328b51 Mon Sep 17 00:00:00 2001 From: Vladimir Marko Date: Fri, 1 Sep 2017 13:35:26 +0100 Subject: Add debug info for link-time generated thunks. Add debug info for method call thunks (currently unused) and Baker read barrier thunks. Refactor debug info generation for trampolines and record their sizes; change their names to start with upper-case letters, so that they can be easily generated as `#fn_name`. This improved debug info must be generated by `dex2oat -g`, the debug info generated by `oatdump --symbolize` remains the same as before, except for the renamed trampolines and an adjustment for "code delta", i.e. the Thumb mode bit. Cortex-A53 erratum 843419 workaround thunks are not covered by this CL. Test: Manual; run-test --gdb -Xcompiler-option -g 160, pull symbols for gdbclient, break in the introspection entrypoint, check that gdb knows the new symbols (and disassembles them) and `backtrace` works when setting $pc to an address in the thunk. Bug: 36141117 Change-Id: Id224b72cfa7a0628799c7db65e66e24c8517aabf --- compiler/debug/method_debug_info.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'compiler/debug/method_debug_info.h') diff --git a/compiler/debug/method_debug_info.h b/compiler/debug/method_debug_info.h index ed1da2c26e..567891087a 100644 --- a/compiler/debug/method_debug_info.h +++ b/compiler/debug/method_debug_info.h @@ -17,6 +17,8 @@ #ifndef ART_COMPILER_DEBUG_METHOD_DEBUG_INFO_H_ #define ART_COMPILER_DEBUG_METHOD_DEBUG_INFO_H_ +#include + #include "compiled_method.h" #include "dex_file.h" @@ -24,7 +26,7 @@ namespace art { namespace debug { struct MethodDebugInfo { - const char* trampoline_name; + std::string trampoline_name; const DexFile* dex_file; // Native methods (trampolines) do not reference dex file. size_t class_def_index; uint32_t dex_method_index; -- cgit v1.2.3-59-g8ed1b