This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA]: Watchpoints per thread patch
- From: Ulrich Weigand <Ulrich dot Weigand at de dot ibm dot com>
- To: jjohnstn at redhat dot com
- Cc: gdb-patches at sources dot redhat dot com
- Date: Fri, 5 Nov 2004 12:48:51 +0100
- Subject: Re: [RFA]: Watchpoints per thread patch
Jeff Johnston wrote:
> (s390_remove_one_watchpoint): New function.
> (s390_remove_watchpoint_callback): Ditto.
> (s390_remove_watchpoint): Change to iterate through lwps and
> remove the specified watchpoint for each thread.
> (s390_insert_one_watchpoint): New function.
> (s390_insert_watchpoint_callback): Ditto.
> (s390_insert_watchpoint): Change to iterate through lwps and
> insert the specified watchpoint on each thread.
Note that s390_insert/remove_watchpoint simply manipulate a global
data structure holding current watch points; only the routine
s390_fix_watch_points actually changes per-thread kernel state.
So it would appear simpler to only call s390_fix_watch_points
in a per-thread loop, and leave the higher-level functions alone.
(When a new thread attaches, you only need to run s390_fix_watch_points
on the new thread as well.)
Mit freundlichen Gruessen / Best Regards
Ulrich Weigand
--
Dr. Ulrich Weigand
Linux for S/390 Design & Development
IBM Deutschland Entwicklung GmbH, Schoenaicher Str. 220, 71032 Boeblingen
Phone: +49-7031/16-3727 --- Email: Ulrich.Weigand@de.ibm.com