diff mbox series

[v2,3/3] tests/tcg: disable enterN insn tests for test-i386 with clang

Message ID 20181009145933.18925-4-alex.bennee@linaro.org
State New
Headers show
Series Travis tweaks and tcg test fixes | expand

Commit Message

Alex Bennée Oct. 9, 2018, 2:59 p.m. UTC
The enter[qwl] instructions aren't supported by clang's inline
assembler. Apply the hammer to work around it when we re-use our
system compiler to build tcg tests.

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
---
 tests/tcg/i386/test-i386.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Paolo Bonzini Oct. 9, 2018, 3:48 p.m. UTC | #1
On 09/10/2018 16:59, Alex Bennée wrote:
> The enter[qwl] instructions aren't supported by clang's inline
> assembler. Apply the hammer to work around it when we re-use our
> system compiler to build tcg tests.
> 
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>

Do you have a bug for this in llvm?  It doesn't seem to be a good idea.

Paolo

> ---
>  tests/tcg/i386/test-i386.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/tests/tcg/i386/test-i386.c b/tests/tcg/i386/test-i386.c
> index c5f67000e4..da632c9b67 100644
> --- a/tests/tcg/i386/test-i386.c
> +++ b/tests/tcg/i386/test-i386.c
> @@ -2098,6 +2098,7 @@ long enter_stack[4096];
>  
>  static void test_enter(void)
>  {
> +#if !(defined __clang__)
>  #if defined(__x86_64__)
>      TEST_ENTER("q", uint64_t, 0);
>      TEST_ENTER("q", uint64_t, 1);
> @@ -2114,6 +2115,7 @@ static void test_enter(void)
>      TEST_ENTER("w", uint16_t, 1);
>      TEST_ENTER("w", uint16_t, 2);
>      TEST_ENTER("w", uint16_t, 31);
> +#endif
>  }
>  
>  #ifdef TEST_SSE
>
Alex Bennée Oct. 9, 2018, 4:35 p.m. UTC | #2
Paolo Bonzini <pbonzini@redhat.com> writes:

> On 09/10/2018 16:59, Alex Bennée wrote:
>> The enter[qwl] instructions aren't supported by clang's inline
>> assembler. Apply the hammer to work around it when we re-use our
>> system compiler to build tcg tests.
>>
>> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
>
> Do you have a bug for this in llvm?  It doesn't seem to be a good
> idea.

I thought I had an llvm bugzilla login but I can't find the details.
I'll have to a wait until an admin can add me.

>
> Paolo
>
>> ---
>>  tests/tcg/i386/test-i386.c | 2 ++
>>  1 file changed, 2 insertions(+)
>>
>> diff --git a/tests/tcg/i386/test-i386.c b/tests/tcg/i386/test-i386.c
>> index c5f67000e4..da632c9b67 100644
>> --- a/tests/tcg/i386/test-i386.c
>> +++ b/tests/tcg/i386/test-i386.c
>> @@ -2098,6 +2098,7 @@ long enter_stack[4096];
>>
>>  static void test_enter(void)
>>  {
>> +#if !(defined __clang__)
>>  #if defined(__x86_64__)
>>      TEST_ENTER("q", uint64_t, 0);
>>      TEST_ENTER("q", uint64_t, 1);
>> @@ -2114,6 +2115,7 @@ static void test_enter(void)
>>      TEST_ENTER("w", uint16_t, 1);
>>      TEST_ENTER("w", uint16_t, 2);
>>      TEST_ENTER("w", uint16_t, 31);
>> +#endif
>>  }
>>
>>  #ifdef TEST_SSE
>>


--
Alex Bennée
diff mbox series

Patch

diff --git a/tests/tcg/i386/test-i386.c b/tests/tcg/i386/test-i386.c
index c5f67000e4..da632c9b67 100644
--- a/tests/tcg/i386/test-i386.c
+++ b/tests/tcg/i386/test-i386.c
@@ -2098,6 +2098,7 @@  long enter_stack[4096];
 
 static void test_enter(void)
 {
+#if !(defined __clang__)
 #if defined(__x86_64__)
     TEST_ENTER("q", uint64_t, 0);
     TEST_ENTER("q", uint64_t, 1);
@@ -2114,6 +2115,7 @@  static void test_enter(void)
     TEST_ENTER("w", uint16_t, 1);
     TEST_ENTER("w", uint16_t, 2);
     TEST_ENTER("w", uint16_t, 31);
+#endif
 }
 
 #ifdef TEST_SSE