public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: "mjw at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: systemtap@sources.redhat.com
Subject: [Bug uprobes/10458] uaddr() returns one past current instruction for uprobes
Date: Fri, 31 Jul 2009 18:10:00 -0000	[thread overview]
Message-ID: <20090731181015.28468.qmail@sourceware.org> (raw)
In-Reply-To: <20090729111010.10458.mjw@redhat.com>


------- Additional Comments From mjw at redhat dot com  2009-07-31 18:10 -------
That worked very well. The advantage of this is that the pt_regs IP_REG now
always points to the actual instruction we are interested in. I added the same
for the kprobe variants. Now these act similarly to other probes that provice
pt_regs. This also means we can get rid of a anomaly in the unwinder where we
would always adjust the instruction by one even for cases where that wasn't
necessary (and where effectively we could unwind from the wrong spot just before
a function entry).

commit 6415dddecb81f59996e422e87e1d3da266d743e8
Author: Mark Wielaard <mjw@redhat.com>
Date:   Fri Jul 31 18:46:47 2009 +0200

    PR10458. User actual breakpoint address for [ku]probe[ret].
    
    Setup the pt_regs REG_IP to the actual breakpoint address before
    entering a probe handler for [ku]probe[ret] (and restore it after
    returning). This helps getting symbol resolution and backtraces
    more correct and makes it more conform with other probe handlers
    like the iutrace and profile timers that also provide pt_regs
    (which untill now exhibited off-by-one errors while unwinding).
    
    * tapsets.cxx (dwarf_derived_probe_group::emit_module_decls):
      Setup REG_IP correctly before calling enter_kprobe_probe
      and enter_kretprobe_probe, and restore afterwards.
      (uprobe_derived_probe_group::emit_module_decls): Likewise for
      enter_uprobe_probe and enter_uretprobe_probe.
      (kprobe_derived_probe_group::emit_module_decls): Likewise for
      enter_kprobe2_probe and enter_kretprobe2_probe.
    * runtime/unwind/i386.h (arch_unw_init_frame_info): Initialize
      info->call_frame to zero.
    * runtime/unwind/x86_64.h (arch_unw_init_frame_info): Likewise.


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


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

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

  parent reply	other threads:[~2009-07-31 18:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-29 11:10 [Bug uprobes/10458] New: " mjw at redhat dot com
2009-07-29 14:52 ` [Bug uprobes/10458] " fche at redhat dot com
2009-07-29 16:00 ` mhiramat at redhat dot com
2009-07-29 16:17 ` jkenisto at us dot ibm dot com
2009-07-29 17:22 ` jkenisto at us dot ibm dot com
2009-07-29 22:32 ` mjw at redhat dot com
2009-07-29 22:38 ` jistone at redhat dot com
2009-07-29 23:51 ` fche at redhat dot com
2009-07-30  0:28 ` jistone at redhat dot com
2009-07-30 14:44 ` mjw at redhat dot com
2009-07-31 18:10 ` mjw at redhat dot com [this message]
2009-07-31 18:29 ` jkenisto at us dot ibm dot com
2009-07-31 18:56 ` mjw 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=20090731181015.28468.qmail@sourceware.org \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=systemtap@sources.redhat.com \
    /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).