Code in can_use_hardware_watchpoint()

Jim Blandy
Mon Aug 16 00:04:00 GMT 1999

I'm not really familiar with this code, but:

> One solution is to add an:
>       else if (v->lval == lval_register)
>         return 0;

I think this is the right thing.

The value chain is supposed to be a list of all the values generated
while evaluating the watchpoint's expression.  (What if someone else
generates a value in the mean time?  Don't you think it's a bad idea
to draft a list intended for storage management into use in expression
analysis?  Bleah.)  If you find anything on there that could change,
but can't be watched, you should return zero.

But the fix seems so obvious there must be something else going on...

More information about the Gdb mailing list