public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "palves at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug gdb/9310] nexti command does not work when debugging ARM assembly language
Date: Fri, 26 Oct 2012 18:38:00 -0000	[thread overview]
Message-ID: <bug-9310-4717-mVS1JBztDY@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-9310-4717@http.sourceware.org/bugzilla/>

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

Pedro Alves <palves at redhat dot com> changed:

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

--- Comment #2 from Pedro Alves <palves at redhat dot com> 2012-10-26 18:38:19 UTC ---
ARM or Thumb?  A fix went in on 2012-08-22, for Thumb 'bx pc' and 'blx pc'.

Otherwise, it may be simpler if you could debug this.  Here's how.

Debug the arm gdb with the host's (x86, I presume) gdb.  On the (arm/android)
gdb, and put a breakpoint on that particular bl instruction's address, and run
to it (b *0xADDR; c).  Then, on the top (x86) gdb, set a breakpoint on
arm_get_next_pc, and let the android gdb continue.  Tell the android GDB to
continue the android program as well.  arm_get_next_pc will be hit.  This is
the function that computes where the execution will land next, so GDB can put a
breakpoint there, so that the android program executes only one instruction (is
single-stepped).  The symptom of the bug usually means that for some reason
this computing the next pc goes wrong.  It's usually evident whether the
computed address looks reasonable or not.

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


  parent reply	other threads:[~2012-10-26 18:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-9310-4717@http.sourceware.org/bugzilla/>
2012-10-26  8:40 ` zhudonghai at gmail dot com
2012-10-26 18:38 ` palves at redhat dot com [this message]
2012-10-27  9:10 ` zhudonghai at gmail dot com
2012-11-22 18:50 ` palves at redhat dot com
2013-10-30 17:32 ` will.newton at gmail 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-9310-4717-mVS1JBztDY@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=gdb-prs@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).