public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
From: Jim Blandy <jimb@codesourcery.com>
To: Thiago Jung Bauermann <bauerman@br.ibm.com>
Cc: gdb@sourceware.org
Subject: Re: Stepping off breakpoints in non-stop debugging mode
Date: Mon, 17 Dec 2007 19:41:00 -0000	[thread overview]
Message-ID: <m3bq8pjehc.fsf@codesourcery.com> (raw)
In-Reply-To: <1197861489.6746.323.camel@localhost.localdomain> (Thiago Jung Bauermann's message of "Mon, 17 Dec 2007 01:18:09 -0200")


Thiago Jung Bauermann <bauerman at br.ibm.com> writes:
> On Sat, 2007-12-08 at 01:23 -0800, Jim Blandy wrote:
>> For CodeSourcery's contract with Ericsson, I've implemented the
>> kprobes strategy for stepping off breakpoints in GDB for the i386; the
>> full patch is at the bottom of this message.  It introduces no
>> regressions on i386, using displaced stepping for stepping off all
>> breakpoints.  Combined with Vlad's work to leave breakpoints inserted
>> at all times, this gives us breakpoint behavior suitable for non-stop
>> debugging.
>> 
>> As far as the public GDB project is concerned, what do folks think
>> about the kprobes approach?
>
> Apologies if if you've already thought these through...
>
> Did you give any thoughts to the x86_64 instructions? I don't actually
> know much about them, but in this e-mail
>
> http://sourceware.org/ml/systemtap/2007-q1/msg00571.html
>
> Roland McGrath mentions some complexities involved in pc-relative
> addressing there, which don't exist in the i386 case. Also, he is
> concerned that instruction parsing would need to be carefully done.

This is a great find --- thanks very much.  I was aware of the
PC-relative addressing on the x86_64, but figured we'd cross that
bridge when we came to it.  From what Roland has written, it seems
that will be quite involved.

The interface I posted does allow the 'copy_insn' gdbarch method to
simply say, "I've taken care of emulating this instruction for you".
I don't know yet if that's practical in all the cases we care about.

      reply	other threads:[~2007-12-17 19:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-08  9:23 Jim Blandy
2007-12-08 17:04 ` Daniel Jacobowitz
2007-12-10 23:05   ` Jim Blandy
2007-12-10 23:17     ` Daniel Jacobowitz
2007-12-11 18:24       ` Jim Blandy
2007-12-11 18:44         ` Daniel Jacobowitz
2007-12-17  3:31 ` Thiago Jung Bauermann
2007-12-17 19:41   ` Jim Blandy [this message]

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=m3bq8pjehc.fsf@codesourcery.com \
    --to=jimb@codesourcery.com \
    --cc=bauerman@br.ibm.com \
    --cc=gdb@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).