#line 2 "../src/kernel/none/bfffo.h"
#if !defined(INLINE)
extern int bfffo(ulong x);
#else
#if defined(__GNUC__) && !defined(DISABLE_INLINE)
#ifdef LONG_IS_64BIT
# define bfffo(x) \
__extension__ ({ \
static int __bfffo_tabshi[16]={4,3,2,2,1,1,1,1,0,0,0,0,0,0,0,0};\
int __value = BITS_IN_LONG - 4; \
ulong __arg1=(x); \
if (__arg1 & ~0xffffffffUL) {__value -= 32; __arg1 >>= 32;}\
if (__arg1 & ~0xffffUL) {__value -= 16; __arg1 >>= 16;} \
if (__arg1 & ~0x00ffUL) {__value -= 8; __arg1 >>= 8;} \
if (__arg1 & ~0x000fUL) {__value -= 4; __arg1 >>= 4;} \
__value + __bfffo_tabshi[__arg1]; \
})
#else
# define bfffo(x) \
__extension__ ({ \
static int __bfffo_tabshi[16]={4,3,2,2,1,1,1,1,0,0,0,0,0,0,0,0};\
int __value = BITS_IN_LONG - 4; \
ulong __arg1=(x); \
if (__arg1 & ~0xffffUL) {__value -= 16; __arg1 >>= 16;} \
if (__arg1 & ~0x00ffUL) {__value -= 8; __arg1 >>= 8;} \
if (__arg1 & ~0x000fUL) {__value -= 4; __arg1 >>= 4;} \
__value + __bfffo_tabshi[__arg1]; \
})
#endif
#else
INLINE int
bfffo(ulong x)
{
static int tabshi[16]={4,3,2,2,1,1,1,1,0,0,0,0,0,0,0,0};
int value = BITS_IN_LONG - 4;
ulong arg1=x;
#ifdef LONG_IS_64BIT
if (arg1 & ~0xffffffffUL) {value -= 32; arg1 >>= 32;}
#endif
if (arg1 & ~0xffffUL) {value -= 16; arg1 >>= 16;}
if (arg1 & ~0x00ffUL) {value -= 8; arg1 >>= 8;}
if (arg1 & ~0x000fUL) {value -= 4; arg1 >>= 4;}
return value + tabshi[arg1];
}
#endif
#endif