Statistics
| Branch: | Revision:

root / include / qemu / host-utils.h @ 5a37532d

History | View | Annotate | Download (7.5 kB)

# Date Author Comment
f540166b 02/17/2013 04:28 pm Richard Henderson

host-utils: Use __int128_t for mul[us]64

Replace some x86_64 specific inline assembly with something that
all 64-bit hosts ought to optimize well. At worst this becomes
a call to the gcc __multi3 routine, which is no worse than our
implementation in util/host-utils.c....

72d81155 02/16/2013 01:09 pm Richard Henderson

host-utils: Fix coding style and add comments

Add function comments to the routines, documenting the corner
cases upon which we are standardizing. Fix the few instances
of non-standard coding style.

Signed-off-by: Richard Henderson <>
Reviewed-by: Eric Blake <>...

01654373 02/16/2013 01:09 pm Richard Henderson

host-utils: Add host long specific aliases for clz, ctz, ctpop

We will standardize on these names, rather than the similar routines
currently residing in qemu/bitops.h.

Signed-off-by: Richard Henderson <>
Reviewed-by: Eric Blake <>...

fbeadf50 02/02/2013 10:16 pm Paolo Bonzini

bitops: unify bitops_ffsl with the one in host-utils.h, call it bitops_ctzl

We had two copies of a ffs function for longs with subtly different
semantics and, for the one in bitops.h, a confusing name: the result
was off-by-one compared to the library function ffsl....

4c37ef02 01/25/2013 07:18 pm Paolo Bonzini

host-utils: add ffsl

We can provide fast versions based on the other functions defined
by host-utils.h. Some care is required on glibc, which provides
ffsl already.

Reviewed-by: Eric Blake <>
Signed-off-by: Paolo Bonzini <>...

1de7afc9 12/19/2012 09:32 am Paolo Bonzini

misc: move include files to include/qemu/

Signed-off-by: Paolo Bonzini <>