Bug 12458 - Incorrect module bias on prelinked "find"
Summary: Incorrect module bias on prelinked "find"
Status: RESOLVED FIXED
Alias: None
Product: systemtap
Classification: Unclassified
Component: translator (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-01 23:29 UTC by Josh Stone
Modified: 2011-03-16 21:19 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments
section info for un-prelinked find (1.43 KB, text/plain)
2011-02-01 23:30 UTC, Josh Stone
Details
section info for prelinked find (1.56 KB, text/plain)
2011-02-01 23:30 UTC, Josh Stone
Details
section info for find.debug (1.57 KB, text/plain)
2011-02-01 23:31 UTC, Josh Stone
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Josh Stone 2011-02-01 23:29:29 UTC
Original report: http://sourceware.org/ml/systemtap/2011-q1/msg00182.html

I've reproduced this on Fedora 14 x86_64 -- probing every function in "find" segfaults the child; probing just "main" results in no probe hits.  Using "prelink -u" restores the expected behavior.  Using GDB, I see that dwfl_module_getdwarf is returning a bias=0x38.  Looking at the section information, indeed several of the sections were shifted 0x38 by prelink, including the PROGBITS .interp, but .text is not moved at all, so we should probably still expect bias=0 overall.

elfutils-0.151-1.fc14.x86_64
findutils-4.5.9-2.fc14.x86_64
gcc-4.5.1-4.fc14.x86_64
prelink-0.4.3-4.fc14.x86_64
systemtap commit 55b377f

Attachments will follow with eu-readelf -hlS for prelinked, prelink-u, and .debug.
Comment 1 Josh Stone 2011-02-01 23:30:19 UTC
Created attachment 5223 [details]
section info for un-prelinked find
Comment 2 Josh Stone 2011-02-01 23:30:48 UTC
Created attachment 5224 [details]
section info for prelinked find
Comment 3 Josh Stone 2011-02-01 23:31:14 UTC
Created attachment 5225 [details]
section info for find.debug
Comment 4 Josh Stone 2011-02-02 18:21:36 UTC
Roland posted his analysis on the Fedora bug report:
  https://bugzilla.redhat.com/show_bug.cgi?id=674465

His fixes are in elfutils.git, and it appears to work now for me.  Once a new elfutils release is made, we'll close this bug and recommend users upgrade.
Comment 5 Frank Ch. Eigler 2011-02-24 23:02:09 UTC
elfutils 0.152 released with the needed fixes.