Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* `step'-like commands in breakpoint commands list
@ 1999-04-12 15:51 Philippe De Muyter
  1999-04-13 21:10 ` Todd Whitesel
  0 siblings, 1 reply; 2+ messages in thread
From: Philippe De Muyter @ 1999-04-12 15:51 UTC (permalink / raw)
  To: gdb-patches

On m68k-motorola-sysv and on powerpc-ibm-aix4.1.5.0, with gdb-4.17.87,
the testsuite fails at `continue in infrun_breakpoint_command_test', because
the breakpoint commands list is only executed up to the first `step' command.
The patch below fixes that.

Tue Apr 13 00:31:48 1999  Philippe De Muyter  <phdm@macqel.be>

	* infrun.c (clear_proceed_status): Do not set `breakpoint_proceeded'.

--- ./infrun.c	Tue Apr 13 00:30:53 1999
+++ ./infrun.c	Tue Apr 13 00:30:48 1999
@@ -783,7 +783,13 @@ clear_proceed_status ()
   stop_after_trap = 0;
   stop_soon_quietly = 0;
   proceed_to_finish = 0;
+#if 0 /* FIXME : Disabled 1999-04-12 by phdm@macqel.be, to allow `step',
+	 `next', `finish', etc. to work in breakpoint commands list.  As
+	 this is the only instruction that sets `breakpoint_proceeded',
+	 all the `breakpoint_proceeded'-related stuff could also be removed.
+	 */
   breakpoint_proceeded = 1;	/* We're about to proceed... */
+#endif
 
   /* Discard any remaining commands or status from previous stop.  */
   bpstat_clear (&stop_bpstat);


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: `step'-like commands in breakpoint commands list
  1999-04-12 15:51 `step'-like commands in breakpoint commands list Philippe De Muyter
@ 1999-04-13 21:10 ` Todd Whitesel
  0 siblings, 0 replies; 2+ messages in thread
From: Todd Whitesel @ 1999-04-13 21:10 UTC (permalink / raw)
  To: gdb-patches

> On m68k-motorola-sysv and on powerpc-ibm-aix4.1.5.0, with gdb-4.17.87,
> the testsuite fails at `continue in infrun_breakpoint_command_test', because
> the breakpoint commands list is only executed up to the first `step' command.
> The patch below fixes that.
...
> +#if 0 /* FIXME : Disabled 1999-04-12 by phdm@macqel.be, to allow `step',
> +	 `next', `finish', etc. to work in breakpoint commands list.  As
> +	 this is the only instruction that sets `breakpoint_proceeded',
> +	 all the `breakpoint_proceeded'-related stuff could also be removed.
> +	 */
>    breakpoint_proceeded = 1;	/* We're about to proceed... */
> +#endif

Is this patch safe?? What about the comment further down:

	/* The inferior is proceeded by the command; bomb out now.
	   The bpstat chain has been blown away by wait_for_inferior.
	   But since execution has stopped again, there is a new bpstat
	   to look at, so start over.  */

I should also note that due to the recursive implementation of
bpstat_do_actions(), it is probably not a good idea to allow
bpstat_do_action() calls to accumulate on the stack if the inferior
keeps hitting breakpoints that have command lists. Also, when you
request a Quit, then GDB forgets all that breakpoint command list
state, and behaves differently when you continue the inferior.

-- 
Todd Whitesel
toddpw @ wrs.com


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1999-04-13 21:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-04-12 15:51 `step'-like commands in breakpoint commands list Philippe De Muyter
1999-04-13 21:10 ` Todd Whitesel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox