From: Daniel Jacobowitz <drow@mvista.com>
To: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: gdb-patches@sources.redhat.com
Subject: Re: mips gdbserver reports R0 != 0
Date: Tue, 27 Jan 2004 17:12:00 -0000 [thread overview]
Message-ID: <20040127171204.GA6369@nevyn.them.org> (raw)
In-Reply-To: <20040128.000717.126570739.anemo@mba.ocn.ne.jp>
On Wed, Jan 28, 2004 at 12:07:17AM +0900, Atsushi Nemoto wrote:
> >>>>> On Tue, 27 Jan 2004 09:17:18 -0500, Daniel Jacobowitz <drow@mvista.com> said:
>
> >> I could not see the reason (maybe regcache?), but this patch fixed
> >> my problem.
>
> drow> Did it fix the stepping problem, or did it fix the value
> drow> displayed for $zero?
>
> Both. My stepping problem is triggered by wrong $zero value. I tried
> with 'set debug remote 1' and found gdb inserted breakpoint at wrong
> place when stepping 'beqz' instruction.
Oh, I see how this happens now. Thanks for the explanation; in that
case something definitely needs to be done.
> drow> The register at that address is actually a saved flag used for
> drow> syscall restarting. I have some local patches to support it
> drow> properly, but I haven't had time to do anything with them :(
> drow> Partly because of the number of gross hacks involved.
>
> The 'that address' means &pt_regs->regs[0] in kernel, right?
>
> I had not noticed that. Thank you. So my patch is not correct.
>
> Maybe the correct fix is clearing register cache in
> new_register_cache(). I will try later.
Explicitly zeroing the register cache should fix this, so I'd be
happier with that solution.
[Do you have a copyright assignment on file for GDB, btw? If not, I'll
make the patch myself for you to test, to spare us the legal dance.]
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
next prev parent reply other threads:[~2004-01-27 17:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-27 10:35 Atsushi Nemoto
2004-01-27 14:17 ` Daniel Jacobowitz
2004-01-27 15:01 ` Atsushi Nemoto
2004-01-27 17:12 ` Daniel Jacobowitz [this message]
2004-01-28 1:33 ` Atsushi Nemoto
2004-01-29 1:51 ` Atsushi Nemoto
2004-01-30 15:09 ` Daniel Jacobowitz
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=20040127171204.GA6369@nevyn.them.org \
--to=drow@mvista.com \
--cc=anemo@mba.ocn.ne.jp \
--cc=gdb-patches@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