[cfe-commits] r132319 - in /cfe/trunk/test: Makefile Unit/lit.site.cfg.in lit.site.cfg.in

Galina Kistanova gkistanova at gmail.com
Wed Jun 1 17:45:07 PDT 2011


Hello,

For some reason I havn't received notifications from the cfe-commits
list and almost missed this discussion. Sorry.

> > What's the intended use of this? What problem are you solving?

As Eli has pointed, some tests depend on a particular target to be
supported by the backend, which is not always the case. Such tests
should be effectively excluded (one way or another). We should not
force people to support all possible backends just to get tests pass.

> Any reason something like XTARGET won't work here?

XTARGET won't work nicely here because it marks a test as pass for
listed platforms. In this particular case, all targets except X86
should be listed (effectively * will be used) in the XTARGET
statement. I don't think this is a good idea. Having these tests
"pass" is not a good idea either, they must be "unsupported" which
they actually are.

If some test is platform-specific for a reason, it should be taged as such.
I have been thinking of extending REQUIRES statement for this purpose
or adding a new DEPENDS one, but it is not there yet.

My current goal was to separate the existing platform-specific tests
from generic, and start this discussion. The suggested approach is not
very elegant, but we have the same tests directory structure in llvm,
and it seems doing its job.

Thanks

Galina



On Wed, Jun 1, 2011 at 3:47 PM, Douglas Gregor <dgregor at apple.com> wrote:
>
> On May 31, 2011, at 12:05 AM, Chandler Carruth wrote:
>
>> On Mon, May 30, 2011 at 10:18 PM, Eli Friedman <eli.friedman at gmail.com> wrote:
>>> On Mon, May 30, 2011 at 9:36 PM, Chandler Carruth <chandlerc at google.com> wrote:
>>>> On Mon, May 30, 2011 at 5:29 PM, Galina Kistanova <gkistanova at gmail.com> wrote:
>>>>> Preparations for separating target-specific clang tests.
>>>>
>>>> What's the intended use of this? What problem are you solving? We
>>>> already have the ability to use target-specific triples in tests.
>>>
>>> I assume this is intended to fix cases where clang tests try to
>>> generate x86 code... we have maybe 50 or so clang tests which do that.
>>>  If you try to build without the x86 backend (e.g. on ARM), the tests
>>> fail with "error: unable to create target: 'No available targets are
>>> compatible with this triple, see -version for the available
>>> targets.'".  See
>>> http://google1.osuosl.org:8011/builders/clang-native-arm-cortex-a9 .
>>
>> Any reason something like XTARGET won't work here? I'm not terribly
>> familiar with how that's implemented I admit, it just seems nicer than
>> a whole separate tree.
>>
>> Also, I thought these tests were essentially on the way out in favor
>> of directly testing the LLVM IR whenever possible. I can imagine a few
>> needing to remain, but hopefully few enough to make a whole separate
>> tree unnecessary... But maybe I'm just not thinking of the particular
>> architecture-specific things needing testing.
>
>
> We do prefer to use architecture-independent IR for our tests wherever possible, and have tried to replace assembly-checking tests with IR tests whenever possible.
>
>        - Doug
>




More information about the cfe-commits mailing list