- To: gdb-patches at sourceware dot cygnus dot com
- Subject: Re: GDB 5.0 won't build on GNU/Linux/sparc
- From: Alexandre Oliva <aoliva at cygnus dot com>
- Date: 20 May 2000 06:49:34 -0300
- Organization: Cygnus Solutions, a Red Hat Company
- References: <oraehlelgf.fsf@tamanduatei.dcc.unicamp.br>
On May 20, 2000, Alexandre Oliva <aoliva@cygnus.com> wrote:
> On GNU/Linux/sparc, it builds correctly, but it still doesn't work
> :-( child_resume is called with step==1, and aborts because
> SOFTWARE_SINGLE_STEP_P is also 1.
This patch fixes this problem, and now it appears to work (not that I
have tested it extensively!)
The problem was that, when resume issued the software single step
command, it cleared `step'. Later on, it would test whether step was
zero and think it had been asked to `continue'. Ok to install?
Index: gdb/ChangeLog
from Alexandre Oliva <aoliva@cygnus.com>
* infrun.c (resume): Do not change continue to step if we single
step on software.
Index: gdb/infrun.c
===================================================================
RCS file: /cvs/src/src/gdb/infrun.c,v
retrieving revision 1.6.2.2
diff -u -r1.6.2.2 infrun.c
--- gdb/infrun.c 2000/04/20 11:00:29 1.6.2.2
+++ gdb/infrun.c 2000/05/20 09:39:27
@@ -902,7 +902,7 @@
}
else
{
- if (!step)
+ if (!SOFTWARE_SINGLE_STEP_P && !step)
{
warning ("Internal error, changing continue to step.");
remove_breakpoints ();
--
Alexandre Oliva Enjoy Guaranį, see http://www.ic.unicamp.br/~oliva/
Cygnus Solutions, a Red Hat company aoliva@{redhat, cygnus}.com
Free Software Developer and Evangelist CS PhD student at IC-Unicamp
oliva@{lsd.ic.unicamp.br, gnu.org} Write to mailing lists, not to me
- To: Alexandre Oliva <aoliva at cygnus dot com>
- Subject: Re: GDB 5.0 won't build on GNU/Linux/sparc
- From: Michael Snyder <msnyder at cygnus dot com>
- Date: Wed, 28 Jun 2000 09:13:26 -0700
- CC: gdb-patches at sourceware dot cygnus dot com
- Organization: Cygnus Solutions
- References: <oraehlelgf.fsf@tamanduatei.dcc.unicamp.br> <ork8gpd00h.fsf@tamanduatei.dcc.unicamp.br> <org0r27nj1.fsf@saci.lsd.ic.unicamp.br>
- Reply-To: msnyder at cygnus dot com
Alexandre Oliva wrote:
>
> On May 20, 2000, Alexandre Oliva <aoliva@cygnus.com> wrote:
>
> > * infrun.c (resume): Do not change continue to step if we single
> > step on software.
>
> > Index: gdb/infrun.c
> > ===================================================================
> > RCS file: /cvs/src/src/gdb/infrun.c,v
> > retrieving revision 1.6.2.2
> > diff -u -r1.6.2.2 infrun.c
> > --- gdb/infrun.c 2000/04/20 11:00:29 1.6.2.2
> > +++ gdb/infrun.c 2000/05/20 09:39:27
> > @@ -902,7 +902,7 @@
> > }
> > else
> > {
> > - if (!step)
> > + if (!SOFTWARE_SINGLE_STEP_P && !step)
> > {
> > warning ("Internal error, changing continue to step.");
> > remove_breakpoints ();
>
> I'm not sure I understood the final decision regarding this patch.
> Should I check it in or not?
No. I'm not comfortable with it. I would like to know why
sunos/sparc and solaris/sparc etc. never needed this change.
It seems to me that other SOFTWARE_SINGLE_STEP_P targets must
have dealt with the situation differently, and probably
linux/sparc needs to do whatever they were doing.