-/* Perform an operation on two bitmaps, yielding a third. */
-extern int bitmap_operation (bitmap, bitmap, bitmap, enum bitmap_bits);
-
-#define bitmap_and(DST,A,B) (void)bitmap_operation (DST,A,B,BITMAP_AND)
-#define bitmap_and_into(DST_SRC,B) (void)bitmap_operation (DST_SRC,DST_SRC,B,BITMAP_AND)
-#define bitmap_and_compl(DST,A,B) (void)bitmap_operation (DST,A,B,BITMAP_AND_COMPL)
-#define bitmap_and_compl_into(DST_SRC,B) (void)bitmap_operation (DST_SRC,DST_SRC,B,BITMAP_AND_COMPL)
-#define bitmap_ior(DST,A,B) (void)bitmap_operation (DST,A,B,BITMAP_IOR)
-#define bitmap_ior_into(DST_SRC,B) (void)bitmap_operation (DST_SRC,DST_SRC,B,BITMAP_IOR)
-#define bitmap_ior_compl(DST,A,B) (void)bitmap_operation (DST,A,Br,BITMAP_IOR_COMPL)
-#define bitmap_xor(DST,A,B) (void)bitmap_operation (DST,A,B,BITMAP_XOR)
-#define bitmap_xor_into(DST_SRC,B) (void)bitmap_operation (DST_SRC,DST_SRC,B,BITMAP_XOR)
-
-/* `or' into one bitmap the `and' of a second bitmap witih the complement
- of a third. Return nonzero if the bitmap changes. */
-extern bool bitmap_ior_and_compl_into (bitmap, bitmap, bitmap);
-extern bool bitmap_ior_and_compl (bitmap, bitmap, bitmap, bitmap);
-
-/* Clear a single register in a register set. */
-extern void bitmap_clear_bit (bitmap, int);
-
-/* Set a single register in a register set. */
-extern void bitmap_set_bit (bitmap, int);
+/* True if the bitmap has only a single bit set. */
+extern bool bitmap_single_bit_set_p (const_bitmap);
+
+/* Count the number of bits set in the bitmap. */
+extern unsigned long bitmap_count_bits (const_bitmap);
+
+/* Boolean operations on bitmaps. The _into variants are two operand
+ versions that modify the first source operand. The other variants
+ are three operand versions that to not destroy the source bitmaps.
+ The operations supported are &, & ~, |, ^. */
+extern void bitmap_and (bitmap, const_bitmap, const_bitmap);
+extern void bitmap_and_into (bitmap, const_bitmap);
+extern bool bitmap_and_compl (bitmap, const_bitmap, const_bitmap);
+extern bool bitmap_and_compl_into (bitmap, const_bitmap);
+#define bitmap_compl_and(DST, A, B) bitmap_and_compl (DST, B, A)
+extern void bitmap_compl_and_into (bitmap, const_bitmap);
+extern void bitmap_clear_range (bitmap, unsigned int, unsigned int);
+extern void bitmap_set_range (bitmap, unsigned int, unsigned int);
+extern bool bitmap_ior (bitmap, const_bitmap, const_bitmap);
+extern bool bitmap_ior_into (bitmap, const_bitmap);
+extern void bitmap_xor (bitmap, const_bitmap, const_bitmap);
+extern void bitmap_xor_into (bitmap, const_bitmap);
+
+/* DST = A | (B & C). Return true if DST changes. */
+extern bool bitmap_ior_and_into (bitmap DST, const_bitmap B, const_bitmap C);
+/* DST = A | (B & ~C). Return true if DST changes. */
+extern bool bitmap_ior_and_compl (bitmap DST, const_bitmap A, const_bitmap B, const_bitmap C);
+/* A |= (B & ~C). Return true if A changes. */
+extern bool bitmap_ior_and_compl_into (bitmap DST, const_bitmap B, const_bitmap C);
+
+/* Clear a single bit in a bitmap. Return true if the bit changed. */
+extern bool bitmap_clear_bit (bitmap, int);
+
+/* Set a single bit in a bitmap. Return true if the bit changed. */
+extern bool bitmap_set_bit (bitmap, int);