This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
RFC: Change rules for adding/changing test cases
- From: DJ Delorie <dj at redhat dot com>
- To: gcc at gcc dot gnu dot org
- Date: Tue, 19 Mar 2002 16:21:31 -0500
- Subject: RFC: Change rules for adding/changing test cases
Given that the preprocessor is integrated into cc1, and that there are
more and more people helping with gcc, and more and more ports to new
chips, I would like to propose changing the rules for approving new
test cases and maintaining old ones as follows:
All test cases must have comments indicating what type of failure
they are testing (i.e. the conditions that indicated the need for a
test case, location of the abort, whatever), and when fixed,
comments indicating what/how it was fixed.
This way, if a new port sees a failure in a specific test, the porter
can read the comments to see if they've repeated that mistake in their
port, and thus correct the bug quickly.
So I see these three cases:
1. New testcase for a bug that's not yet fixed. Should include a
comment saying what failure was seen in gcc (like "caused abort in
foo.c:bar() on for blat-elf"). That way, if someone wants to fix
the bug, they can reproduce the original bug easily, rather than
hunting for a failure and perhaps tripping over some unrelated
failure and missing the original one.
2. New testcase for a recently fixed bug. Should include a comment as
in #1, and one saying how it was fixed (like "caused by wrong
constraints in addsi3 for foo-elf chip").
3. Fix a bug tested by an existing testcase. Should add comment to
existing testcase as in #2 above, even if there's already a comment
or two in there (assuming it's saying something new).
This way, each testcase will contain a history of how people dealt
with that failure, so that others won't have to search the mail
archives or web to try to figure out what a given failure means.