disable unittest on specific targets (broken buildbots)

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

disable unittest on specific targets (broken buildbots)

David Blaikie via cfe-dev
Hi,

I have a commit which breaks a unittest (gtest and not a lit test) on
certain platforms/buildbots: clang-ppc64be-linux,
clang-x64-windows-msvc.
Those platforms do not support the calling conventions used in the test:
```
[==========] 1 test from 1 test case ran. (45 ms total)
[  PASSED  ] 0 tests.
[  FAILED  ] 1 test, listed below:
[  FAILED  ] StructuralEquivalenceFunctionTest.FunctionsWithDifferentCallingConventions

 1 FAILED TEST
input.cc:1:16: warning: calling convention 'fastcall' ignored for this
target [-Wignored-attributes]
__attribute__((fastcall)) void foo();
               ^
input.cc:1:16: warning: calling convention 'ms_abi' ignored for this
target [-Wignored-attributes]
__attribute__((ms_abi))   void foo();
               ^
```

Is there a way to disable a unittest on these platforms?
I am thinking about #ifndef ppc and #ifndef windows ... is there such
defines available?

Many thanks,
Gabor
_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: disable unittest on specific targets (broken buildbots)

David Blaikie via cfe-dev
I am going to use this if there are no objections:
 #if  defined(__x86_64__) && defined(__linux__)
// tests here
#endif

On Thu, Jan 24, 2019 at 4:20 PM Gábor Márton <[hidden email]> wrote:

>
> Hi,
>
> I have a commit which breaks a unittest (gtest and not a lit test) on
> certain platforms/buildbots: clang-ppc64be-linux,
> clang-x64-windows-msvc.
> Those platforms do not support the calling conventions used in the test:
> ```
> [==========] 1 test from 1 test case ran. (45 ms total)
> [  PASSED  ] 0 tests.
> [  FAILED  ] 1 test, listed below:
> [  FAILED  ] StructuralEquivalenceFunctionTest.FunctionsWithDifferentCallingConventions
>
>  1 FAILED TEST
> input.cc:1:16: warning: calling convention 'fastcall' ignored for this
> target [-Wignored-attributes]
> __attribute__((fastcall)) void foo();
>                ^
> input.cc:1:16: warning: calling convention 'ms_abi' ignored for this
> target [-Wignored-attributes]
> __attribute__((ms_abi))   void foo();
>                ^
> ```
>
> Is there a way to disable a unittest on these platforms?
> I am thinking about #ifndef ppc and #ifndef windows ... is there such
> defines available?
>
> Many thanks,
> Gabor
_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: disable unittest on specific targets (broken buildbots)

David Blaikie via cfe-dev
In reply to this post by David Blaikie via cfe-dev
For such a target-specific calling convention, I would recommending arranging for the test to use a fixed target, instead of whatever the host target is.

On Thu, Jan 24, 2019 at 7:21 AM Gábor Márton via cfe-dev <[hidden email]> wrote:
Hi,

I have a commit which breaks a unittest (gtest and not a lit test) on
certain platforms/buildbots: clang-ppc64be-linux,
clang-x64-windows-msvc.
Those platforms do not support the calling conventions used in the test:
```
[==========] 1 test from 1 test case ran. (45 ms total)
[  PASSED  ] 0 tests.
[  FAILED  ] 1 test, listed below:
[  FAILED  ] StructuralEquivalenceFunctionTest.FunctionsWithDifferentCallingConventions

 1 FAILED TEST
input.cc:1:16: warning: calling convention 'fastcall' ignored for this
target [-Wignored-attributes]
__attribute__((fastcall)) void foo();
               ^
input.cc:1:16: warning: calling convention 'ms_abi' ignored for this
target [-Wignored-attributes]
__attribute__((ms_abi))   void foo();
               ^
```

Is there a way to disable a unittest on these platforms?
I am thinking about #ifndef ppc and #ifndef windows ... is there such
defines available?

Many thanks,
Gabor
_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev

_______________________________________________
cfe-dev mailing list
[hidden email]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev