From 91cc06c1814bd1d0fd6635bc3d7632a2bb7b0e7c Mon Sep 17 00:00:00 2001 From: David Srbecky Date: Mon, 7 Mar 2016 16:13:58 +0000 Subject: Mark DWARF lines in non-debuggable methods as "not a statement". This is a hint to the debugger that breakpoints and stepping might not function as intended (since we have limited information). Change-Id: I23c4a816182cc7548fcd69fbd00112225e7b1710 --- compiler/optimizing/optimizing_compiler.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'compiler/optimizing/optimizing_compiler.cc') diff --git a/compiler/optimizing/optimizing_compiler.cc b/compiler/optimizing/optimizing_compiler.cc index b49b91d984..42f22afd80 100644 --- a/compiler/optimizing/optimizing_compiler.cc +++ b/compiler/optimizing/optimizing_compiler.cc @@ -913,7 +913,8 @@ bool OptimizingCompiler::JitCompile(Thread* self, return false; } - if (GetCompilerDriver()->GetCompilerOptions().GetGenerateDebugInfo()) { + const CompilerOptions& compiler_options = GetCompilerDriver()->GetCompilerOptions(); + if (compiler_options.GetGenerateDebugInfo()) { const auto* method_header = reinterpret_cast(code); const uintptr_t code_address = reinterpret_cast(method_header->GetCode()); CompiledMethod compiled_method( @@ -936,6 +937,7 @@ bool OptimizingCompiler::JitCompile(Thread* self, access_flags, code_item, false, // deduped. + compiler_options.GetNativeDebuggable(), code_address, code_address + code_allocator.GetSize(), &compiled_method -- cgit v1.2.3-59-g8ed1b