diff options
author | Nicholas Duffek <nsd@redhat.com> | 2000-04-07 01:14:10 +0000 |
---|---|---|
committer | Nicholas Duffek <nsd@redhat.com> | 2000-04-07 01:14:10 +0000 |
commit | 2f09097b734af8840d2141a26a53b9c67e67fcf2 (patch) | |
tree | c6fd0a041816d5bfb6211d1fde18788f1e51d223 /gdb/testsuite | |
parent | 34cbe64ecf7ae8c7e029e4af582d98a7910a3bcf (diff) | |
download | gdb-2f09097b734af8840d2141a26a53b9c67e67fcf2.zip gdb-2f09097b734af8840d2141a26a53b9c67e67fcf2.tar.gz gdb-2f09097b734af8840d2141a26a53b9c67e67fcf2.tar.bz2 |
* sol-thread.c (GET_LWP, GET_THREAD, BUILD_LWP, BUILD_THREAD):
Change to rely on PIDGET etc.
* config/i386/nm-i386sol2.h (TARGET_HAS_WATCHPOINTS,
TARGET_CAN_USE_HARDWARE_WATCHPOINT, HAVE_CONTINUABLE_WATCHPOINT,
STOPPED_BY_WATCHPOINT, target_[insert/remove]_watchpoint):
define. Allow target to use procfs hardware watchpoints.
* config/sparc/nm-sun4sol2.h: ditto.
* config/i386/tm-i386sol2.h (PIDGET, TIDGET, MERGEPID): modify
definitions to use 16 bits for the pid, 15 bits for the tid, and
1 bit for the flag.
* config/sparc/tm-sun4sol2.h: ditto.
(SOFTWARE_SINGLE_STEP, SOFTWARE_SINGLE_STEP_P): undefine.
* testsuite/gdb.threads/pthreads.exp (all_threads_running): Allow
for more than 15 thread increments.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r-- | gdb/testsuite/gdb.threads/pthreads.exp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gdb/testsuite/gdb.threads/pthreads.exp b/gdb/testsuite/gdb.threads/pthreads.exp index 15a5df8..2e7f29c 100644 --- a/gdb/testsuite/gdb.threads/pthreads.exp +++ b/gdb/testsuite/gdb.threads/pthreads.exp @@ -113,7 +113,7 @@ proc all_threads_running {} { # been called 15 times. This should be plenty of time to allow # every thread to run at least once, since each thread sleeps for # one second between calls to common_routine. - gdb_test "tbreak common_routine if hits == 15" "" + gdb_test "tbreak common_routine if hits >= 15" "" # Start all the threads running again and wait for the inferior # to stop. Since no other breakpoints are set at this time @@ -135,9 +135,16 @@ proc all_threads_running {} { # Check that we stopped when we actually expected to stop, by # verifying that there have been 15 previous hits. + # NOTE: Because of synchronization behavior, it is possible for + # more than one thread to increment "hits" between one breakpoint + # trap and the next. So stopping after 16 or 17 hits should be + # considered acceptable. + send_gdb "p common_routine::hits\n" gdb_expect { -re ".*= 15\r\n$gdb_prompt $" {} + -re ".*= 16\r\n$gdb_prompt $" {} + -re ".*= 17\r\n$gdb_prompt $" {} default { fail "stopped before calling common_routine 15 times" return 0 |