[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Libunwind-devel] [PATCHv2 0/3] Add core dump unwinding support to libun
From: |
Denys Vlasenko |
Subject: |
[Libunwind-devel] [PATCHv2 0/3] Add core dump unwinding support to libunwind |
Date: |
Tue, 21 Feb 2012 18:19:42 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux i686; rv:10.0) Gecko/20120131 Thunderbird/10.0 |
On 02/10/2012 11:12 AM, Tommi Rantala wrote:
On 02/09/2012 02:03 PM, ext Denys Vlasenko wrote:
Please review.
Hi, couple of comments:
I tested this quickly also on ARM (Nokia N9), and with the register remapping
thing removed from _UCD_access_reg(), the example program gives backtraces that
match what gdb reports for couple of coredumps.
Great :)
- It would be nice if there was a way to add "backing files" to explicit
address ranges (e.g. based on a copy of /proc/pid/maps taken when the process crashed).
This would allow for processing of coredumps that have some of the program headers
intentionally stripped to save space:
http://gitorious.org/qa-tools/rich-core/trees/master/core-reducer
I propose to implement this later.
- Please do not call exit() or _exit() from the library, but fail gracefully
and return some error code. I would remove the _UCD_lib.[ch] files completely.
Ok.
- Please base your work against what is available in libunwind.git. That way
you will also avoid changes to generated files (Makefile.in etc) in your
patches.
Ok
- This one is probably obvious, but let me say it anyway: please change the
indentation to match the style used in libunwind code base.
Ok.
Updated patch set follows.
Patch 1:
Introduce struct elf_dyn_info: a common part of struct UPT_info
and struct UCD_info (to be introduced later).
Make _UPTi_find_unwind_table function operate only on this part
of struct UPT_info.
Patch 2:
Move ptrace-independent code from src/ptrace/_UPT_find_proc_info.c
to src/dwarf/{G,L}find_unwind_table.c. Name this moved function
"find_unwind_table()" - what name do you guys prefer?
We already have dwarf_search_unwind_table(), will it be confusing to also
have dwarf_find_unwind_table()?
Patch 3:
Add src/coredump/*. Took the review comments into an account:
uses code commonalized in patches 1, 2; reformatted to follow the style.
Please review.
--
vda