public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Doug Evans <dje@google.com>
To: Jan Kratochvil <jan.kratochvil@redhat.com>
Cc: Luis Machado <luisgpm@linux.vnet.ibm.com>,
	gdb-patches@sourceware.org,
	       Pedro Alves <pedro@codesourcery.com>,
	       Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
Subject: Re: [PATCH] testcases: Fix assorted problems related to powerpc
Date: Tue, 09 Nov 2010 05:46:00 -0000	[thread overview]
Message-ID: <AANLkTi=qiRA7yHQwFamcD5z77wbEFHJu2OmWn1Uobz+s@mail.gmail.com> (raw)
In-Reply-To: <20101109044704.GA24214@host0.dyn.jankratochvil.net>

On Mon, Nov 8, 2010 at 8:47 PM, Jan Kratochvil
<jan.kratochvil@redhat.com> wrote:
> On Wed, 29 Sep 2010 15:34:01 +0200, Luis Machado wrote:
>> Updated patch without the "fix" to watch-read.exp.
>
> Checked-in with the same \. -> \\. change as described in:
>        Re: [PATCH] testsuite: break-entry.exp: convert entry point for ppc64
>        http://sourceware.org/ml/gdb-patches/2010-10/msg00057.html
>
> Tested on:
>        {x86_64,x86_64-m32}-fedora14-linux-gnu
>        {ppc64,ppc64-m32}-rhel6-linux-gnu
>
>
> Thanks,
> Jan
>
>
> http://sourceware.org/ml/gdb-cvs/2010-11/msg00043.html
>
> --- src/gdb/testsuite/ChangeLog 2010/11/08 18:05:55     1.2502
> +++ src/gdb/testsuite/ChangeLog 2010/11/09 04:44:16     1.2503
> @@ -1,3 +1,13 @@
> +2010-11-09  Edjunior Machado  <emachado@br.ibm.com>
> +           Luis Machado  <luisgpm@br.ibm.com>
> +
> +       * gdb.base/maint.exp: Expect "." prefix.
> +       * gdb.base/nodebug.exp: Expect "." Likewise.
> +       * gdb.base/sepsymtab.exp: Expect "." Likewise.
> +       * gdb.base/watchpoint-cond-gone.exp: Likewise.
> +       * gdb.base/watchpoint.exp: Expect a software watch to be created for
> +       POWER server processors.
> +
>  2010-11-08  Edjunior Machado  <emachado@br.ibm.com>
>            Luis Machado  <luisgpm@br.ibm.com>
>
> --- src/gdb/testsuite/gdb.base/maint.exp        2010/09/08 17:22:26     1.48
> +++ src/gdb/testsuite/gdb.base/maint.exp        2010/11/09 04:44:17     1.49
> @@ -253,7 +253,7 @@
>            -re "msymbols_output\r\n$gdb_prompt $" {
>                send_gdb "shell grep factorial msymbols_output\n"
>                gdb_expect {
> -                   -re "\\\[ *$decimal\\\] \[tT\]\[ \t\]+$hex factorial.*$gdb_prompt $" {
> +                   -re "\\\[ *$decimal\\\] \[tT\]\[ \t\]+$hex \\.?factorial.*$gdb_prompt $" {
>                        pass "maint print msymbols"
>                    }
>                    -re ".*$gdb_prompt $"     { fail "maint print msymbols" }
> @@ -280,7 +280,7 @@
>        gdb_test_multiple "shell ls msymbols_output2" "maint print msymbols" {
>            -re "msymbols_output2\r\n$gdb_prompt $" {
>                gdb_test_multiple "shell grep factorial msymbols_output2" "maint print msymbols" {
> -                   -re "\\\[ *$decimal\\\] \[tT\]\[ \t\]+$hex factorial.*$gdb_prompt $" {
> +                   -re "\\\[ *$decimal\\\] \[tT\]\[ \t\]+$hex \\.?factorial.*$gdb_prompt $" {
>                        pass "maint print msymbols"
>                    }
>                    -re ".*$gdb_prompt $" {
> --- src/gdb/testsuite/gdb.base/nodebug.exp      2010/05/25 19:34:04     1.14
> +++ src/gdb/testsuite/gdb.base/nodebug.exp      2010/11/09 04:44:17     1.15
> @@ -75,7 +75,7 @@
>
>     if {![test_compiler_info "gcc-*"]} then { setup_xfail "mips-sgi-irix5*" "mips-sgi-irix6*" }
>     gdb_test "p top" \
> -       "\{(<(text variable|function), no debug info>|short \\(int\\)|short \\(\\))\} \[0-9a-fx]* <top(\\(int\\)|)>"
> +       "\{(<(text variable|function), no debug info>|short \\(int\\)|short \\(\\))\} \[0-9a-fx]* <\\.?top(\\(int\\)|)>"
>     if {![test_compiler_info "gcc-*"]} then { setup_xfail "mips-sgi-irix5*" "mips-sgi-irix6*" }
>     gdb_test "whatis top" \
>        "(<(text variable|function), no debug info>|short \\(int\\)|short \\(\\))"
> @@ -85,7 +85,7 @@
>     if {![test_compiler_info "gcc-*"]} then { setup_xfail "mips-sgi-irix5*" }
>     setup_xfail "mips-sgi-irix6*"
>     gdb_test "p middle" \
> -       "\{(<(text variable|function), no debug info>|short \\(int\\)|short \\(\\))\} \[0-9a-fx]* <middle(\\(int\\)|)>"
> +       "\{(<(text variable|function), no debug info>|short \\(int\\)|short \\(\\))\} \[0-9a-fx]* <\\.?middle(\\(int\\)|)>"
>     if {![test_compiler_info "gcc-*"]} then { setup_xfail "mips-sgi-irix5*" }
>     setup_xfail "mips-sgi-irix6*"
>     gdb_test "whatis middle" \
> --- src/gdb/testsuite/gdb.base/sepsymtab.exp    2010/01/01 07:32:01     1.9
> +++ src/gdb/testsuite/gdb.base/sepsymtab.exp    2010/11/09 04:44:17     1.10
> @@ -45,7 +45,7 @@
>  set command "info sym main"
>  set command_regex [string_to_regexp $command]
>  gdb_test_multiple "$command" "$command" {
> -    -re "^${command_regex}\[\r\n\]+main in section \[^\r\n\]+\[\r\n\]+$gdb_prompt \$" {
> +    -re "^${command_regex}\[\r\n\]+\\.?main in section \[^\r\n\]+\[\r\n\]+$gdb_prompt \$" {
>        pass "$command"
>     }
>  }
> --- src/gdb/testsuite/gdb.base/watchpoint-cond-gone.exp 2010/06/01 21:29:21     1.2
> +++ src/gdb/testsuite/gdb.base/watchpoint-cond-gone.exp 2010/11/09 04:44:17     1.3
> @@ -46,6 +46,7 @@
>
>  # We may stay either in the function itself or only at the first instruction of
>  # its caller depending on the epilogue unwinder (or valid epilogue CFI) presence.
> +
>  gdb_test "finish" \
> -        "Watchpoint .* deleted because the program has left the block in.*which its expression is valid..*in (jumper|func).*" \
> +        "Watchpoint .* deleted because the program has left the block in.*which its expression is valid..*in (\\.?jumper|func).*" \
>         "Catch the no longer valid watchpoint"
> --- src/gdb/testsuite/gdb.base/watchpoint.exp   2010/09/04 15:30:09     1.31
> +++ src/gdb/testsuite/gdb.base/watchpoint.exp   2010/11/09 04:44:17     1.32
> @@ -683,7 +683,13 @@
>            "$watchpoint_msg \[0-9\]+: \\*\\(int \\*\\) 0"
>        delete_breakpoints
>
> -       gdb_test "watch *global_ptr" "$watchpoint_msg \[0-9\]+: \\*global_ptr"
> +       # This step requires two HW watchpoints.  Since PPC Server only has
> +       # a single one, it will use a SW watchpoint in this case.
> +       if [istarget powerpc64-*] {
> +           set watchpoint_msg "Watchpoint"
> +       }
> +
> +       gdb_test "watch *global_ptr" "$watchpoint_msg \[0-9\]+: \\\*global_ptr"
>        gdb_test "set \$global_ptr_breakpoint_number = \$bpnum" ""
>        gdb_test "next" ".*global_ptr = buf.*" "global_ptr next"
>        gdb_test_multiple "next" "next over ptr init" {

I wonder if it would be sufficiently useful to have comments there to
explain why the \\.? is present.
It could even be factored out to something like

set ppc_prefix "\\.?"

or a function call that prepended the prefix when necessary.

It feels like an obscure target-specific detail that is going to get
scattered throughout the testsuite.

  reply	other threads:[~2010-11-09  5:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-29 16:32 Luis Machado
2010-11-09  4:47 ` Jan Kratochvil
2010-11-09  5:46   ` Doug Evans [this message]
2010-11-27 22:09   ` Andreas Schwab
  -- strict thread matches above, loose matches on Subject: below --
2010-09-28 21:47 Luis Machado
2010-09-28 21:48 ` Pedro Alves
2010-09-29 15:04   ` Luis Machado

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='AANLkTi=qiRA7yHQwFamcD5z77wbEFHJu2OmWn1Uobz+s@mail.gmail.com' \
    --to=dje@google.com \
    --cc=emachado@linux.vnet.ibm.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jan.kratochvil@redhat.com \
    --cc=luisgpm@linux.vnet.ibm.com \
    --cc=pedro@codesourcery.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).