public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Yao Qi <yao@codesourcery.com>
Cc: Michal Lesniewski <m.lesniewski@samsung.com>, gdb@sourceware.org
Subject: Re: Implementation of different software breakpoint kinds in gdb server
Date: Thu, 18 Oct 2012 10:42:00 -0000	[thread overview]
Message-ID: <507FDD00.1000309@redhat.com> (raw)
In-Reply-To: <507FD9CB.7060805@codesourcery.com>

On 10/18/2012 11:28 AM, Yao Qi wrote:
> On 10/18/2012 06:08 PM, Pedro Alves wrote:
>> Offhand, the main issues with tracepoints on ARM are:
>>
>> #1 - gdbserver needs to know how to step over the tracepoints, without gdb's intervention.
>>
>> #2 - ARM can't hw single-step, so that needs to be done the hard way, with breakpoints
>>      (a.k.a., software single-step).
>>      All the logic to do that is in gdb.  This conflicts with #1.
>>
>> So we'd need to teach gdbserver to software single-step.  Maybe it's possible
>> to tell offline all the possible destinations of an instruction, so we could still
>> leave that logic in gdb, but I suspect not.
> 
> I am wondering that it might be relatively easier to implement fast tracepoint in which step-over is not needed, if finding a jumppad is not a problem :)

Maybe.  :-)

The "move out of jumppad" logic uses single-stepping.  I guess we could come up
with something clever to avoid it.  Related, linux_fast_tracepoint_collecting logic
assumes it can identify a thread from its tls base / thread area.  And this assumes
you can retrieve this address without an infcall.  This is possible on x86.  Don't know
about ARM (well, in an ABI-stable way).

-- 
Pedro Alves

  reply	other threads:[~2012-10-18 10:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-18  9:23 Michal Lesniewski
2012-10-18 10:08 ` Pedro Alves
2012-10-18 10:28   ` Yao Qi
2012-10-18 10:42     ` Pedro Alves [this message]
2012-10-18 11:44   ` Michal Lesniewski
2012-10-18 12:01     ` Pedro Alves
2012-10-19  0:31       ` John Gilmore
2012-10-19  8:51         ` Michal Lesniewski

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=507FDD00.1000309@redhat.com \
    --to=palves@redhat.com \
    --cc=gdb@sourceware.org \
    --cc=m.lesniewski@samsung.com \
    --cc=yao@codesourcery.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).