This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: Remote watchpoint support.
- To: jtc at redback dot com
- Subject: Re: Remote watchpoint support.
- From: Eli Zaretskii <eliz at delorie dot com>
- Date: Tue, 31 Oct 2000 04:06:56 -0500 (EST)
- CC: msalter at redhat dot com, gdb-patches at sources dot redhat dot com
- References: <200010301416.e9UEG6m18981@deneb.localdomain> <5mg0leoyg6.fsf@jtc.redback.com>
- Reply-to: Eli Zaretskii <eliz at is dot elta dot co dot il>
> From: jtc@redback.com (J.T. Conklin)
> Date: 30 Oct 2000 12:39:53 -0800
>
> One thing I dislike about it is that the debug agent never explicitly
> tells GDB that a watchpoint has been hit, but rather it is implicitly
> coded in the return value of the query.
I agree that this is not a good design.
> The second is the return value of 0 if the target stopped for another
> reason. I (now) know that this is the current behavior of the target_
> stopped_data_address() macro, but it use the one address that I think
> might be very important to watch on targets where the zero page isn't
> unmapped (in which case a reference would cause a exception/trap).
I would actually be very happy if we could change the interface of
target_stopped_data_address so that zero would not be treated
specially. One problem with the current design is that I cannot catch
NULL pointer dereferences on Windows, where the null page cannot be
unmapped from the address space of DJGPP programs. This prevents me
from finding such bugs by setting a watchpoint at address 0.
> While it might not be possible to fix in GDB's internals for some
> time
What would it take to change that? Perhaps it would be a good idea to
have the list of the obstacles, in case someone might try to negotiate
them one by one.