|
static uword | clib_bitmap_is_zero (uword *ai) |
| predicate function; is an entire bitmap empty? More...
|
|
static uword | clib_bitmap_is_equal (uword *a, uword *b) |
| predicate function; are two bitmaps equal? More...
|
|
static uword | clib_bitmap_set_no_check (uword *a, uword i, uword new_value) |
| Sets the ith bit of a bitmap to new_value. More...
|
|
static uword * | clib_bitmap_set (uword *ai, uword i, uword value) |
| Sets the ith bit of a bitmap to new_value Removes trailing zeros from the bitmap. More...
|
|
static uword | clib_bitmap_get (uword *ai, uword i) |
| Gets the ith bit value from a bitmap. More...
|
|
static uword | clib_bitmap_get_no_check (uword *ai, uword i) |
| Gets the ith bit value from a bitmap Does not sanity-check the bit position. More...
|
|
static uword | clib_bitmap_get_multiple_no_check (uword *ai, uword i, uword n_bits) |
|
static uword | clib_bitmap_get_multiple (uword *bitmap, uword i, uword n_bits) |
| Gets the ith through ith + n_bits bit values from a bitmap. More...
|
|
static uword * | clib_bitmap_set_multiple (uword *bitmap, uword i, uword value, uword n_bits) |
| sets the ith through ith + n_bits bits in a bitmap More...
|
|
static uword * | clfib_bitmap_set_region (uword *bitmap, uword i, uword value, uword n_bits) |
|
static uword | clib_bitmap_first_set (uword *ai) |
| Return the lowest numbered set bit in a bitmap. More...
|
|
static uword | clib_bitmap_last_set (uword *ai) |
| Return the higest numbered set bit in a bitmap. More...
|
|
static uword | clib_bitmap_first_clear (uword *ai) |
| Return the lowest numbered clear bit in a bitmap. More...
|
|
static uword | clib_bitmap_count_set_bits (uword *ai) |
| Return the number of set bits in a bitmap. More...
|
|
static uword * | clib_bitmap_and (uword *ai, uword *bi) |
| Logical operator across two bitmaps. More...
|
|
static uword * | clib_bitmap_andnot (uword *ai, uword *bi) |
| Logical operator across two bitmaps. More...
|
|
static uword * | clib_bitmap_or (uword *ai, uword *bi) |
| Logical operator across two bitmaps. More...
|
|
static uword * | clib_bitmap_xor (uword *ai, uword *bi) |
| Logical operator across two bitmaps. More...
|
|
static uword * | clib_bitmap_dup_and (uword *ai, uword *bi) |
| Logical operator across two bitmaps which duplicates the first bitmap. More...
|
|
static uword * | clib_bitmap_dup_andnot (uword *ai, uword *bi) |
| Logical operator across two bitmaps which duplicates the first bitmap. More...
|
|
static uword * | clib_bitmap_dup_or (uword *ai, uword *bi) |
| Logical operator across two bitmaps which duplicates the first bitmap. More...
|
|
static uword * | clib_bitmap_dup_xor (uword *ai, uword *bi) |
| Logical operator across two bitmaps which duplicates the first bitmap. More...
|
|
static uword * | clib_bitmap_random (uword *ai, uword n_bits, u32 *seed) |
| Return a random bitmap of the requested length. More...
|
|
static uword | clib_bitmap_next_set (uword *ai, uword i) |
| Return the next set bit in a bitmap starting at bit i. More...
|
|
static uword | clib_bitmap_next_clear (uword *ai, uword i) |
| Return the next clear bit in a bitmap starting at bit i. More...
|
|
static uword | unformat_bitmap_list (unformat_input_t *input, va_list *va) |
| unformat a list of bit ranges into a bitmap (eg "0-3,5-7,11" ) More...
|
|
static u8 * | format_bitmap_hex (u8 *s, va_list *args) |
| Format a bitmap as a string of hex bytes. More...
|
|
Bitmaps built as vectors of machine words.
Definition in file bitmap.h.
static u8* format_bitmap_hex |
( |
u8 * |
s, |
|
|
va_list * |
args |
|
) |
| |
|
inlinestatic |
Format a bitmap as a string of hex bytes.
uword * bitmap; s = format ("%U", format_bitmap_hex, bitmap);
Standard format_function_t arguments
- Parameters
-
s | - string under construction |
args | - varargs list comprising a single uword * |
- Returns
- string under construction
Definition at line 744 of file bitmap.h.
unformat a list of bit ranges into a bitmap (eg "0-3,5-7,11" )
uword * bitmap; rv = unformat ("%U", unformat_bitmap_list, &bitmap);
Standard unformat_function_t arguments
- Parameters
-
input | - pointer an unformat_input_t |
va | - varargs list comprising a single uword ** |
- Returns
- 1 on success, 0 on failure
Definition at line 693 of file bitmap.h.