On Tue, Jul 27, 2004 at 07:24:31PM -0400, Jeff Johnston wrote:
Daniel Jacobowitz wrote:
On Tue, Jul 27, 2004 at 02:56:19PM -0400, Jeff Johnston wrote:
+# Watch values that will be modified by distinct threads.
+gdb_test "watch args\[0\]" "Hardware watchpoint 2: args\\\[0\\\]"
+gdb_test "watch args\[1\]" "Hardware watchpoint 3: args\\\[1\\\]"
What about platforms without hardware watchpoints? This test will
generate a lot of FAILs in that case.
I mentioned this both in my original posting and in the test case itself.
There is a test for hardware watchpoints and if there are no hardware
watchpoints, it returns 0.
# This test verifies that a watchpoint is detected in the proper thread
# so the test is only meaningful on a system with hardware watchpoints.
if [target_info exists gdb,no_hardware_watchpoints] {
return 0;
}
OK. Unfortunately I don't think this test is conclusive; unix.exp will
always claim to have hardware watchpoints, and on many systems it does
not (for instance powerpc-linux). If that turns out to be true we can
introduce gdb_has_hardware_watchpoints or something along those lines.