[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [5592] target-ppc: optimize popcntb
From: |
andrzej zaborowski |
Subject: |
Re: [Qemu-devel] [5592] target-ppc: optimize popcntb |
Date: |
Sat, 1 Nov 2008 14:57:36 +0100 |
2008/11/1 Laurent Desnogues <address@hidden>:
> On Sat, Nov 1, 2008 at 1:29 PM, Laurent Desnogues
> <address@hidden> wrote:
>>
>> Wouldn't it make sense to use builtin's as is done in host-utils.h?
>
> Forget that, I thought it was traditional bit counting.
On ppc host there might be a builtin for it, on the x86 Xeon cpus with
SSE4 there's also a bitcounting instruction but this approach is
actually faster than transferring the number to the MMX register,
running the instruction and copying the value back. In the benchmarks
I've seen the speed is comparable with table lookup on x86 and -O3.
Cheers