This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA] Keep breakpoints always inserted.


On Sat, Mar 15, 2008 at 01:12:14PM +0300, Vladimir Prus wrote:
> > This patch is OK, if you will add the missing pieces: a NEWS entry and
> > documentation for the new command, and a testcase that enables
> > always-inserted and verifies that it isn't a brick.
> 
> I've added NEW and documentation.
> 
> I'm still not sure how to test this adequately.

This version is OK when Eli is happy with the documentation.

For a testcase, I agree that we need to run the whole testsuite in
this mode to get full coverage.  But it's useful to have a single
test that runs in this mode even if the rest of the testsuite
doesn't, in case someone completely breaks it.  That's why the
gdb.server tests run for native targets that build gdbserver,
even when the rest of the testsuite uses "run".

Could you write a test that uses "set break always-inserted" and does
something simple like running to a function and then continuing past
it to another breakpoint?

> +	  /* We're allowing a thread to run past a breakpoint it has
> +             hit, by single-stepping the thread with the breakpoint
> +             removed.  In which case, we need to single-step only this
> +             thread, and keep others stopped, as they can miss this
> +             breakpoint if allowed to run.
> +
> +	     The current code actually removes all breakpoints when
> +	     doing this, not just the one being stepped over, so if we
> +	     let other threads run, we can actually miss any
> +	     breakpoint, not just the one at PC.  */

Extra spacing here?

-- 
Daniel Jacobowitz
CodeSourcery


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]