This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
RE: [pushed] Add test to make sure GDB knows which "kind" of watchpoint the target has
- From: "Pierre Muller" <pierre dot muller at ics-cnrs dot unistra dot fr>
- To: "'Pedro Alves'" <palves at redhat dot com>, <gdb-patches at sourceware dot org>
- Date: Tue, 16 Sep 2014 15:23:44 +0200
- Subject: RE: [pushed] Add test to make sure GDB knows which "kind" of watchpoint the target has
- Authentication-results: sourceware.org; auth=none
- References: <1410873512-762-1-git-send-email-palves at redhat dot com>
Hi Pedro,
I think there is a typo inside this:
> + set sw_watch_pc [get_pc "get sw watchpoint PC"]
> +
> + delete_breakpoints
> +
> + # Allow hardware watchpoints again.
> + gdb_test_no_output "set can-use-hw-watchpoints 1"
> +
> + gdb_test "watch global" \
> + "Hardware watchpoint .*: global" \
> + "set hardware watchpoint on global variable"
> +
> + gdb_test "continue" \
> + "Hardware watchpoint .*: global.*Old value = 1.*New value =
> 2.*set_global \\(val=2\\).*$srcfile.*" \
> + "hardware watchpoint triggers"
> +
> + set hw_watch_pc [get_pc "get hw watchpoint PC"]
> +
> + gdb_assert {$sw_watch_pc == $sw_watch_pc} "hw watchpoint stops at
> right instruction"
Shouldn't this be
{$sw_watch_pc == $hw_watch_pc}?
Pierre Muller