From 1109fb3cacc8bb667979780c2b4b12ce5bb64549 Mon Sep 17 00:00:00 2001 From: David Srbecky Date: Tue, 7 Apr 2015 20:21:06 +0100 Subject: Implement CFI for Quick. CFI is necessary for stack unwinding in gdb, lldb, and libunwind. Change-Id: Ic3b84c9dc91c4bae80e27cda02190f3274e95ae8 --- compiler/dex/quick/codegen_util.cc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'compiler/dex/quick/codegen_util.cc') diff --git a/compiler/dex/quick/codegen_util.cc b/compiler/dex/quick/codegen_util.cc index 232a2286e2..ff5f735255 100644 --- a/compiler/dex/quick/codegen_util.cc +++ b/compiler/dex/quick/codegen_util.cc @@ -1072,6 +1072,9 @@ Mir2Lir::Mir2Lir(CompilationUnit* cu, MIRGraph* mir_graph, ArenaAllocator* arena dex_cache_arrays_layout_(cu->compiler_driver->GetDexCacheArraysLayout(cu->dex_file)), pc_rel_temp_(nullptr), dex_cache_arrays_min_offset_(std::numeric_limits::max()), + cfi_(&last_lir_insn_, + cu->compiler_driver->GetCompilerOptions().GetGenerateGDBInformation(), + arena), in_to_reg_storage_mapping_(arena) { switch_tables_.reserve(4); fill_array_data_.reserve(4); @@ -1164,7 +1167,7 @@ CompiledMethod* Mir2Lir::GetCompiledMethod() { ArrayRef(encoded_mapping_table_), ArrayRef(vmap_encoder.GetData()), ArrayRef(native_gc_map_), - ArrayRef(), + ArrayRef(*cfi_.Patch(code_buffer_.size())), ArrayRef(patches_)); } -- cgit v1.2.3-59-g8ed1b