Re: Test Code for C-like Compilers

Ian Lance Taylor <ian@airs.com>
Sun, 15 Mar 2009 11:46:08 -0700

          From comp.compilers

Related articles
Test Code for C-like Compilers jmensch@shaw.ca (Julian Mensch) (2009-03-08)
Re: Test Code for C-like Compilers kamalpr@hp.com (kamal) (2009-03-14)
Re: Test Code for C-like Compilers ian@airs.com (Ian Lance Taylor) (2009-03-15)
| List of all articles for this month |
From: Ian Lance Taylor <ian@airs.com>
Newsgroups: comp.compilers
Date: Sun, 15 Mar 2009 11:46:08 -0700
Organization: Compilers Central
References: 09-03-041 09-03-060
Keywords: testing
Posted-Date: 15 Mar 2009 16:59:55 EDT

kamal <kamalpr@hp.com> writes:


> Julian Mensch wrote:
>>
>> I was wondering if anyone here knows of some good, publicly
>> available test code for C-like compilers -- samples designed to catch
>> and point out subtle bugs in compilers like operator precedence
>> glitches, subtle unexpected behavior with control flow, etc. Anyone
>> can throw together some simple code tests, but I'm wondering if anyone
>
> This will do the job for you -but it is not publicly available, nor
> are other competing products.
>
> http://www.peren.com/pages/cvsa_set.htm
> [The regression suite for gcc is probably the best you can do for free. -John]


Probably true, although, as a gcc developer, I have to say that the
gcc regression suite is not very good as a general compiler testsuite.
It is an excellent record of bugs found and fixed in gcc, and it has
good support for testing the details of some of gcc's command line
options. However, it's fairly bad at identifying subtle code
generation problems. When I'm modifying gcc, I fairly often find that
a patch will pass the testsuite but will fail when bootstrapping gcc.


Ian



Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.