Re: Why no hwatch command in gdb ?

Tom Tromey
2011-03-10T21:04:08Z

>>>>> "Philippe" == Philippe Waroquiers <philippe.waroquiers@skynet.be> writes:

Philippe> On the side of 'hardware' watchpoints limitations:
Philippe> I am busy embedding a gdbserver inside Valgrind (target is
Philippe> to integrate it in April, but more review activity is still needed).

Delightful.

Philippe> I only encountered a small problem with gdb "remote": There is
Philippe> a gdb command to configure the nr of remote hardware
Philippe> watchpoint but there is no command to configure the length for
Philippe> an hardware watchpoint: e.g. for i386, gdb remote "hardcodes"
Philippe> the length to 4 bytes (which looks wrong btw, as the real hw
Philippe> can go up to 8 bytes I believe).

Philippe> So, I have in a corner a patch implementing
Philippe> 'set remote hardware-watchpoint-length-limit'
Philippe> to configure the max length limit of an hw watchpoint.

Philippe> I believe it would be nice to add this new command in gdb.

As far as I understand it, this sounds ok.

Why can't this be negotiated between gdb and the remote?
Then the in-valgrind gdbserver could just report unlimited and the user
wouldn't have to fool around.

Philippe> If you want more info about the gdbserver in Valgrind, I can
Philippe> give more (I expect to output a new improved beta version of
Philippe> the Valgrind gdbserver patch in the coming days).

If you send out announcements, feel free to CC this list.

Tom