public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: "mjw at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: systemtap@sourceware.org
Subject: [Bug runtime/12566] usymbols.exp 64-bit test failing on ppc64
Date: Fri, 11 Mar 2011 21:29:00 -0000	[thread overview]
Message-ID: <bug-12566-6586-UKiEY5CaSG@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-12566-6586@http.sourceware.org/bugzilla/>

http://sourceware.org/bugzilla/show_bug.cgi?id=12566

Mark Wielaard <mjw at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mjw at redhat dot com

--- Comment #2 from Mark Wielaard <mjw at redhat dot com> 2011-03-11 21:29:16 UTC ---
(In reply to comment #1)
> In the 64-bit case (which fails):
> 
> # eu-readelf -s usymbols-m64  | fgrep main_handler
>    63: 0000000010010c48     16 FUNC    GLOBAL DEFAULT       22 main_handler
> # fgrep main_handler /tmp/stapImPRwN/stap-symbols.h 
>   { 0x10010c48, "main_handler" },
> 
> That's good, the eu-readelf and stap values match.
> 
> When run under gb,
> (gdb) p &main_handler
> $1 = (void (*)(int)) 0x10000700 <main_handler>
> 
> That's bad - when run, somehow the address has changed.
> 
> # fgrep /usymbols-m64 /proc/9183/maps 
> 10000000-10010000 r-xp 00000000 fd:00 2239236                           
> /root/ppc64/testsuite/usymbols-m64
> 10010000-10020000 rw-p 00000000 fd:00 2239236                           
> /root/ppc64/testsuite/usymbols-m64
> 
> The 0x10010c48 address exists within that 2nd non-executable vma (the code in
> vma.c only looks at executable vmas), which is why the symbol lookup code
> fails.  The gdb address (0x10000700) does exist within the 1st executable vma.
> 
> Perhaps there is some relocation going on that systemtap needs to know about.

The 0x10010c48 address is a pointer into the .odp table. So it is an indirect
address to the real function address. We had a little discussion on making
systemtap deal with that better on the mailinglist:
http://sourceware.org/ml/systemtap/2011-q1/threads.html#00082

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

  parent reply	other threads:[~2011-03-11 21:29 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-10 19:43 [Bug runtime/12566] New: " dsmith at redhat dot com
2011-03-11 21:02 ` [Bug runtime/12566] " dsmith at redhat dot com
2011-03-11 21:29 ` mjw at redhat dot com [this message]
2011-08-25  2:49 ` phan at redhat dot com
2017-10-11 10:44 ` mark at klomp dot org
2017-10-11 10:48 ` mjw at fedoraproject dot org
2023-12-06 15:48 ` wcohen at redhat dot com

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-12566-6586-UKiEY5CaSG@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=systemtap@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).