[rfc, rfa/doc] Multi-threaded watchpoint improvements

Daniel Jacobowitz drow@false.org
Sat Sep 22 14:04:00 GMT 2007


On Sat, Sep 22, 2007 at 11:03:43AM +0200, Eli Zaretskii wrote:
> Thanks (and sorry for the delay in reviewing: it was a busy week).

No problem - I appreciate your looking at it!

> The old text clearly separated the description of what GDB does for
> data-write watchpoints from what it does for date-read/data-access
> watchpoints.  The new text confuses things, because it doesn't keep
> that separation.  I suggest to rephrase the last paragraph as follows:

I like your version.

>   watched value has changed.  Watchpoints whose watched values has
>   changed are announced as hit.

"have changed", right?

> Also, I don't understand the purpose of this sentence:
> 
> > +@value{GDBN} only supports process-wide watchpoints.
> 
> "Process-wide watchpoints'' as opposed to what?

As opposed to thread-specific watchpoints.  We can make a watchpoint
act like it is thread-specific (or we will be able to once Luis's
patch is done), but we don't support setting hardware watchpoints that
only trigger in a specific thread.  Yet, anyway.

> Is this perhaps the opposite of ``process-wide watchpoints''?  If so,
> it sounds like a contradiction: first you say we don't support
> per-thread watchpoints, then you say we do (for some platforms).
> 
> What am I missing here?

This is how I implement a process-wide watchpoint -- which is what the
core target-independent parts of GDB support -- using thread-specific
watchpoint registers supported by i386 GNU/Linux.

Does that clarify?  Something like "process-wide watchpoints, which
trigger in all threads"?

-- 
Daniel Jacobowitz
CodeSourcery



More information about the Gdb-patches mailing list