public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Ian Lance Taylor <ian@airs.com>
To: "Joseph S. Myers" <joseph@codesourcery.com>
Cc: gcc@gcc.gnu.org
Subject: Re: Some tests in gcc.c-torture rely on undefined behaviour?
Date: Tue, 12 Jul 2005 18:39:00 -0000	[thread overview]
Message-ID: <m3r7e3kgx5.fsf@gossamer.airs.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0507121639180.15582@digraph.polyomino.org.uk>

"Joseph S. Myers" <joseph@codesourcery.com> writes:

> Such tests are in general bugs.  You'd have to ask Torbjorn about what the 
> original purpose of the old parts of c-torture was, as that may have 
> differed from the current GCC testsuite, but invalid tests should be 
> removed (or, perhaps better, moved to gcc.c-torture/compile) or have 
> relevant options such as -fwrapv added.

The original purpose was simply to collect programs which caused the
compiler to fail.  When he saw a bug report with a test case, he
collected the test case, reduced it, and added it to the torture
tests.  The tests were simply run at various optimization levels.
Tests which caused the compiler to crash were put in compile, tests
which showed a miscompilation visible at run time were put in execute.

I would guess that 920612-1.c, at least, could just be changed to use
unsigned int, and it would continue to test whatever bug it was
testing when it was originally added.

Ian

  reply	other threads:[~2005-07-12 18:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-12 14:41 Nicholas Nethercote
2005-07-12 16:45 ` Joe Buck
2005-07-12 16:47 ` Joseph S. Myers
2005-07-12 18:39   ` Ian Lance Taylor [this message]
2005-07-12 18:47     ` Diego Novillo
2005-07-12 18:50       ` Ian Lance Taylor
2005-07-13  3:47   ` Nicholas Nethercote
2005-07-13 19:58 ` Robert Dewar

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=m3r7e3kgx5.fsf@gossamer.airs.com \
    --to=ian@airs.com \
    --cc=gcc@gcc.gnu.org \
    --cc=joseph@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).