Patchwork [04/10] bitops: Use non-bitops ctzl

login
register
mail settings
Submitter Richard Henderson
Date Feb. 14, 2013, 1:47 a.m.
Message ID <1360806463-23632-5-git-send-email-rth@twiddle.net>
Download mbox | patch
Permalink /patch/220347/
State New
Headers show

Comments

Richard Henderson - Feb. 14, 2013, 1:47 a.m.
The use of ctz has already eliminated zero, and thus the difference
in edge conditions between the two routines is irrelevant.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 util/bitops.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/util/bitops.c b/util/bitops.c
index 7b853cf..9cd1c3a 100644
--- a/util/bitops.c
+++ b/util/bitops.c
@@ -60,7 +60,7 @@  found_first:
         return result + size;	/* Nope. */
     }
 found_middle:
-    return result + bitops_ctzl(tmp);
+    return result + ctzl(tmp);
 }
 
 /*