<div dir="ltr">We generally use compiler-rt tests to test the end-to-end behavior, so it makes sense to test the different ways the report can trigger.</div><br><div class="gmail_quote"><div dir="ltr">On Mon, Jan 14, 2019 at 11:11 PM Roman Lebedev <<a href="mailto:lebedev.ri@gmail.com">lebedev.ri@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Tue, Jan 15, 2019 at 6:48 AM Vlad Tsyrklevich <<a href="mailto:vlad@tsyrklevich.net" target="_blank">vlad@tsyrklevich.net</a>> wrote:<br>
><br>
> Hi Roman, unfortunately '*' is not handled for UNSUPPORTED like it is for XFAIL.<br>
Oh well, good to know i suppose :)<br>
I guess i should have simply deleted those two tests instead.<br>
<br>
> I considered submitting the change below but don't have time to investigate how to write an appropriate test for lit. At first I submitted a change to make the UNSUPPORTED an XFAIL but realized the semantics are different. I've reverted your changes in r351159.<br>
Thanks.<br>
I'll change the testing approach like i wondered in the commit message<br>
and resubmit, hopefully that will do it.<br>
<br>
Also, i'm not quite sure what these compiler-rt tests should be testing.<br>
It is my belief that they should only be testing the handler itself,<br>
so testing the every way it can be triggered is not really necessary.<br>
<br>
> --- a/llvm/utils/lit/lit/Test.py<br>
> +++ b/llvm/utils/lit/lit/Test.py<br>
> @@ -345,6 +345,10 @@ class Test:<br>
>          triple = getattr(self.suite.config, 'target_triple', "")<br>
><br>
>          try:<br>
> +            # If this is the wildcard, it's always unsupported.<br>
> +            if item == '*':<br>
> +                return ['*']<br>
> +<br>
>              return [item for item in self.unsupported<br>
>                      if BooleanExpression.evaluate(item, features, triple)]<br>
>          except ValueError as e:<br>
<br>
Roman.<br>
<br>
> On Mon, Jan 14, 2019 at 2:48 PM Roman Lebedev via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>> wrote:<br>
>><br>
>> Author: lebedevri<br>
>> Date: Mon Jan 14 14:44:19 2019<br>
>> New Revision: 351134<br>
>><br>
>> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=351134&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=351134&view=rev</a><br>
>> Log:<br>
>> [compiler-rt] UBSan: just completely disable two alignment-assumption tests for now.<br>
>><br>
>> And they are faling on clang-cmake-armv7-full too.<br>
>> *ONLY* these two.<br>
>> I'm not sure what to make of it.<br>
>><br>
>> Perhaps doing a malloc and checking that pointer will<br>
>> make them fail as expected?<br>
>><br>
>> Modified:<br>
>>     compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function-variable.cpp<br>
>>     compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function.cpp<br>
>><br>
>> Modified: compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function-variable.cpp<br>
>> URL: <a href="http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function-variable.cpp?rev=351134&r1=351133&r2=351134&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function-variable.cpp?rev=351134&r1=351133&r2=351134&view=diff</a><br>
>> ==============================================================================<br>
>> --- compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function-variable.cpp (original)<br>
>> +++ compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function-variable.cpp Mon Jan 14 14:44:19 2019<br>
>> @@ -1,7 +1,5 @@<br>
>> -// FIXME: <a href="https://code.google.com/p/address-sanitizer/issues/detail?id=316" rel="noreferrer" target="_blank">https://code.google.com/p/address-sanitizer/issues/detail?id=316</a><br>
>> -// I'm not sure this is actually *that* issue, but this seems oddly similar to the other XFAIL'ed cases.<br>
>> -// UNSUPPORTED: android<br>
>> -// UNSUPPORTED: ios<br>
>> +// FIXME: Fails on android, armv7. Not sure what is going on.<br>
>> +// UNSUPPORTED: *<br>
>><br>
>>  // RUN: %clang   -x c   -fsanitize=alignment -O0 %s -o %t && %run %t 2>&1 | FileCheck %s --implicit-check-not=" assumption " --implicit-check-not="note:" --implicit-check-not="error:"<br>
>>  // RUN: %clang   -x c   -fsanitize=alignment -O1 %s -o %t && %run %t 2>&1 | FileCheck %s --implicit-check-not=" assumption " --implicit-check-not="note:" --implicit-check-not="error:"<br>
>><br>
>> Modified: compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function.cpp<br>
>> URL: <a href="http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function.cpp?rev=351134&r1=351133&r2=351134&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function.cpp?rev=351134&r1=351133&r2=351134&view=diff</a><br>
>> ==============================================================================<br>
>> --- compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function.cpp (original)<br>
>> +++ compiler-rt/trunk/test/ubsan/TestCases/Pointer/alignment-assumption-attribute-alloc_align-on-function.cpp Mon Jan 14 14:44:19 2019<br>
>> @@ -1,7 +1,5 @@<br>
>> -// FIXME: <a href="https://code.google.com/p/address-sanitizer/issues/detail?id=316" rel="noreferrer" target="_blank">https://code.google.com/p/address-sanitizer/issues/detail?id=316</a><br>
>> -// I'm not sure this is actually *that* issue, but this seems oddly similar to the other XFAIL'ed cases.<br>
>> -// UNSUPPORTED: android<br>
>> -// UNSUPPORTED: ios<br>
>> +// FIXME: Fails on android, armv7. Not sure what is going on.<br>
>> +// UNSUPPORTED: *<br>
>><br>
>>  // RUN: %clang   -x c   -fsanitize=alignment -O0 %s -o %t && %run %t 2>&1 | FileCheck %s --implicit-check-not=" assumption " --implicit-check-not="note:" --implicit-check-not="error:"<br>
>>  // RUN: %clang   -x c   -fsanitize=alignment -O1 %s -o %t && %run %t 2>&1 | FileCheck %s --implicit-check-not=" assumption " --implicit-check-not="note:" --implicit-check-not="error:"<br>
>><br>
>><br>
>> _______________________________________________<br>
>> llvm-commits mailing list<br>
>> <a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
>> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</a><br>
</blockquote></div>