qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Mips 64 emulation not compiling


From: J. Mayer
Subject: Re: [Qemu-devel] Mips 64 emulation not compiling
Date: Sat, 27 Oct 2007 16:12:50 +0200

On Sat, 2007-10-27 at 15:27 +0200, Christian "Eddie" Dost wrote:
> The sparc64 popc works in O(lg(n))

No, it has a fix cost, whatever the operand is.
It has another advantage: it does not need any intermediate variable,
which is great when running on CISC host in the Qemu execution
environmnent.

> , the "optimized" code below work in 
> O(n).

Yes. But it's false.... It shoudl be val &= val - 1
instead of val  ^= val - 1...

[...]

I did tests on my PC, which will imho close the debate: the Sparc
implementation is at least 50 % faster. I did generate 2 ^ 29 random
numbers to achieve this test (and checked that the repartition was OK).

-- 
J. Mayer <address@hidden>
Never organized





reply via email to

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