From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: deuling@de.ibm.com (Markus Deuling)
Cc: gdb-patches@sourceware.org (GDB Patches)
Subject: Re: [patch]: Improve spu-info testcase
Date: Wed, 16 Jul 2008 19:29:00 -0000 [thread overview]
Message-ID: <200807161928.m6GJSR1W006890@d12av02.megacenter.de.ibm.com> (raw)
In-Reply-To: <4861E262.909@de.ibm.com> from "Markus Deuling" at Jun 25, 2008 08:14:58 AM
Markus Deuling wrote:
> * gdb.arch/spu-info.exp (tmp_file): Introduce temporary file and set
> it as command line argument for test binary. Delete after usage.
> * gdb.arch/spu-info.c (main): Receive command line arguments.
> (do_dma_test): Add file paramater.
Sorry for the late reply ...
> @@ -221,7 +218,10 @@ main (unsigned long long speid, unsigned
> res = do_event_test ();
>
> /* info spu dma */
> - res = do_dma_test ();
> + if (argc == 2)
> + res = do_dma_test (argv[1]);
> + else
> + res = do_dma_test ("/var/tmp/tmp_buf");
I'd prefer this gets passed *always* as argument, and the .exp script
chooses the name ...
> +set tmp_file ""
> +if { [info exists env(PWD)] &&
> + [info exists env(USER)] } then {
> + set tmp_file $env(PWD)/gdb_spu_info_$env(USER)
> + gdb_test "set args $tmp_file" "" ""
> +}
... because I think we should just use a name in the directory where
the tests execute anyway. Other tests do it likewise (e.g. the corefile
tests).
> gdb_test "info spu dma" \
> - "Tag-Group Status.*0x00000000.*Tag-Group Mask.*0x00000000.*Stall-and-Notify.*0x00000000.*Atomic Cmd Status.*0x00000000.*Opcode.*Tag.*TId.*RId.*EA.*LSA.*Size.*LstAddr.*LstSize.*E.*0.*0.*0.*0.*0x00000 0x00000.*" \
> + "Tag-Group Status.*0x00000001.*Tag-Group Mask.*0x00000001.*Stall-and-Notify.*0x00000000.*Atomic Cmd Status.*0x00000000.*Opcode.*Tag.*TId.*RId.*EA.*LSA.*Size.*LstAddr.*LstSize.*E.*0.*0.*0.*0.*0x00000 0x00000.*" \
> "info spu dma (empty)"
> - "Tag-Group Status.*0x00000000.*Tag-Group Mask.*0x00000020.*Stall-and-Notify.*0x00000000.*Atomic Cmd Status.*0x00000000.*Opcode.*Tag.*TId.*RId.*EA.*LSA.*Size.*LstAddr.*LstSize.*E.*getl.*putllc.*get.*mfcsync.*get.*0.*0.*0.*0.*0x00000 0x00000.*" \
> + "Tag-Group Status.*0x00000001.*Tag-Group Mask.*0x00000020.*Stall-and-Notify.*0x00000000.*Atomic Cmd Status.*0x00000000.*Opcode.*Tag.*TId.*RId.*EA.*LSA.*Size.*LstAddr.*LstSize.*E.*getl.*putllc.*get.*mfcsync.*get.*0.*0.*0.*0.*0x00000 0x00000.*" \
> "info spu dma (non-empty)"
This seem to be unrelated changes; are they deliberate?
If so, they need to be mentioned in the ChangeLog.
> +if { [file exists $tmp_file] } then {
> + file delete $tmp_file
> +}
This will not work for remote tests; you should use
remote_file build delete
like e.g. corefile.exp does.
Bye,
Ulrich
--
Dr. Ulrich Weigand
GNU Toolchain for Linux on System z and Cell BE
Ulrich.Weigand@de.ibm.com
prev parent reply other threads:[~2008-07-16 19:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-20 12:23 Markus Deuling
2008-06-24 19:30 ` Ulrich Weigand
2008-06-25 12:43 ` Markus Deuling
2008-07-16 19:29 ` Ulrich Weigand [this message]
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=200807161928.m6GJSR1W006890@d12av02.megacenter.de.ibm.com \
--to=uweigand@de.ibm.com \
--cc=deuling@de.ibm.com \
--cc=gdb-patches@sourceware.org \
/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