This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] [PR tdep/20928] Decode properly flags of %ccr register on sparc64
On 03/20/2017 03:54 PM, Ivo Raisr wrote:
> On 17.3.2017 17:42, Pedro Alves wrote:
>> On 03/14/2017 08:37 AM, Ivo Raisr wrote:
>> I was hoping that someone who actually knows sparc would
>> take a look. :-)
>>
>> My only comment would be wondering about a adding some test.
>> E.g., some small assembly test in gdb.arch/ that you'd single-step
>> and make sure that the expected changes can be observed in
>> the affected registers / flags.
>
> Please see attached new patch extended with new tests added.
>
> Only the following files were added (compared to previous patch submission):
>
> gdb/testsuite/gdb.arch/sparc64-regs.S
> gdb/testsuite/gdb.arch/sparc64-regs.exp
>
> I.
Very nice! Feel free to push with a couple nits below fixed.
> diff --git a/gdb/testsuite/gdb.arch/sparc64-regs.exp b/gdb/testsuite/gdb.arch/sparc64-regs.exp
> new file mode 100644
> index 0000000..fff9964
> --- /dev/null
> +++ b/gdb/testsuite/gdb.arch/sparc64-regs.exp
> @@ -0,0 +1,117 @@
> +# Copyright 2017-2017 Free Software Foundation, Inc.
Single "2017".
> +##########################################
> +set lno [gdb_get_line_number "sparc64-regs.exp: after first %fsr" $srcfile]
> +gdb_test "break $srcfile:$lno" "Breakpoint \[0-9\] at .*"
Give this gdb_test a 3rd parameter that avoids showing the line
number in gdb.sum, to avoid spurious/unnecessary gdb.sum change
if/when the test source changes.
Thanks,
Pedro Alves