diff options
author | Daniel Jacobowitz <drow@false.org> | 2007-10-01 00:17:58 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2007-10-01 00:17:58 +0000 |
commit | d983da9c3dfa91e6840fee2a7479d98ee4759f13 (patch) | |
tree | 9a1c14b44f1a2de2d2c087b00d987deb2fe8274d /gdb/testsuite/gdb.threads/watchthreads.c | |
parent | d830e0e0c9d4b1827385c473cb545e07a72c9b81 (diff) | |
download | gdb-d983da9c3dfa91e6840fee2a7479d98ee4759f13.zip gdb-d983da9c3dfa91e6840fee2a7479d98ee4759f13.tar.gz gdb-d983da9c3dfa91e6840fee2a7479d98ee4759f13.tar.bz2 |
2007-09-16 Daniel Jacobowitz <dan@codesourcery.com>
Jeff Johnston <jjohnstn@redhat.com>
* breakpoint.c (watchpoints_triggered): New.
(bpstat_stop_status): Remove STOPPED_BY_WATCHPOINT argument.
Check watchpoint_triggered instead. Combine handling for software
and hardware watchpoints. Do not use target_stopped_data_address
here. Always check a watchpoint if its scope breakpoint triggers.
Do not stop for thread or overlay events. Improve check for
triggered watchpoints without a value change.
(watch_command_1): Insert the scope breakpoint first. Link the
scope breakpoint to the watchpoint.
* breakpoint.h (enum watchpoint_triggered): New.
(struct breakpoint): Add watchpoint_triggered.
(bpstat_stop_status): Update prototype.
(watchpoints_triggered): Declare.
* infrun.c (enum infwait_status): Add infwait_step_watch_state.
(stepped_after_stopped_by_watchpoint): Delete.
(handle_inferior_event): Make stepped_after_stopped_by_watchpoint
local. Handle infwait_step_watch_state. Update calls to
bpstat_stop_status. Use watchpoints_triggered to check
watchpoints.
* remote.c (stepped_after_stopped_by_watchpoint): Remove extern.
(remote_stopped_data_address): Do not check it.
* gdb.texinfo (Setting Watchpoints): Adjust warning text about
multi-threaded watchpoints.
* gdbint.texinfo (Watchpoints): Describe how watchpoints are
checked. Describe sticky notification. Expand description
of steppable and continuable watchpoints.
(Watchpoints and Threads): New subsection.
* gdb.threads/watchthreads.c (thread_function): Sleep between
iterations.
* gdb.threads/watchthreads.exp: Allow two watchpoints to trigger
at once for S/390. Generate matching fails and passes.
Diffstat (limited to 'gdb/testsuite/gdb.threads/watchthreads.c')
-rw-r--r-- | gdb/testsuite/gdb.threads/watchthreads.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/testsuite/gdb.threads/watchthreads.c b/gdb/testsuite/gdb.threads/watchthreads.c index c607429..ef391f0 100644 --- a/gdb/testsuite/gdb.threads/watchthreads.c +++ b/gdb/testsuite/gdb.threads/watchthreads.c @@ -56,7 +56,7 @@ void *thread_function(void *arg) { /* Don't run forever. Run just short of it :) */ while (*myp > 0) { - (*myp) ++; /* Loop increment. */ + (*myp) ++; usleep (1); /* Loop increment. */ } pthread_exit(NULL); |