qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] tcg: fix 16-byte vector operations detection


From: Peter Maydell
Subject: Re: [Qemu-devel] [PATCH] tcg: fix 16-byte vector operations detection
Date: Fri, 6 Apr 2018 10:03:10 +0100

On 5 April 2018 at 21:31, Paolo Bonzini <address@hidden> wrote:
> On 28/03/2018 15:31, Laurent Vivier wrote:
>> configure tries to detect if the compiler
>> supports 16-byte vector operations.
>>
>> As stated in the comment of the detection
>> program, there is a problem with the system
>> compiler on GCC on Centos 7.
>>
>> This program doesn't actually detect the problem
>> with GCC on RHEL7 on PPC64LE (Red Hat 4.8.5-28).
>>
>> This patch updates the test to look more like
>> it is in QEMU helpers, and now detects the problem.
>>
>> The error reported is:
>>
>>   CC      ppc64-softmmu/accel/tcg/tcg-runtime-gvec.o
>>   ..//accel/tcg/tcg-runtime-gvec.c: In function ‘helper_gvec_shl8i’:
>>   ../accel/tcg/tcg-runtime-gvec.c:558:26: internal compiler error: in 
>> emit_move_insn, at expr.c:3495
>>            *(vec8 *)(d + i) = *(vec8 *)(a + i) << shift;
>>                             ^
>> Fixes: db43267 "tcg: Add generic vector expanders"
>> Signed-off-by: Laurent Vivier <address@hidden>
>> ---
>>  configure | 8 ++++++++
>>  1 file changed, 8 insertions(+)
>>
>> diff --git a/configure b/configure
>> index 4d0e92c96c..a2301dd0dc 100755
>> --- a/configure
>> +++ b/configure
>> @@ -5054,6 +5054,14 @@ static S2 c2;
>>  static S4 c4;
>>  static S8 c8;
>>  static int i;
>> +void helper(void *d, void *a, int shift, int i);
>> +void helper(void *d, void *a, int shift, int i)
>> +{
>> +  *(U1 *)(d + i) = *(U1 *)(a + i) << shift;
>> +  *(U2 *)(d + i) = *(U2 *)(a + i) << shift;
>> +  *(U4 *)(d + i) = *(U4 *)(a + i) << shift;
>> +  *(U8 *)(d + i) = *(U8 *)(a + i) << shift;
>> +}
>>  int main(void)
>>  {
>>    a1 += b1; a2 += b2; a4 += b4; a8 += b8;
>>
>
> Queued, thanks.

This is already in master...

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]