History | View | Annotate | Download (7.5 kB)
host-utils: Use __int128_t for mul[us]64
Replace some x86_64 specific inline assembly with something thatall 64-bit hosts ought to optimize well. At worst this becomesa call to the gcc __multi3 routine, which is no worse than ourimplementation in util/host-utils.c....
host-utils: Fix coding style and add comments
Add function comments to the routines, documenting the cornercases upon which we are standardizing. Fix the few instancesof non-standard coding style.
Signed-off-by: Richard Henderson <rth@twiddle.net>Reviewed-by: Eric Blake <eblake@redhat.com>...
host-utils: Add host long specific aliases for clz, ctz, ctpop
We will standardize on these names, rather than the similar routinescurrently residing in qemu/bitops.h.
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 differentsemantics and, for the one in bitops.h, a confusing name: the resultwas off-by-one compared to the library function ffsl....
host-utils: add ffsl
We can provide fast versions based on the other functions definedby host-utils.h. Some care is required on glibc, which providesffsl already.
Reviewed-by: Eric Blake <eblake@redhat.com>Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>...
misc: move include files to include/qemu/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>