Bug 229424 - FEAT: libunwind-using-elfutils for symbols resolving
Summary: FEAT: libunwind-using-elfutils for symbols resolving
Keywords:
Status: CLOSED INSUFFICIENT_DATA
Alias: None
Product: Fedora
Classification: Fedora
Component: libunwind
Version: rawhide
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jan Kratochvil
QA Contact:
URL:
Whiteboard: bzcl34nup
Depends On: 230793 230850 230903
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-02-20 22:46 UTC by Mike Cvet
Modified: 2008-05-07 01:12 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-05-07 01:12:56 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Test program (2.54 KB, application/octet-stream)
2007-02-20 22:46 UTC, Mike Cvet
no flags Details
gcc -S -g stepper.c (8.72 KB, application/octet-stream)
2007-02-20 22:47 UTC, Mike Cvet
no flags Details
Implementation (v2). (55.74 KB, patch)
2007-03-04 15:43 UTC, Jan Kratochvil
no flags Details | Diff
Implementation (v4). (57.02 KB, patch)
2007-03-06 23:29 UTC, Jan Kratochvil
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Sourceware 4083 0 None None None Never

Description Mike Cvet 2007-02-20 22:46:15 UTC
From referenced bug:

When stepping into new functions on i386, the frame being stepped 
from may dissapear during the first instruction of that stack frame.

The frame then reappears on subsequent steps.

I'll attach the source of a test program and its assembly.

Stepping into 'jump()' from 'foo()' results in the stack trace missing frame 
'foo()' on the first instruction of the new frame.

Comment 1 Mike Cvet 2007-02-20 22:46:15 UTC
Created attachment 148454 [details]
Test program

Comment 2 Mike Cvet 2007-02-20 22:47:48 UTC
Created attachment 148455 [details]
gcc -S -g stepper.c

Comment 3 Jan Kratochvil 2007-02-25 12:33:27 UTC
Problem is that -fasynchronous-unwind-tables is not default on i?86 and so
.eh_frame is not present there. .eh_frame is the only unwind information
currently supported by libunwind.
GDB supports also .debug_frame (generated by -g) and so it handles the case
without problem.
libunwind supports heuristics for unwinding without .eh_frame in general cases
(function bodies) but it fails in the prologue as was reported here.

libunwind support for .debug_frame has been discussed at:
http://lists.gnu.org/archive/html/libunwind-devel/2007-02/msg00000.html

Considering this Bug as a tracker for libunwind based on elfutils unwinding method.


Comment 4 Jan Kratochvil 2007-03-04 15:43:09 UTC
Created attachment 149211 [details]
Implementation (v2).

Currently it passes the testsuite (tested on x86) with some exceptions below.
Performance looks as a bit lower but it was not investigated so far.
Code could be cleaned up a bit but some David Mosberger-Tang internal API
advices could be helpful.

Comment 5 Jan Kratochvil 2007-03-04 15:45:33 UTC
Bug 230903: FEAT: dwfl_module_addrname() should also return lowpc+highpc
results in this current libunwind-using-elfutils testsuite regression:

Backtrace does not match on level==7, want "_start+", got "_start"
FAILURE: detected 1 errors
FAIL: run-ptrace-stepper
Backtrace does not match on level==5, want "_start+", got "_start"
FAILURE: detected 1 errors
Backtrace does not match on level==5, want "_start+", got "_start"
FAILURE: detected 1 errors
Backtrace does not match on level==5, want "_start+", got "_start"
FAILURE: detected 1 errors
Backtrace does not match on level==5, want "_start+", got "_start"
FAILURE: detected 1 errors
XFAIL: run-ptrace-signull


Comment 6 Jan Kratochvil 2007-03-04 15:48:30 UTC
Implementation currently needs for VDSO symbols resolving a kernel workaround
Bug 230850: [kernel] /proc/PID/mem is not readable
implemented to elfutils; needed on kernel-xen-2.6.19-1.2898.2.3.fc7.i686.
Some unlisted libunwind-using-elfutils testsuite regressions apply otherwise.


Comment 7 Jan Kratochvil 2007-03-04 15:52:23 UTC
Implementation currently recommends to rather use an elfutils bugfix
Bug 230793: File descriptors leakage
Some unlisted libunwind-using-elfutils testsuite regressions apply otherwise
(the regressions may no longer be true as elfutils caching is now implemented).


Comment 8 Jan Kratochvil 2007-03-06 23:29:57 UTC
Created attachment 149409 [details]
Implementation (v4).

npremji: Tested/bugfixed now also on x86_64.
It should be usable with elfutils-0.126-1 (only Bug 230793 fix is recommended).

Comment 9 Jan Kratochvil 2007-04-29 17:59:04 UTC
NEEDINFO(npremji) as a dependency on his work-in-progress libunwind
changes as there may be conflicts of these two patches.  This patch should get
applied after his one gets applied.

This patch (of Comment 8) should also get ported to elfutils-0.127-1 finally
fixing Bug 230903 needing the patch update.  It also fixes Bug 230793 referenced
in Comment 8.


Comment 10 Nurdin Premji 2007-04-30 15:03:49 UTC
(In reply to comment #9)
My patches are mostly in, with maybe a few bugfixes to follow.


Comment 11 Bug Zapper 2008-04-03 19:12:49 UTC
Based on the date this bug was created, it appears to have been reported
against rawhide during the development of a Fedora release that is no
longer maintained. In order to refocus our efforts as a project we are
flagging all of the open bugs for releases which are no longer
maintained. If this bug remains in NEEDINFO thirty (30) days from now,
we will automatically close it.

If you can reproduce this bug in a maintained Fedora version (7, 8, or
rawhide), please change this bug to the respective version and change
the status to ASSIGNED. (If you're unable to change the bug's version
or status, add a comment to the bug and someone will change it for you.)

Thanks for your help, and we apologize again that we haven't handled
these issues to this point.

The process we're following is outlined here:
http://fedoraproject.org/wiki/BugZappers/F9CleanUp

We will be following the process here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping to ensure this
doesn't happen again.

Comment 12 Bug Zapper 2008-05-07 01:12:55 UTC
This bug has been in NEEDINFO for more than 30 days since feedback was
first requested. As a result we are closing it.

If you can reproduce this bug in the future against a maintained Fedora
version please feel free to reopen it against that version.

The process we're following is outlined here:
http://fedoraproject.org/wiki/BugZappers/F9CleanUp


Note You need to log in before you can comment on or make changes to this bug.