qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v1 09/41] s390x/tcg: Implement VECTOR CHECKSUM


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH v1 09/41] s390x/tcg: Implement VECTOR CHECKSUM
Date: Mon, 15 Apr 2019 23:08:32 -1000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1

On 4/15/19 10:58 PM, David Hildenbrand wrote:
>> You could use
>>
>>   tcg_gen_add2_i32(sum, tmp, sum, zero, tmp, zero);
>>   tcg_gen_add_i32(sum, sum, tmp);
> That makes perfect sense, I will use that for now, thanks!
> 

Here's a funny one.  We can do this in one operation:

  tcg_gen_add2_i32(tmp, sum, sum, sum, tmp, tmp);

The lower (sum+tmp) carries into the upper (sum+tmp).
We take the upper result and discard the lower.


r~



reply via email to

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