This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 1/2] watchpoint-reuse-slot.exp: skip some tests on targets have different wp and bp registers
- From: Pedro Alves <palves at redhat dot com>
- To: Yao Qi <qiyaoltc at gmail dot com>, gdb-patches at sourceware dot org
- Date: Mon, 16 Mar 2015 12:34:58 +0000
- Subject: Re: [PATCH 1/2] watchpoint-reuse-slot.exp: skip some tests on targets have different wp and bp registers
- Authentication-results: sourceware.org; auth=none
- References: <1426257692-30461-1-git-send-email-qiyaoltc at gmail dot com>
On 03/13/2015 02:41 PM, Yao Qi wrote:
> From: Yao Qi <yao.qi@linaro.org>
>
> watchpoint-reuse-slot.exp sets two hardware breakpoint and/or watchpoint,
> to test the same debugging register can be used correctly. However,
> on some targets, such as arm and aarch64, hardware has different
> registers for breakpoint and watchpoint, so don't have to do test
> if one breakpoint and one watchpoint are requested and target hardware
> has different debugging registers for breakpoint and watchpoint.
Hmm, is this just to save test time? If so, I'd prefer not skipping,
as it may always catch other bugs, in the target backends or
the kernel.
Despite the test's file name, the test doesn't actually create two
breakpoints/watchpoints at the same time, as mentioned at the top
of the file.
In any case:
> +# Return true if the same debugging register can be used for both
s/can be/is/
> +# watchpoint and breakpoint.
> +
> +proc dbg_registers_for_watch_and_break {} {
I think "same" should be in the proc name:
same_dbg_registers_for_watch_and_break
> + if { [istarget "arm*-linux*"] || [istarget "aarch64*-*-linux*"] } {
> + # arm and aarch64 has different registers for watchpoint and
s/has/have/
Thanks,
Pedro Alves