[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] bitops: provide an inline implementation of fin
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH] bitops: provide an inline implementation of find_first_bit |
Date: |
Sun, 22 Dec 2013 09:04:27 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 |
On 12/22/2013 03:32 AM, Aurelien Jarno wrote:
> find_first_bit has started to be used heavily in TCG code. The current
> implementation based on find_next_bit is not optimal and can't be
> optimized be the compiler if the bit array has a fixed size, which is
> the case most of the time.
>
> This new implementation does not use find_next_bit and is yet small
> enough to be inlined.
>
> Cc: Richard Henderson <address@hidden>
> Cc: Corentin Chary <address@hidden>
>
> Signed-off-by: Aurelien Jarno <address@hidden>
> ---
> include/qemu/bitops.h | 12 +++++++++++-
> 1 file changed, 11 insertions(+), 1 deletion(-)
Reviewed-by: Richard Henderson <address@hidden>
r~