From: Andrew Cagney <cagney@gnu.org>
To: Paul Hilfinger <hilfingr@gnat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] Some testcases for long long bitfields
Date: Sun, 28 Nov 2004 17:34:00 -0000 [thread overview]
Message-ID: <41AA0C0B.4040407@gnu.org> (raw)
In-Reply-To: <20041126224912.5BFCF9648@nile.gnat.com>
Paul Hilfinger wrote:
> I believe that the following revision of the bitfields2 test (for
> bitfields in long long fields) addresses Andrew's comments. I have
> tested it on i686 GNU/Linux with GCC 3.2.3. OK?
>
> Some specifics:
>
>
>>- Why? Or is this really a known bug?
>>
>>>+ if $no_signed then {
>>>+ setup_xfail "*-*-*"
>>>+ }
>>>+ set test "set long long signed bitfield negative"
>>>+ gdb_test_multiple "print flags.s2 = -1" $test {
>>>+ -re "warning: Value does not fit.*$gdb_prompt $" {
>>>+ fail "$test"
>>>+ gdb_suppress_tests
>>>+ }
>>>+ -re "= -1.*$gdb_prompt $" {
>>>+ pass "$test"
>>>+ }
>>>+ }
>
>
> Well, this is what bitfields does, which is what I used as a model. On
> reflection, however, it seems to me that XFAIL is inappropriate, since if
> there is a failure here, it is most likely due to the fact the compiler
> being used does not support signed bitfields---that is, a compiler for
> which !defined(__STDC__) && !defined(__cplusplus) and which interprets
> bitfields as unsigned. So it seems that the tests ought to be considered
> unsupported instead, and I have made that change. But that merely changes
> your question to "ARE there any compilers we need worry about with this
> property". I have no idea, but other testcases seem to be written as if
> there are.
True, ok.
>>- delete this:
>>+if [istarget "mips-idt-*"] then {
>>+ # Restart because IDT/SIM runs out of file descriptors.
>>+ gdb_exit
>>+ gdb_start
>>+ gdb_reinitialize_dir $srcdir/$subdir
>>+ gdb_load ${binfile}
>>+}
>
>
> Done. I observe, by the way, that this same code appears in several
> existing tests: bitfields, funcargs, opaque, scope.
>
>
>>perhaps think about what I did for the sig*.exp tests - have main as a
>>loop so that it looped around after each test sequence was finished -
>>will on remote systems improve the performance somewhat. But what ever.
>
>
> OK. I have made a variant of this change that does not use GDB to modify the
> control flow of the program.
Thanks! Ok for commit.
Andrew
next prev parent reply other threads:[~2004-11-28 17:34 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-11-01 11:38 Paul Hilfinger
2004-11-11 20:09 ` Andrew Cagney
2004-11-11 20:32 ` Paul Hilfinger
2004-11-26 22:49 ` Paul Hilfinger
2004-11-28 17:34 ` Andrew Cagney [this message]
2004-11-29 9:22 ` Paul Hilfinger
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=41AA0C0B.4040407@gnu.org \
--to=cagney@gnu.org \
--cc=gdb-patches@sources.redhat.com \
--cc=hilfingr@gnat.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