Next: __retarget_lock_init
, __retarget_lock_init_recursive
, __retarget_lock_close
, __retarget_lock_close_recursive
, __retarget_lock_acquire
, __retarget_lock_acquire_recursive
, __retarget_lock_try_acquire
, __retarget_lock_try_acquire_recursive
, __retarget_lock_release
, __retarget_lock_release_recursive
—locking routines, Up: Miscellaneous Macros and Functions [Contents][Index]
13.1 ffs
—find first bit set in a word ¶
Synopsis
#include <strings.h>
int ffs(int word);
Description
ffs
returns the first bit set in a word.
Returns
ffs
returns 0 if c is 0, 1 if c is odd, 2 if c is a multiple of
2, etc.
Portability
ffs
is not ANSI C.
No supporting OS subroutines are required.